index-def4825d.js 5.7 KB

1
  1. import{d as Q,H as W,r as m,x as X,b as j,a1 as I,o as s,c as T,f as e,B as o,a as t,F as Y,P as J,A as c,a2 as V,G as u,l as _,Q as Z,R as $,S as ee,a6 as ae,K as le,_ as te,L as oe,U as re,V as pe,W as se,X as ie}from"./index-bf9ff227.js";import{_ as de}from"./index.vue_vue_type_script_setup_true_lang-d90f8b28.js";import{_ as ne}from"./DictTag.vue_vue_type_script_lang-a9dd3e98.js";import{_ as me}from"./ContentWrap.vue_vue_type_script_setup_true_lang-e7a6a44f.js";import{a as ce,D as U}from"./dict-3320eb00.js";import{d as ue}from"./formatTime-7c094983.js";import{d as fe}from"./download-20922b56.js";import{_ as ye,g as _e,d as ge,e as we}from"./ErrorCodeForm.vue_vue_type_script_setup_true_lang-6027572d.js";import{u as be}from"./useMessage-5b7a04fd.js";import"./index-1943929a.js";import"./color-6e929987.js";import"./el-card-3ab8deb4.js";import"./Dialog-e1cdd070.js";import"./_plugin-vue_export-helper-1b428a4d.js";const he=Q({name:"SystemErrorCode",__name:"index",setup(ve){const b=be(),{t:D}=W(),h=m(!0),v=m(!1),k=m(0),C=m([]),r=X({pageNo:1,pageSize:10,type:void 0,applicationName:void 0,code:void 0,message:void 0,createTime:[]}),S=m(),f=async()=>{h.value=!0;try{const i=await _e(r);C.value=i.list,k.value=i.total}finally{h.value=!1}},y=()=>{r.pageNo=1,f()},K=()=>{S.value.resetFields(),y()},E=m(),N=(i,a)=>{E.value.open(i,a)},O=async()=>{try{await b.exportConfirm(),v.value=!0;const i=await we(r);fe.excel(i,"\u9519\u8BEF\u7801.xls")}catch{}finally{v.value=!1}};return j(()=>{f()}),(i,a)=>{const P=Z,z=$,d=ee,x=ae,F=le,g=te,n=oe,M=re,R=me,p=pe,H=ne,q=se,A=de,w=I("hasPermi"),B=ie;return s(),T(Y,null,[e(R,null,{default:o(()=>[e(M,{class:"-mb-15px",model:t(r),ref_key:"queryFormRef",ref:S,inline:!0,"label-width":"90px"},{default:o(()=>[e(d,{label:"\u9519\u8BEF\u7801\u7C7B\u578B",prop:"type"},{default:o(()=>[e(z,{modelValue:t(r).type,"onUpdate:modelValue":a[0]||(a[0]=l=>t(r).type=l),placeholder:"\u8BF7\u9009\u62E9\u9519\u8BEF\u7801\u7C7B\u578B",clearable:""},{default:o(()=>[(s(!0),T(Y,null,J(t(ce)(t(U).SYSTEM_ERROR_CODE_TYPE),l=>(s(),c(P,{key:l.value,label:l.label,value:l.value,class:"!w-240px"},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(d,{label:"\u5E94\u7528\u540D",prop:"applicationName"},{default:o(()=>[e(x,{modelValue:t(r).applicationName,"onUpdate:modelValue":a[1]||(a[1]=l=>t(r).applicationName=l),placeholder:"\u8BF7\u8F93\u5165\u5E94\u7528\u540D",clearable:"",onKeyup:V(y,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),e(d,{label:"\u9519\u8BEF\u7801\u7F16\u7801",prop:"code"},{default:o(()=>[e(x,{modelValue:t(r).code,"onUpdate:modelValue":a[2]||(a[2]=l=>t(r).code=l),placeholder:"\u8BF7\u8F93\u5165\u9519\u8BEF\u7801\u7F16\u7801",clearable:"",onKeyup:V(y,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),e(d,{label:"\u9519\u8BEF\u7801\u63D0\u793A",prop:"message"},{default:o(()=>[e(x,{modelValue:t(r).message,"onUpdate:modelValue":a[3]||(a[3]=l=>t(r).message=l),placeholder:"\u8BF7\u8F93\u5165\u9519\u8BEF\u7801\u63D0\u793A",clearable:"",onKeyup:V(y,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),e(d,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"createTime"},{default:o(()=>[e(F,{modelValue:t(r).createTime,"onUpdate:modelValue":a[4]||(a[4]=l=>t(r).createTime=l),"value-format":"YYYY-MM-DD HH:mm:ss",type:"daterange","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","default-time":[new Date("1 00:00:00"),new Date("1 23:59:59")],class:"!w-240px"},null,8,["modelValue","default-time"])]),_:1}),e(d,null,{default:o(()=>[e(n,{onClick:y},{default:o(()=>[e(g,{icon:"ep:search",class:"mr-5px"}),a[8]||(a[8]=u(" \u641C\u7D22"))]),_:1}),e(n,{onClick:K},{default:o(()=>[e(g,{icon:"ep:refresh",class:"mr-5px"}),a[9]||(a[9]=u(" \u91CD\u7F6E"))]),_:1}),_((s(),c(n,{type:"primary",plain:"",onClick:a[5]||(a[5]=l=>N("create"))},{default:o(()=>[e(g,{icon:"ep:plus",class:"mr-5px"}),a[10]||(a[10]=u(" \u65B0\u589E "))]),_:1})),[[w,["system:error-code:create"]]]),_((s(),c(n,{type:"success",plain:"",onClick:O,loading:t(v)},{default:o(()=>[e(g,{icon:"ep:download",class:"mr-5px"}),a[11]||(a[11]=u(" \u5BFC\u51FA "))]),_:1},8,["loading"])),[[w,["system:error-code:export"]]])]),_:1})]),_:1},8,["model"])]),_:1}),e(R,null,{default:o(()=>[_((s(),c(q,{data:t(C)},{default:o(()=>[e(p,{label:"\u7F16\u53F7",align:"center",prop:"id"}),e(p,{label:"\u7C7B\u578B",align:"center",prop:"type",width:"80"},{default:o(l=>[e(H,{type:t(U).SYSTEM_ERROR_CODE_TYPE,value:l.row.type},null,8,["type","value"])]),_:1}),e(p,{label:"\u5E94\u7528\u540D",align:"center",prop:"applicationName",width:"200"}),e(p,{label:"\u9519\u8BEF\u7801\u7F16\u7801",align:"center",prop:"code",width:"120"}),e(p,{label:"\u9519\u8BEF\u7801\u63D0\u793A",align:"center",prop:"message",width:"300"}),e(p,{label:"\u5907\u6CE8",align:"center",prop:"memo",width:"200"}),e(p,{label:"\u521B\u5EFA\u65F6\u95F4",align:"center",prop:"createTime",width:"180",formatter:t(ue)},null,8,["formatter"]),e(p,{label:"\u64CD\u4F5C",align:"center","class-name":"small-paddingfixed-width"},{default:o(l=>[_((s(),c(n,{link:"",type:"primary",onClick:G=>N("update",l.row.id)},{default:o(()=>a[12]||(a[12]=[u(" \u7F16\u8F91 ")])),_:2},1032,["onClick"])),[[w,["system:error-code:update"]]]),_((s(),c(n,{link:"",type:"danger",onClick:G=>(async L=>{try{await b.delConfirm(),await ge(L),b.success(D("common.delSuccess")),await f()}catch{}})(l.row.id)},{default:o(()=>a[13]||(a[13]=[u(" \u5220\u9664 ")])),_:2},1032,["onClick"])),[[w,["system:error-code:delete"]]])]),_:1})]),_:1},8,["data"])),[[B,t(h)]]),e(A,{total:t(k),page:t(r).pageNo,"onUpdate:page":a[6]||(a[6]=l=>t(r).pageNo=l),limit:t(r).pageSize,"onUpdate:limit":a[7]||(a[7]=l=>t(r).pageSize=l),onPagination:f},null,8,["total","page","limit"])]),_:1}),e(ye,{ref_key:"formRef",ref:E,onSuccess:f},null,512)],64)}}});export{he as default};