2025-03-20 10:25:32 +08:00

2 lines
8.2 KiB
JavaScript

import{a0 as te,a1 as le,M as ue,N as ne,L as oe,a2 as ae,a3 as ie,S as se,T as re,Q as de,B as _e,w as pe,C as ce}from"./element-plus.2acb577d.js";import{_ as fe}from"./index.vue_vue_type_style_index_0_lang.9e5f7fb0.js";import{d as N,s as me,r as y,Z as v,o as r,c as E,U as n,L as u,R as s,S as p,u as t,K as c,Q as f,T as R,a9 as U,a as b,M as ke,V as Ee,i as Be,n as be}from"./@vue.821a47ec.js";import{_ as Ae}from"./index.vue_vue_type_script_setup_true_lang.61cb6e34.js";import{P as De}from"./index.f292cd50.js";import{a as ge,d as Fe}from"./index.81df6f20.js";import{e as $}from"./@element-plus.dabbc398.js";import{a as ye}from"./oa_financial.d5633b25.js";import"./lodash-es.df44a280.js";import"./async-validator.fb49d0f5.js";import"./@vueuse.81e2759c.js";import"./dayjs.d2a77ee0.js";import"./axios.9e996410.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./lodash.6bfd3540.js";import"./vue-router.4c04f9b6.js";import"./pinia.fefed778.js";import"./css-color-function.8ff67959.js";import"./color.bfa08e9a.js";import"./clone.660f80c4.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./ms.564e106c.js";import"./nprogress.dcb32030.js";import"./vue-clipboard3.e681583f.js";import"./clipboard.3ad9b20b.js";import"./echarts.42bea269.js";import"./tslib.60310f1a.js";import"./zrender.2cb48b70.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.8864a4be.js";const ve={class:"detail-popup"},we={class:"flex",style:{position:"relative"}},xe={class:"w-280[px]",style:{position:"absolute",left:"250px"}},Ce={key:0},he=N({name:"customdetail"}),Ve=N({...he,emits:["close"],setup(Te,{expose:L,emit:P}){const M=P,w=me(),A=y(!1),x=y(null),_=ge().userInfo,k=y(!1),l=v({id:0,extends:{}}),Q=async o=>{console.log(o);for(const e in o)o[e]!=null&&o[e]!=null&&(l[e]=o[e])},i=v({id:l.id,check:"",content:"",check_node:1,check_admin_ids:"",check_admin_names:""}),G=()=>{if(!i.content)return feedback.msgError("\u8BF7\u586B\u5199\u64A4\u56DE\u539F\u56E0");i.check=3,B()},K=async()=>{A.value=!0,await be(),x.value.open()},Z=o=>{i.check_admin_names=o.name,i.check_admin_ids=o.id,A.value=!1},j=o=>{if(o==1)return"\u4EA4\u901A\u8D39";if(o==2)return"\u4F4F\u5BBF\u8D39";if(o==3)return"\u9910\u8865\u8D39";if(o==4)return"\u62DB\u5F85\u8D39";if(o==5)return"\u6C7D\u6CB9\u8D39";if(o==6)return"\u5176\u4ED6\u8D39"},q=()=>{var o;(o=w.value)==null||o.open()},z=(o,e)=>{if(o==0)return e.user_id_info[0].name;if(o==1)return"\u90E8\u95E8\u8D1F\u8D23\u4EBA";if(o==2)return"\u6216\u7B7E";if(o==3)return"\u4F1A\u7B7E";if(o==4)return e.user_id_info[0].name},C=()=>l.steps.findIndex(e=>e.sort==l.check_step_sort),H=()=>{M("close")},B=async()=>{l.flow_info.check_type!=2&&delete i.check_node,i.id=l.id,await ye({...i}),H()},J=v([4,3,2]),h=()=>J.includes(l.check_status)?!1:l.admin_id==_.id?!0:(l==null?void 0:l.check_admin_ids.length)>1?l.steps[C()].check_list.map(o=>o.check_user_id).includes(_.id)?!1:l==null?void 0:l.check_admin_ids.split(",").map(Number).includes(_.id):(l==null?void 0:l.check_admin_ids)==_.id;return L({open:q,setFormData:Q}),(o,e)=>{const d=te,D=le,g=ue,O=ne,V=oe,T=ae,W=ie,S=se,X=re,F=_e,m=pe,Y=fe,I=ce,ee=de;return r(),E("div",ve,[n(De,{ref_key:"popupRef",ref:w,showFootBtn:!1,title:"\u5BA1\u6279\u8BE6\u60C5",async:!0,width:"60vw"},{default:u(()=>[n(V,null,{header:u(()=>e[10]||(e[10]=[s("\u5BA1\u6279\u5185\u5BB9")])),default:u(()=>[n(D,{column:3,border:""},{default:u(()=>[n(d,{label:"\u62A5\u9500\u51ED\u8BC1\u7F16\u53F7","label-align":"left",align:"left"},{default:u(()=>[s(p(t(l).code),1)]),_:1}),n(d,{label:"\u539F\u59CB\u5355\u636E\u65E5\u671F","label-align":"left",align:"left"},{default:u(()=>[s(p(t(l).expense_time),1)]),_:1}),n(d,{label:"\u5165\u8D26\u6708\u4EFD","label-align":"left",align:"left"},{default:u(()=>[s(p(t(l).income_month),1)]),_:1}),t(l).annex?(r(),c(d,{key:0,label:"\u9644\u4EF6","label-align":"left",align:"left"},{default:u(()=>[n(Ae,{annex:t(l).annex||[]},null,8,["annex"])]),_:1})):f("",!0)]),_:1}),n(O,{data:t(l).detail},{default:u(()=>[n(g,{label:"\u62A5\u9500\u91D1\u989D","show-overflow-tooltip":"",prop:"amount"}),n(g,{label:"\u62A5\u9500\u9879\u76EE","show-overflow-tooltip":"",prop:"cate_id"},{default:u(({row:a})=>[s(p(j(a.cate_id)),1)]),_:1}),n(g,{label:"\u5907\u6CE8\u4FE1\u606F","show-overflow-tooltip":"",prop:"remark"})]),_:1},8,["data"])]),_:1}),n(V,null,{header:u(()=>e[11]||(e[11]=[s("\u5BA1\u6279\u6D41\u7A0B")])),default:u(()=>[n(D,{column:3,border:""},{default:u(()=>[n(d,{label:"\u5BA1\u6279\u72B6\u6001","label-align":"left",align:"left"},{default:u(()=>[s(p(t(l).check_status_text),1)]),_:1}),n(d,{label:"\u5F53\u524D\u5BA1\u6838\u4EBA","label-align":"left",align:"left"},{default:u(()=>[s(p(t(l).check_admin_users||"\u5BA1\u6279\u7ED3\u675F"),1)]),_:1}),n(d,{label:"\u6284\u9001\u4EBA","label-align":"left",align:"left"},{default:u(()=>[s(p(t(l).copy_users),1)]),_:1})]),_:1}),n(D,{column:1,border:""},{default:u(()=>[n(d,{label:"\u5BA1\u6279\u6D41\u7A0B","label-align":"left",align:"left"},{default:u(()=>[n(W,{class:"mb-4",style:{"max-width":"50vw"},space:200,active:C()+1,simple:""},{default:u(()=>[n(T,{icon:t($),title:t(l).record[t(l).record.length-1].check_user_name+"\u521B\u5EFA"},null,8,["icon","title"]),(r(!0),E(R,null,U(t(l).steps,a=>(r(),c(T,{icon:t($),title:z(a.flow_type,a)},null,8,["icon","title"]))),256))]),_:1},8,["active"])]),_:1}),n(d,{label:"\u5BA1\u6279\u8BB0\u5F55","label-align":"left",align:"left"},{default:u(()=>[(r(!0),E(R,null,U(t(l).record,a=>(r(),E("p",null,[b("span",null,p(a.check_user_name+a.status_text),1),s("\u4E86\u7533\u8BF7 "+p(a.check_time)+" ",1),b("span",null," \u64CD\u4F5C\u610F\u89C1\uFF1A "+p(a.content),1)]))),256))]),_:1}),t(l).flow_info.check_type==2&&t(l).check_status!=3&&t(l).check_status!=2&&t(l).admin_id!=t(_).id?(r(),c(d,{key:0,label:"\u5BA1\u6279\u8282\u70B9","label-align":"left",align:"left"},{default:u(()=>[b("div",we,[n(X,{modelValue:t(i).check_node,"onUpdate:modelValue":e[0]||(e[0]=a=>t(i).check_node=a)},{default:u(()=>[n(S,{label:1},{default:u(()=>e[12]||(e[12]=[s("\u5BA1\u6279\u7ED3\u675F")])),_:1}),n(S,{label:2},{default:u(()=>e[13]||(e[13]=[s("\u4E0B\u4E00\u5BA1\u6279\u4EBA")])),_:1})]),_:1},8,["modelValue"]),b("div",xe,[ke(n(F,{modelValue:t(i).check_admin_names,"onUpdate:modelValue":e[1]||(e[1]=a=>t(i).check_admin_names=a),placeholder:"\u70B9\u51FB\u9009\u62E9\u4E0B\u4E00\u5BA1\u6279\u4EBA",clearable:"",readonly:"",onClick:K},null,8,["modelValue"]),[[Ee,t(i).check_node==2]])])])]),_:1})):f("",!0),h()&&t(l).admin_id!=t(_).id?(r(),c(d,{key:1,label:"\u5BA1\u6279\u610F\u89C1","label-align":"left",align:"left"},{default:u(()=>[n(F,{type:"textarea",modelValue:t(i).content,"onUpdate:modelValue":e[2]||(e[2]=a=>t(i).content=a)},null,8,["modelValue"])]),_:1})):f("",!0),h()?(r(),c(d,{key:2,label:"\u64CD\u4F5C","label-align":"left",align:"left"},{default:u(()=>[t(l).admin_id!=t(_).id?(r(),c(m,{key:0,type:"primary",onClick:e[3]||(e[3]=a=>(t(i).check=1,B()))},{default:u(()=>e[14]||(e[14]=[s(" \u901A\u8FC7 ")])),_:1})):f("",!0),t(l).admin_id!=t(_).id&&t(l).flow_info.check_type!=3?(r(),c(m,{key:1,onClick:e[4]||(e[4]=a=>(t(i).check=2,B()))},{default:u(()=>e[15]||(e[15]=[s(" \u62D2\u7EDD ")])),_:1})):f("",!0),t(l).admin_id!=t(_).id&&t(l).flow_info.check_type==3?(r(),c(m,{key:2,onClick:e[5]||(e[5]=a=>(t(i).check=2,B()))},{default:u(()=>e[16]||(e[16]=[s(" \u56DE\u9000 ")])),_:1})):f("",!0),t(l).admin_id==t(_).id?(r(),c(m,{key:3,type:"info",onClick:e[6]||(e[6]=a=>k.value=!0)},{default:u(()=>e[17]||(e[17]=[s(" \u64A4\u56DE ")])),_:1})):f("",!0)]),_:1})):f("",!0)]),_:1})]),_:1}),t(A)?(r(),E("div",Ce,[n(Y,{ref_key:"personnel",ref:x,onConfirm:Z,type:"1"},null,512)])):f("",!0),n(ee,{modelValue:t(k),"onUpdate:modelValue":e[9]||(e[9]=a=>Be(k)?k.value=a:null),title:"\u64A4\u56DE\u5BA1\u6279",width:"550px"},{default:u(()=>[n(I,{label:"\u64A4\u56DE\u539F\u56E0"},{default:u(()=>[n(F,{modelValue:t(i).content,"onUpdate:modelValue":e[7]||(e[7]=a=>t(i).content=a),type:"textarea"},null,8,["modelValue"])]),_:1}),n(I,{label:""},{default:u(()=>[n(m,{type:"primary",onClick:G},{default:u(()=>e[18]||(e[18]=[s("\u64A4\u56DE")])),_:1}),n(m,{onClick:e[8]||(e[8]=a=>k.value=!1)},{default:u(()=>e[19]||(e[19]=[s("\u53D6\u6D88")])),_:1})]),_:1})]),_:1},8,["modelValue"])]),_:1},512)])}}});const ct=Fe(Ve,[["__scopeId","data-v-0d9a4f6f"]]);export{ct as default};