SysConfig.8e906377.js 4.0 KB

1
  1. import{P as e,Q as t,p as o,A as s}from"../element-plus/element-plus.a206f5fe.js";import{A as a,b as i}from"../../assets/index.9d3f0ed9.js";import{S as l}from"../SysConfig/SysConfig.b8170049.js";import{m as r}from"../como-admin-web/como-admin-web.4290f457.js";import{d as n,B as m,r as d,E as c,i as u,ad as p,o as f,c as j,P as b,S as C,Q as v,a9 as h,T as g,H as y,u as x,V as w,W as T,ak as _,al as I}from"../@vue/@vue.2e72eb65.js";import"../lodash-es/lodash-es.72245c2f.js";import"../async-validator/async-validator.21881447.js";import"../@vueuse/@vueuse.decddfd9.js";import"../dayjs/dayjs.c17b983f.js";import"../@element-plus/@element-plus.3703707e.js";import"../@ctrl/@ctrl.9c8f424f.js";import"../@popperjs/@popperjs.f1fb8f77.js";import"../normalize-wheel-es/normalize-wheel-es.94de1731.js";import"../vue-router/vue-router.8caf83cb.js";import"../mitt/mitt.fcf4f812.js";import"../como-ts-utils/como-ts-utils.52443996.js";import"../szjcomo-utils/szjcomo-utils.8c09309c.js";import"../crypto-js/crypto-js.38083f5b.js";import"../ua-parser-js/ua-parser-js.f2fc0435.js";import"../como-validator/como-validator.c3b2e2bb.js";import"../axios/axios.93b23c89.js";import"../pinia/pinia.0960c1bb.js";import"../vue-count-to/vue-count-to.ec270ea8.js";import"../@wangeditor/@wangeditor.bc4d1034.js";import"../xlsx/xlsx.a42c9766.js";import"../docx-preview/docx-preview.ad0b8171.js";import"../jszip/jszip.e379f989.js";import"../vue-como-image/vue-como-image.1f08e6a4.js";import"../echarts/echarts.adb31f9c.js";import"../tslib/tslib.e35f93b8.js";import"../zrender/zrender.a6916eca.js";import"../vue3-count-to/vue3-count-to.20d3c162.js";import"../BaseValidRule/BaseValidRule.98e536d5.js";import"../Controller/Controller.ef4ed6a0.js";const F=(e=[])=>{const t=[r.ElementTableColumnGender.Ins.Name("序号").Field("config_id").Width(70).Fixed(!0).Convert(),r.ElementTableColumnGender.Ins.Name("配置项名称").Field("field_label").Fixed(!0).Width(160).Convert(),r.ElementTableColumnGender.Ins.Name("配置项索引").Field("field_index").Width(200).Convert(),r.ElementTableColumnGender.Ins.Name("配置项说明").Field("field_desc").MinWidth(200).Convert(),r.ElementTableColumnGender.Ins.Name("状态").Field("field_status").Width(80).Type("switch").Convert(),r.ElementTableColumnGender.Ins.Name("排序").Field("field_sort").Width(70).Convert(),r.ElementTableColumnGender.Ins.Name("操作人员").Field("username").Width(100).Convert(),r.ElementTableColumnGender.Ins.Name("更新时间").Field("update_time").Width(180).Convert(),r.ElementTableColumnGender.Ins.Name("操作").Field("actions").Type("custom").Fixed("right").Width(170).Convert()];return r.ComoTableComponent.Ins.Columns(t).Pagination({currentPage:r.ElementTableColumnGender.Ins.CurrentPage,pageSize:200,total:0}).FooterShow(!1).RowHeight(60,"px").Data(e).Border().MaxHeight("80vh").toObject()},G={class:"ConfigsList"},E=n({__name:"SysConfig",setup(r){const n=m("comoDialog"),E=l.Ins.SetDialogIns(n),S=d([]),W=d(a.Ins.GetThemeColor()),z=async function(){const e=await E.Select({page:1,limit:1e3});S.value=e};return c((async()=>{W.value=await i().GetAppProThemeColor()})),u((()=>z())),(a,i)=>{const l=o,r=s,n=p("como-table"),m=e,d=t;return f(),j("div",G,[b(d,{type:"border-card",class:"sys-config-tabs"},{default:C((()=>[(f(!0),j(v,null,h(S.value,((e,t)=>(f(),g(m,{key:t,label:`${e.name}`},{default:C((()=>[b(n,y(x(F)(e.children),{onSwitchChange:i[1]||(i[1]=e=>x(E).SwitchChangeConfig(e,z)),"table-theme-color":W.value}),{headerLeft:C((()=>[b(l,{type:"danger",style:w({backgroundColor:W.value,border:"none"}),onClick:i[0]||(i[0]=()=>x(E).Create({},S.value,z))},{default:C((()=>[T(" 添加配置项 ")])),_:1},8,["style"])])),buttons:C((e=>[b(r,_(I(e.column)),{default:C((e=>[b(l,{type:"success",text:"",onClick:()=>x(E).Update(e.row,S.value,z)},{default:C((()=>[T("编辑")])),_:2},1032,["onClick"]),b(l,{type:"danger",text:"",onClick:()=>x(E).Delete(e.row,z)},{default:C((()=>[T("删除")])),_:2},1032,["onClick"])])),_:2},1040)])),_:2},1040,["table-theme-color"])])),_:2},1032,["label"])))),128))])),_:1})])}}});export{E as default};