This commit is contained in:
njdaoyehu 2025-04-23 17:37:24 +08:00
parent f95d182632
commit e69bc1821f
36 changed files with 26 additions and 26 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
var D=Object.getOwnPropertySymbols;var R=Object.prototype.hasOwnProperty,N=Object.prototype.propertyIsEnumerable;var x=(a,d)=>{var i={};for(var e in a)R.call(a,e)&&d.indexOf(e)<0&&(i[e]=a[e]);if(a!=null&&D)for(var e of D(a))d.indexOf(e)<0&&N.call(a,e)&&(i[e]=a[e]);return i};import{u as P,B as $}from"./useTable-e949a6b7.js";import{T as j}from"./useForm-baba730a.js";import{S as O,j as V,_ as A}from"./index.js";import{N as H,j as h}from"./antd-0679333d.js";import{r as z,s as E}from"./deviceApi-260fcde9.js";import{u as F}from"./index-679d8a0a.js";import{D as K,c as U,s as C}from"./drawer-8318451d.js";import{d as W,o as G,a6 as L,Z as S,_ as Z,$ as Y,k as p,u as c,a5 as b,l as q,G as J,a4 as Q,a8 as X}from"./vue-72a104e4.js";import"./index-8a6826ba.js";import"./useWindowSizeFn-1db11f4f.js";import"./onMountedOrActivated-ee461833.js";import"./sortable.esm-15c0a34e.js";import"./copyTextToClipboard-3ca69a78.js";const ee={class:"header"},te=W({__name:"index",setup(a){const[d,{openDrawer:i}]=F(),[e,{reload:v}]=P({api:t=>E(w(t)),columns:U,formConfig:{labelWidth:0,schemas:C,showAdvancedButton:!1},useSearchForm:!0,showTableSetting:!1,bordered:!0,showIndexColumn:!1,canResize:!1,rowKey:t=>t.id,actionColumn:{width:180,title:"操作",dataIndex:"action",fixed:void 0}});G(()=>{WebViewService.setIsLoading(!1).then(()=>{})});const w=t=>{const g=t,{pageNum:n,pageSize:u,field:f="id",order:m="descend"}=g,I=x(g,["pageNum","pageSize","field","order"]),s={pageNum:n,pageSize:u,orderByClause:`${f} ${m==="descend"?"desc":"asc"}`};return Object.keys(I).forEach(_=>{const l=C.find(M=>M.field===_),o=t[_],r=_;l?o!==void 0&&o!==""&&(l.component==="Input"?s[r]=`%${o.trim()}%`:["Select","ApiSelect","ApiTreeSelect"].includes(l.component)?s[r]=V(o)?o.value:o:l.component==="RangePicker"?(s[`${r}From`]=h(o[0]).startOf("d").format("YYYY-MM-DD HH:mm:ss"),s[`${r}To`]=h(o[1]).endOf("d").format("YYYY-MM-DD HH:mm:ss")):l.component==="DatePicker"?s[r]=h(o).format(l.componentProps.format||"YYYY-MM-DD"):s[r]=o):s[r]=o}),s},y=()=>{i(!0,{isUpdate:!1})},T=t=>{i(!0,{record:t,isUpdate:!0})},k=t=>{z(t.id).then(n=>{v()})},B=()=>{v()};return(t,n)=>{const u=L("a-button");return S(),Z("div",null,[Y("div",ee,[p(c(O),{size:"19",name:"list"}),n[0]||(n[0]=Y("div",{class:"title"},"设备列表",-1))]),p(c($),{onRegister:c(e)},{toolbar:b(()=>[p(u,{type:"primary",onClick:y,icon:q(c(H))},{default:b(()=>n[1]||(n[1]=[J("新增")])),_:1},8,["icon"])]),bodyCell:b(({column:f,record:m})=>[f.dataIndex==="action"?(S(),Q(c(j),{key:0,actions:[{label:"编辑",icon:"clarity:note-edit-line",onClick:T.bind(null,m),divider:!0},{label:"删除",icon:"ant-design:delete-outlined",color:"error",popConfirm:{title:"是否确认删除",confirm:k.bind(null,m),placement:"topRight"}}]},null,8,["actions"])):X("",!0)]),_:1},8,["onRegister"]),p(K,{onRegister:c(d),onSuccess:B},null,8,["onRegister"])])}}});const he=A(te,[["__scopeId","data-v-56d2e6a3"]]);export{he as default}; var D=Object.getOwnPropertySymbols;var R=Object.prototype.hasOwnProperty,N=Object.prototype.propertyIsEnumerable;var x=(a,d)=>{var i={};for(var e in a)R.call(a,e)&&d.indexOf(e)<0&&(i[e]=a[e]);if(a!=null&&D)for(var e of D(a))d.indexOf(e)<0&&N.call(a,e)&&(i[e]=a[e]);return i};import{u as P,B as $}from"./useTable-e949a6b7.js";import{T as j}from"./useForm-baba730a.js";import{S as O,j as V,_ as A}from"./index.js";import{N as H,j as h}from"./antd-0679333d.js";import{r as z,s as E}from"./deviceApi-260fcde9.js";import{u as F}from"./index-679d8a0a.js";import{D as K,c as U,s as C}from"./drawer-dcc643f2.js";import{d as W,o as G,a6 as L,Z as S,_ as Z,$ as Y,k as p,u as c,a5 as b,l as q,G as J,a4 as Q,a8 as X}from"./vue-72a104e4.js";import"./index-8a6826ba.js";import"./useWindowSizeFn-1db11f4f.js";import"./onMountedOrActivated-ee461833.js";import"./sortable.esm-15c0a34e.js";import"./copyTextToClipboard-3ca69a78.js";const ee={class:"header"},te=W({__name:"index",setup(a){const[d,{openDrawer:i}]=F(),[e,{reload:v}]=P({api:t=>E(w(t)),columns:U,formConfig:{labelWidth:0,schemas:C,showAdvancedButton:!1},useSearchForm:!0,showTableSetting:!1,bordered:!0,showIndexColumn:!1,canResize:!1,rowKey:t=>t.id,actionColumn:{width:180,title:"操作",dataIndex:"action",fixed:void 0}});G(()=>{WebViewService.setIsLoading(!1).then(()=>{})});const w=t=>{const g=t,{pageNum:n,pageSize:u,field:f="id",order:m="descend"}=g,I=x(g,["pageNum","pageSize","field","order"]),s={pageNum:n,pageSize:u,orderByClause:`${f} ${m==="descend"?"desc":"asc"}`};return Object.keys(I).forEach(_=>{const l=C.find(M=>M.field===_),o=t[_],r=_;l?o!==void 0&&o!==""&&(l.component==="Input"?s[r]=`%${o.trim()}%`:["Select","ApiSelect","ApiTreeSelect"].includes(l.component)?s[r]=V(o)?o.value:o:l.component==="RangePicker"?(s[`${r}From`]=h(o[0]).startOf("d").format("YYYY-MM-DD HH:mm:ss"),s[`${r}To`]=h(o[1]).endOf("d").format("YYYY-MM-DD HH:mm:ss")):l.component==="DatePicker"?s[r]=h(o).format(l.componentProps.format||"YYYY-MM-DD"):s[r]=o):s[r]=o}),s},y=()=>{i(!0,{isUpdate:!1})},T=t=>{i(!0,{record:t,isUpdate:!0})},k=t=>{z(t.id).then(n=>{v()})},B=()=>{v()};return(t,n)=>{const u=L("a-button");return S(),Z("div",null,[Y("div",ee,[p(c(O),{size:"19",name:"list"}),n[0]||(n[0]=Y("div",{class:"title"},"设备列表",-1))]),p(c($),{onRegister:c(e)},{toolbar:b(()=>[p(u,{type:"primary",onClick:y,icon:q(c(H))},{default:b(()=>n[1]||(n[1]=[J("新增")])),_:1},8,["icon"])]),bodyCell:b(({column:f,record:m})=>[f.dataIndex==="action"?(S(),Q(c(j),{key:0,actions:[{label:"编辑",icon:"clarity:note-edit-line",onClick:T.bind(null,m),divider:!0},{label:"删除",icon:"ant-design:delete-outlined",color:"error",popConfirm:{title:"是否确认删除",confirm:k.bind(null,m),placement:"topRight"}}]},null,8,["actions"])):X("",!0)]),_:1},8,["onRegister"]),p(K,{onRegister:c(d),onSuccess:B},null,8,["onRegister"])])}}});const he=A(te,[["__scopeId","data-v-56d2e6a3"]]);export{he as default};

