1 |
- /* empty css *//* empty css */import{u as e,_ as t}from"./useOpen-a24750bc.js";import{u as a}from"./useGetList-10bd17fb.js";/* empty css *//* empty css */import"./el-tooltip-4ed993c7.js";/* empty css */import{_ as s}from"./destroy.vue_vue_type_script_setup_true_lang-3e425698.js";import{_ as r}from"./update.vue_vue_type_script_setup_true_lang-03546537.js";import{_ as l}from"./index.vue_vue_type_script_setup_true_lang-a6bb1841.js";import{_ as o}from"./operate.vue_vue_type_script_setup_true_lang-e1034c0d.js";import{_ as p}from"./search.vue_vue_type_script_setup_true_lang-5fdc06f2.js";/* empty css *//* empty css */import{_ as i}from"./create.vue_vue_type_script_setup_true_lang-75a91df6.js";import{u}from"./useDestroy-ee426241.js";import{d as m,n as d,z as n,o as _,c,a as j,w as f,f as v,e as b,Z as y,l as h,a9 as w,a5 as g,a6 as V,aa as x,ab as k,a2 as C}from"./index-fe6c8641.js";/* empty css *//* empty css *//* empty css */import"./index-7cd89372.js";/* empty css */import"./add.vue_vue_type_script_setup_true_lang-ff3ef2bf.js";/* empty css *//* empty css *//* empty css */import"./useCreate-21e18dc5.js";import"./useShow-401252b0.js";const U={class:"table-default"},R=m({__name:"index",setup(m){const R="permissions/departments",{data:G,query:L,search:O,reset:S,loading:Z}=a(R,!1),{destroy:q,deleted:z}=u(),{open:D,close:F,title:H,visible:I,id:K}=e(),P=d((()=>{var e;return null==(e=G.value)?void 0:e.data}));return n((()=>{O(),z(S)})),(e,a)=>{const u=g,m=V,d=p,n=o,G=x,z=l,Q=r,Y=s,A=k,B=t,E=C;return _(),c("div",null,[j(d,{search:v(O),reset:v(S)},{body:f((()=>[j(m,{label:"部门名称",prop:"department_name"},{default:f((()=>[j(u,{modelValue:v(L).department_name,"onUpdate:modelValue":a[0]||(a[0]=e=>v(L).department_name=e),name:"department_name",clearable:""},null,8,["modelValue"])])),_:1})])),_:1},8,["search","reset"]),b("div",U,[j(n,{show:v(D)},null,8,["show"]),y((_(),h(A,{data:v(P),class:"mt-3","row-key":"id","default-expand-all":"","tree-props":{children:"children"}},{default:f((()=>[j(G,{prop:"department_name",label:"部门名称"}),j(G,{prop:"sort",label:"排序"}),j(G,{prop:"status",label:"状态"},{default:f((e=>[j(z,{modelValue:e.row.status,"onUpdate:modelValue":t=>e.row.status=t,id:e.row.id,api:R,onRefresh:v(O)},null,8,["modelValue","onUpdate:modelValue","id","onRefresh"])])),_:1}),j(G,{prop:"created_at",label:"创建时间"}),j(G,{label:"操作",width:"200"},{default:f((e=>[j(Q,{onClick:t=>v(D)(e.row.id)},null,8,["onClick"]),j(Y,{onClick:t=>v(q)(R,e.row.id)},null,8,["onClick"])])),_:1})])),_:1},8,["data"])),[[E,v(Z)]])]),j(B,{modelValue:v(I),"onUpdate:modelValue":a[2]||(a[2]=e=>w(I)?I.value=e:null),title:v(H),"destroy-on-close":""},{default:f((()=>[j(i,{onClose:a[1]||(a[1]=e=>v(F)(v(S))),primary:v(K),api:R},null,8,["primary"])])),_:1},8,["modelValue","title"])])}}});export{R as default};
|