import{c as N,G as V,u as y}from"./crud.b8c9afc7.js";import{T as D,M as b}from"./index.373e4c1e.js";import"./elementPlus.c5b0e04f.js";import{_ as k}from"./index.vue_vue_type_script_setup_true_lang.209078d8.js";import B from"./index.dc351dbf.js";import{d as M,r as o,q as R,j as G,a9 as l,o as I,E as O,G as i,M as a,K as T,L as j,B as E,u as m,t as q}from"./vue.65d9dadc.js";import"./dictionary.e641576e.js";import"./dictionary.afac2490.js";import"./echarts.72dc8373.js";import"./_plugin-vue_export-helper.c27b6911.js";const W=M({__name:"index",setup(z,{expose:_}){let s=o(!1),c=o(null),u=o(null);const t=o(),d=o(),p=o(),w=R("$hasPermissions"),P=async()=>{const e=await V();y().setPermissionData(e.data)},C=e=>{c.value=e.id,u.value=e.name,s.value=!0},x=()=>{s.value=!1},{crudExpose:n}=D({crudRef:d,crudBinding:p});return G(async()=>{await P();const{crudOptions:e}=N({crudExpose:n,rolePermission:t,handleDrawerOpen:C,hasPermissions:w});b({crudExpose:n,crudOptions:e,context:{}}),n.doRefresh()}),_(t),(e,f)=>{const g=l("el-tag"),h=l("fs-crud"),v=l("fs-page");return I(),O(v,null,{default:i(()=>[a(h,E({ref_key:"crudRef",ref:d},p.value),{cell_url:i(r=>[a(g,{size:"small"},{default:i(()=>[T(j(r.row.url),1)]),_:2},1024)]),_:1},16),a(k,{ref_key:"rolePermission",ref:t},null,512),a(B,{drawerVisible:m(s),"onUpdate:drawerVisible":f[0]||(f[0]=r=>q(s)?s.value=r:s=r),roleId:m(c),roleName:m(u),onDrawerClose:x},null,8,["drawerVisible","roleId","roleName"])]),_:1})}}});export{W as default};
