index-a600eab7.js 7.0 KB

1
  1. import{as as I,d as X,r as _,g as Z,z as $,T as aa,o as p,c as N,i as a,w as r,a as l,U as Y,F as R,C as F,k as i,l as d,D as f,S as L,Y as ea,I as la,G as ta,H as ra,q as oa,n as sa,s as pa,J as na,K as ua,L as ia,M as ca,_ as _a,__tla as da}from"./index-2f799233.js";import{_ as ma,__tla as fa}from"./index-e6cd813f.js";import{_ as ya,__tla as ga}from"./DictTag-ea4c6cc2.js";import{_ as wa,__tla as ha}from"./ContentWrap-9da801df.js";import{a as G,D as v,__tla as ba}from"./dict-20c916e2.js";import{d as va,__tla as xa}from"./formatTime-2157894c.js";import{d as Sa}from"./download-20922b56.js";import Ta,{__tla as ka}from"./ApiErrorLogDetail-f007cc83.js";import{I as y}from"./constants-d55a3460.js";import{u as Ia,__tla as Na}from"./useMessage-e567ad40.js";import{__tla as Ra}from"./index-1c180a16.js";import"./color-6e929987.js";import{__tla as Va}from"./el-card-c64c83d1.js";import{__tla as Ua}from"./Dialog-6fd39e06.js";import{__tla as Ca}from"./el-descriptions-item-0a78cef7.js";let M,Ea=Promise.all([(()=>{try{return da}catch{}})(),(()=>{try{return fa}catch{}})(),(()=>{try{return ga}catch{}})(),(()=>{try{return ha}catch{}})(),(()=>{try{return ba}catch{}})(),(()=>{try{return xa}catch{}})(),(()=>{try{return ka}catch{}})(),(()=>{try{return Na}catch{}})(),(()=>{try{return Ra}catch{}})(),(()=>{try{return Va}catch{}})(),(()=>{try{return Ua}catch{}})(),(()=>{try{return Ca}catch{}})()]).then(async()=>{M=_a(X({name:"InfraApiErrorLog",__name:"index",setup(Oa){const x=Ia(),S=_(!0),V=_(0),U=_([]),o=Z({pageNo:1,pageSize:10,userId:null,userType:null,applicationName:null,requestUrl:null,processStatus:null,exceptionTime:[]}),C=_(),T=_(!1),g=async()=>{S.value=!0;try{const t=await(n=o,I.get({url:"/infra/api-error-log/page",params:n}));U.value=t.list,V.value=t.total}finally{S.value=!1}var n},w=()=>{o.pageNo=1,g()},H=()=>{C.value.resetFields(),w()},E=_(),O=async(n,t)=>{try{const m=t===y.DONE?"\u5DF2\u5904\u7406":"\u5DF2\u5FFD\u7565";await x.confirm("\u786E\u8BA4\u6807\u8BB0\u4E3A"+m+"?"),await((u,h)=>I.put({url:"/infra/api-error-log/update-status?id="+u+"&processStatus="+h}))(n,t),await x.success(m),await g()}catch{}},K=async()=>{try{await x.exportConfirm(),T.value=!0;const t=await(n=o,I.download({url:"/infra/api-error-log/export-excel",params:n}));Sa.excel(t,"\u5F02\u5E38\u65E5\u5FD7.xls")}catch{}finally{T.value=!1}var n};return $(()=>{g()}),(n,t)=>{const m=ea,u=la,h=ta,P=ra,J=oa,k=sa,c=pa,j=na,A=wa,s=ua,D=ya,B=ia,Q=ma,b=aa("hasPermi"),W=ca;return p(),N(R,null,[a(A,null,{default:r(()=>[a(j,{class:"-mb-15px",model:l(o),ref_key:"queryFormRef",ref:C,inline:!0,"label-width":"68px"},{default:r(()=>[a(u,{label:"\u7528\u6237\u7F16\u53F7",prop:"userId"},{default:r(()=>[a(m,{modelValue:l(o).userId,"onUpdate:modelValue":t[0]||(t[0]=e=>l(o).userId=e),placeholder:"\u8BF7\u8F93\u5165\u7528\u6237\u7F16\u53F7",clearable:"",onKeyup:Y(w,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),a(u,{label:"\u7528\u6237\u7C7B\u578B",prop:"userType"},{default:r(()=>[a(P,{modelValue:l(o).userType,"onUpdate:modelValue":t[1]||(t[1]=e=>l(o).userType=e),placeholder:"\u8BF7\u9009\u62E9\u7528\u6237\u7C7B\u578B",clearable:"",class:"!w-240px"},{default:r(()=>[(p(!0),N(R,null,F(l(G)(l(v).USER_TYPE),e=>(p(),i(h,{key:e.value,label:e.label,value:e.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),a(u,{label:"\u5E94\u7528\u540D",prop:"applicationName"},{default:r(()=>[a(m,{modelValue:l(o).applicationName,"onUpdate:modelValue":t[2]||(t[2]=e=>l(o).applicationName=e),placeholder:"\u8BF7\u8F93\u5165\u5E94\u7528\u540D",clearable:"",onKeyup:Y(w,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),a(u,{label:"\u5F02\u5E38\u65F6\u95F4",prop:"exceptionTime"},{default:r(()=>[a(J,{modelValue:l(o).exceptionTime,"onUpdate:modelValue":t[3]||(t[3]=e=>l(o).exceptionTime=e),"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}),a(u,{label:"\u5904\u7406\u72B6\u6001",prop:"processStatus"},{default:r(()=>[a(P,{modelValue:l(o).processStatus,"onUpdate:modelValue":t[4]||(t[4]=e=>l(o).processStatus=e),placeholder:"\u8BF7\u9009\u62E9\u5904\u7406\u72B6\u6001",clearable:"",class:"!w-240px"},{default:r(()=>[(p(!0),N(R,null,F(l(G)(l(v).INFRA_API_ERROR_LOG_PROCESS_STATUS),e=>(p(),i(h,{key:e.value,label:e.label,value:e.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),a(u,null,{default:r(()=>[a(c,{onClick:w},{default:r(()=>[a(k,{icon:"ep:search",class:"mr-5px"}),d(" \u641C\u7D22")]),_:1}),a(c,{onClick:H},{default:r(()=>[a(k,{icon:"ep:refresh",class:"mr-5px"}),d(" \u91CD\u7F6E")]),_:1}),f((p(),i(c,{type:"success",plain:"",onClick:K,loading:l(T)},{default:r(()=>[a(k,{icon:"ep:download",class:"mr-5px"}),d(" \u5BFC\u51FA ")]),_:1},8,["loading"])),[[b,["infra:api-error-log:export"]]])]),_:1})]),_:1},8,["model"])]),_:1}),a(A,null,{default:r(()=>[f((p(),i(B,{data:l(U)},{default:r(()=>[a(s,{label:"\u65E5\u5FD7\u7F16\u53F7",align:"center",prop:"id"}),a(s,{label:"\u7528\u6237\u7F16\u53F7",align:"center",prop:"userId"}),a(s,{label:"\u7528\u6237\u7C7B\u578B",align:"center",prop:"userType"},{default:r(e=>[a(D,{type:l(v).USER_TYPE,value:e.row.userType},null,8,["type","value"])]),_:1}),a(s,{label:"\u5E94\u7528\u540D",align:"center",prop:"applicationName",width:"200"}),a(s,{label:"\u8BF7\u6C42\u65B9\u6CD5",align:"center",prop:"requestMethod",width:"80"}),a(s,{label:"\u8BF7\u6C42\u5730\u5740",align:"center",prop:"requestUrl",width:"180"}),a(s,{label:"\u5F02\u5E38\u53D1\u751F\u65F6\u95F4",align:"center",prop:"exceptionTime",width:"180",formatter:l(va)},null,8,["formatter"]),a(s,{label:"\u5F02\u5E38\u540D",align:"center",prop:"exceptionName",width:"180"}),a(s,{label:"\u5904\u7406\u72B6\u6001",align:"center",prop:"processStatus"},{default:r(e=>[a(D,{type:l(v).INFRA_API_ERROR_LOG_PROCESS_STATUS,value:e.row.processStatus},null,8,["type","value"])]),_:1}),a(s,{label:"\u64CD\u4F5C",align:"center",width:"200"},{default:r(e=>[f((p(),i(c,{link:"",type:"primary",onClick:q=>{return z=e.row,void E.value.open(z);var z}},{default:r(()=>[d(" \u8BE6\u7EC6 ")]),_:2},1032,["onClick"])),[[b,["infra:api-error-log:query"]]]),e.row.processStatus===l(y).INIT?f((p(),i(c,{key:0,link:"",type:"primary",onClick:q=>O(e.row.id,l(y).DONE)},{default:r(()=>[d(" \u5DF2\u5904\u7406 ")]),_:2},1032,["onClick"])),[[b,["infra:api-error-log:update-status"]]]):L("",!0),e.row.processStatus===l(y).INIT?f((p(),i(c,{key:1,link:"",type:"primary",onClick:q=>O(e.row.id,l(y).IGNORE)},{default:r(()=>[d(" \u5DF2\u5FFD\u7565 ")]),_:2},1032,["onClick"])),[[b,["infra:api-error-log:update-status"]]]):L("",!0)]),_:1})]),_:1},8,["data"])),[[W,l(S)]]),a(Q,{total:l(V),page:l(o).pageNo,"onUpdate:page":t[5]||(t[5]=e=>l(o).pageNo=e),limit:l(o).pageSize,"onUpdate:limit":t[6]||(t[6]=e=>l(o).pageSize=e),onPagination:g},null,8,["total","page","limit"])]),_:1}),a(Ta,{ref_key:"detailRef",ref:E},null,512)],64)}}}),[["__file","D:/zx/mall-newfeifan-zx-business/src/views/infra/apiErrorLog/index.vue"]])});export{Ea as __tla,M as default};