View File

@ -1 +1 @@
import{k as _,B,b1 as T,u as y,a8 as l,_ as D}from"./index.js";import{c as d,u as L}from"./index-fb041426.js";import{aZ as P}from"./antd-0679333d.js";import{d as w,c as f,u as t,Z as s,_ as C,k as E,a4 as S,a8 as k,a1 as F,F as v,a6 as a}from"./vue-72a104e4.js";import"./index-263734bb.js";import"./index-0a75e8e4.js";import"./useContentViewHeight-1771cd5b.js";import"./useWindowSizeFn-1db11f4f.js";import"./lock-a170f962.js";const x=w({name:"LayoutFeatures",components:{BackTop:P,LayoutLockPage:d(()=>_(()=>import("./index-6c3f423b.js"),["./index-6c3f423b.js","./vue-72a104e4.js","./LockPage-1f0cbf71.js","./index.js","./antd-0679333d.js","./index-a17248e3.css","./lock-a170f962.js","./header-b90f4bbc.js","./LockPage-b0b08e00.css"],import.meta.url)),SettingDrawer:d(()=>_(()=>import("./index-ddf909b2.js").then(e=>e.i),["./index-ddf909b2.js","./index-679d8a0a.js","./index.js","./vue-72a104e4.js","./antd-0679333d.js","./index-a17248e3.css","./index-ac2d527c.css","./index-fb041426.js","./index-263734bb.js","./index-0a75e8e4.js","./useContentViewHeight-1771cd5b.js","./useWindowSizeFn-1db11f4f.js","./index-054645fa.css","./lock-a170f962.js","./index-fffcad33.css"],import.meta.url))},setup(){const{getUseOpenBackTop:e,getShowSettingButton:i,getSettingButtonPosition:u,getFullContent:c}=B(),p=T(),{prefixCls:m}=y("setting-drawer-feature"),{getShowHeader:o}=L(),n=f(()=>p.getSessionTimeout),r=f(()=>{if(!t(i))return!1;const g=t(u);return g===l.AUTO?!t(o)||t(c):g===l.FIXED});return{getTarget:()=>document.body,getUseOpenBackTop:e,getIsFixedSettingDrawer:r,prefixCls:m,getIsSessionTimeout:n}}});function I(e,i,u,c,p,m){const o=a("LayoutLockPage"),n=a("BackTop"),r=a("SettingDrawer");return s(),C(v,null,[E(o),e.getUseOpenBackTop?(s(),S(n,{key:0,target:e.getTarget},null,8,["target"])):k("",!0),e.getIsFixedSettingDrawer?(s(),S(r,{key:1,class:F(e.prefixCls)},null,8,["class"])):k("",!0)],64)}const N=D(x,[["render",I]]);export{N as default}; import{k as _,B,b1 as T,u as y,a8 as l,_ as D}from"./index.js";import{c as d,u as L}from"./index-fb041426.js";import{aZ as P}from"./antd-0679333d.js";import{d as w,c as f,u as t,Z as s,_ as C,k as E,a4 as S,a8 as k,a1 as F,F as v,a6 as a}from"./vue-72a104e4.js";import"./index-263734bb.js";import"./index-0a75e8e4.js";import"./useContentViewHeight-1771cd5b.js";import"./useWindowSizeFn-1db11f4f.js";import"./lock-a170f962.js";const x=w({name:"LayoutFeatures",components:{BackTop:P,LayoutLockPage:d(()=>_(()=>import("./index-6c3f423b.js"),["./index-6c3f423b.js","./vue-72a104e4.js","./LockPage-1f0cbf71.js","./index.js","./antd-0679333d.js","./index-6d9b3862.css","./lock-a170f962.js","./header-b90f4bbc.js","./LockPage-b0b08e00.css"],import.meta.url)),SettingDrawer:d(()=>_(()=>import("./index-ddf909b2.js").then(e=>e.i),["./index-ddf909b2.js","./index-679d8a0a.js","./index.js","./vue-72a104e4.js","./antd-0679333d.js","./index-6d9b3862.css","./index-ac2d527c.css","./index-fb041426.js","./index-263734bb.js","./index-0a75e8e4.js","./useContentViewHeight-1771cd5b.js","./useWindowSizeFn-1db11f4f.js","./index-054645fa.css","./lock-a170f962.js","./index-fffcad33.css"],import.meta.url))},setup(){const{getUseOpenBackTop:e,getShowSettingButton:i,getSettingButtonPosition:u,getFullContent:c}=B(),p=T(),{prefixCls:m}=y("setting-drawer-feature"),{getShowHeader:o}=L(),n=f(()=>p.getSessionTimeout),r=f(()=>{if(!t(i))return!1;const g=t(u);return g===l.AUTO?!t(o)||t(c):g===l.FIXED});return{getTarget:()=>document.body,getUseOpenBackTop:e,getIsFixedSettingDrawer:r,prefixCls:m,getIsSessionTimeout:n}}});function I(e,i,u,c,p,m){const o=a("LayoutLockPage"),n=a("BackTop"),r=a("SettingDrawer");return s(),C(v,null,[E(o),e.getUseOpenBackTop?(s(),S(n,{key:0,target:e.getTarget},null,8,["target"])):k("",!0),e.getIsFixedSettingDrawer?(s(),S(r,{key:1,class:F(e.prefixCls)},null,8,["class"])):k("",!0)],64)}const N=D(x,[["render",I]]);export{N as default};

