import{w as N,O as T,t as U,P as Q,I as j,Q as q}from"./element-plus.9816852d.js";import{_ as K}from"./index.vue_vue_type_script_setup_true_lang.f99137a4.js";import{b as M}from"./index.4eaf9bd5.js";import{u as O}from"./usePaging.2ad8e1e6.js";import{u as z}from"./useDictOptions.a2448547.js";import{f as G,g as H}from"./examined.6dd89177.js";import"./lodash.675f209e.js";import{_ as J}from"./editFlow.vue_vue_type_script_setup_true_name_flowEdit_lang.32131868.js";import{d as B,s as W,r as E,$ as X,af as Y,o as t,c as n,M as d,u as p,K as r,L as u,U as o,R as k,a as C,Q as i,k as Z,n as g}from"./@vue.51d7f2d8.js";import"./@vueuse.ec90c285.js";import"./@element-plus.a074d1f6.js";import"./lodash-es.29c53eac.js";import"./dayjs.576af3ba.js";import"./@amap.8a62addd.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.b082b0c1.js";import"./@popperjs.36402333.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./axios.54f807ba.js";import"./vue-router.9f65afb1.js";import"./pinia.56356cb7.js";import"./vue-demi.b3a9cad9.js";import"./css-color-function.0a5c0f85.js";import"./color.e5eb3bba.js";import"./clone.546d9b81.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.aee266dc.js";import"./ms.a9ae1d6d.js";import"./nprogress.f73355d0.js";import"./vue-clipboard3.dca5bca3.js";import"./clipboard.16e4491b.js";import"./echarts.ac57a99a.js";import"./zrender.d54ce080.js";import"./tslib.60310f1a.js";import"./highlight.js.dba6fa1b.js";import"./@highlightjs.40d5feba.js";import"./index.2d3a3dd9.js";import"./index.vue_vue_type_style_index_0_scoped_95d1884e_lang.0fc4c9f8.js";import"./dialog_index.vue_vue_type_script_setup_true_name_companyLists_lang.9f664f5c.js";import"./admin.e57e13d6.js";const ee={class:"mt-4"},te={key:0},oe={key:1},ae={key:2},se={key:3},ie={key:4},le={key:5},ne={key:6},ue={key:7},pe={class:"flex mt-4 justify-end"},re=B({name:"flowLists"}),st=B({...re,setup(me){const c=W(),_=E(!1),D=X({name:"",check_type:"",type:"",flow_cate:"",department_ids:"",copy_uids:"",remark:"",flow_list:"",admin_id:"",status:"",delete_user_id:""}),b=E([]),A=a=>{b.value=a.map(({id:l})=>l)},{dictData:F}=z(""),{pager:m,getLists:y,resetParams:de,resetPage:ce}=O({fetchFun:H,params:D}),V=async()=>{var a;_.value=!0,await g(),(a=c.value)==null||a.open("add")},$=async a=>{var l,f;_.value=!0,await g(),(l=c.value)==null||l.open("edit"),(f=c.value)==null||f.setFormData(a)},S=a=>{console.log(a.status),G({id:a.id,status:a.status})};return y(),(a,l)=>{const f=M,w=N,s=T,x=U,P=Q,L=K,R=j,h=Y("perms"),I=q;return t(),n("div",null,[d((t(),r(R,{class:"!border-none",shadow:"never"},{default:u(()=>[d((t(),r(w,{type:"primary",onClick:V},{icon:u(()=>[o(f,{name:"el-icon-Plus"})]),default:u(()=>[k(" \u65B0\u589E ")]),_:1})),[[h,["flow/add"]]]),C("div",ee,[o(P,{data:p(m).lists,onSelectionChange:A},{default:u(()=>[o(s,{type:"selection",width:"55"}),o(s,{label:"\u5BA1\u6279\u6D41\u540D\u79F0",prop:"name","show-overflow-tooltip":""}),o(s,{label:"\u5E94\u7528\u6A21\u5757",prop:"type","show-overflow-tooltip":""},{default:u(({row:e})=>[e.type==1?(t(),n("span",te,"\u5047\u52E4")):i("",!0),e.type==2?(t(),n("span",oe,"\u884C\u653F")):i("",!0),e.type==3?(t(),n("span",ae,"\u8D22\u52A1")):i("",!0),e.type==4?(t(),n("span",se,"\u4EBA\u4E8B")):i("",!0),e.type==5?(t(),n("span",ie,"\u5176\u4ED6")):i("",!0),e.type==6?(t(),n("span",le,"\u62A5\u9500")):i("",!0),e.type==7?(t(),n("span",ne,"\u53D1\u7968")):i("",!0),e.type==8?(t(),n("span",ue,"\u5408\u540C")):i("",!0)]),_:1}),o(s,{label:"\u5E94\u7528\u5BA1\u6279\u7C7B\u578Bid",prop:"flow_cate","show-overflow-tooltip":""}),o(s,{label:"\u5E94\u7528\u90E8\u95E8",prop:"department","show-overflow-tooltip":""}),o(s,{label:"\u6284\u9001\u4EBAID",prop:"copy_uids","show-overflow-tooltip":""}),o(s,{label:"\u6D41\u7A0B\u8BF4\u660E",prop:"remark","show-overflow-tooltip":""}),o(s,{label:"\u6D41\u7A0B\u6570\u636E\u5E8F\u5217\u5316",prop:"flow_list","show-overflow-tooltip":""}),o(s,{label:"\u521B\u5EFA\u4EBAID",prop:"admin_id","show-overflow-tooltip":""}),d((t(),r(s,{label:"\u8D26\u53F7\u72B6\u6001","min-width":"100"},{default:u(({row:e})=>[e.root!=1?(t(),r(x,{key:0,modelValue:e.status,"onUpdate:modelValue":v=>e.status=v,"active-value":1,"inactive-value":0,onChange:v=>S(e)},null,8,["modelValue","onUpdate:modelValue","onChange"])):i("",!0)]),_:1})),[[h,["auth.admin/edit"]]]),o(s,{label:"\u5220\u9664\u4EBAID",prop:"delete_user_id","show-overflow-tooltip":""}),o(s,{label:"\u64CD\u4F5C",width:"120",fixed:"right"},{default:u(({row:e})=>[d((t(),r(w,{type:"primary",link:"",onClick:v=>$(e)},{default:u(()=>[k(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[h,["flow/edit"]]]),d((t(),r(w,{type:"danger",link:"",onClick:v=>a.handleDelete(e.id)},{default:u(()=>[k(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[h,["flow/delete"]]])]),_:1})]),_:1},8,["data"])]),C("div",pe,[o(L,{modelValue:p(m),"onUpdate:modelValue":l[0]||(l[0]=e=>Z(m)?m.value=e:null),onChange:p(y)},null,8,["modelValue","onChange"])])]),_:1})),[[I,p(m).loading]]),p(_)?(t(),r(J,{key:0,ref_key:"editRef",ref:c,"dict-data":p(F),onSuccess:p(y),onClose:l[1]||(l[1]=e=>_.value=!1)},null,8,["dict-data","onSuccess"])):i("",!0)])}}});export{st as default};