2 lines
4.1 KiB
JavaScript
2 lines
4.1 KiB
JavaScript
import{w as N,O as U,t as A,P as Q,I as j,Q as q}from"./element-plus.b0ecf6ae.js";import{_ as I}from"./index.vue_vue_type_script_setup_true_lang.ebbecf1a.js";import{f as K,b as M}from"./index.2ce58885.js";import{u as O}from"./usePaging.60d02673.js";import{u as z}from"./useDictOptions.c461c83a.js";import{e as G,f as H}from"./examined.522e4d48.js";import{d as b,s as J,r as C,$ as W,af as X,o as s,c as Y,M as u,u as n,K as p,L as l,U as e,R as h,a as g,S as Z,k as tt,Q as et,n as y}from"./@vue.51d7f2d8.js";import"./lodash.ffb5376d.js";import{_ as ot}from"./editCate.vue_vue_type_script_setup_true_name_flowTypeEdit_lang.43fd0d47.js";import"./@vueuse.ec90c285.js";import"./@element-plus.c80b8015.js";import"./lodash-es.29c53eac.js";import"./dayjs.e873ead7.js";import"./@amap.8a62addd.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.82a509e0.js";import"./@popperjs.36402333.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./axios.f9df025a.js";import"./vue-router.9f65afb1.js";import"./pinia.56356cb7.js";import"./vue-demi.b3a9cad9.js";import"./css-color-function.4b0c77cb.js";import"./color.992612d2.js";import"./clone.d8d3ae9a.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.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.fb62f914.js";import"./index.vue_vue_type_style_index_0_scoped_95d1884e_lang.0fc4c9f8.js";const at={class:"mt-4"},it={class:"flex mt-4 justify-end"},nt=b({name:"flowTypeLists"}),Ht=b({...nt,setup(lt){const m=J(),c=C(!1),k=W({type:"",title:"",name:"",icon:"",department_ids:"",status:""}),E=C([]),D=t=>{E.value=t.map(({id:o})=>o)},{dictData:F}=z(""),{pager:r,getLists:d,resetParams:st,resetPage:rt}=O({fetchFun:H,params:k}),V=async()=>{var t;c.value=!0,await y(),(t=m.value)==null||t.open("add")},B=async t=>{var o,_;c.value=!0,await y(),(o=m.value)==null||o.open("edit"),(_=m.value)==null||_.setFormData(t)},S=async t=>{await K.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await apiFlowTypeDelete({id:t}),d()},$=t=>{G({id:t.id,status:t.status})};return d(),(t,o)=>{const _=M,w=N,i=U,x=A,P=Q,T=I,L=j,f=X("perms"),R=q;return s(),Y("div",null,[u((s(),p(L,{class:"!border-none",shadow:"never"},{default:l(()=>[u((s(),p(w,{type:"primary",onClick:V},{icon:l(()=>[e(_,{name:"el-icon-Plus"})]),default:l(()=>[h(" \u65B0\u589E ")]),_:1})),[[f,["flow_type/add"]]]),g("div",at,[e(P,{data:n(r).lists,onSelectionChange:D},{default:l(()=>[h(Z(n(r))+" ",1),e(i,{label:"id",prop:"id","show-overflow-tooltip":"",width:"60"}),e(i,{label:"\u540D\u79F0",prop:"title","show-overflow-tooltip":""}),e(i,{label:"\u5E94\u7528\u90E8\u95E8",prop:"department","show-overflow-tooltip":""}),e(i,{label:"\u6807\u8BC6",prop:"name","show-overflow-tooltip":""}),e(i,{label:"\u56FE\u6807",prop:"icon","show-overflow-tooltip":""}),e(i,{label:"\u6240\u5C5E\u5206\u7C7B",prop:"type_name","show-overflow-tooltip":""}),u((s(),p(i,{label:"\u8D26\u53F7\u72B6\u6001","min-width":"100"},{default:l(({row:a})=>[e(x,{modelValue:a.status,"onUpdate:modelValue":v=>a.status=v,"active-value":1,"inactive-value":0,onChange:v=>$(a)},null,8,["modelValue","onUpdate:modelValue","onChange"])]),_:1})),[[f,["auth.admin/edit"]]]),e(i,{label:"\u64CD\u4F5C",align:"center",width:"auto",fixed:"right"},{default:l(({row:a})=>[u((s(),p(w,{type:"primary",link:"",onClick:v=>B(a)},{default:l(()=>[h(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[f,["flow/edit"]]]),u((s(),p(w,{type:"danger",link:"",onClick:v=>S(a.id)},{default:l(()=>[h(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[f,["flow/delete"]]])]),_:1})]),_:1},8,["data"])]),g("div",it,[e(T,{modelValue:n(r),"onUpdate:modelValue":o[0]||(o[0]=a=>tt(r)?r.value=a:null),onChange:n(d)},null,8,["modelValue","onChange"])])]),_:1})),[[R,n(r).loading]]),n(c)?(s(),p(ot,{key:0,ref_key:"editRef",ref:m,"dict-data":n(F),onSuccess:n(d),onClose:o[1]||(o[1]=a=>c.value=!1)},null,8,["dict-data","onSuccess"])):et("",!0)])}}});export{Ht as default};
|