index-92cdd00d.js 6.8 KB

1
  1. import{d as J,h as L,r as c,e as Z,l as $,Q as ee,o as n,c as R,f as e,w as t,a as l,R as F,F as I,q as ae,v as u,n as i,x as d,V as le,A as te,y as re,z as oe,B as se,j as ne,C as _e,D as ce,W as pe,X as me,G as ue,H as ie,I as de,_ as fe,__tla as ye}from"./index-e3afde76.js";import{_ as he,__tla as be}from"./index-51c17e69.js";import{_ as ge,__tla as ke}from"./DictTag-715a7ef1.js";import{_ as we,__tla as ve}from"./ContentWrap-5f2f4872.js";import{a as Ce,D as H,__tla as Ve}from"./dict-a141296d.js";import{d as xe,__tla as Te}from"./formatTime-cee700cd.js";import{b as Se,d as Ue,__tla as Me}from"./index-b4090625.js";import De,{__tla as Ne}from"./RoleForm-4a2d9daf.js";import ze,{__tla as Re}from"./RoleAssignMenuForm-38126821.js";import Fe,{__tla as Ie}from"./RoleDataPermissionForm-afdc7e7b.js";import{u as He,__tla as Oe}from"./useMessage-0b1b25bd.js";import{__tla as Pe}from"./index-2d20a7ff.js";import"./color-6e929987.js";import{__tla as Ye}from"./el-card-6198c22a.js";import{__tla as Ae}from"./Dialog-c20523c4.js";import"./constants-40f13f5e.js";import"./tree-0af4953a.js";import{__tla as qe}from"./index-1a98c486.js";import{__tla as Be}from"./index-c6c6bb97.js";import{__tla as Ke}from"./index-3eb0dcf8.js";let O,je=Promise.all([(()=>{try{return ye}catch{}})(),(()=>{try{return be}catch{}})(),(()=>{try{return ke}catch{}})(),(()=>{try{return ve}catch{}})(),(()=>{try{return Ve}catch{}})(),(()=>{try{return Te}catch{}})(),(()=>{try{return Me}catch{}})(),(()=>{try{return Ne}catch{}})(),(()=>{try{return Re}catch{}})(),(()=>{try{return Ie}catch{}})(),(()=>{try{return Oe}catch{}})(),(()=>{try{return Pe}catch{}})(),(()=>{try{return Ye}catch{}})(),(()=>{try{return Ae}catch{}})(),(()=>{try{return qe}catch{}})(),(()=>{try{return Be}catch{}})(),(()=>{try{return Ke}catch{}})()]).then(async()=>{O=fe(J({name:"SystemRole",__name:"index",setup(Ge){const v=He(),{t:P}=L(),g=c(!0),C=c(0),V=c([]),r=Z({pageNo:1,pageSize:10,code:"",name:"",status:void 0,createTime:[],roleType:1}),x=c();c(!1);const Y=p=>{r.roleType=p.paneName,console.log(r.roleType),_()},_=async()=>{g.value=!0;try{const p=await Se(r);V.value=p.list,C.value=p.total}finally{g.value=!1}},b=()=>{r.pageNo=1,_()},A=()=>{x.value.resetFields(),b()},T=c(),S=(p,o)=>{T.value.open(p,o)},U=c(),M=c();return $(()=>{_()}),(p,o)=>{const D=le,f=te,q=re,B=oe,K=se,k=ne,m=_e,j=ce,N=we,z=pe,G=me,s=ue,Q=ge,W=ie,X=he,y=ee("hasPermi"),E=de;return n(),R(I,null,[e(N,null,{default:t(()=>[e(j,{ref_key:"queryFormRef",ref:x,inline:!0,model:l(r),class:"-mb-15px","label-width":"68px"},{default:t(()=>[e(f,{label:"\u89D2\u8272\u540D\u79F0",prop:"name"},{default:t(()=>[e(D,{modelValue:l(r).name,"onUpdate:modelValue":o[0]||(o[0]=a=>l(r).name=a),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u8F93\u5165\u89D2\u8272\u540D\u79F0",onKeyup:F(b,["enter"])},null,8,["modelValue"])]),_:1}),e(f,{label:"\u89D2\u8272\u6807\u8BC6",prop:"code"},{default:t(()=>[e(D,{modelValue:l(r).code,"onUpdate:modelValue":o[1]||(o[1]=a=>l(r).code=a),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u8F93\u5165\u89D2\u8272\u6807\u8BC6",onKeyup:F(b,["enter"])},null,8,["modelValue"])]),_:1}),e(f,{label:"\u72B6\u6001",prop:"status"},{default:t(()=>[e(B,{modelValue:l(r).status,"onUpdate:modelValue":o[2]||(o[2]=a=>l(r).status=a),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u9009\u62E9\u72B6\u6001"},{default:t(()=>[(n(!0),R(I,null,ae(l(Ce)(l(H).COMMON_STATUS),a=>(n(),u(q,{key:a.value,label:a.label,value:a.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(f,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"createTime"},{default:t(()=>[e(K,{modelValue:l(r).createTime,"onUpdate:modelValue":o[3]||(o[3]=a=>l(r).createTime=a),"default-time":[new Date("1 00:00:00"),new Date("1 23:59:59")],class:"!w-240px","end-placeholder":"\u7ED3\u675F\u65E5\u671F","start-placeholder":"\u5F00\u59CB\u65E5\u671F",type:"daterange","value-format":"YYYY-MM-DD HH:mm:ss"},null,8,["modelValue","default-time"])]),_:1}),e(f,null,{default:t(()=>[e(m,{onClick:b},{default:t(()=>[e(k,{class:"mr-5px",icon:"ep:search"}),i(" \u641C\u7D22 ")]),_:1}),e(m,{onClick:A},{default:t(()=>[e(k,{class:"mr-5px",icon:"ep:refresh"}),i(" \u91CD\u7F6E ")]),_:1}),d((n(),u(m,{plain:"",type:"primary",onClick:o[4]||(o[4]=a=>S("create"))},{default:t(()=>[e(k,{class:"mr-5px",icon:"ep:plus"}),i(" \u65B0\u589E ")]),_:1})),[[y,["system:role:create"]]])]),_:1})]),_:1},8,["model"])]),_:1}),e(G,{modelValue:l(r).roleType,"onUpdate:modelValue":o[5]||(o[5]=a=>l(r).roleType=a),onTabClick:Y,class:"parent-tabs"},{default:t(()=>[e(z,{label:"\u5E73\u53F0\u89D2\u8272",name:1}),e(z,{label:"\u5E97\u94FA\u89D2\u8272",name:2})]),_:1},8,["modelValue"]),e(N,null,{default:t(()=>[d((n(),u(W,{data:l(V)},{default:t(()=>[e(s,{align:"center",label:"\u89D2\u8272\u7F16\u53F7",prop:"id"}),e(s,{align:"center",label:"\u89D2\u8272\u540D\u79F0",prop:"name"}),e(s,{align:"center",label:"\u89D2\u8272\u7C7B\u578B",prop:"type"}),e(s,{align:"center",label:"\u89D2\u8272\u6807\u8BC6",prop:"code"}),e(s,{align:"center",label:"\u663E\u793A\u987A\u5E8F",prop:"sort"}),e(s,{align:"center",label:"\u5907\u6CE8",prop:"remark"}),e(s,{align:"center",label:"\u72B6\u6001",prop:"status"},{default:t(a=>[e(Q,{type:l(H).COMMON_STATUS,value:a.row.status},null,8,["type","value"])]),_:1}),e(s,{formatter:l(xe),align:"center",label:"\u521B\u5EFA\u65F6\u95F4",prop:"createTime",width:"180"},null,8,["formatter"]),e(s,{width:300,align:"center",label:"\u64CD\u4F5C"},{default:t(a=>[d((n(),u(m,{link:"",type:"primary",onClick:w=>S("update",a.row.id)},{default:t(()=>[i(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[y,["system:role:update"]]]),d((n(),u(m,{link:"",preIcon:"ep:basketball",title:"\u83DC\u5355\u6743\u9650",type:"primary",onClick:w=>(async h=>{M.value.open(h)})(a.row)},{default:t(()=>[i(" \u83DC\u5355\u6743\u9650 ")]),_:2},1032,["onClick"])),[[y,["system:permission:assign-role-menu"]]]),d((n(),u(m,{link:"",preIcon:"ep:coin",title:"\u6570\u636E\u6743\u9650",type:"primary",onClick:w=>(async h=>{U.value.open(h)})(a.row)},{default:t(()=>[i(" \u6570\u636E\u6743\u9650 ")]),_:2},1032,["onClick"])),[[y,["system:permission:assign-role-data-scope"]]]),d((n(),u(m,{link:"",type:"danger",onClick:w=>(async h=>{try{await v.delConfirm(),await Ue(h),v.success(P("common.delSuccess")),await _()}catch{}})(a.row.id)},{default:t(()=>[i(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[y,["system:role:delete"]]])]),_:1})]),_:1},8,["data"])),[[E,l(g)]]),e(X,{limit:l(r).pageSize,"onUpdate:limit":o[6]||(o[6]=a=>l(r).pageSize=a),page:l(r).pageNo,"onUpdate:page":o[7]||(o[7]=a=>l(r).pageNo=a),total:l(C),onPagination:_},null,8,["limit","page","total"])]),_:1}),e(De,{ref_key:"formRef",ref:T,onSuccess:_},null,512),e(ze,{ref_key:"assignMenuFormRef",ref:M,onSuccess:_},null,512),e(Fe,{ref_key:"dataPermissionFormRef",ref:U,onSuccess:_},null,512)],64)}}}),[["__scopeId","data-v-17c20125"],["__file","D:/zx/mall-newfeifan-zx-admin/src/views/system/role/index.vue"]])});export{je as __tla,O as default};