View File

@ -1 +1 @@
import{k as D,p as U,u as b,an as N,v as O,X as P,bc as S,_ as x}from"./index.js";import{D as A}from"./siteSetting-efd6ab5b.js";import{c as v,u as E}from"./index-fb041426.js";import{u as R}from"./index-8a6826ba.js";import{h as V}from"./header-b90f4bbc.js";import{D as B,q as L}from"./antd-0679333d.js";import{d as T,c as F,Z as l,_ as q,k as t,a5 as g,F as z,a6 as n,a4 as k,a8 as _,$ as a,a1 as s,a0 as I}from"./vue-72a104e4.js";import"./index-263734bb.js";import"./index-0a75e8e4.js";import"./useContentViewHeight-1771cd5b.js";import"./useWindowSizeFn-1db11f4f.js";import"./lock-a170f962.js";const H=T({name:"UserDropdown",components:{Dropdown:B,Menu:L,MenuItem:v(()=>D(()=>import("./DropMenuItem-91227dd6.js"),["./DropMenuItem-91227dd6.js","./index.js","./vue-72a104e4.js","./antd-0679333d.js","./index-a17248e3.css"],import.meta.url)),MenuDivider:L.Divider,LockAction:v(()=>D(()=>import("./LockModal-dca74201.js"),["./LockModal-dca74201.js","./index.js","./vue-72a104e4.js","./antd-0679333d.js","./index-a17248e3.css","./index-8a6826ba.js","./useWindowSizeFn-1db11f4f.js","./index-7064e331.css","./useForm-baba730a.js","./copyTextToClipboard-3ca69a78.js","./useForm-01d9c31d.css","./lock-a170f962.js","./header-b90f4bbc.js","./LockModal-ca58db68.css"],import.meta.url))},props:{theme:U.oneOf(["dark","light"])},setup(){const{prefixCls:e}=b("header-user-dropdown"),{t:h}=O(),{getShowDoc:C,getUseLockPage:w}=E(),c=N(),y=F(()=>{const{realName:f="",avatar:M,tenant:$}=c.getUserInfo||{};return{realName:f,avatar:M||V,desc:"",tenant:$}}),[o,{openModal:p}]=R();function u(){p(!0)}function d(){c.confirmLoginOut()}function m(){P(A)}function r(){S.push("/change-password")}function i(f){switch(f.key){case"password":r();break;case"logout":d();break;case"doc":m();break;case"lock":u();break}}return{prefixCls:e,t:h,getUserInfo:y,handleMenuClick:i,getShowDoc:C,register:o,getUseLockPage:w}}});const W=["src"];function X(e,h,C,w,c,y){const o=n("MenuItem"),p=n("MenuDivider"),u=n("Menu"),d=n("Dropdown"),m=n("LockAction");return l(),q(z,null,[t(d,{placement:"bottomLeft",overlayClassName:`${e.prefixCls}-dropdown-overlay`},{overlay:g(()=>[t(u,{onClick:e.handleMenuClick},{default:g(()=>[e.getShowDoc?(l(),k(o,{key:"doc",text:e.t("layout.header.dropdownItemDoc"),icon:"ion:document-text-outline"},null,8,["text"])):_("",!0),e.getShowDoc?(l(),k(p,{key:1})):_("",!0),e.getUseLockPage?(l(),k(o,{key:"lock",text:e.t("layout.header.tooltipLock"),icon:"ion:lock-closed-outline"},null,8,["text"])):_("",!0),t(o,{key:"password",text:e.t("layout.header.tooltipChangePassword"),icon:"ion:document-lock-outline"},null,8,["text"]),t(o,{key:"logout",text:e.t("layout.header.dropdownItemLoginOut"),icon:"ion:power-outline"},null,8,["text"])]),_:1},8,["onClick"])]),default:g(()=>{var r,i;return[a("span",{class:s([[e.prefixCls,`${e.prefixCls}--${e.theme}`],"flex"])},[a("span",{style:{"margin-right":"10px"},class:s(`${e.prefixCls}__name`)},I((i=(r=e.getUserInfo.tenant)==null?void 0:r.productList)==null?void 0:i[0].name),3),a("img",{class:s(`${e.prefixCls}__header`),src:e.getUserInfo.avatar},null,10,W),a("span",{class:s(`${e.prefixCls}__info hidden md:block`)},[a("span",{class:s([`${e.prefixCls}__name`,"truncate"])},I(e.getUserInfo.realName),3)],2)],2)]}),_:1},8,["overlayClassName"]),t(m,{onRegister:e.register},null,8,["onRegister"])],64)}const se=x(H,[["render",X]]);export{se as default}; import{k as D,p as U,u as b,an as N,v as O,X as P,bc as S,_ as x}from"./index.js";import{D as A}from"./siteSetting-efd6ab5b.js";import{c as v,u as E}from"./index-fb041426.js";import{u as R}from"./index-8a6826ba.js";import{h as V}from"./header-b90f4bbc.js";import{D as B,q as L}from"./antd-0679333d.js";import{d as T,c as F,Z as l,_ as q,k as t,a5 as g,F as z,a6 as n,a4 as k,a8 as _,$ as a,a1 as s,a0 as I}from"./vue-72a104e4.js";import"./index-263734bb.js";import"./index-0a75e8e4.js";import"./useContentViewHeight-1771cd5b.js";import"./useWindowSizeFn-1db11f4f.js";import"./lock-a170f962.js";const H=T({name:"UserDropdown",components:{Dropdown:B,Menu:L,MenuItem:v(()=>D(()=>import("./DropMenuItem-91227dd6.js"),["./DropMenuItem-91227dd6.js","./index.js","./vue-72a104e4.js","./antd-0679333d.js","./index-6d9b3862.css"],import.meta.url)),MenuDivider:L.Divider,LockAction:v(()=>D(()=>import("./LockModal-dca74201.js"),["./LockModal-dca74201.js","./index.js","./vue-72a104e4.js","./antd-0679333d.js","./index-6d9b3862.css","./index-8a6826ba.js","./useWindowSizeFn-1db11f4f.js","./index-7064e331.css","./useForm-baba730a.js","./copyTextToClipboard-3ca69a78.js","./useForm-01d9c31d.css","./lock-a170f962.js","./header-b90f4bbc.js","./LockModal-ca58db68.css"],import.meta.url))},props:{theme:U.oneOf(["dark","light"])},setup(){const{prefixCls:e}=b("header-user-dropdown"),{t:h}=O(),{getShowDoc:C,getUseLockPage:w}=E(),c=N(),y=F(()=>{const{realName:f="",avatar:M,tenant:$}=c.getUserInfo||{};return{realName:f,avatar:M||V,desc:"",tenant:$}}),[o,{openModal:p}]=R();function u(){p(!0)}function d(){c.confirmLoginOut()}function m(){P(A)}function r(){S.push("/change-password")}function i(f){switch(f.key){case"password":r();break;case"logout":d();break;case"doc":m();break;case"lock":u();break}}return{prefixCls:e,t:h,getUserInfo:y,handleMenuClick:i,getShowDoc:C,register:o,getUseLockPage:w}}});const W=["src"];function X(e,h,C,w,c,y){const o=n("MenuItem"),p=n("MenuDivider"),u=n("Menu"),d=n("Dropdown"),m=n("LockAction");return l(),q(z,null,[t(d,{placement:"bottomLeft",overlayClassName:`${e.prefixCls}-dropdown-overlay`},{overlay:g(()=>[t(u,{onClick:e.handleMenuClick},{default:g(()=>[e.getShowDoc?(l(),k(o,{key:"doc",text:e.t("layout.header.dropdownItemDoc"),icon:"ion:document-text-outline"},null,8,["text"])):_("",!0),e.getShowDoc?(l(),k(p,{key:1})):_("",!0),e.getUseLockPage?(l(),k(o,{key:"lock",text:e.t("layout.header.tooltipLock"),icon:"ion:lock-closed-outline"},null,8,["text"])):_("",!0),t(o,{key:"password",text:e.t("layout.header.tooltipChangePassword"),icon:"ion:document-lock-outline"},null,8,["text"]),t(o,{key:"logout",text:e.t("layout.header.dropdownItemLoginOut"),icon:"ion:power-outline"},null,8,["text"])]),_:1},8,["onClick"])]),default:g(()=>{var r,i;return[a("span",{class:s([[e.prefixCls,`${e.prefixCls}--${e.theme}`],"flex"])},[a("span",{style:{"margin-right":"10px"},class:s(`${e.prefixCls}__name`)},I((i=(r=e.getUserInfo.tenant)==null?void 0:r.productList)==null?void 0:i[0].name),3),a("img",{class:s(`${e.prefixCls}__header`),src:e.getUserInfo.avatar},null,10,W),a("span",{class:s(`${e.prefixCls}__info hidden md:block`)},[a("span",{class:s([`${e.prefixCls}__name`,"truncate"])},I(e.getUserInfo.realName),3)],2)],2)]}),_:1},8,["overlayClassName"]),t(m,{onRegister:e.register},null,8,["onRegister"])],64)}const se=x(H,[["render",X]]);export{se as default};

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
import{B as g,u as v}from"./useTable-e949a6b7.js";import{T as C}from"./useForm-baba730a.js";import{S as w,r as S,q as T,s as B,_ as R}from"./index.js";import{u as k}from"./index-679d8a0a.js";import{R as D,c as y,s as I}from"./drawer-c24723db.js";import{d as $,l as A,o as E,a6 as a,Z as _,_ as F,$ as h,k as r,a5 as m,G as N,a4 as V,a8 as x}from"./vue-72a104e4.js";import{N as M}from"./antd-0679333d.js";import"./index-8a6826ba.js";import"./useWindowSizeFn-1db11f4f.js";import"./onMountedOrActivated-ee461833.js";import"./sortable.esm-15c0a34e.js";import"./copyTextToClipboard-3ca69a78.js";import"./authorityApi-b12c1221.js";const P=$({name:"UserPage",methods:{PlusOutlined:M,h:A},components:{SvgIcon:w,BasicTable:g,RoleDrawer:D,TableAction:C},setup(){const{createMessage:e}=T(),[o,{openDrawer:i}]=k(),[p,{reload:l}]=v({api:B,columns:y,formConfig:{labelWidth:0,schemas:I,showAdvancedButton:!1},useSearchForm:!0,showTableSetting:!1,bordered:!0,showIndexColumn:!1,canResize:!1,pagination:!1,actionColumn:{width:180,title:"操作",dataIndex:"action",fixed:void 0}});function f(){i(!0,{isUpdate:!1})}function c(n){i(!0,{record:n,isUpdate:!0})}function d(n){S(n.id).then(t=>{e.success("删除用户成功!"),l()},t=>{e.error(`删除用户失败:${t}`)})}function u(){l()}return E(()=>{WebViewService.setIsLoading(!1).then(()=>{})}),{registerTable:p,registerDrawer:o,handleCreate:f,handleEdit:c,handleDelete:d,handleSuccess:u}}});const U={class:"header"};function z(e,o,i,p,l,f){const c=a("SvgIcon"),d=a("a-button"),u=a("TableAction"),n=a("BasicTable"),t=a("RoleDrawer");return _(),F("div",null,[h("div",U,[r(c,{size:"19",name:"list"}),o[0]||(o[0]=h("div",{class:"title"},"用户列表",-1))]),r(n,{onRegister:e.registerTable},{toolbar:m(()=>[r(d,{type:"primary",onClick:e.handleCreate,icon:e.h(e.PlusOutlined)},{default:m(()=>o[1]||(o[1]=[N("新 增")])),_:1},8,["onClick","icon"])]),bodyCell:m(({column:b,record:s})=>[b.key==="action"?(_(),V(u,{key:0,actions:[{label:"编辑",icon:"clarity:note-edit-line",onClick:e.handleEdit.bind(null,s),divider:!0,disabled:s.username==="admin"},{label:"删除",icon:"ant-design:delete-outlined",color:"error",popConfirm:{title:"是否确认删除",confirm:e.handleDelete.bind(null,s),placement:"topRight"},disabled:s.username==="admin"}]},null,8,["actions"])):x("",!0)]),_:1},8,["onRegister"]),r(t,{onRegister:e.registerDrawer,onSuccess:e.handleSuccess},null,8,["onRegister","onSuccess"])])}const ee=R(P,[["render",z],["__scopeId","data-v-90dcdd60"]]);export{ee as default}; import{B as g,u as v}from"./useTable-e949a6b7.js";import{T as C}from"./useForm-baba730a.js";import{S as w,r as S,q as T,s as B,_ as R}from"./index.js";import{u as k}from"./index-679d8a0a.js";import{R as D,c as y,s as I}from"./drawer-b1df0d5f.js";import{d as $,l as A,o as E,a6 as a,Z as _,_ as F,$ as h,k as r,a5 as m,G as N,a4 as V,a8 as x}from"./vue-72a104e4.js";import{N as M}from"./antd-0679333d.js";import"./index-8a6826ba.js";import"./useWindowSizeFn-1db11f4f.js";import"./onMountedOrActivated-ee461833.js";import"./sortable.esm-15c0a34e.js";import"./copyTextToClipboard-3ca69a78.js";import"./authorityApi-b12c1221.js";const P=$({name:"UserPage",methods:{PlusOutlined:M,h:A},components:{SvgIcon:w,BasicTable:g,RoleDrawer:D,TableAction:C},setup(){const{createMessage:e}=T(),[o,{openDrawer:i}]=k(),[p,{reload:l}]=v({api:B,columns:y,formConfig:{labelWidth:0,schemas:I,showAdvancedButton:!1},useSearchForm:!0,showTableSetting:!1,bordered:!0,showIndexColumn:!1,canResize:!1,pagination:!1,actionColumn:{width:180,title:"操作",dataIndex:"action",fixed:void 0}});function f(){i(!0,{isUpdate:!1})}function c(n){i(!0,{record:n,isUpdate:!0})}function d(n){S(n.id).then(t=>{e.success("删除用户成功!"),l()},t=>{e.error(`删除用户失败:${t}`)})}function u(){l()}return E(()=>{WebViewService.setIsLoading(!1).then(()=>{})}),{registerTable:p,registerDrawer:o,handleCreate:f,handleEdit:c,handleDelete:d,handleSuccess:u}}});const U={class:"header"};function z(e,o,i,p,l,f){const c=a("SvgIcon"),d=a("a-button"),u=a("TableAction"),n=a("BasicTable"),t=a("RoleDrawer");return _(),F("div",null,[h("div",U,[r(c,{size:"19",name:"list"}),o[0]||(o[0]=h("div",{class:"title"},"用户列表",-1))]),r(n,{onRegister:e.registerTable},{toolbar:m(()=>[r(d,{type:"primary",onClick:e.handleCreate,icon:e.h(e.PlusOutlined)},{default:m(()=>o[1]||(o[1]=[N("新 增")])),_:1},8,["onClick","icon"])]),bodyCell:m(({column:b,record:s})=>[b.key==="action"?(_(),V(u,{key:0,actions:[{label:"编辑",icon:"clarity:note-edit-line",onClick:e.handleEdit.bind(null,s),divider:!0,disabled:s.username==="admin"},{label:"删除",icon:"ant-design:delete-outlined",color:"error",popConfirm:{title:"是否确认删除",confirm:e.handleDelete.bind(null,s),placement:"topRight"},disabled:s.username==="admin"}]},null,8,["actions"])):x("",!0)]),_:1},8,["onRegister"]),r(t,{onRegister:e.registerDrawer,onSuccess:e.handleSuccess},null,8,["onRegister","onSuccess"])])}const ee=R(P,[["render",z],["__scopeId","data-v-90dcdd60"]]);export{ee as default};

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
<!doctype html><html lang="en" id="htmlRoot"><head><script crossorigin src="./_app.config.js"></script><meta charset="UTF-8"/><meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/><meta name="renderer" content="webkit"/><meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=0"/><title>中核集团预埋件检测系统</title><link rel="icon" href="./favicon.ico"/><style>#app{background-color:#0d1540}</style><script type="module" crossorigin src="./assets/index.js"></script><link rel="modulepreload" crossorigin href="./assets/vue-72a104e4.js"><link rel="modulepreload" crossorigin href="./assets/antd-0679333d.js"><link rel="stylesheet" href="./assets/index-a17248e3.css"></head><body><div id="app"><style>html[data-theme=dark] .app-loading{background-color:transparent}html[data-theme=dark] .app-loading .app-loading-title{color:transparent}.app-loading{display:flex;flex-direction:column;align-items:center;justify-content:center;width:100%;height:100%;background-color:transparent}.app-loading .app-loading-wrap{display:flex;position:absolute;top:50%;left:50%;flex-direction:column;align-items:center;justify-content:center;transform:translate3d(-50%,-50%,0)}.app-loading .dots{display:flex;align-items:center;justify-content:center;padding:98px}.app-loading .app-loading-title{display:flex;align-items:center;justify-content:center;margin-top:30px;color:rgb(0 0 0 / 85%);font-size:30px}.app-loading .app-loading-logo{display:block;width:90px;margin:0 auto;margin-bottom:20px}.dot{display:inline-block;position:relative;box-sizing:border-box;width:48px;height:48px;margin-top:30px;transform:rotate(45deg);animation:ant-rotate 1.2s infinite linear;font-size:32px}.dot i{display:block;position:absolute;width:20px;height:20px;transform:scale(.75);transform-origin:50% 50%;animation:ant-spin-move 1s infinite linear alternate;border-radius:100%;opacity:.3;background-color:#0065cc}.dot i:first-child{top:0;left:0}.dot i:nth-child(2){top:0;right:0;animation-delay:.4s}.dot i:nth-child(3){right:0;bottom:0;animation-delay:.8s}.dot i:nth-child(4){bottom:0;left:0;animation-delay:1.2s}@keyframes ant-rotate{to{transform:rotate(405deg)}}@keyframes ant-rotate{to{transform:rotate(405deg)}}@keyframes ant-spin-move{to{opacity:1}}@keyframes ant-spin-move{to{opacity:1}}</style><div class="app-loading"><div class="app-loading-wrap"></div></div></div></body></html> <!doctype html><html lang="en" id="htmlRoot"><head><script crossorigin src="./_app.config.js"></script><meta charset="UTF-8"/><meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/><meta name="renderer" content="webkit"/><meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=0"/><title>中核集团预埋件检测系统</title><link rel="icon" href="./favicon.ico"/><style>#app{background-color:#0d1540}</style><script type="module" crossorigin src="./assets/index.js"></script><link rel="modulepreload" crossorigin href="./assets/vue-72a104e4.js"><link rel="modulepreload" crossorigin href="./assets/antd-0679333d.js"><link rel="stylesheet" href="./assets/index-6d9b3862.css"></head><body><div id="app"><style>html[data-theme=dark] .app-loading{background-color:transparent}html[data-theme=dark] .app-loading .app-loading-title{color:transparent}.app-loading{display:flex;flex-direction:column;align-items:center;justify-content:center;width:100%;height:100%;background-color:transparent}.app-loading .app-loading-wrap{display:flex;position:absolute;top:50%;left:50%;flex-direction:column;align-items:center;justify-content:center;transform:translate3d(-50%,-50%,0)}.app-loading .dots{display:flex;align-items:center;justify-content:center;padding:98px}.app-loading .app-loading-title{display:flex;align-items:center;justify-content:center;margin-top:30px;color:rgb(0 0 0 / 85%);font-size:30px}.app-loading .app-loading-logo{display:block;width:90px;margin:0 auto;margin-bottom:20px}.dot{display:inline-block;position:relative;box-sizing:border-box;width:48px;height:48px;margin-top:30px;transform:rotate(45deg);animation:ant-rotate 1.2s infinite linear;font-size:32px}.dot i{display:block;position:absolute;width:20px;height:20px;transform:scale(.75);transform-origin:50% 50%;animation:ant-spin-move 1s infinite linear alternate;border-radius:100%;opacity:.3;background-color:#0065cc}.dot i:first-child{top:0;left:0}.dot i:nth-child(2){top:0;right:0;animation-delay:.4s}.dot i:nth-child(3){right:0;bottom:0;animation-delay:.8s}.dot i:nth-child(4){bottom:0;left:0;animation-delay:1.2s}@keyframes ant-rotate{to{transform:rotate(405deg)}}@keyframes ant-rotate{to{transform:rotate(405deg)}}@keyframes ant-spin-move{to{opacity:1}}@keyframes ant-spin-move{to{opacity:1}}</style><div class="app-loading"><div class="app-loading-wrap"></div></div></div></body></html>