ss-component-new 1.1.821 → 1.1.823
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{OrbitControls-D6pgin7s.js → OrbitControls-Cm4Xs_Bq.js} +1 -1
- package/dist/{OrbitControls-Ff5ikkUQ.cjs → OrbitControls-D-XDZGf-.cjs} +1 -1
- package/dist/{STLLoader-BNh7D2zV.cjs → STLLoader-BxpEhvEg.cjs} +161 -161
- package/dist/{STLLoader-LGKv5i3H.js → STLLoader-DofhZbOw.js} +522 -593
- package/dist/{array-D1hKYLwI.cjs → array-Bfmx0w6P.cjs} +2 -2
- package/dist/{array-C60T9pDZ.js → array-DbAuNWGt.js} +1 -1
- package/dist/{iconfont-v9CcCMwF.js → iconfont-DQodgJo8.js} +73 -75
- package/dist/iconfont-Di4uXnX1.cjs +1 -0
- package/dist/icons/svg/editTable.svg +1 -1
- package/dist/icons/svg/export.svg +1 -0
- package/dist/icons/svg/model.svg +1 -0
- package/dist/icons/svg/three.svg +1 -0
- package/dist/index-1i-XlS2m.js +101 -0
- package/dist/{index-BdsJiFeW.cjs → index-6jSC3unU.cjs} +1 -1
- package/dist/{index-2kzGjuzu.js → index-6zbHinQ6.js} +10 -9
- package/dist/index-B-oe2x1V.cjs +109 -0
- package/dist/index-B-qent3l.cjs +1 -0
- package/dist/{index-CukZ8eDZ.js → index-BBo52W9F.js} +4 -4
- package/dist/index-BOev8isw.cjs +21 -0
- package/dist/index-BQgnYD51.js +6492 -0
- package/dist/{index-owcnOlVq.js → index-BYW-ix_Q.js} +5 -5
- package/dist/{index-4_M1SpeV.js → index-Bi1gr72d.js} +14 -14
- package/dist/{index-DnVaHi8q.js → index-BmHmnXS9.js} +7 -7
- package/dist/index-BoS30LXH.cjs +1 -0
- package/dist/index-BuBMi9JA.cjs +1 -0
- package/dist/{index-Zi9xLtwj.js → index-BvE05H-i.js} +2 -2
- package/dist/index-BwpOMKef.cjs +1 -0
- package/dist/index-C18ZPRC7.cjs +1 -0
- package/dist/{index-HVJSfh2g.js → index-CJx2DcDb.js} +21 -19
- package/dist/{index-B3cUSGXB.js → index-CL59qQ_W.js} +9 -8
- package/dist/{index-DDsJpzfR.js → index-CLdN0W98.js} +47 -47
- package/dist/index-CPP7L10q.cjs +1 -0
- package/dist/index-CSWIBSmo.cjs +1 -0
- package/dist/{index-DEobyz7r.js → index-CTgZZ96L.js} +6 -5
- package/dist/{index-WXpPDsev.js → index-CZ1ui4mT.js} +1 -1
- package/dist/index-CfQvGqaX.cjs +1 -0
- package/dist/index-CgJYAzeA.cjs +1 -0
- package/dist/{index-Cuj-fGNO.cjs → index-ChZHGw_N.cjs} +1 -1
- package/dist/index-ChtmIuBu.js +29771 -0
- package/dist/index-CjFcaJcL.cjs +1 -0
- package/dist/index-CjTmkzBO.js +24 -0
- package/dist/{index-Dtw4WkUo.cjs → index-CngO0AUc.cjs} +1 -1
- package/dist/index-CqCPdyGu.js +1248 -0
- package/dist/index-Cr6pWv0l.cjs +1 -0
- package/dist/{index-Cw95lvvp.js → index-D8Msszln.js} +223 -223
- package/dist/index-DDvUG6fk.js +22 -0
- package/dist/{index-CdMrhxHS.js → index-DMlIMlyC.js} +10 -10
- package/dist/{index-3Cdyqd1B.cjs → index-DOBeGYzT.cjs} +1 -1
- package/dist/index-DP0k43fj.cjs +1 -0
- package/dist/index-DTxccgVM.cjs +1 -0
- package/dist/{index-JAJeIBYE.cjs → index-DVAGljX0.cjs} +1 -1
- package/dist/{index-B5Vi6RBj.cjs → index-DVCrYVKw.cjs} +1 -1
- package/dist/{index-CY2iphpd.cjs → index-DbniLh9G.cjs} +1 -1
- package/dist/index-Dj_ofPeK.cjs +1 -0
- package/dist/{index-DtogzZej.js → index-DocnYz5P.js} +1 -1
- package/dist/index-DrL7vroa.js +319 -0
- package/dist/index-Dt2McMki.js +13668 -0
- package/dist/{index-Cphx1eY1.js → index-Gba1Qfcc.js} +7 -8
- package/dist/{index-DMb9Vu-7.js → index-IUkCD4R_.js} +1 -1
- package/dist/{index-DAyzDsjs.js → index-K6BRW_Bw.js} +1 -1
- package/dist/{index-DzM8zZqe.js → index-OH9t-y2p.js} +4 -4
- package/dist/index-PNDdZKYG.cjs +1 -0
- package/dist/{index-Dn04IPFM.js → index-QETLKFyV.js} +10 -10
- package/dist/{index-BWHtpT9o.cjs → index-RgTvyK54.cjs} +1 -1
- package/dist/{index-CF_0RdqV.cjs → index-dukFqRog.cjs} +1 -1
- package/dist/{index-C9Boo2Cw.cjs → index-dyoOdMKX.cjs} +1 -1
- package/dist/index-f9bwREQl.cjs +1 -0
- package/dist/{index-Dxoxm0Cc.js → index-mmWAqzR5.js} +25 -25
- package/dist/index-rPc9VS0S.cjs +1 -0
- package/dist/index-tPamnhR2.js +236 -0
- package/dist/{index-H3kf9EQv.js → index-tX2Hs05F.js} +11 -10
- package/dist/{index-DEU-pXeW.js → index-uvns6W6E.js} +1838 -1812
- package/dist/index-weauvEnW.cjs +4 -0
- package/dist/{index-B8xEed7C.cjs → index-wlnPb2aB.cjs} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-iyZtrhDf.js → index.vue_vue_type_script_setup_true_lang-C4G6mB7R.js} +28 -28
- package/dist/{index.vue_vue_type_script_setup_true_lang-CaYQQb8M.cjs → index.vue_vue_type_script_setup_true_lang-CWi4UVPF.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-qefZ9E5G.js → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CtN9Ij0Y.js} +53 -23
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CTcahF4Z.cjs → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-mQIxU0SD.cjs} +90 -90
- package/dist/{index.vue_vue_type_style_index_0_scoped_6bfd62db_lang-Cxjh1E1z.js → index.vue_vue_type_style_index_0_scoped_1966237d_lang-D3xcEtDT.js} +6488 -6474
- package/dist/{index.vue_vue_type_style_index_0_scoped_6bfd62db_lang-0eNHRdYw.cjs → index.vue_vue_type_style_index_0_scoped_1966237d_lang-DwIFJsxs.cjs} +14 -14
- package/dist/{index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-kymzIBO8.js → index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-D5CTJUDi.js} +17 -17
- package/dist/{index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-GlR2V0TC.cjs → index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-VPQBXOPW.cjs} +1 -1
- package/dist/index.vue_vue_type_style_index_1_lang-DraQDAAw.cjs +32 -0
- package/dist/index.vue_vue_type_style_index_1_lang-hffXwR3x.js +7028 -0
- package/dist/isUndefined-4Qg9wncf.js +84 -0
- package/dist/isUndefined-BEt4O79g.cjs +1 -0
- package/dist/{main-C6I42yaU.js → main-CBCk94h5.js} +30 -29
- package/dist/main-DO_PN7jt.cjs +1 -0
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +2 -2
- package/dist/ss-component.js +11 -11
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +12 -12
- package/dist/threeModel-GKSAzHfe.cjs +1 -0
- package/dist/{threeModel-BEt5OVCP.js → threeModel-RJwJMtfW.js} +91 -92
- package/dist/{threePreview-BUZRvBRx.js → threePreview-BSqdALPK.js} +3 -3
- package/dist/{threePreview-Dyzqu5s7.cjs → threePreview-CKvbwCiX.cjs} +1 -1
- package/dist/threeSceneView-BVbVe_Et.js +1277 -0
- package/dist/threeSceneView-KvCERteS.cjs +5 -0
- package/dist/{threeViewerHost-IhSFkCeD.js → threeViewerHost-AuhfL2Cn.js} +55 -57
- package/dist/threeViewerHost-D0pu5wk5.cjs +1 -0
- package/package.json +1 -1
- package/public/icons/svg/editTable.svg +1 -1
- package/public/icons/svg/export.svg +1 -0
- package/public/icons/svg/model.svg +1 -0
- package/public/icons/svg/three.svg +1 -0
- package/dist/animationData-B2T3Oamw.js +0 -108
- package/dist/animationData-Db_9HBoM.cjs +0 -1
- package/dist/iconfont-CZj6ltAs.cjs +0 -1
- package/dist/index-2KKrCkl8.cjs +0 -1
- package/dist/index-2OWkrGDh.js +0 -24
- package/dist/index-B1iXzkUF.cjs +0 -1
- package/dist/index-BBB4VObc.cjs +0 -11
- package/dist/index-BIVWMqJQ.cjs +0 -1
- package/dist/index-BWpZSzL1.cjs +0 -1
- package/dist/index-BllULnvx.cjs +0 -1
- package/dist/index-BvO1uTn0.js +0 -21
- package/dist/index-C2bI4adc.js +0 -8628
- package/dist/index-C9pN8_un.js +0 -548
- package/dist/index-CPdKWCSo.cjs +0 -1
- package/dist/index-CQfFbeTJ.cjs +0 -1
- package/dist/index-CZJOPfp5.js +0 -1152
- package/dist/index-Cb0q1Y5b.cjs +0 -1
- package/dist/index-Cfomm0G1.cjs +0 -109
- package/dist/index-CvvFU_QA.cjs +0 -1
- package/dist/index-DYMLmifU.cjs +0 -1
- package/dist/index-DfPyuGyq.js +0 -101
- package/dist/index-Dm2qfeUm.cjs +0 -1
- package/dist/index-DtX1F0sz.cjs +0 -4
- package/dist/index-Du3VUDcF.cjs +0 -1
- package/dist/index-VWNqRYy9.js +0 -36270
- package/dist/index-kmj8K3JX.cjs +0 -1
- package/dist/index-ndZw4AQJ.cjs +0 -1
- package/dist/index-y5FEcncv.cjs +0 -1
- package/dist/index.vue_vue_type_style_index_1_lang-Bmwy3cgo.cjs +0 -42
- package/dist/index.vue_vue_type_style_index_1_lang-Rs1M3B8e.js +0 -11984
- package/dist/main-2gDZp_zL.cjs +0 -1
- package/dist/threeModel-DgOcIXVI.cjs +0 -1
- package/dist/threeSceneView-BZx98QgN.js +0 -1450
- package/dist/threeSceneView-DSkGJN5d.cjs +0 -5
- package/dist/threeViewerHost-T_51aUg5.cjs +0 -1
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { defineComponent as n, reactive as o, onMounted as r, createElementBlock as s, openBlock as c, createVNode as m } from "vue";
|
|
2
|
+
import { s as u } from "./index-ChtmIuBu.js";
|
|
3
|
+
import { S as i } from "./index-BmHmnXS9.js";
|
|
4
|
+
import { u as p, ay as l } from "./index.vue_vue_type_style_index_1_lang-hffXwR3x.js";
|
|
5
|
+
import { s as d } from "./index-Dt2McMki.js";
|
|
6
|
+
const x = /* @__PURE__ */ n({
|
|
7
|
+
__name: "index",
|
|
8
|
+
setup(f) {
|
|
9
|
+
const e = o({ ...i }), t = p(), { activeMenuPath: a } = d(t);
|
|
10
|
+
return r(async () => {
|
|
11
|
+
e.structureId = await l(a.value);
|
|
12
|
+
}), (_, g) => (c(), s("div", null, [
|
|
13
|
+
m(u, {
|
|
14
|
+
itemData: e.pageData,
|
|
15
|
+
onChange: e.handleItemDataChange
|
|
16
|
+
}, null, 8, ["itemData", "onChange"])
|
|
17
|
+
]));
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
export {
|
|
21
|
+
x as default
|
|
22
|
+
};
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { defineComponent as y, ref as C, onMounted as _, createElementBlock as c, openBlock as g, createVNode as v } from "vue";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { _ as
|
|
2
|
+
import { p as h, s as k, c as m, g as x } from "./index-Dt2McMki.js";
|
|
3
|
+
import { u as M } from "./index.vue_vue_type_style_index_1_lang-hffXwR3x.js";
|
|
4
|
+
import { s as D } from "./index-ChtmIuBu.js";
|
|
5
|
+
import { a as T, d as S, f as w } from "./index-IUkCD4R_.js";
|
|
6
|
+
import { _ as B } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
7
7
|
const N = { class: "menu-content" }, E = /* @__PURE__ */ y({
|
|
8
8
|
__name: "index",
|
|
9
9
|
setup(I) {
|
|
10
|
-
const p = h
|
|
10
|
+
const p = M(h), { menus: b } = k(p), r = C([]), f = async () => {
|
|
11
11
|
var o, l, t, a;
|
|
12
|
-
const e = await
|
|
12
|
+
const e = await x({
|
|
13
13
|
key: {
|
|
14
14
|
type: "mainEquip",
|
|
15
15
|
systemKey: sessionStorage.getItem("systemKey")
|
|
@@ -82,17 +82,17 @@ const N = { class: "menu-content" }, E = /* @__PURE__ */ y({
|
|
|
82
82
|
}), r.value = l;
|
|
83
83
|
});
|
|
84
84
|
const d = (e) => {
|
|
85
|
-
(e == null ? void 0 : e.buttonName) === "新增" ?
|
|
85
|
+
(e == null ? void 0 : e.buttonName) === "新增" ? T(e == null ? void 0 : e.singleContent) : (e == null ? void 0 : e.buttonName) === "删除" ? S(e == null ? void 0 : e.singleContent) : (e == null ? void 0 : e.buttonName) === "编辑" && w(e == null ? void 0 : e.singleContent);
|
|
86
86
|
};
|
|
87
87
|
return (e, o) => (g(), c("div", N, [
|
|
88
|
-
v(
|
|
88
|
+
v(D, {
|
|
89
89
|
itemData: r.value,
|
|
90
90
|
class: "table-content",
|
|
91
91
|
onChange: d
|
|
92
92
|
}, null, 8, ["itemData"])
|
|
93
93
|
]));
|
|
94
94
|
}
|
|
95
|
-
}), R = /* @__PURE__ */
|
|
95
|
+
}), R = /* @__PURE__ */ B(E, [["__scopeId", "data-v-26f5cadc"]]);
|
|
96
96
|
export {
|
|
97
97
|
R as default
|
|
98
98
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("./index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("./index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-VPQBXOPW.cjs"),e=require("vue"),_=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),C=["title"],f={key:0,class:"menu-operate-icon"},u={class:"menu-config-wrap"},k=["onClick"],h={class:"module-dialog-content"};function v(o,l,B,V,N,M){const i=e.resolveComponent("svg-icon"),d=e.resolveComponent("el-popover"),c=e.resolveComponent("ssMenu"),r=e.resolveComponent("el-button"),g=e.resolveComponent("ssDialog");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(c,{class:"vertical-menu",mode:o.mode,menuList:o.renderMenuList,onClickMenu:o.clickMenu,onOpenMenu:o.openMenu,onCloseMenu:o.closeMenu},{title:e.withCtx(({menu:t})=>{var s,a;return[e.createVNode(i,{name:t.icon??((t==null?void 0:t.level)<=2?"default":""),class:"menu-icon"},null,8,["name"]),e.createElementVNode("span",{title:t.title,class:"menu-title",style:e.normalizeStyle({marginRight:t!=null&&t.config&&((s=t==null?void 0:t.config)==null?void 0:s.length)>0?"25px":"1px"})},e.toDisplayString(t.title??""),13,C),t!=null&&t.config&&((a=t==null?void 0:t.config)==null?void 0:a.length)>0?(e.openBlock(),e.createElementBlock("span",f,[e.createVNode(d,{title:"",placement:"bottom-start",trigger:"click","popper-class":"menu-operate-popover"},{reference:e.withCtx(()=>[e.createVNode(i,{name:"config"})]),default:e.withCtx(()=>[e.createElementVNode("div",u,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t==null?void 0:t.config,n=>(e.openBlock(),e.createElementBlock("div",{class:"menu-config-item",key:n.id,onClick:b=>o.clickMenuIcon(t,n)},[e.createVNode(i,{name:n==null?void 0:n.operateIcon,style:{width:"15px",height:"15px","margin-right":"8px"}},null,8,["name"]),e.createElementVNode("span",null,e.toDisplayString(n==null?void 0:n.operateType),1)],8,k))),128))])]),_:2},1024)])):e.createCommentVNode("",!0)]}),_:1},8,["mode","menuList","onClickMenu","onOpenMenu","onCloseMenu"]),e.createVNode(g,{class:"module-dialog",title:o.dialogInfo.title,visible:o.dialogInfo.show,width:o.dialogInfo.width,onBeforeDestroy:o.beforeDialogDestroy},{default:e.withCtx(()=>[e.createElementVNode("div",h,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.dialogRenderComps,t=>(e.openBlock(),e.createElementBlock("div",{key:t.id},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.getComponents((t==null?void 0:t.comp)??"Input")),{itemData:t==null?void 0:t.compData,key:t==null?void 0:t.id,content:(t==null?void 0:t.contents)??[],config:t==null?void 0:t.config,onContentChange:o.handleCompChange},null,40,["itemData","content","config","onContentChange"]))]))),128))])]),footer:e.withCtx(()=>[e.createElementVNode("div",null,[e.createVNode(r,{id:"themeBorderButton",onClick:o.beforeDialogDestroy},{default:e.withCtx(()=>l[0]||(l[0]=[e.createTextVNode("取消")])),_:1,__:[0]},8,["onClick"]),e.createVNode(r,{id:"themeButton",onClick:o.clickSubmitForm},{default:e.withCtx(()=>l[1]||(l[1]=[e.createTextVNode(" 确认 ")])),_:1,__:[1]},8,["onClick"])])]),_:1},8,["title","visible","width","onBeforeDestroy"])],64)}const y=_._export_sfc(p._sfc_main,[["render",v],["__scopeId","data-v-86d2b6b8"]]);exports.default=y;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),I=require("./index.vue_vue_type_script_setup_true_lang-CWi4UVPF.cjs"),k=require("./threeViewerHost-D0pu5wk5.cjs"),C=require("./index-BOev8isw.cjs"),x=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),V=require("./index-weauvEnW.cjs"),S=require("./index-BpPyaNFa.cjs"),A={class:"avatar-model-wrap"},N={key:0},E=e.defineComponent({__name:"index",props:{disabled:{type:Boolean,default:!1},avatarUrl:{type:String,default:""},size:{type:[String,Number],default:"large"},userInfo:{type:Object,default:{}}},emits:["submitImage","deleteImage"],setup(s,{emit:y}){const u=s,i=y,m=e.computed(()=>"http://222.92.178.198:62001"),d=e.ref(""),h=e.ref(""),_=e.ref();e.watch(()=>{var o;return(o=u.userInfo)==null?void 0:o.avatarUrl},o=>{h.value=m.value+"/"+o},{immediate:!0});const w=async()=>{if(!(u!=null&&u.disabled))try{const o=await k.downloadAvatarApi({url:d.value});if(o.status!==200)throw new Error(`HTTP error! status: ${o.status}`);const f=new Blob([o.data],{type:o.headers["content-type"]});_.value=f}catch(o){throw new Error(o)}},B=async o=>{var f,g,t,n,c;try{const r=await k.uploadFile(o);((f=r==null?void 0:r.data)==null?void 0:f.code)===200&&(h.value=m.value+"/"+((t=(g=r.data)==null?void 0:g.result)==null?void 0:t.url),d.value=(c=(n=r.data)==null?void 0:n.result)==null?void 0:c.url,i("submitImage",d.value))}catch(r){C.ElMessage.error(r)}},b=async()=>{try{if(!h.value)return}catch(o){C.ElMessage.error(o)}};return(o,f)=>{var g,t;return e.openBlock(),e.createElementBlock("div",A,[e.createVNode(I._sfc_main,{avatarUrl:h.value,avatarBlob:_.value,size:s.size,onClickAvatar:w,onSubmitImage:B,onDeleteImage:b},{avatarDefault:e.withCtx(()=>{var n,c,r,l;return[e.createTextVNode(e.toDisplayString(((c=(n=s.userInfo)==null?void 0:n.account)==null?void 0:c.charAt(0))||((l=(r=s.userInfo)==null?void 0:r.姓名)==null?void 0:l.charAt(0))||"未知"),1)]}),_:1},8,["avatarUrl","avatarBlob","size"]),s.disabled?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",N,e.toDisplayString(((g=s.userInfo)==null?void 0:g.account)||((t=s.userInfo)==null?void 0:t.账号)||"未知"),1))])}}}),U=x._export_sfc(E,[["__scopeId","data-v-0bab4582"]]),T=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}}},emits:["clickSignButton","clickSubmitSign","beforeDestroy"],setup(s,{emit:y}){const u=s,i=e.ref({}),m=e.ref([]),d=y,h=t=>{i.value.dialogShow=(t==null?void 0:t.label)==="电子签名",d("clickSignButton",t)},_=()=>{i.value.dialogShow=!1,d("beforeDestroy")},w=e.computed(()=>"http://222.92.178.198:62001"),B=t=>{var a;const n=t.split(","),c=(a=n==null?void 0:n[0])==null?void 0:a.match(/:(.*?);/)[1],r=atob(n[1]);let l=r.length;const v=new Uint8Array(l);for(;l--;)v[l]=r.charCodeAt(l);return new Blob([v],{type:c})},b=async t=>{var n,c,r;try{const l=await k.uploadFile(t);((n=l==null?void 0:l.data)==null?void 0:n.code)===200&&d("clickSubmitSign",(r=(c=l.data)==null?void 0:c.result)==null?void 0:r.url)}catch(l){C.ElMessage.error(l)}},o=e.ref(""),f=t=>{o.value=t,i.value.dialogShow=!1;const n=new FormData,c=B(t);n.append("file",c,"image.png"),b(n)},g=t=>{const n=new FormData;n.append("file",t==null?void 0:t.file),b(n)};return e.watch(()=>u==null?void 0:u.itemData,t=>{var c,r,l,v;o.value="",(c=i.value)!=null&&c.dialogShow&&(i.value.dialogShow=!1);const n=(r=t==null?void 0:t.find(a=>(a==null?void 0:a.key)==="signConfig"))==null?void 0:r.contents;n&&Object.keys(n).forEach(a=>{(n[a]===void 0||n[a]===null||n[a]==="")&&delete n[a]}),i.value=(l=t==null?void 0:t.find(a=>(a==null?void 0:a.key)==="signConfig"))==null?void 0:l.contents,m.value=(v=t==null?void 0:t.find(a=>(a==null?void 0:a.key)==="signTypeList"))==null?void 0:v.contents},{immediate:!0}),(t,n)=>{const c=e.resolveComponent("el-empty"),r=e.resolveComponent("el-image"),l=e.resolveComponent("el-button"),v=e.resolveComponent("el-upload");return e.openBlock(),e.createBlock(V.Signature,{signPadInfo:i.value,onBeforeDestroy:_,onClickSubmitSign:f},{signatureRender:e.withCtx(()=>{var a,p;return[e.createElementVNode("div",{class:"signature-render",style:e.normalizeStyle({width:`${(a=i.value)==null?void 0:a.signPadWidth}%`})},[e.createVNode(r,{src:o.value?o.value:w.value+"/"+((p=s.userInfo)==null?void 0:p.signature),fit:"contain"},{error:e.withCtx(()=>[e.createVNode(c,{"image-size":60,description:" "},{image:e.withCtx(()=>[e.createVNode(S.SvgIcon,{name:"emptyImg"})]),_:1})]),_:1},8,["src"])],4)]}),signatureTypes:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,a=>{var p;return e.openBlock(),e.createElementBlock("div",{key:a.label,class:"signature-button"},[(p=a.label)!=null&&p.includes("上传")?(e.openBlock(),e.createBlock(v,{key:0,ref_for:!0,ref:"uploadRef","http-request":g,"show-file-list":!1},{trigger:e.withCtx(()=>[e.createVNode(l,{disabled:a.disabled,id:"themeButton"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.label),1)]),icon:e.withCtx(()=>[e.createVNode(S.SvgIcon,{name:a.icon??""},null,8,["name"])]),_:2},1032,["disabled"])]),_:2},1536)):(e.openBlock(),e.createBlock(l,{key:1,id:"themeButton",disabled:a.disabled,onClick:z=>h(a)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.label),1)]),icon:e.withCtx(()=>[e.createVNode(S.SvgIcon,{name:a.icon??""},null,8,["name"])]),_:2},1032,["disabled","onClick"]))])}),128))]),_:1},8,["signPadInfo"])}}}),q=x._export_sfc(T,[["__scopeId","data-v-c57c424e"]]);exports.ssAvatar=U;exports.ssSignature=q;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),a=require("./index-PNDdZKYG.cjs"),c=require("./index-DP0k43fj.cjs"),l=require("./index-weauvEnW.cjs"),d=require("./index-BOev8isw.cjs"),g=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),_={class:"personal-wrapper"},b={class:"personal-box left"},m={class:"base-avatar"},v={class:"center-avatar"},f={class:"base-info"},p={class:"base-signature"},k={class:"personal-box right"},C=e.defineComponent({__name:"index",setup(S){const t=e.reactive({...a.State}),u=d.useLoginState(),{loginUserInfo:n}=d.storeToRefs(u);return e.onMounted(()=>{var s;t.getUserTableHeadersAsync(),t.refreshLoginUserInfoAsync((s=n==null?void 0:n.value)==null?void 0:s.id),a.tabKey.value++}),(s,o)=>{const r=e.resolveDirective("loading");return e.openBlock(),e.createElementBlock("div",_,[e.createElementVNode("div",b,[e.createElementVNode("div",m,[e.createElementVNode("div",v,[e.withDirectives(e.createVNode(c.ssAvatar,{disabled:t.uploadDisabled,userInfo:e.unref(n),onSubmitImage:o[0]||(o[0]=i=>t.submitImageAsync("avatarUrl",i))},null,8,["disabled","userInfo"]),[[r,t.avatarLoading]])])]),e.createElementVNode("div",f,[e.createVNode(l.ssForm,{formDisabled:!0,rowContents:t.rowContents,isEnableWrap:!1,isButtonRow:!0,isEdit:!1},null,8,["rowContents"])]),e.createElementVNode("div",p,[e.withDirectives(e.createVNode(c.ssSignature,{userInfo:e.unref(n),itemData:t.itemData,onClickSignButton:t.clickSignButton,onBeforeDestroy:t.beforeSignDestroy,onClickSubmitSign:o[1]||(o[1]=i=>t.submitImageAsync("signature",i))},null,8,["userInfo","itemData","onClickSignButton","onBeforeDestroy"]),[[r,t.signatureLoading]])])]),e.withDirectives((e.openBlock(),e.createElementBlock("div",k,[(e.openBlock(),e.createBlock(l.ssTab,{key:e.unref(a.tabKey),tabsContents:t.tabsContents,onChangeTrigger:t.changeFormTrigger,onClickTrigger:t.clickTabButton},null,8,["tabsContents","onChangeTrigger","onClickTrigger"]))])),[[r,t.loading]])])}}}),B=g._export_sfc(C,[["__scopeId","data-v-4dacc119"]]);exports.default=B;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),d=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),d=require("./index-BOev8isw.cjs"),f=require("vue-router"),b=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),g={class:"tenant-wrap"},C={class:"tenant-content"},k=e.defineComponent({__name:"index",setup(V){const n=e.reactive({tenantKey:""}),i=e.reactive({tenantKey:[{required:!0,message:"请选择模型",trigger:"blur"}]}),p=e.ref(null),_=e.ref([]),v=f.useRouter(),y=async()=>{var l,o;try{const r=await d.getInsofDataApi({key:{layer:"superAdmin"}});if(r.data.code===200){const s=(o=(l=r==null?void 0:r.data)==null?void 0:l.result)==null?void 0:o.flatMap(t=>t==null?void 0:t.key),u=s==null?void 0:s.map(t=>({value:t==null?void 0:t.systemKey,label:`【${t==null?void 0:t.systemKey}】`+((t==null?void 0:t.name)??"未知")}));_.value=[...u].sort((t,c)=>t.value.localeCompare(c.value))}else d.ElMessage.error("获取模型数据响应失败")}catch{d.ElMessage.error("获取模型数据失败")}};e.onMounted(()=>{y()});const m=l=>{l==null||l.validate(o=>{o&&(console.log("submitForm",n),sessionStorage.setItem("tenantKey",n==null?void 0:n.tenantKey),v.push("/login"))})};return(l,o)=>{const r=e.resolveComponent("el-option"),s=e.resolveComponent("el-select"),u=e.resolveComponent("el-form-item"),t=e.resolveComponent("el-form"),c=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",g,[e.createElementVNode("div",C,[o[3]||(o[3]=e.createElementVNode("div",{class:"tenant-title"},"租户信息",-1)),e.createVNode(t,{model:n,rules:i,ref_key:"formRef",ref:p},{default:e.withCtx(()=>[e.createVNode(u,{label:"",prop:"tenantKey"},{default:e.withCtx(()=>[e.createVNode(s,{modelValue:n.tenantKey,"onUpdate:modelValue":o[0]||(o[0]=a=>n.tenantKey=a),placeholder:"请选择(可搜索查询)",filterable:"",clearable:""},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(_.value,a=>(e.openBlock(),e.createBlock(r,{key:a.value,label:a.label,value:a.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1},8,["model","rules"]),e.createVNode(c,{type:"primary",onClick:o[1]||(o[1]=a=>m(p.value))},{default:e.withCtx(()=>o[2]||(o[2]=[e.createTextVNode(" 确认 ")])),_:1,__:[2]})])])}}}),x=b._export_sfc(k,[["__scopeId","data-v-5d82b8dd"]]);exports.default=x;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const n=require("./index-
|
|
1
|
+
"use strict";const n=require("./index-BOev8isw.cjs"),o=require("vue"),i=e=>{const t={};for(let a in e)a!=="id"&&(t[a]=e[a]);const s=t==null?void 0:t.主菜单名称;n.createInsofDataApi({key:{type:"mainEquip",systemKey:sessionStorage.getItem("systemKey"),pageKey:s},value:{tableData:t}})},l=e=>{n.deleteInsofDataApi({id:e==null?void 0:e.id})},p=e=>{const t={};for(let a in e)a!=="id"&&(t[a]=e[a]);const s=t==null?void 0:t.主菜单名称;n.updateInsofDataApi({id:e==null?void 0:e.id,key:{type:"mainEquip",systemKey:sessionStorage.getItem("systemKey"),pageKey:s},value:{tableData:t}})};o.ref([]);const r={comp:"Group",name:"/平台管理/主菜单管理",compData:[{key:"groupContents",contents:[{comp:"Table",compData:[{key:"header",contents:[{label:"主菜单名称",formType:"Select",options:[],prop:"主菜单名称"},{label:"隐藏三维显示",formType:"Switch",value:!1,prop:"隐藏三维显示"},{label:"操作"}]},{key:"extraButton",contents:[{label:"新增"}]},{key:"rowButton",contents:[{label:"查看"},{label:"编辑"},{label:"删除"}]}],name:""}]}]};exports.addMenuContent=i;exports.deleteMenuContent=l;exports.fixMenuContent=p;exports.tempMainMenuPageData=r;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const i=require("vue"),I=require("./index.vue_vue_type_style_index_1_lang-Bmwy3cgo.cjs"),pe=require("./index-Cfomm0G1.cjs"),y=require("./index-BBB4VObc.cjs"),E=I.useModelComp(I.pinia),m=pe.useUnit(I.pinia),k=I.useMenuState(I.pinia),{menus:ee,configMenu:H,activeMenuPath:q,cacheStructures:F}=I.storeToRefs(k),j=i.ref(!1),te=i.computed(()=>{var e,t;return[{key:"extraButton",contents:[]},{key:"rowButton",contents:[{label:"修改"}]},{key:"header",contents:[{label:"菜单名称",prop:"title",isFormColHidden:!1},{label:"菜单类型",prop:"menuType",formType:"select",options:[{label:"系统菜单",value:"集团"},{label:"公司",value:"公司"}],isTableColHidden:!1,isFormColHidden:!0},{label:"操作"}]},{key:"tableContents",contents:(t=(e=I.cloneDeep(ee.value))==null?void 0:e.map(l=>({...l,menuType:"系统菜单"})))==null?void 0:t.filter(l=>l.title!=="系统管理"&&l.title!=="平台管理")}]}),$=i.ref([]),_=i.ref([{label:"新建"}]),fe=i.computed(()=>[{key:"extraButton",contents:_.value},{key:"rowButton",contents:[{label:"修改"},{label:"删除"}]},{key:"header",contents:[{label:"操作类型",prop:"operateType",formType:"select",options:[{label:"新增",value:"新增"},{label:"编辑",value:"编辑"},{label:"删除",value:"删除"}],value:""},{label:"操作图标",prop:"operateIcon",formType:"inputPopover",value:""},{label:"操作触发事件",prop:"trigger",formType:"select",options:[{label:"弹出弹窗",value:"openDialog"}],value:"openDialog"},{label:"配置一:",prop:"dialogConfig",formType:"button",value:"弹窗内容",isTableColHidden:!0},{label:"配置二:",prop:"contentConfig",formType:"button",value:"模块内容",isTableColHidden:!0},{label:"继承配置:",prop:"allowInherit",formType:"radio",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!1,isTableColHidden:!0},{label:"操作"}]},{key:"tableContents",contents:$.value}]),J=i.ref([]),T=i.ref({}),de=i.ref({}),R=i.ref([{label:"菜单",prop:"path",isFormColHidden:!0,value:""},{label:"操作类型:",prop:"operateType",type:"select",contents:[{label:"新增",value:"新增"},{label:"编辑",value:"编辑"},{label:"删除",value:"删除"}],value:""},{label:"操作图标:",prop:"operateIcon",type:"inputPopover",value:""},{label:"操作触发事件:",prop:"trigger",type:"select",contents:[{label:"弹出弹窗",value:"openDialog"}],value:"openDialog"},{label:"生成的菜单图标:",prop:"menuIcon",type:"inputPopover",value:""},{label:"配置一:",prop:"dialogConfig",type:"button",value:"操作触发的弹窗结构"},{label:"配置二:",prop:"contentConfig",type:"button",value:"操作生成的模块结构",isFormColHidden:!1},{label:"",prop:"structureIds",type:"input",value:[],isFormColHidden:!0},{label:"继承配置:",prop:"allowInherit",type:"radio",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0}]),O=e=>{var t;J.value=e?(t=R.value)==null?void 0:t.map(l=>l.prop==="dialogConfig"||l.prop==="contentConfig"||l.prop==="trigger"?l:{...l,value:e?e[l==null?void 0:l.prop]:""}):R.value},ie=i.ref([{label:"查询"},{label:"重置"}]),ge=async()=>{},le=e=>e.map(t=>t.childMenus&&t.childMenus.length>0?{...t,value:t==null?void 0:t.title,label:t==null?void 0:t.title,children:le(t.childMenus)}:{...t,value:t==null?void 0:t.title,label:t==null?void 0:t.title}),g=i.reactive({show:!1,title:"菜单配置",width:"30%",type:"create"}),U=i.ref([]),C=i.ref({}),h=i.ref(null),ae=i.ref([]),oe=i.computed(()=>{var e;return(e=le(ee.value))==null?void 0:e.filter(t=>t.title!=="系统管理"&&t.title!=="平台管理")}),ne=async e=>{var l,u,n,c;const t=await y.getInsofDataApi({key:{type:"subStructure",systemKey:sessionStorage.getItem("systemKey"),pageKey:e,version:1}});if(((l=t==null?void 0:t.data)==null?void 0:l.code)===200&&(u=t.data)!=null&&u.result){const r=(c=(n=t.data)==null?void 0:n.result)==null?void 0:c.map(p=>{var f;return{id:p==null?void 0:p.id,...(f=p==null?void 0:p.value)==null?void 0:f.pageData}});ae.value=r,k.setCacheStructures({key:"contentConfig",data:r})}},ve=async e=>{var t;j.value=!0,h.value={...e,rootNode:I.findRootNodeByPath(oe.value,e.path)},k.setCacheStructures(null),(e==null?void 0:e.level)===0?_.value.splice(0):(_.value=[{label:"新建"}],U.value=(t=e==null?void 0:e.path)==null?void 0:t.split("/")),await k.setConfigMenu(null),await ne(e==null?void 0:e.path),await K(e)},ye=e=>{switch(e){case"新建":return"create";case"修改":return"update";case"删除":return"delete"}},be=async(e,t)=>{var l,u;if(!h.value)return y.ElMessage.warning("请先选择菜单");if(g.type=ye(e),U.value=[],E.setSubmitCurStructure(!1),m.setSelectTitle([]),C.value=I.cloneDeep(t),g.type!=="delete"){switch(g.type){case"create":O(null),await k.setConfigMenu(null);break;case"update":O(C.value),await k.setConfigMenu(C.value),console.log("clickRowButton",C.value);break}await i.nextTick(),g.title=`【${g.type==="create"?(l=h.value)==null?void 0:l.path:(u=C.value)==null?void 0:u.path}】菜单配置${e}`,g.show=!0}else await re(C.value,g.type)},ue=i.ref(!0),he=async e=>{var t;T.value=e,await k.setConfigMenu({...T.value,path:(t=h.value)==null?void 0:t.path}),ue.value=(e==null?void 0:e.operateType)!=="新增"};i.watch(()=>ue.value,async e=>{var t;await i.nextTick(),J.value=(t=R.value)==null?void 0:t.map(l=>l.prop==="dialogConfig"||l.prop==="contentConfig"||l.prop==="trigger"?l.prop==="contentConfig"?{...l,isFormColHidden:e}:l:{...l,value:T.value?T.value[l==null?void 0:l.prop]:""})},{immediate:!0,deep:!0});const Ce=i.ref(null),Ie=async(e,t)=>{var r,p,f,s,b;if(g.type==="create"){const a=(p=(r=F.value)==null?void 0:r.filter(d=>(d==null?void 0:d.key)===t))==null?void 0:p.flatMap(d=>d==null?void 0:d.data);E.setItemData(a),k.setCacheStructures({key:t,data:a})}if(console.log("getTriggerStructures1",e==null?void 0:e.structureIds,t),!(e!=null&&e.structureIds)||((f=e==null?void 0:e.structureIds)==null?void 0:f.length)===0)return;const l=(b=(s=e==null?void 0:e.structureIds)==null?void 0:s.filter(a=>(a==null?void 0:a.key)===t))==null?void 0:b.map(a=>a==null?void 0:a.id);let u=l==null?void 0:l.map(a=>{if(a)return y.getInsofDataApi({id:a})});const n=await Promise.all(u),c=n==null?void 0:n.every(a=>{var d;return((d=a==null?void 0:a.data)==null?void 0:d.code)===200});if(console.log("getTriggerStructures2",e==null?void 0:e.structureIds,t,n),c&&(n==null?void 0:n.length)>0){const a=n==null?void 0:n.map(d=>{var M,D,N,P,A,o,x;return{id:(N=(D=(M=d==null?void 0:d.data)==null?void 0:M.result)==null?void 0:D[0])==null?void 0:N.id,...(x=(o=(A=(P=d==null?void 0:d.data)==null?void 0:P.result)==null?void 0:A[0])==null?void 0:o.value)==null?void 0:x.pageData}});E.setItemData(a),k.setCacheStructures({key:t,data:a})}},ke=async e=>{var n,c,r,p,f;const t=e==="操作触发的弹窗结构"?"dialogConfig":"contentConfig";k.setButtonTriggerType(t),await Ie(C.value,t);let l;(n=T.value)!=null&&n.subMenus&&((c=T.value)==null?void 0:c.subMenus.length)>0&&(l=(r=U.value)==null?void 0:r.map(s=>({value:s})),l.unshift({value:(p=C.value)==null?void 0:p.title}));let u;g.type==="create"?u={...T.value,path:(f=h.value)==null?void 0:f.path}:g.type==="update"&&(u=H.value),await k.setConfigMenu(u),m.setSelectTitle(l),E.setIsEdit("edit")},K=async e=>{var l,u,n,c,r,p;const t=await y.getInsofDataApi({key:{type:"menuConfigData",systemKey:sessionStorage.getItem("systemKey"),pageKey:q.value+"/"+(e==null?void 0:e.path),tableId:""}});((l=t==null?void 0:t.data)==null?void 0:l.code)===200&&(u=t.data)!=null&&u.result&&($.value=((c=(n=t.data)==null?void 0:n.result)==null?void 0:c.length)>0?(p=(r=t.data)==null?void 0:r.result)==null?void 0:p.map(f=>{var s;return{id:f==null?void 0:f.id,...(s=f==null?void 0:f.value)==null?void 0:s.tableData}}):[]),j.value=!1},B=async(e,t,l="contentConfig")=>{var u,n,c,r,p,f;try{let s,b;t==="create"?(s={key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:q.value+"/"+((u=h.value)==null?void 0:u.path),type:"structure",rootNodePath:(c=(n=h.value)==null?void 0:n.rootNode)==null?void 0:c.path,structureBelong:l,parentTable:"",version:1},value:{pageData:e}},b=y.createInsofDataApi):t==="update"?(s={id:e==null?void 0:e.id,value:{pageData:e}},b=y.updateInsofDataApi):t==="delete"&&(s={id:e},b=y.deleteInsofDataApi);const a=await b(s);if(((r=a==null?void 0:a.data)==null?void 0:r.code)!==200)throw y.ElMessage.error("保存响应失败"),new Error("保存响应失败");const d=t==="create"?(p=a==null?void 0:a.data)==null?void 0:p.result:e==null?void 0:e.id;return{status:((f=a==null?void 0:a.data)==null?void 0:f.code)===200,data:{id:d,key:l}}}catch{y.ElMessage.error("保存响应失败")}},Y=(e,t)=>{var f,s,b;const l=(f=e==null?void 0:e.flatMap(a=>a==null?void 0:a.data))==null?void 0:f.map(a=>a==null?void 0:a.id),u=t.filter(a=>!(l!=null&&l.includes(a))),n=l==null?void 0:l.filter(a=>!t.includes(a));let c=null,r=null,p=null;return c=[...u,...n].filter(a=>a),r=(s=e==null?void 0:e.flatMap(a=>a==null?void 0:a.data))==null?void 0:s.filter(a=>!(a!=null&&a.id)),p=(b=e==null?void 0:e.flatMap(a=>a==null?void 0:a.data))==null?void 0:b.filter(a=>a==null?void 0:a.id).filter(a=>Object.keys(a).length>1),{deleteIds:c,createComps:r,updateComps:p}},Z=(e,t)=>{var u,n,c,r,p,f;let l=[];return((u=t==null?void 0:t.deleteIds)==null?void 0:u.length)>0&&((n=t==null?void 0:t.deleteIds)==null||n.forEach(s=>{l.push(B(s,"delete",e))})),((c=t==null?void 0:t.createComps)==null?void 0:c.length)>0&&((r=t==null?void 0:t.createComps)==null||r.forEach(s=>{l.push(B(s,"create",e))})),((p=t==null?void 0:t.updateComps)==null?void 0:p.length)>0&&((f=t==null?void 0:t.updateComps)==null||f.forEach(s=>{s!=null&&s.id&&l.push(B(s,"update",e))})),l},Te=e=>{const t=new Map;return e.forEach(l=>{t.set(l.id,l)}),Array.from(t.values())},Me=async(e,t)=>{var l,u,n,c,r,p,f;try{const s=e==null?void 0:e.filter(o=>(o==null?void 0:o.key)==="contentConfig"),b=e==null?void 0:e.filter(o=>(o==null?void 0:o.key)==="dialogConfig");await i.nextTick();const a=(n=(u=(l=F.value)==null?void 0:l.filter(o=>(o==null?void 0:o.key)==="dialogConfig"))==null?void 0:u.flatMap(o=>o==null?void 0:o.data))==null?void 0:n.map(o=>o==null?void 0:o.id);let d=(p=(r=(c=F.value)==null?void 0:c.filter(o=>(o==null?void 0:o.key)==="contentConfig"))==null?void 0:r.flatMap(o=>o==null?void 0:o.data))==null?void 0:p.map(o=>o==null?void 0:o.id);d=[...d,...(f=ae.value)==null?void 0:f.map(o=>o==null?void 0:o.id)];const M=Y(b,a),D=Y(s,d),N=Z("dialogConfig",M),P=Z("contentConfig",D),A=[...N,...P];await Promise.all(A).then(o=>{var z,G,L,V,Q,W,X;if(!(o==null?void 0:o.every(v=>v.status)))return;let w=(z=o==null?void 0:o.flatMap(v=>v==null?void 0:v.data))==null?void 0:z.filter(v=>(v==null?void 0:v.id)!==null&&(v==null?void 0:v.id)!==void 0);if(((G=M==null?void 0:M.updateComps)==null?void 0:G.length)===0&&g.type==="update"){const v=(V=(L=C.value)==null?void 0:L.structureIds)==null?void 0:V.filter(S=>(S==null?void 0:S.key)==="dialogConfig");w=[...w,...v]}if(((Q=D==null?void 0:D.updateComps)==null?void 0:Q.length)===0&&g.type==="update"){const v=(X=(W=C.value)==null?void 0:W.structureIds)==null?void 0:X.filter(S=>(S==null?void 0:S.key)==="contentConfig");w=[...w,...v]}const ce=Te(w);re({...t,isNotInitial:!0,structureIds:ce},g.type)}).catch(o=>{y.ElMessage.error(o)})}catch(s){throw y.ElMessage.error(s),new Error(s)}},re=async(e,t)=>{var n,c;let l,u;t==="create"?(l={key:{type:"menuConfigData",systemKey:sessionStorage.getItem("systemKey"),pageKey:q.value+"/"+((n=h.value)==null?void 0:n.path),tableId:"",rootNodePath:e==null?void 0:e.rootNodePath},value:{tableData:e}},u=y.createInsofDataApi):t==="update"?(l={id:e==null?void 0:e.id,value:{tableData:e}},u=y.updateInsofDataApi):t==="delete"&&(l={ids:[e.id,...(c=e==null?void 0:e.structureIds)==null?void 0:c.map(r=>r.id)]},u=y.batchDeleteInsofDataApi),I.handleSubmitAsync(u,l,t).then(r=>{t==="create"&&$.value.push({...e,id:r}),t&&r&&y.ElMessage.success("响应成功"),K(h.value)})},De=async()=>{var l,u,n,c,r;const e=JSON.parse(I.cloneDeep(JSON.stringify(F.value)));await i.nextTick();const t=g.type==="create"?{...H.value,rootNodePath:(u=(l=h.value)==null?void 0:l.rootNode)==null?void 0:u.path}:{...H.value,rootNodePath:(c=(n=h.value)==null?void 0:n.rootNode)==null?void 0:c.path,id:(r=C.value)==null?void 0:r.id};await Me(e,t),T.value={},g.show=!1,await K(h.value)},Se=()=>{g.show=!1},se={comp:"Group",name:"/平台管理/菜单管理",compData:[{key:"groupContents",contents:[{comp:"Table",compData:te.value,name:""}]}]},we=Object.freeze(Object.defineProperty({__proto__:null,beforeDialogDestroy:Se,buttonValue:ie,changeTrigger:he,changedRow:de,clickNodeTrigger:ve,clickRowButton:be,clickSubmitForm:De,clickTrigger:ke,dialogInfo:g,formatFormData:O,getInitialSubStructure:ne,getTableDataAsync:K,handleItemDataChange:ge,inputForm:T,menuPageData:fe,operatingForm:Ce,pageData:te,renderFormData:J,tableLoading:j,tempMenuPageData:se,treeData:oe},Symbol.toStringTag,{value:"Module"}));exports.State=we;exports.tempMenuPageData=se;
|
|
1
|
+
"use strict";const g=require("vue"),O=require("./index.vue_vue_type_style_index_1_lang-DraQDAAw.cjs"),i=require("./index-BOev8isw.cjs"),pe=require("./index-B-oe2x1V.cjs"),A=O.useModelComp(i.pinia),m=pe.useUnit(i.pinia),I=O.useMenuState(i.pinia),{menus:ee,configMenu:B,activeMenuPath:q,cacheStructures:E}=i.storeToRefs(I),j=g.ref(!1),te=g.computed(()=>{var e,t;return[{key:"extraButton",contents:[]},{key:"rowButton",contents:[{label:"修改"}]},{key:"header",contents:[{label:"菜单名称",prop:"title",isFormColHidden:!1},{label:"菜单类型",prop:"menuType",formType:"select",options:[{label:"系统菜单",value:"集团"},{label:"公司",value:"公司"}],isTableColHidden:!1,isFormColHidden:!0},{label:"操作"}]},{key:"tableContents",contents:(t=(e=i.cloneDeep(ee.value))==null?void 0:e.map(l=>({...l,menuType:"系统菜单"})))==null?void 0:t.filter(l=>l.title!=="系统管理"&&l.title!=="平台管理")}]}),$=g.ref([]),H=g.ref([{label:"新建"}]),fe=g.computed(()=>[{key:"extraButton",contents:H.value},{key:"rowButton",contents:[{label:"修改"},{label:"删除"}]},{key:"header",contents:[{label:"操作类型",prop:"operateType",formType:"select",options:[{label:"新增",value:"新增"},{label:"编辑",value:"编辑"},{label:"删除",value:"删除"}],value:""},{label:"操作图标",prop:"operateIcon",formType:"inputPopover",value:""},{label:"操作触发事件",prop:"trigger",formType:"select",options:[{label:"弹出弹窗",value:"openDialog"}],value:"openDialog"},{label:"配置一:",prop:"dialogConfig",formType:"button",value:"弹窗内容",isTableColHidden:!0},{label:"配置二:",prop:"contentConfig",formType:"button",value:"模块内容",isTableColHidden:!0},{label:"继承配置:",prop:"allowInherit",formType:"radio",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!1,isTableColHidden:!0},{label:"操作"}]},{key:"tableContents",contents:$.value}]),J=g.ref([]),k=g.ref({}),de=g.ref({}),_=g.ref([{label:"菜单",prop:"path",isFormColHidden:!0,value:""},{label:"操作类型:",prop:"operateType",type:"select",contents:[{label:"新增",value:"新增"},{label:"编辑",value:"编辑"},{label:"删除",value:"删除"}],value:""},{label:"操作图标:",prop:"operateIcon",type:"inputPopover",value:""},{label:"操作触发事件:",prop:"trigger",type:"select",contents:[{label:"弹出弹窗",value:"openDialog"}],value:"openDialog"},{label:"生成的菜单图标:",prop:"menuIcon",type:"inputPopover",value:""},{label:"配置一:",prop:"dialogConfig",type:"button",value:"操作触发的弹窗结构"},{label:"配置二:",prop:"contentConfig",type:"button",value:"操作生成的模块结构",isFormColHidden:!1},{label:"",prop:"structureIds",type:"input",value:[],isFormColHidden:!0},{label:"继承配置:",prop:"allowInherit",type:"radio",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0}]),R=e=>{var t;J.value=e?(t=_.value)==null?void 0:t.map(l=>l.prop==="dialogConfig"||l.prop==="contentConfig"||l.prop==="trigger"?l:{...l,value:e?e[l==null?void 0:l.prop]:""}):_.value},ie=g.ref([{label:"查询"},{label:"重置"}]),ge=async()=>{},le=e=>e.map(t=>t.childMenus&&t.childMenus.length>0?{...t,value:t==null?void 0:t.title,label:t==null?void 0:t.title,children:le(t.childMenus)}:{...t,value:t==null?void 0:t.title,label:t==null?void 0:t.title}),v=g.reactive({show:!1,title:"菜单配置",width:"30%",type:"create"}),U=g.ref([]),C=g.ref({}),h=g.ref(null),ae=g.ref([]),oe=g.computed(()=>{var e;return(e=le(ee.value))==null?void 0:e.filter(t=>t.title!=="系统管理"&&t.title!=="平台管理")}),ne=async e=>{var l,u,n,c;const t=await i.getInsofDataApi({key:{type:"subStructure",systemKey:sessionStorage.getItem("systemKey"),pageKey:e,version:1}});if(((l=t==null?void 0:t.data)==null?void 0:l.code)===200&&(u=t.data)!=null&&u.result){const r=(c=(n=t.data)==null?void 0:n.result)==null?void 0:c.map(p=>{var f;return{id:p==null?void 0:p.id,...(f=p==null?void 0:p.value)==null?void 0:f.pageData}});ae.value=r,I.setCacheStructures({key:"contentConfig",data:r})}},ve=async e=>{var t;j.value=!0,h.value={...e,rootNode:i.findRootNodeByPath(oe.value,e.path)},I.setCacheStructures(null),(e==null?void 0:e.level)===0?H.value.splice(0):(H.value=[{label:"新建"}],U.value=(t=e==null?void 0:e.path)==null?void 0:t.split("/")),await I.setConfigMenu(null),await ne(e==null?void 0:e.path),await F(e)},ye=e=>{switch(e){case"新建":return"create";case"修改":return"update";case"删除":return"delete"}},be=async(e,t)=>{var l,u;if(!h.value)return i.ElMessage.warning("请先选择菜单");if(v.type=ye(e),U.value=[],A.setSubmitCurStructure(!1),m.setSelectTitle([]),C.value=i.cloneDeep(t),v.type!=="delete"){switch(v.type){case"create":R(null),await I.setConfigMenu(null);break;case"update":R(C.value),await I.setConfigMenu(C.value),console.log("clickRowButton",C.value);break}await g.nextTick(),v.title=`【${v.type==="create"?(l=h.value)==null?void 0:l.path:(u=C.value)==null?void 0:u.path}】菜单配置${e}`,v.show=!0}else await re(C.value,v.type)},ue=g.ref(!0),he=async e=>{var t;k.value=e,await I.setConfigMenu({...k.value,path:(t=h.value)==null?void 0:t.path}),ue.value=(e==null?void 0:e.operateType)!=="新增"};g.watch(()=>ue.value,async e=>{var t;await g.nextTick(),J.value=(t=_.value)==null?void 0:t.map(l=>l.prop==="dialogConfig"||l.prop==="contentConfig"||l.prop==="trigger"?l.prop==="contentConfig"?{...l,isFormColHidden:e}:l:{...l,value:k.value?k.value[l==null?void 0:l.prop]:""})},{immediate:!0,deep:!0});const Ce=g.ref(null),Ie=async(e,t)=>{var r,p,f,s,b;if(v.type==="create"){const a=(p=(r=E.value)==null?void 0:r.filter(d=>(d==null?void 0:d.key)===t))==null?void 0:p.flatMap(d=>d==null?void 0:d.data);A.setItemData(a),I.setCacheStructures({key:t,data:a})}if(console.log("getTriggerStructures1",e==null?void 0:e.structureIds,t),!(e!=null&&e.structureIds)||((f=e==null?void 0:e.structureIds)==null?void 0:f.length)===0)return;const l=(b=(s=e==null?void 0:e.structureIds)==null?void 0:s.filter(a=>(a==null?void 0:a.key)===t))==null?void 0:b.map(a=>a==null?void 0:a.id);let u=l==null?void 0:l.map(a=>{if(a)return i.getInsofDataApi({id:a})});const n=await Promise.all(u),c=n==null?void 0:n.every(a=>{var d;return((d=a==null?void 0:a.data)==null?void 0:d.code)===200});if(console.log("getTriggerStructures2",e==null?void 0:e.structureIds,t,n),c&&(n==null?void 0:n.length)>0){const a=n==null?void 0:n.map(d=>{var T,M,w,N,P,o,K;return{id:(w=(M=(T=d==null?void 0:d.data)==null?void 0:T.result)==null?void 0:M[0])==null?void 0:w.id,...(K=(o=(P=(N=d==null?void 0:d.data)==null?void 0:N.result)==null?void 0:P[0])==null?void 0:o.value)==null?void 0:K.pageData}});A.setItemData(a),I.setCacheStructures({key:t,data:a})}},ke=async e=>{var n,c,r,p,f;const t=e==="操作触发的弹窗结构"?"dialogConfig":"contentConfig";I.setButtonTriggerType(t),await Ie(C.value,t);let l;(n=k.value)!=null&&n.subMenus&&((c=k.value)==null?void 0:c.subMenus.length)>0&&(l=(r=U.value)==null?void 0:r.map(s=>({value:s})),l.unshift({value:(p=C.value)==null?void 0:p.title}));let u;v.type==="create"?u={...k.value,path:(f=h.value)==null?void 0:f.path}:v.type==="update"&&(u=B.value),await I.setConfigMenu(u),m.setSelectTitle(l),A.setIsEdit("edit")},F=async e=>{var l,u,n,c,r,p;const t=await i.getInsofDataApi({key:{type:"menuConfigData",systemKey:sessionStorage.getItem("systemKey"),pageKey:q.value+"/"+(e==null?void 0:e.path),tableId:""}});((l=t==null?void 0:t.data)==null?void 0:l.code)===200&&(u=t.data)!=null&&u.result&&($.value=((c=(n=t.data)==null?void 0:n.result)==null?void 0:c.length)>0?(p=(r=t.data)==null?void 0:r.result)==null?void 0:p.map(f=>{var s;return{id:f==null?void 0:f.id,...(s=f==null?void 0:f.value)==null?void 0:s.tableData}}):[]),j.value=!1},x=async(e,t,l="contentConfig")=>{var u,n,c,r,p,f;try{let s,b;t==="create"?(s={key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:q.value+"/"+((u=h.value)==null?void 0:u.path),type:"structure",rootNodePath:(c=(n=h.value)==null?void 0:n.rootNode)==null?void 0:c.path,structureBelong:l,parentTable:"",version:1},value:{pageData:e}},b=i.createInsofDataApi):t==="update"?(s={id:e==null?void 0:e.id,value:{pageData:e}},b=i.updateInsofDataApi):t==="delete"&&(s={id:e},b=i.deleteInsofDataApi);const a=await b(s);if(((r=a==null?void 0:a.data)==null?void 0:r.code)!==200)throw i.ElMessage.error("保存响应失败"),new Error("保存响应失败");const d=t==="create"?(p=a==null?void 0:a.data)==null?void 0:p.result:e==null?void 0:e.id;return{status:((f=a==null?void 0:a.data)==null?void 0:f.code)===200,data:{id:d,key:l}}}catch{i.ElMessage.error("保存响应失败")}},Y=(e,t)=>{var f,s,b;const l=(f=e==null?void 0:e.flatMap(a=>a==null?void 0:a.data))==null?void 0:f.map(a=>a==null?void 0:a.id),u=t.filter(a=>!(l!=null&&l.includes(a))),n=l==null?void 0:l.filter(a=>!t.includes(a));let c=null,r=null,p=null;return c=[...u,...n].filter(a=>a),r=(s=e==null?void 0:e.flatMap(a=>a==null?void 0:a.data))==null?void 0:s.filter(a=>!(a!=null&&a.id)),p=(b=e==null?void 0:e.flatMap(a=>a==null?void 0:a.data))==null?void 0:b.filter(a=>a==null?void 0:a.id).filter(a=>Object.keys(a).length>1),{deleteIds:c,createComps:r,updateComps:p}},Z=(e,t)=>{var u,n,c,r,p,f;let l=[];return((u=t==null?void 0:t.deleteIds)==null?void 0:u.length)>0&&((n=t==null?void 0:t.deleteIds)==null||n.forEach(s=>{l.push(x(s,"delete",e))})),((c=t==null?void 0:t.createComps)==null?void 0:c.length)>0&&((r=t==null?void 0:t.createComps)==null||r.forEach(s=>{l.push(x(s,"create",e))})),((p=t==null?void 0:t.updateComps)==null?void 0:p.length)>0&&((f=t==null?void 0:t.updateComps)==null||f.forEach(s=>{s!=null&&s.id&&l.push(x(s,"update",e))})),l},Te=e=>{const t=new Map;return e.forEach(l=>{t.set(l.id,l)}),Array.from(t.values())},Me=async(e,t)=>{var l,u,n,c,r,p,f;try{const s=e==null?void 0:e.filter(o=>(o==null?void 0:o.key)==="contentConfig"),b=e==null?void 0:e.filter(o=>(o==null?void 0:o.key)==="dialogConfig");await g.nextTick();const a=(n=(u=(l=E.value)==null?void 0:l.filter(o=>(o==null?void 0:o.key)==="dialogConfig"))==null?void 0:u.flatMap(o=>o==null?void 0:o.data))==null?void 0:n.map(o=>o==null?void 0:o.id);let d=(p=(r=(c=E.value)==null?void 0:c.filter(o=>(o==null?void 0:o.key)==="contentConfig"))==null?void 0:r.flatMap(o=>o==null?void 0:o.data))==null?void 0:p.map(o=>o==null?void 0:o.id);d=[...d,...(f=ae.value)==null?void 0:f.map(o=>o==null?void 0:o.id)];const T=Y(b,a),M=Y(s,d),w=Z("dialogConfig",T),N=Z("contentConfig",M),P=[...w,...N];await Promise.all(P).then(o=>{var z,G,L,V,Q,W,X;if(!(o==null?void 0:o.every(y=>y.status)))return;let S=(z=o==null?void 0:o.flatMap(y=>y==null?void 0:y.data))==null?void 0:z.filter(y=>(y==null?void 0:y.id)!==null&&(y==null?void 0:y.id)!==void 0);if(((G=T==null?void 0:T.updateComps)==null?void 0:G.length)===0&&v.type==="update"){const y=(V=(L=C.value)==null?void 0:L.structureIds)==null?void 0:V.filter(D=>(D==null?void 0:D.key)==="dialogConfig");S=[...S,...y]}if(((Q=M==null?void 0:M.updateComps)==null?void 0:Q.length)===0&&v.type==="update"){const y=(X=(W=C.value)==null?void 0:W.structureIds)==null?void 0:X.filter(D=>(D==null?void 0:D.key)==="contentConfig");S=[...S,...y]}const ce=Te(S);re({...t,isNotInitial:!0,structureIds:ce},v.type)}).catch(o=>{i.ElMessage.error(o)})}catch(s){throw i.ElMessage.error(s),new Error(s)}},re=async(e,t)=>{var n,c;let l,u;t==="create"?(l={key:{type:"menuConfigData",systemKey:sessionStorage.getItem("systemKey"),pageKey:q.value+"/"+((n=h.value)==null?void 0:n.path),tableId:"",rootNodePath:e==null?void 0:e.rootNodePath},value:{tableData:e}},u=i.createInsofDataApi):t==="update"?(l={id:e==null?void 0:e.id,value:{tableData:e}},u=i.updateInsofDataApi):t==="delete"&&(l={ids:[e.id,...(c=e==null?void 0:e.structureIds)==null?void 0:c.map(r=>r.id)]},u=i.batchDeleteInsofDataApi),O.handleSubmitAsync(u,l,t).then(r=>{t==="create"&&$.value.push({...e,id:r}),t&&r&&i.ElMessage.success("响应成功"),F(h.value)})},De=async()=>{var l,u,n,c,r;const e=JSON.parse(i.cloneDeep(JSON.stringify(E.value)));await g.nextTick();const t=v.type==="create"?{...B.value,rootNodePath:(u=(l=h.value)==null?void 0:l.rootNode)==null?void 0:u.path}:{...B.value,rootNodePath:(c=(n=h.value)==null?void 0:n.rootNode)==null?void 0:c.path,id:(r=C.value)==null?void 0:r.id};await Me(e,t),k.value={},v.show=!1,await F(h.value)},Se=()=>{v.show=!1},se={comp:"Group",name:"/平台管理/菜单管理",compData:[{key:"groupContents",contents:[{comp:"Table",compData:te.value,name:""}]}]},we=Object.freeze(Object.defineProperty({__proto__:null,beforeDialogDestroy:Se,buttonValue:ie,changeTrigger:he,changedRow:de,clickNodeTrigger:ve,clickRowButton:be,clickSubmitForm:De,clickTrigger:ke,dialogInfo:v,formatFormData:R,getInitialSubStructure:ne,getTableDataAsync:F,handleItemDataChange:ge,inputForm:k,menuPageData:fe,operatingForm:Ce,pageData:te,renderFormData:J,tableLoading:j,tempMenuPageData:se,treeData:oe},Symbol.toStringTag,{value:"Module"}));exports.State=we;exports.tempMenuPageData=se;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("vue"),_=require("./index-RgTvyK54.cjs"),r=require("./index-BOev8isw.cjs"),f=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),m=(t,l,a)=>{var n,p,u,g;let e=l;e.title.text=(a==null?void 0:a.chartName)??"",e.xAxis.data=(n=r.cloneDeep(t))==null?void 0:n.map(i=>i.x),e.legend.data=(u=(p=r.cloneDeep(t))==null?void 0:p[0])!=null&&u.y?Object.keys(r.cloneDeep(t)[0].y):[];let o=[];return((g=e.legend.data)==null?void 0:g.length)>0&&r.cloneDeep(e.legend.data).forEach(i=>{var x;const y=(x=r.cloneDeep(t))==null?void 0:x.map(c=>{var h;return(h=c==null?void 0:c.y)==null?void 0:h[i]});o.push({name:i,type:"line",data:y})}),e.series=o,e},d=[{key:"折线图",value:{title:{text:"",left:"center",top:25,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis"},legend:{data:[]},grid:{left:"6%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",axisLabel:{interval:0},data:[]},yAxis:{type:"value"},series:[]}}],C={class:"eCharts"},D={__name:"index",props:{eChartContents:Array},setup(t){const l=t,a=s.ref({});return s.onMounted(()=>{var o;const e=l==null?void 0:l.eChartContents;a.value=m(r.cloneDeep(e==null?void 0:e.compData),(o=d==null?void 0:d.find(n=>(n==null?void 0:n.key)===(e==null?void 0:e.name)))==null?void 0:o.value,e==null?void 0:e.extraContent)}),(e,o)=>(s.openBlock(),s.createElementBlock("div",C,[s.createVNode(_.ssChart,{optionContents:a.value},null,8,["optionContents"])]))}},b=f._export_sfc(D,[["__scopeId","data-v-0440fac3"]]);exports.default=b;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as M } from "./index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-
|
|
1
|
+
import { _ as M } from "./index.vue_vue_type_style_index_0_scoped_86d2b6b8_lang-D5CTJUDi.js";
|
|
2
2
|
import { resolveComponent as a, createElementBlock as s, openBlock as l, Fragment as f, createVNode as n, withCtx as i, createElementVNode as r, createCommentVNode as D, normalizeStyle as b, toDisplayString as C, renderList as h, createTextVNode as u, createBlock as B, resolveDynamicComponent as w } from "vue";
|
|
3
3
|
import { _ as I } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
4
|
const V = ["title"], $ = {
|
|
@@ -0,0 +1,319 @@
|
|
|
1
|
+
import { ref as g, computed as C, reactive as P } from "vue";
|
|
2
|
+
import { s as R, c4 as x, c5 as B, c6 as F, g as _, u as j, p as L, c as z, f as J, E } from "./index-Dt2McMki.js";
|
|
3
|
+
import { aP as H, u as Z, d as G, r as Q } from "./index.vue_vue_type_style_index_1_lang-hffXwR3x.js";
|
|
4
|
+
const A = j(L), { loginUserInfo: o, cryptoInfo: c } = R(A), X = Z(L), { activeMenuPath: v } = R(X), Y = g(0), M = C(() => {
|
|
5
|
+
var s, a, t, r, l, n;
|
|
6
|
+
return [
|
|
7
|
+
{
|
|
8
|
+
label: "",
|
|
9
|
+
// name: 'account',
|
|
10
|
+
name: "账号",
|
|
11
|
+
prop: "账号",
|
|
12
|
+
value: ((s = o.value) == null ? void 0 : s.账号) ?? "未知"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
label: "",
|
|
16
|
+
// name: 'userRoles',
|
|
17
|
+
name: "角色名称",
|
|
18
|
+
prop: "角色名称",
|
|
19
|
+
// value: loginUserInfo.value?.userRoles?.join('、')
|
|
20
|
+
value: ((a = o.value) == null ? void 0 : a.layer) === "superAdmin" ? "超级管理员" : (t = o.value) == null ? void 0 : t.角色名称
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
label: "",
|
|
24
|
+
// name: 'userDept',
|
|
25
|
+
name: "部门名称",
|
|
26
|
+
prop: "部门名称",
|
|
27
|
+
value: ((r = o.value) == null ? void 0 : r.部门名称) ?? "未知"
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
label: "",
|
|
31
|
+
// name: 'userDept',
|
|
32
|
+
name: "状态",
|
|
33
|
+
prop: "状态",
|
|
34
|
+
value: ((l = o.value) == null ? void 0 : l.layer) === "superAdmin" ? "启用" : (n = o.value) == null ? void 0 : n.状态
|
|
35
|
+
}
|
|
36
|
+
];
|
|
37
|
+
}), ee = () => {
|
|
38
|
+
}, D = g(!1), w = P({
|
|
39
|
+
dialogTitle: "电子签名",
|
|
40
|
+
dialogWidth: "30",
|
|
41
|
+
dialogShow: !1,
|
|
42
|
+
url: ""
|
|
43
|
+
}), S = g([
|
|
44
|
+
{
|
|
45
|
+
label: "签字版",
|
|
46
|
+
icon: x,
|
|
47
|
+
type: "button",
|
|
48
|
+
disabled: !1
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
label: "电子签名",
|
|
52
|
+
icon: B,
|
|
53
|
+
type: "button",
|
|
54
|
+
disabled: !1
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
label: "上传手写签名",
|
|
58
|
+
icon: F,
|
|
59
|
+
type: "buttonUpload",
|
|
60
|
+
disabled: !1
|
|
61
|
+
}
|
|
62
|
+
]), U = g(!1), I = g(!1), N = g(!1), K = C(() => {
|
|
63
|
+
var r, l, n;
|
|
64
|
+
const s = sessionStorage.getItem("authority"), a = JSON.parse(s || ""), t = (r = v.value) != null && r.startsWith("/") ? (l = v.value) == null ? void 0 : l.substring(1) : v.value;
|
|
65
|
+
return Array.isArray(a) ? (N.value = !(a != null && a.includes(`${t}/上传头像`)), (n = S.value) == null ? void 0 : n.map((e) => ({
|
|
66
|
+
...e,
|
|
67
|
+
disabled: !(a != null && a.includes(`${t}/签名`))
|
|
68
|
+
}))) : typeof a == "string" && (a == null ? void 0 : a.toUpperCase()) === "SUPERADMIN" ? S.value : [];
|
|
69
|
+
}), ae = C(() => [
|
|
70
|
+
{
|
|
71
|
+
key: "signConfig",
|
|
72
|
+
contents: w
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
key: "signTypeList",
|
|
76
|
+
contents: K.value
|
|
77
|
+
}
|
|
78
|
+
]), te = (s) => {
|
|
79
|
+
w.dialogShow = s.label === "电子签名";
|
|
80
|
+
}, $ = () => {
|
|
81
|
+
w.dialogShow = !1;
|
|
82
|
+
}, k = async (s) => {
|
|
83
|
+
var t, r, l, n, e, i, p, d, f;
|
|
84
|
+
const a = await _({
|
|
85
|
+
id: s
|
|
86
|
+
// key: {
|
|
87
|
+
// systemKey: sessionStorage.getItem("systemKey"),
|
|
88
|
+
// type: "data",
|
|
89
|
+
// // pageKey: '/系统管理/用户管理',
|
|
90
|
+
// pageKey: '系统管理/用户管理',
|
|
91
|
+
// }
|
|
92
|
+
});
|
|
93
|
+
if (((t = a == null ? void 0 : a.data) == null ? void 0 : t.code) === 200 && a.data.result && Array.isArray(a.data.result) && a.data.result.length > 0) {
|
|
94
|
+
const y = {
|
|
95
|
+
...(n = (l = (r = a.data.result) == null ? void 0 : r[0]) == null ? void 0 : l.value) == null ? void 0 : n.tableData,
|
|
96
|
+
id: (i = (e = a.data.result) == null ? void 0 : e[0]) == null ? void 0 : i.id,
|
|
97
|
+
layer: (f = (d = (p = a.data.result) == null ? void 0 : p[0]) == null ? void 0 : d.key) == null ? void 0 : f.layer
|
|
98
|
+
};
|
|
99
|
+
A.setLoginUserInfo(y);
|
|
100
|
+
}
|
|
101
|
+
}, V = async (s, a) => {
|
|
102
|
+
var r, l, n;
|
|
103
|
+
const t = z(s);
|
|
104
|
+
t == null || delete t.id;
|
|
105
|
+
try {
|
|
106
|
+
const e = await J({
|
|
107
|
+
id: (r = o.value) == null ? void 0 : r.id,
|
|
108
|
+
// key: {
|
|
109
|
+
// // type: "data",
|
|
110
|
+
// systemKey: sessionStorage.getItem("systemKey"),
|
|
111
|
+
// pageKey: '/系统管理/用户管理',
|
|
112
|
+
// layer: loginUserInfo.value?.layer
|
|
113
|
+
// },
|
|
114
|
+
value: {
|
|
115
|
+
tableData: t
|
|
116
|
+
}
|
|
117
|
+
});
|
|
118
|
+
((l = e == null ? void 0 : e.data) == null ? void 0 : l.code) === 200 && ($(), E.success("修改成功"), await k((n = o.value) == null ? void 0 : n.id), await A.setLogRecordAsync({
|
|
119
|
+
type: a,
|
|
120
|
+
data: s
|
|
121
|
+
}, v.value));
|
|
122
|
+
} catch {
|
|
123
|
+
E.error("修改响应失败");
|
|
124
|
+
} finally {
|
|
125
|
+
D.value = !1, U.value = !1, I.value = !1;
|
|
126
|
+
}
|
|
127
|
+
}, se = async (s, a) => {
|
|
128
|
+
var r;
|
|
129
|
+
const t = {
|
|
130
|
+
...o.value,
|
|
131
|
+
status: ((r = o.value) == null ? void 0 : r.status) ?? "启用",
|
|
132
|
+
// password: encryptData(loginUserInfo.value?.password, cryptoInfo?.publicKey),
|
|
133
|
+
[s]: a
|
|
134
|
+
};
|
|
135
|
+
U.value = s === "avatarUrl", I.value = s === "signature", await V(t, "图片修改");
|
|
136
|
+
}, b = P({
|
|
137
|
+
baseCols: [],
|
|
138
|
+
otherCols: []
|
|
139
|
+
}), W = g([]), q = g(), re = (s, a, t) => {
|
|
140
|
+
var n, e, i, p, d, f;
|
|
141
|
+
let r;
|
|
142
|
+
const l = a;
|
|
143
|
+
((e = (n = o.value) == null ? void 0 : n.layer) == null ? void 0 : e.toUpperCase()) !== "SUPERADMIN" ? r = (i = o.value) != null && i.password ? G((p = o.value) == null ? void 0 : p.password, (d = c == null ? void 0 : c.value) == null ? void 0 : d.privateKey) : Q : r = (f = o.value) == null ? void 0 : f.password, r === l ? t() : t(new Error("输入的密码与原密码不匹配,请重新输入"));
|
|
144
|
+
}, ne = (s, a, t) => {
|
|
145
|
+
a ? /^(?=.*[A-Z])(?=.*[a-z])(?=.*\d)(?=.*[!@#$%^&*(),.?":{}|<>]).{6,}$/.test(a) ? t() : t(new Error("密码必须包含大写字母、小写字母、数字和特殊字符,并且长度至少为6个字符")) : t(new Error("请输入密码"));
|
|
146
|
+
}, le = (s, a, t) => {
|
|
147
|
+
var r;
|
|
148
|
+
a !== ((r = q.value) == null ? void 0 : r.newtPass) ? t(new Error("两次输入的密码不一致")) : t();
|
|
149
|
+
}, oe = async () => {
|
|
150
|
+
var a, t, r, l, n, e, i, p, d, f;
|
|
151
|
+
const s = await _({
|
|
152
|
+
key: {
|
|
153
|
+
systemKey: sessionStorage.getItem("systemKey"),
|
|
154
|
+
type: "structure",
|
|
155
|
+
// pageKey: "/系统管理/用户管理"
|
|
156
|
+
pageKey: "系统管理/用户管理"
|
|
157
|
+
}
|
|
158
|
+
});
|
|
159
|
+
if (((a = s == null ? void 0 : s.data) == null ? void 0 : a.code) === 200 && s.data.result && ((t = s.data.result) == null ? void 0 : t.length) > 0) {
|
|
160
|
+
const y = (i = (e = (n = (l = (r = s.data.result) == null ? void 0 : r[0]) == null ? void 0 : l.value) == null ? void 0 : n.pageData) == null ? void 0 : e.compData) == null ? void 0 : i.find((u) => (u == null ? void 0 : u.key) === "header"), m = (p = M.value) == null ? void 0 : p.map((u) => u == null ? void 0 : u.prop);
|
|
161
|
+
b.baseCols = y && ((d = y.contents) == null ? void 0 : d.map((u) => ({
|
|
162
|
+
...u,
|
|
163
|
+
isFormColHidden: (m == null ? void 0 : m.includes(u == null ? void 0 : u.prop)) || (u == null ? void 0 : u.label) === "操作"
|
|
164
|
+
})));
|
|
165
|
+
const h = (f = y.contents) == null ? void 0 : f.find((u) => (u == null ? void 0 : u.prop) === "password"), O = [
|
|
166
|
+
{
|
|
167
|
+
...h,
|
|
168
|
+
label: "当前密码",
|
|
169
|
+
prop: "currentPass",
|
|
170
|
+
validator: re
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
...h,
|
|
174
|
+
label: "新密码",
|
|
175
|
+
prop: "newtPass",
|
|
176
|
+
validator: ne
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
...h,
|
|
180
|
+
label: "确认密码",
|
|
181
|
+
prop: "confirmNewPass",
|
|
182
|
+
validator: le
|
|
183
|
+
}
|
|
184
|
+
];
|
|
185
|
+
b.otherCols = O, pe(o.value);
|
|
186
|
+
}
|
|
187
|
+
}, ue = (s) => {
|
|
188
|
+
q.value = s;
|
|
189
|
+
}, ie = async ({ content: s, buttonName: a }) => {
|
|
190
|
+
var r, l, n, e, i;
|
|
191
|
+
let t;
|
|
192
|
+
a === "确定" && (t = {
|
|
193
|
+
...o.value,
|
|
194
|
+
status: ((r = o.value) == null ? void 0 : r.status) ?? "启用",
|
|
195
|
+
// 目前是超管密码明文传输,非超管用户密码加密传输
|
|
196
|
+
password: ((n = (l = o.value) == null ? void 0 : l.layer) == null ? void 0 : n.toUpperCase()) === "SUPERADMIN" ? s == null ? void 0 : s.confirmNewPass : H(s == null ? void 0 : s.confirmNewPass, (e = c.value) == null ? void 0 : e.publicKey)
|
|
197
|
+
}), a === "保存基本信息" && (t = {
|
|
198
|
+
...o.value,
|
|
199
|
+
...s,
|
|
200
|
+
status: ((i = o.value) == null ? void 0 : i.status) ?? "启用"
|
|
201
|
+
}), D.value = !0, await V(t, a);
|
|
202
|
+
}, T = () => {
|
|
203
|
+
var r, l;
|
|
204
|
+
const s = {
|
|
205
|
+
base: [
|
|
206
|
+
{
|
|
207
|
+
label: "保存基本信息"
|
|
208
|
+
}
|
|
209
|
+
],
|
|
210
|
+
other: [
|
|
211
|
+
{
|
|
212
|
+
label: "重置",
|
|
213
|
+
background: "#b7b8b8"
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
label: "确定"
|
|
217
|
+
}
|
|
218
|
+
]
|
|
219
|
+
}, a = sessionStorage.getItem("authority"), t = JSON.parse(a || "");
|
|
220
|
+
if (Array.isArray(t)) {
|
|
221
|
+
const n = (r = v.value) != null && r.startsWith("/") ? (l = v.value) == null ? void 0 : l.substring(1) : v.value, e = t != null && t.includes(`${n}/基本信息`) ? s == null ? void 0 : s.base : [], i = t != null && t.includes(`${n}/修改密码`) ? s == null ? void 0 : s.other : [];
|
|
222
|
+
return {
|
|
223
|
+
base: e,
|
|
224
|
+
other: i
|
|
225
|
+
};
|
|
226
|
+
} else return typeof t == "string" && (t == null ? void 0 : t.toUpperCase()) === "SUPERADMIN" ? s : null;
|
|
227
|
+
}, pe = (s) => {
|
|
228
|
+
var a, t, r, l, n;
|
|
229
|
+
W.value = [
|
|
230
|
+
{
|
|
231
|
+
value: "基础信息",
|
|
232
|
+
label: "基础信息",
|
|
233
|
+
children: [
|
|
234
|
+
{
|
|
235
|
+
type: "form",
|
|
236
|
+
content: {
|
|
237
|
+
rowContents: (a = b.baseCols) == null ? void 0 : a.map((e) => ({
|
|
238
|
+
...e,
|
|
239
|
+
width: 2,
|
|
240
|
+
type: e == null ? void 0 : e.formType,
|
|
241
|
+
name: e == null ? void 0 : e.prop,
|
|
242
|
+
prop: e == null ? void 0 : e.prop,
|
|
243
|
+
contents: e == null ? void 0 : e.options,
|
|
244
|
+
value: s[e == null ? void 0 : e.prop]
|
|
245
|
+
})),
|
|
246
|
+
formRules: {
|
|
247
|
+
userName: [
|
|
248
|
+
{ required: !0, message: "输入不能为空", trigger: "blur" }
|
|
249
|
+
],
|
|
250
|
+
birthDay: [
|
|
251
|
+
{ required: !0, message: "输入不能为空", trigger: "blur" }
|
|
252
|
+
],
|
|
253
|
+
phone: [
|
|
254
|
+
{ required: !0, message: "输入不能为空", trigger: "blur" }
|
|
255
|
+
]
|
|
256
|
+
},
|
|
257
|
+
buttonValue: (t = T()) == null ? void 0 : t.base,
|
|
258
|
+
isEnableWrap: !1,
|
|
259
|
+
isButtonRow: !1
|
|
260
|
+
},
|
|
261
|
+
value: ""
|
|
262
|
+
}
|
|
263
|
+
]
|
|
264
|
+
},
|
|
265
|
+
{
|
|
266
|
+
value: "修改密码",
|
|
267
|
+
label: "修改密码",
|
|
268
|
+
children: [
|
|
269
|
+
{
|
|
270
|
+
type: "form",
|
|
271
|
+
content: {
|
|
272
|
+
rowContents: (r = b.otherCols) == null ? void 0 : r.map((e) => ({
|
|
273
|
+
...e,
|
|
274
|
+
width: 1,
|
|
275
|
+
type: e == null ? void 0 : e.formType,
|
|
276
|
+
name: e == null ? void 0 : e.prop,
|
|
277
|
+
contents: e == null ? void 0 : e.options
|
|
278
|
+
})),
|
|
279
|
+
formRules: (l = b.otherCols) == null ? void 0 : l.reduce((e, i) => (e[i.prop] = [
|
|
280
|
+
{ required: !0, message: "输入有误", trigger: "change" },
|
|
281
|
+
{
|
|
282
|
+
validator: (p, d, f) => i.validator(p, d, f),
|
|
283
|
+
trigger: "blur"
|
|
284
|
+
}
|
|
285
|
+
], e), {}),
|
|
286
|
+
buttonValue: (n = T()) == null ? void 0 : n.other,
|
|
287
|
+
isEnableWrap: !1
|
|
288
|
+
},
|
|
289
|
+
value: ""
|
|
290
|
+
}
|
|
291
|
+
]
|
|
292
|
+
}
|
|
293
|
+
];
|
|
294
|
+
}, ve = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
295
|
+
__proto__: null,
|
|
296
|
+
avatarLoading: U,
|
|
297
|
+
beforeSignDestroy: $,
|
|
298
|
+
changeFormTrigger: ue,
|
|
299
|
+
clickFormButton: ee,
|
|
300
|
+
clickSignButton: te,
|
|
301
|
+
clickTabButton: ie,
|
|
302
|
+
getUserTableHeadersAsync: oe,
|
|
303
|
+
itemData: ae,
|
|
304
|
+
loading: D,
|
|
305
|
+
refreshLoginUserInfoAsync: k,
|
|
306
|
+
rowContents: M,
|
|
307
|
+
signPadInfo: w,
|
|
308
|
+
signTypes: K,
|
|
309
|
+
signatureLoading: I,
|
|
310
|
+
submitImageAsync: se,
|
|
311
|
+
tabKey: Y,
|
|
312
|
+
tabsContents: W,
|
|
313
|
+
tempSignTypes: S,
|
|
314
|
+
uploadDisabled: N
|
|
315
|
+
}, Symbol.toStringTag, { value: "Module" }));
|
|
316
|
+
export {
|
|
317
|
+
ve as S,
|
|
318
|
+
Y as t
|
|
319
|
+
};
|