ss-component-new 1.1.321 → 1.1.322
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/{array-B7a7NPJU.cjs → array-BbvvSsMu.cjs} +1 -1
- package/dist/{array-C-FBt-w6.js → array-D1c5z7wR.js} +2 -2
- package/dist/{cloneDeep-Dfe27GGP.cjs → cloneDeep-Cz5C3YTY.cjs} +1 -1
- package/dist/{cloneDeep-BCBo2P7c.js → cloneDeep-_BP6PqFE.js} +1 -1
- package/dist/{index-DtKo1EwI.cjs → index-2DyWZAdI.cjs} +1 -1
- package/dist/{index-B8R_1YcJ.cjs → index-8Hh6ndcp.cjs} +1 -1
- package/dist/{index-BQg0VVq4.cjs → index-B04yaoqW.cjs} +1 -1
- package/dist/{index-zKJ_fhRb.js → index-B5mGte2C.js} +1 -1
- package/dist/{index-BYj7719b.js → index-B5xspgKx.js} +4 -4
- package/dist/{index-DYKwo9dQ.cjs → index-BDEd8FiZ.cjs} +1 -1
- package/dist/{index-B31X029_.js → index-BHVJl56b.js} +1 -1
- package/dist/{index-DH_8-yVF.cjs → index-BLnGKCeV.cjs} +1 -1
- package/dist/{index-CvyP7SN4.cjs → index-BViHfbD_.cjs} +1 -1
- package/dist/{index-DJCo-V_0.js → index-Bbd67AeJ.js} +3 -3
- package/dist/{index-Bs0aQvhY.cjs → index-BcojRq7f.cjs} +1 -1
- package/dist/{index-B9ylWbtH.cjs → index-BmH4vIv5.cjs} +1 -1
- package/dist/{index-BW8fHFr3.cjs → index-BnhhKe8F.cjs} +1 -1
- package/dist/{index-IynRqxzh.js → index-Bo9FXjtY.js} +9 -9
- package/dist/{index-BhRm0szn.cjs → index-BtqwaqYq.cjs} +1 -1
- package/dist/{index-CXJxkaVz.cjs → index-BvHZX-h-.cjs} +1 -1
- package/dist/{index-BCoI86GW.js → index-C6JIrngm.js} +8 -8
- package/dist/{index-a2ldY1f-.js → index-CAc69tT_.js} +188 -175
- package/dist/{index-C_ALukSb.js → index-CCK5r26s.js} +5 -5
- package/dist/{index-9GphTnn3.js → index-CFmGx7au.js} +3 -3
- package/dist/{index-Bgho40P2.cjs → index-CIKYVmYG.cjs} +1 -1
- package/dist/{index-Ca2rHt6C.js → index-COd6JefL.js} +1 -1
- package/dist/{index-BeJ-4T1d.js → index-CPFvyv9G.js} +7 -7
- package/dist/{index-56_km5fJ.cjs → index-CS1cZGwT.cjs} +1 -1
- package/dist/{index-GQAcezLl.cjs → index-CVOAzSks.cjs} +1 -1
- package/dist/{index-XAfW8sqN.js → index-CZoo5L0I.js} +8 -8
- package/dist/{index-CymFMSAS.js → index-C_IxW7Md.js} +9 -9
- package/dist/{index-bag5UhkN.js → index-Cex_DdEz.js} +6 -6
- package/dist/{index-6JoL18KU.js → index-CifB8Q5h.js} +6 -6
- package/dist/{index-B1pGYX6g.js → index-Cq_-kyms.js} +3 -3
- package/dist/{index-Cum9FmiL.js → index-CvmUTrUZ.js} +7 -7
- package/dist/{index-CLaDIaSW.cjs → index-CvqVEDJp.cjs} +1 -1
- package/dist/{index-CnyOW-3P.js → index-Cy7V5CTy.js} +4 -4
- package/dist/{index-DSmYcj7E.cjs → index-D7VphCVl.cjs} +1 -1
- package/dist/{index-ZC9w1ZOi.cjs → index-DAwrHG2B.cjs} +1 -1
- package/dist/{index-Yb-y-7vb.js → index-DFfFpmpu.js} +5 -5
- package/dist/{index-BK4WawKM.cjs → index-DHpjhrEA.cjs} +1 -1
- package/dist/index-DK5Q4nqN.cjs +11 -0
- package/dist/{index-DGQdhDlx.cjs → index-DSg6qN3u.cjs} +1 -1
- package/dist/{index-DFnqEKzJ.cjs → index-D_43dEyj.cjs} +1 -1
- package/dist/{index-ETZte82B.js → index-DdlsSh-T.js} +5 -5
- package/dist/{index-yAPzGZyB.js → index-DfXZ2EMp.js} +3 -3
- package/dist/{index-B2enzaE2.js → index-DiNYreUx.js} +3 -3
- package/dist/{index-DzbEZsq7.cjs → index-DiPSBd5G.cjs} +1 -1
- package/dist/{index-41WzW0HQ.js → index-Djvu9TqC.js} +8 -8
- package/dist/{index-DWRuDpPB.js → index-GuVmUiOk.js} +1 -1
- package/dist/{index-rsQ55kHW.cjs → index-RK4ejtZg.cjs} +1 -1
- package/dist/{index-CO1MoNNj.cjs → index-TdIgNVKx.cjs} +1 -1
- package/dist/{index-CksMAtZu.cjs → index-UEe32A7X.cjs} +161 -161
- package/dist/{index-gv4Kx45I.cjs → index-feWSPCw8.cjs} +1 -1
- package/dist/index-q45-pnfC.js +5632 -0
- package/dist/{index-C9giOxZg.js → index-znmNCY8T.js} +6 -6
- package/dist/{index.vue_vue_type_script_setup_true_lang-CI6HPiSn.js → index.vue_vue_type_script_setup_true_lang-DCkScM42.js} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-Dhlx6gOT.cjs → index.vue_vue_type_script_setup_true_lang-DXsUWEZn.cjs} +1 -1
- package/dist/index.vue_vue_type_style_index_0_scoped_62633fa4_lang-CMqyfT8F.js +1146 -0
- package/dist/index.vue_vue_type_style_index_0_scoped_62633fa4_lang-CtS3lsVS.cjs +1 -0
- package/dist/{index.vue_vue_type_style_index_0_scoped_d9b749a8_lang-CUJRJXLZ.js → index.vue_vue_type_style_index_0_scoped_d9b749a8_lang-BxpfZWjj.js} +8 -8
- package/dist/{index.vue_vue_type_style_index_0_scoped_d9b749a8_lang-BRb9nIeN.cjs → index.vue_vue_type_style_index_0_scoped_d9b749a8_lang-tJav1eMA.cjs} +1 -1
- package/dist/{login-DFyLmZjC.js → login-B19t0BgJ.js} +2 -2
- package/dist/{login-DI3Yef8J.cjs → login-CIjEq-GP.cjs} +1 -1
- package/dist/{main-MMs-Ocq5.cjs → main-EHe9Q7Jw.cjs} +1 -1
- package/dist/{main-KRl16v8X.js → main-vsUpk0Pc.js} +7 -7
- package/dist/{menu-ClaTWnGZ.cjs → menu-BwznZPTB.cjs} +1 -1
- package/dist/{menu-9axm5sPU.js → menu-DXatuTQB.js} +1 -1
- package/dist/model/final.pcd +19333 -0
- package/dist/model/target.pcd +29276 -0
- package/dist/obj/model.mtl +42 -0
- package/dist/obj/model.obj +26110 -0
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +1 -1
- package/dist/ss-component.js +7 -7
- package/dist/ss-component3.cjs +1 -1
- package/dist/ss-component3.js +1 -1
- package/package.json +1 -1
- package/public/model/final.pcd +19333 -0
- package/public/model/target.pcd +29276 -0
- package/public/obj/model.mtl +42 -0
- package/public/obj/model.obj +26110 -0
- package/dist/index-Coyk-8_r.js +0 -5421
- package/dist/index-aBU24Yq6.cjs +0 -9
- package/dist/index.vue_vue_type_style_index_0_scoped_63a4bd9d_lang-BRkLNqo1.js +0 -1091
- package/dist/index.vue_vue_type_style_index_0_scoped_63a4bd9d_lang-C-PKZjBI.cjs +0 -1
|
@@ -1,1091 +0,0 @@
|
|
|
1
|
-
import { ref as Z, watch as se, defineComponent as $e, defineProps as xe, computed as pe, onMounted as Ve } from "vue";
|
|
2
|
-
import { c as re, g as le, d as ne, e as ve, u as he, s as ee, E as ae } from "./menu-9axm5sPU.js";
|
|
3
|
-
import { al as Be, am as fe, an as Le, ao as Se, aj as q, u as Ge, ap as ue, ah as _e, aq as He, ar as Ye, as as qe, at as ze } from "./index-a2ldY1f-.js";
|
|
4
|
-
import { c as C } from "./cloneDeep-BCBo2P7c.js";
|
|
5
|
-
import { g as We, d as be } from "./crypto-BRyGpjGR.js";
|
|
6
|
-
import { t as Qe, g as Ae } from "./index-bag5UhkN.js";
|
|
7
|
-
import { t as Xe } from "./index-CnyOW-3P.js";
|
|
8
|
-
import { t as Ze } from "./index-DJCo-V_0.js";
|
|
9
|
-
import { t as Ie } from "./index-9GphTnn3.js";
|
|
10
|
-
import { v as we } from "./index-B1pGYX6g.js";
|
|
11
|
-
import { d as ye, p as me, m as ea, g as aa } from "./array-C-FBt-w6.js";
|
|
12
|
-
import { p as ie } from "./index-B31X029_.js";
|
|
13
|
-
import { g as sa } from "./index-BeJ-4T1d.js";
|
|
14
|
-
import { u as je } from "./login-DFyLmZjC.js";
|
|
15
|
-
import { a as ra, s as la, b as ta, c as na, d as ua } from "./index.vue_vue_type_style_index_0_scoped_d9b749a8_lang-CUJRJXLZ.js";
|
|
16
|
-
import { useRouter as oa } from "vue-router";
|
|
17
|
-
Z([]);
|
|
18
|
-
const De = async (e) => {
|
|
19
|
-
let a = [];
|
|
20
|
-
e == null || e.forEach((s) => {
|
|
21
|
-
var r;
|
|
22
|
-
(r = s.compData) == null || r.forEach((c) => {
|
|
23
|
-
var t;
|
|
24
|
-
(t = c.contents) == null || t.forEach((n) => {
|
|
25
|
-
var o, y, f, g;
|
|
26
|
-
const u = (y = (o = n == null ? void 0 : n.compData) == null ? void 0 : o.find((P) => (P == null ? void 0 : P.key) === "extra")) == null ? void 0 : y.value;
|
|
27
|
-
(g = (f = n.compData) == null ? void 0 : f.filter((P) => (P == null ? void 0 : P.key) !== "extra")) == null || g.forEach((P) => {
|
|
28
|
-
var h;
|
|
29
|
-
(h = Be(C(P))) == null || h.forEach(async (T) => {
|
|
30
|
-
var J, b, d, w, j, V, B, k;
|
|
31
|
-
if (T.comp === "Table") {
|
|
32
|
-
const R = await re({
|
|
33
|
-
key: {
|
|
34
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
35
|
-
pageKey: s.name,
|
|
36
|
-
type: "method",
|
|
37
|
-
version: 1,
|
|
38
|
-
methodName: (d = (J = s.name) == null ? void 0 : J.split("/")) == null ? void 0 : d[((b = s.name) == null ? void 0 : b.split("/").length) - 1],
|
|
39
|
-
methodKey: (w = Object.values(u[0])) == null ? void 0 : w[0],
|
|
40
|
-
parentTable: (T == null ? void 0 : T.parentTableContents) ?? ""
|
|
41
|
-
},
|
|
42
|
-
value: {
|
|
43
|
-
pageData: {
|
|
44
|
-
comp: (j = fe(C(T))) == null ? void 0 : j.comp,
|
|
45
|
-
compData: (V = fe(C(T))) == null ? void 0 : V.compData,
|
|
46
|
-
name: (B = fe(C(T))) == null ? void 0 : B.name
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
}), E = R.data.result, v = await ((k = Le(C(T))) == null ? void 0 : k.map(async (S) => {
|
|
50
|
-
var i, A;
|
|
51
|
-
let p;
|
|
52
|
-
S.length !== 0 && (p = await re({
|
|
53
|
-
key: {
|
|
54
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
55
|
-
pageKey: s.name,
|
|
56
|
-
type: "methodData",
|
|
57
|
-
methodKey: (i = Object.values(u[0])) == null ? void 0 : i[0],
|
|
58
|
-
tableId: E
|
|
59
|
-
},
|
|
60
|
-
value: {
|
|
61
|
-
tableData: S
|
|
62
|
-
}
|
|
63
|
-
}));
|
|
64
|
-
const l = (A = (await le({
|
|
65
|
-
key: {
|
|
66
|
-
parentTable: S,
|
|
67
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
68
|
-
pageKey: s.name,
|
|
69
|
-
type: "method"
|
|
70
|
-
}
|
|
71
|
-
})).data.result) == null ? void 0 : A.map(async (M) => await ne({
|
|
72
|
-
id: M.id,
|
|
73
|
-
key: {
|
|
74
|
-
systemKey: M.key.systemKey,
|
|
75
|
-
pageKey: M.key.pageKey,
|
|
76
|
-
type: M.key.type,
|
|
77
|
-
methodKey: M.key.methodKey,
|
|
78
|
-
parentTable: p.data.result
|
|
79
|
-
}
|
|
80
|
-
}));
|
|
81
|
-
return a.push(l), p;
|
|
82
|
-
}));
|
|
83
|
-
a.push(R), a.push(v);
|
|
84
|
-
}
|
|
85
|
-
});
|
|
86
|
-
});
|
|
87
|
-
});
|
|
88
|
-
});
|
|
89
|
-
}), await Promise.all(a);
|
|
90
|
-
}, pa = he(), ge = (e) => e == null ? void 0 : e.map((a) => (a.contents && (a.contents = a.contents.filter((s) => {
|
|
91
|
-
var r;
|
|
92
|
-
return ((r = s.comp) == null ? void 0 : r.toUpperCase()) !== "CALCULATOR";
|
|
93
|
-
})), a.compData && (a.compData = ge(a.compData)), a)), Ce = async (e) => {
|
|
94
|
-
var a, s, r, c, t, n, u, o, y, f, g, P, h, T, J, b, d, w, j, V, B, k, R;
|
|
95
|
-
if ((e == null ? void 0 : e.length) === 0) {
|
|
96
|
-
const E = await le({
|
|
97
|
-
key: {
|
|
98
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
99
|
-
layer: "superAdmin"
|
|
100
|
-
}
|
|
101
|
-
});
|
|
102
|
-
if (((a = E == null ? void 0 : E.data) == null ? void 0 : a.code) === 200 && (c = (r = (s = E == null ? void 0 : E.data) == null ? void 0 : s.result) == null ? void 0 : r[0]) != null && c.id) {
|
|
103
|
-
const v = (n = (t = E == null ? void 0 : E.data) == null ? void 0 : t.result) == null ? void 0 : n[0], S = (y = (o = (u = E == null ? void 0 : E.data) == null ? void 0 : u.result) == null ? void 0 : o[0]) == null ? void 0 : y.key;
|
|
104
|
-
S.systemType = "管理系统", await ne({
|
|
105
|
-
id: v == null ? void 0 : v.id,
|
|
106
|
-
key: S
|
|
107
|
-
});
|
|
108
|
-
}
|
|
109
|
-
return;
|
|
110
|
-
}
|
|
111
|
-
try {
|
|
112
|
-
const E = await le({
|
|
113
|
-
key: {
|
|
114
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
115
|
-
layer: "superAdmin"
|
|
116
|
-
}
|
|
117
|
-
});
|
|
118
|
-
if (((f = E == null ? void 0 : E.data) == null ? void 0 : f.code) === 200 && (h = (P = (g = E == null ? void 0 : E.data) == null ? void 0 : g.result) == null ? void 0 : P[0]) != null && h.id) {
|
|
119
|
-
const v = (J = (T = E == null ? void 0 : E.data) == null ? void 0 : T.result) == null ? void 0 : J[0], S = (w = (d = (b = E == null ? void 0 : E.data) == null ? void 0 : b.result) == null ? void 0 : d[0]) == null ? void 0 : w.key, p = (j = C(e)) == null ? void 0 : j.map((K) => {
|
|
120
|
-
var l;
|
|
121
|
-
return (l = K.compData) == null ? void 0 : l[0];
|
|
122
|
-
});
|
|
123
|
-
S.systemType = (B = (V = p == null ? void 0 : p.find((K) => (K == null ? void 0 : K.key) === "type")) == null ? void 0 : V.contents) == null ? void 0 : B[0], S.name = (R = (k = p == null ? void 0 : p.find((K) => (K == null ? void 0 : K.key) === "name")) == null ? void 0 : k.contents) == null ? void 0 : R[0], await ne({
|
|
124
|
-
id: v == null ? void 0 : v.id,
|
|
125
|
-
key: S
|
|
126
|
-
});
|
|
127
|
-
}
|
|
128
|
-
} catch (E) {
|
|
129
|
-
return Promise.reject(E);
|
|
130
|
-
}
|
|
131
|
-
}, Re = (e) => e == null ? void 0 : e.map((a) => (a.contents && (a.contents = a.contents.filter((s) => {
|
|
132
|
-
var r;
|
|
133
|
-
return ((r = s.comp) == null ? void 0 : r.toUpperCase()) === "CALCULATOR";
|
|
134
|
-
})), a.compData && (a.compData = Re(a.compData)), a)), Ee = (e) => {
|
|
135
|
-
const a = Re(e);
|
|
136
|
-
let s = [];
|
|
137
|
-
return a == null || a.forEach((r) => {
|
|
138
|
-
var c;
|
|
139
|
-
(c = r.compData) != null && c.find((t) => {
|
|
140
|
-
var n;
|
|
141
|
-
return (n = t == null ? void 0 : t.contents) == null ? void 0 : n.find((u) => (u == null ? void 0 : u.comp) === "calculator");
|
|
142
|
-
}) && s.push(r);
|
|
143
|
-
}), s;
|
|
144
|
-
}, Me = async (e) => {
|
|
145
|
-
var a, s, r, c;
|
|
146
|
-
try {
|
|
147
|
-
const t = await re({
|
|
148
|
-
key: {
|
|
149
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
150
|
-
pageKey: "menu",
|
|
151
|
-
type: "structure"
|
|
152
|
-
},
|
|
153
|
-
value: {
|
|
154
|
-
pageData: e
|
|
155
|
-
}
|
|
156
|
-
});
|
|
157
|
-
if (((a = t == null ? void 0 : t.data) == null ? void 0 : a.code) === 200) {
|
|
158
|
-
const n = (r = (s = e == null ? void 0 : e.compData) == null ? void 0 : s[0]) == null ? void 0 : r.contents;
|
|
159
|
-
pa.setRawMenus(n ?? []);
|
|
160
|
-
}
|
|
161
|
-
return (c = t == null ? void 0 : t.data) == null ? void 0 : c.code;
|
|
162
|
-
} catch (t) {
|
|
163
|
-
return Promise.reject(t);
|
|
164
|
-
}
|
|
165
|
-
}, de = async () => {
|
|
166
|
-
var e;
|
|
167
|
-
try {
|
|
168
|
-
const a = We(), s = await re({
|
|
169
|
-
key: {
|
|
170
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
171
|
-
pageKey: "secret",
|
|
172
|
-
type: "system"
|
|
173
|
-
},
|
|
174
|
-
value: {
|
|
175
|
-
cryptoInfo: {
|
|
176
|
-
publicKey: a.publicKey,
|
|
177
|
-
privateKey: a.privateKey
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
});
|
|
181
|
-
return ((e = s == null ? void 0 : s.data) == null ? void 0 : e.code) === 200;
|
|
182
|
-
} catch (a) {
|
|
183
|
-
throw a;
|
|
184
|
-
}
|
|
185
|
-
}, Ya = async (e) => {
|
|
186
|
-
var c, t, n, u, o, y;
|
|
187
|
-
let a = C(e);
|
|
188
|
-
a = [...a, Qe, Xe, Ze, Ie];
|
|
189
|
-
const { menuExist: s, structureExist: r } = await we();
|
|
190
|
-
if (sessionStorage.getItem("systemKey") && !s && !r) {
|
|
191
|
-
const f = (c = ge(a)) == null ? void 0 : c.filter((h) => {
|
|
192
|
-
var T, J, b;
|
|
193
|
-
return ((T = h == null ? void 0 : h.comp) == null ? void 0 : T.toUpperCase()) !== "MENU" && ((J = h == null ? void 0 : h.comp) == null ? void 0 : J.toUpperCase()) !== "MENUTOP" && ((b = h == null ? void 0 : h.comp) == null ? void 0 : b.toUpperCase()) !== "SYSTEM";
|
|
194
|
-
}), g = a == null ? void 0 : a.find((h) => h.comp === "Menu"), P = a == null ? void 0 : a.filter((h) => h.comp === "System");
|
|
195
|
-
await Me(g), await Ce(P), de(), await Se(f), await De((t = Ee(C(e))) == null ? void 0 : t.filter((h) => {
|
|
196
|
-
var T;
|
|
197
|
-
return ((T = h == null ? void 0 : h.comp) == null ? void 0 : T.toUpperCase()) !== "MENU";
|
|
198
|
-
}));
|
|
199
|
-
} else {
|
|
200
|
-
const g = (u = (n = (await le({
|
|
201
|
-
key: {
|
|
202
|
-
systemKey: sessionStorage.getItem("systemKey")
|
|
203
|
-
}
|
|
204
|
-
})).data.result) == null ? void 0 : n.filter((b) => {
|
|
205
|
-
var d;
|
|
206
|
-
return ((d = b == null ? void 0 : b.key) == null ? void 0 : d.layer) !== "superAdmin";
|
|
207
|
-
})) == null ? void 0 : u.map((b) => b.id), P = g == null ? void 0 : g.map(async (b) => await ve({
|
|
208
|
-
id: b
|
|
209
|
-
}));
|
|
210
|
-
await Promise.all(P);
|
|
211
|
-
const h = (o = ge(a)) == null ? void 0 : o.filter((b) => {
|
|
212
|
-
var d, w, j;
|
|
213
|
-
return ((d = b == null ? void 0 : b.comp) == null ? void 0 : d.toUpperCase()) !== "MENU" && ((w = b == null ? void 0 : b.comp) == null ? void 0 : w.toUpperCase()) !== "MENUTOP" && ((j = b == null ? void 0 : b.comp) == null ? void 0 : j.toUpperCase()) !== "SYSTEM";
|
|
214
|
-
}), T = a == null ? void 0 : a.find((b) => b.comp === "Menu"), J = a == null ? void 0 : a.filter((b) => b.comp === "System");
|
|
215
|
-
await Me(T), await Ce(J), de(), await Se(h), await De((y = Ee(C(e))) == null ? void 0 : y.filter((b) => {
|
|
216
|
-
var d;
|
|
217
|
-
return ((d = b == null ? void 0 : b.comp) == null ? void 0 : d.toUpperCase()) !== "MENU";
|
|
218
|
-
}));
|
|
219
|
-
}
|
|
220
|
-
}, Ke = Z(0), te = (e) => {
|
|
221
|
-
const a = [];
|
|
222
|
-
let s = 0, r = "";
|
|
223
|
-
for (; s < e.length; ) {
|
|
224
|
-
const c = e[s];
|
|
225
|
-
r = r + c, r[r.length - 1] === "]" && r[r.length - 2] === "}" && (a.push(r), r = ""), s++;
|
|
226
|
-
}
|
|
227
|
-
return a;
|
|
228
|
-
}, Pe = (e) => {
|
|
229
|
-
const a = [];
|
|
230
|
-
let s = 0, r = "";
|
|
231
|
-
for (; s < e.length; ) {
|
|
232
|
-
const c = e[s];
|
|
233
|
-
r = r + c, r[r.length - 4] === "]" && r[r.length - 3] === "]" && r[r.length - 2] === "," && r[r.length - 1] === "[" ? (a.push(r), r = "") : s === e.length - 1 && a.push(r), s++;
|
|
234
|
-
}
|
|
235
|
-
return a;
|
|
236
|
-
}, fa = (e) => {
|
|
237
|
-
const a = [];
|
|
238
|
-
let s = 0, r = "";
|
|
239
|
-
for (; s < e.length; ) {
|
|
240
|
-
const c = e[s];
|
|
241
|
-
r = r + c, r[r.length - 3] === "]" && r[r.length - 2] === ":" && r[r.length - 1] === "[" ? (a.push(r), r = "") : s === e.length - 1 && a.push(r), s++;
|
|
242
|
-
}
|
|
243
|
-
return a;
|
|
244
|
-
}, ca = (e) => {
|
|
245
|
-
const a = [];
|
|
246
|
-
let s = 0, r = "";
|
|
247
|
-
for (; s < e.length; ) {
|
|
248
|
-
const c = e[s];
|
|
249
|
-
r = r + c, r[r.length] !== "[" && r[r.length - 1] === "," && r[r.length - 2] === "]" && r[r.length - 3] === "}" && r[r.length - 4] === "]" ? (a.push(r), r = "") : s === e.length - 1 && a.push(r), s++;
|
|
250
|
-
}
|
|
251
|
-
return a;
|
|
252
|
-
}, ya = (e) => {
|
|
253
|
-
let a = "";
|
|
254
|
-
return e == null || e.forEach((s, r) => {
|
|
255
|
-
r !== 0 && (a = a + s);
|
|
256
|
-
}), a;
|
|
257
|
-
}, ga = (e) => (e == null ? void 0 : e.map((s) => {
|
|
258
|
-
var r, c;
|
|
259
|
-
return ((r = ye(s)) == null ? void 0 : r.length) !== 0 || ((c = ye(s.slice(1, s.length))) == null ? void 0 : c.length) !== 0;
|
|
260
|
-
})).every((s) => s === !0), Te = (e) => {
|
|
261
|
-
var n, u, o, y, f, g, P, h, T, J, b, d, w, j, V, B, k, R, E, v;
|
|
262
|
-
const a = C(e).slice(1, e.length - 1), s = (n = C(a).split(":")) == null ? void 0 : n[0];
|
|
263
|
-
let r = "{" + ((u = a.replace("{", "$R").split("$R")) == null ? void 0 : u[1]), c = r.slice(1, (r == null ? void 0 : r.length) - 1);
|
|
264
|
-
const t = fa(C(c));
|
|
265
|
-
if ((t == null ? void 0 : t.length) === 2) {
|
|
266
|
-
let S = (y = C(t)) == null ? void 0 : y[0].slice(0, ((o = C(t)) == null ? void 0 : o[0].length) - 2), p = "[" + ((f = C(t)) == null ? void 0 : f[1]);
|
|
267
|
-
if (S.includes("(")) {
|
|
268
|
-
let K = S == null ? void 0 : S.slice(1, (S == null ? void 0 : S.length) - 1);
|
|
269
|
-
if (K != null && K.includes("{")) {
|
|
270
|
-
let l = "";
|
|
271
|
-
(w = (d = (b = (J = (T = (h = (P = (g = C(K)) == null ? void 0 : g.split("(")) == null ? void 0 : P[1]) == null ? void 0 : h.split(")")) == null ? void 0 : T[0]) == null ? void 0 : J.replaceAll("{", "")) == null ? void 0 : b.replaceAll("}", "")) == null ? void 0 : d.split(":")) == null || w.forEach((A) => {
|
|
272
|
-
l = l === "" ? l + A.replaceAll("'", "") : l + "/" + A.replaceAll("'", "");
|
|
273
|
-
});
|
|
274
|
-
let i = l + "[" + ((j = K == null ? void 0 : K.split("[")) == null ? void 0 : j[1]);
|
|
275
|
-
if (q(p == null ? void 0 : p.replaceAll("'", '"')))
|
|
276
|
-
return {
|
|
277
|
-
groupName: s == null ? void 0 : s.slice(1, (s == null ? void 0 : s.length) - 1),
|
|
278
|
-
tableColumn: [],
|
|
279
|
-
tableContents: JSON.parse(p == null ? void 0 : p.replaceAll("'", '"')),
|
|
280
|
-
tableColumnPath: i
|
|
281
|
-
};
|
|
282
|
-
} else {
|
|
283
|
-
let l = [];
|
|
284
|
-
if ((V = K == null ? void 0 : K.split(",")) == null || V.forEach((i) => {
|
|
285
|
-
var A, M, D, O, L, N, U, _;
|
|
286
|
-
if (!(i != null && i.includes("(")))
|
|
287
|
-
l.push(i.slice(1, (i == null ? void 0 : i.length) - 1));
|
|
288
|
-
else {
|
|
289
|
-
let H = "", $ = (M = (A = C(i)) == null ? void 0 : A.split(":")) == null ? void 0 : M[1], G = $.slice(1, ($ == null ? void 0 : $.length) - 2), z = "";
|
|
290
|
-
(_ = (U = (N = (L = (O = (D = C(i)) == null ? void 0 : D.split("(")) == null ? void 0 : O[1]) == null ? void 0 : L.split(")")) == null ? void 0 : N[0]) == null ? void 0 : U.split(":")) == null || _.forEach((X) => {
|
|
291
|
-
z = z === "" ? z + X.replaceAll("'", "") : z + "/" + X.replaceAll("'", "");
|
|
292
|
-
}), H = H + G + "[" + z + "]", l.push(H);
|
|
293
|
-
}
|
|
294
|
-
}), q(p == null ? void 0 : p.replaceAll("'", '"')))
|
|
295
|
-
return {
|
|
296
|
-
groupName: s == null ? void 0 : s.slice(1, (s == null ? void 0 : s.length) - 1),
|
|
297
|
-
tableColumn: l,
|
|
298
|
-
tableContents: JSON.parse(p == null ? void 0 : p.replaceAll("'", '"'))
|
|
299
|
-
};
|
|
300
|
-
}
|
|
301
|
-
}
|
|
302
|
-
} else if (!((B = t == null ? void 0 : t[0]) != null && B.includes("[")) && !((k = t == null ? void 0 : t[0]) != null && k.includes("("))) {
|
|
303
|
-
let S = (R = t == null ? void 0 : t[0].replaceAll("'", "")) == null ? void 0 : R.split(":"), p = [
|
|
304
|
-
[
|
|
305
|
-
{
|
|
306
|
-
[S[0]]: S[1]
|
|
307
|
-
}
|
|
308
|
-
]
|
|
309
|
-
];
|
|
310
|
-
return {
|
|
311
|
-
groupName: s == null ? void 0 : s.slice(1, (s == null ? void 0 : s.length) - 1),
|
|
312
|
-
formContent: p
|
|
313
|
-
};
|
|
314
|
-
} else
|
|
315
|
-
((E = Pe(C(e))) == null ? void 0 : E.length) === 1 && ((v = Pe(C(e))) == null || v.forEach((S) => {
|
|
316
|
-
let p = S.slice(2, S.length - 2);
|
|
317
|
-
console.log(232, p);
|
|
318
|
-
}));
|
|
319
|
-
}, ha = (e, a) => {
|
|
320
|
-
var c;
|
|
321
|
-
const s = [], r = a.length;
|
|
322
|
-
return (c = C(a)) == null || c.forEach((t, n) => {
|
|
323
|
-
let u = [];
|
|
324
|
-
t == null || t.forEach((o) => {
|
|
325
|
-
var y, f, g, P, h, T, J, b, d, w, j, V, B, k, R, E, v;
|
|
326
|
-
if (q(e.replaceAll("'", '"')))
|
|
327
|
-
(y = JSON.parse(e.replaceAll("'", '"'))) == null || y.forEach((S) => {
|
|
328
|
-
s.push([{
|
|
329
|
-
key: o == null ? void 0 : o.key,
|
|
330
|
-
value: (o == null ? void 0 : o.value) + "/" + S
|
|
331
|
-
}]);
|
|
332
|
-
});
|
|
333
|
-
else {
|
|
334
|
-
u.push(o);
|
|
335
|
-
let S;
|
|
336
|
-
if (ga(te(e)))
|
|
337
|
-
C(te(e)).length === 1 ? S = C(te(e)) : S = (f = C(te(e))) == null ? void 0 : f.map((p) => p.slice(1, p.length)), S = S == null ? void 0 : S.map((p) => {
|
|
338
|
-
var M, D, O, L, N, U, _, H;
|
|
339
|
-
const K = C(p).slice(1, p.length - 1), l = (M = C(K).split(":")) == null ? void 0 : M[0];
|
|
340
|
-
let i = "{" + ((D = K.split("{")) == null ? void 0 : D[1]);
|
|
341
|
-
i = C(i).slice(1, i.length - 1);
|
|
342
|
-
let A = ya(i.split(":"));
|
|
343
|
-
if (q(A.slice(0, A.length - 1).replaceAll("'", '"')) || q(A.replaceAll("'", '"')))
|
|
344
|
-
if (i != null && i.includes("[")) {
|
|
345
|
-
let $ = q(A.replaceAll("'", '"')) ? JSON.parse(A.replaceAll("'", '"')) : JSON.parse(A.slice(0, A.length - 1).replaceAll("'", '"'));
|
|
346
|
-
return {
|
|
347
|
-
groupName: l.slice(1, l.length - 1).includes("[") ? "" : l.slice(1, l.length - 1),
|
|
348
|
-
tableColumn: JSON.parse(((O = i.split(":")) == null ? void 0 : O[0]).replaceAll("'", '"')),
|
|
349
|
-
tableContents: $
|
|
350
|
-
};
|
|
351
|
-
} else {
|
|
352
|
-
let $ = (L = i == null ? void 0 : i.replace(":", "$R")) == null ? void 0 : L.split("$R");
|
|
353
|
-
const G = [
|
|
354
|
-
[
|
|
355
|
-
{
|
|
356
|
-
[$[0].replaceAll("'", "")]: ($ == null ? void 0 : $[1]).replaceAll("'", "")
|
|
357
|
-
}
|
|
358
|
-
]
|
|
359
|
-
];
|
|
360
|
-
return {
|
|
361
|
-
groupName: l.slice(1, l.length - 1).includes("[") ? "" : l.slice(1, l.length - 1),
|
|
362
|
-
formContents: G
|
|
363
|
-
};
|
|
364
|
-
}
|
|
365
|
-
else {
|
|
366
|
-
const $ = C(p).slice(2, p.length - 2), G = (N = $ == null ? void 0 : $.replace(":", "$S")) == null ? void 0 : N.split("$S"), z = (U = G == null ? void 0 : G[0]) == null ? void 0 : U.replaceAll("'", '"'), X = (H = (_ = G == null ? void 0 : G[1]) == null ? void 0 : _.replaceAll("'", '"')) == null ? void 0 : H.replace(/\\/g, "\\\\");
|
|
367
|
-
return q(z) && q(X) ? {
|
|
368
|
-
groupName: "",
|
|
369
|
-
tableColumn: JSON.parse(z),
|
|
370
|
-
tableContents: JSON.parse(X)
|
|
371
|
-
} : Te(C(p));
|
|
372
|
-
}
|
|
373
|
-
}), r > 1 && S.length === 1 ? S != null && S.find((p) => {
|
|
374
|
-
var K;
|
|
375
|
-
return (p == null ? void 0 : p.formContents) && ((K = p == null ? void 0 : p.formContents) == null ? void 0 : K.length) > 0;
|
|
376
|
-
}) ? (u.push({
|
|
377
|
-
key: "groupName",
|
|
378
|
-
value: (g = S == null ? void 0 : S[0]) == null ? void 0 : g.groupName
|
|
379
|
-
}), u.push({
|
|
380
|
-
key: "formContent",
|
|
381
|
-
value: (P = S == null ? void 0 : S[0]) == null ? void 0 : P.formContents
|
|
382
|
-
})) : (u.push({
|
|
383
|
-
key: "groupName",
|
|
384
|
-
value: (h = S == null ? void 0 : S[0]) == null ? void 0 : h.groupName
|
|
385
|
-
}), u.push({
|
|
386
|
-
key: "tableColumn",
|
|
387
|
-
value: (T = S == null ? void 0 : S[0]) == null ? void 0 : T.tableColumn
|
|
388
|
-
}), u.push({
|
|
389
|
-
key: "tableContents",
|
|
390
|
-
value: [(b = (J = S == null ? void 0 : S[0]) == null ? void 0 : J.tableContents) == null ? void 0 : b[n]]
|
|
391
|
-
}), u.push({
|
|
392
|
-
key: "tablePath",
|
|
393
|
-
value: (d = S == null ? void 0 : S[0]) == null ? void 0 : d.tableColumnPath
|
|
394
|
-
})) : S == null || S.forEach((p) => {
|
|
395
|
-
var l, i, A, M, D, O, L, N;
|
|
396
|
-
let K;
|
|
397
|
-
a.length === 1 ? Array.isArray(p == null ? void 0 : p.tableContents) && (K = (l = p == null ? void 0 : p.tableContents) != null && l.every((U) => Array.isArray(U)) ? p == null ? void 0 : p.tableContents : [p == null ? void 0 : p.tableContents]) : Array.isArray((i = p == null ? void 0 : p.tableContents) == null ? void 0 : i[n]) ? K = (M = (A = p == null ? void 0 : p.tableContents) == null ? void 0 : A[n]) != null && M.every((U) => Array.isArray(U)) ? (D = p == null ? void 0 : p.tableContents) == null ? void 0 : D[n] : [(O = p == null ? void 0 : p.tableContents) == null ? void 0 : O[n]] : K = [[(L = p == null ? void 0 : p.tableContents) == null ? void 0 : L[n]]], p != null && p.formContents && ((N = p == null ? void 0 : p.formContents) == null ? void 0 : N.length) > 0 ? (u.push({
|
|
398
|
-
key: "groupName",
|
|
399
|
-
value: p == null ? void 0 : p.groupName
|
|
400
|
-
}), u.push({
|
|
401
|
-
key: "formContent",
|
|
402
|
-
value: p == null ? void 0 : p.formContents
|
|
403
|
-
})) : (u.push({
|
|
404
|
-
key: "groupName",
|
|
405
|
-
value: p == null ? void 0 : p.groupName
|
|
406
|
-
}), u.push({
|
|
407
|
-
key: "tableColumn",
|
|
408
|
-
value: p == null ? void 0 : p.tableColumn
|
|
409
|
-
}), u.push({
|
|
410
|
-
key: "tableContents",
|
|
411
|
-
value: K
|
|
412
|
-
}), u.push({
|
|
413
|
-
key: "tablePath",
|
|
414
|
-
value: p == null ? void 0 : p.tableColumnPath
|
|
415
|
-
}));
|
|
416
|
-
});
|
|
417
|
-
else {
|
|
418
|
-
const p = e == null ? void 0 : e.slice(1, e.length - 1), K = (j = (w = C(p)) == null ? void 0 : w.split(":")) == null ? void 0 : j[0], l = (R = (k = (B = (V = C(p)) == null ? void 0 : V.replace(":", "$R")) == null ? void 0 : B.split("$R")) == null ? void 0 : k[1]) == null ? void 0 : R.replaceAll("'", '"');
|
|
419
|
-
q(l == null ? void 0 : l.slice(1, l.length - 1)) ? (u.push({
|
|
420
|
-
key: "groupName",
|
|
421
|
-
value: K == null ? void 0 : K.slice(1, K.length - 1)
|
|
422
|
-
}), u.push({
|
|
423
|
-
key: "formContent",
|
|
424
|
-
value: (E = JSON.parse(l == null ? void 0 : l.slice(1, l.length - 1))) == null ? void 0 : E[n]
|
|
425
|
-
})) : (v = ca(p)) == null || v.forEach((i) => {
|
|
426
|
-
var O, L, N, U, _, H, $, G, z, X;
|
|
427
|
-
const A = i.slice(1, i.length - 2), M = (L = (O = C(A)) == null ? void 0 : O.split(":")) == null ? void 0 : L[0], D = (H = (_ = (U = (N = C(A)) == null ? void 0 : N.replace(":", "$R")) == null ? void 0 : U.split("$R")) == null ? void 0 : _[1]) == null ? void 0 : H.replaceAll("'", '"');
|
|
428
|
-
if (q(D == null ? void 0 : D.slice(1, D.length - 1)))
|
|
429
|
-
u.push({
|
|
430
|
-
key: "groupName",
|
|
431
|
-
value: M == null ? void 0 : M.slice(1, M.length - 1)
|
|
432
|
-
}), Array.isArray(($ = JSON.parse(D == null ? void 0 : D.slice(1, D.length - 1))) == null ? void 0 : $[n]) ? u.push({
|
|
433
|
-
key: "formContent",
|
|
434
|
-
value: (G = JSON.parse(D == null ? void 0 : D.slice(1, D.length - 1))) == null ? void 0 : G[n]
|
|
435
|
-
}) : u.push({
|
|
436
|
-
key: "formContent",
|
|
437
|
-
value: [JSON.parse(D == null ? void 0 : D.slice(1, D.length - 1))]
|
|
438
|
-
});
|
|
439
|
-
else if (q(D == null ? void 0 : D.slice(1, D.length)))
|
|
440
|
-
u.push({
|
|
441
|
-
key: "groupName",
|
|
442
|
-
value: M == null ? void 0 : M.slice(1, M.length - 1)
|
|
443
|
-
}), u.push({
|
|
444
|
-
key: "formContent",
|
|
445
|
-
value: (z = JSON.parse(D == null ? void 0 : D.slice(1, D.length))) == null ? void 0 : z[n]
|
|
446
|
-
});
|
|
447
|
-
else {
|
|
448
|
-
let Y = Te(C(i));
|
|
449
|
-
Y != null && Y.formContent && ((X = Y == null ? void 0 : Y.formContent) == null ? void 0 : X.length) > 0 && (u.push({
|
|
450
|
-
key: "groupName",
|
|
451
|
-
value: Y == null ? void 0 : Y.groupName
|
|
452
|
-
}), u.push({
|
|
453
|
-
key: "formContent",
|
|
454
|
-
value: Y == null ? void 0 : Y.formContent
|
|
455
|
-
}));
|
|
456
|
-
}
|
|
457
|
-
});
|
|
458
|
-
}
|
|
459
|
-
s.push(u);
|
|
460
|
-
}
|
|
461
|
-
});
|
|
462
|
-
}), s;
|
|
463
|
-
}, ke = (e) => {
|
|
464
|
-
const a = [];
|
|
465
|
-
let s = !1;
|
|
466
|
-
return e.forEach((r) => {
|
|
467
|
-
Array.isArray(r) && (s = !0, r.forEach((c) => {
|
|
468
|
-
const t = e.map((n) => n === r ? c : n);
|
|
469
|
-
a.push(...ke(t));
|
|
470
|
-
}));
|
|
471
|
-
}), s ? a : [e];
|
|
472
|
-
}, ia = (e) => {
|
|
473
|
-
var c, t;
|
|
474
|
-
const a = (c = e.map((n) => {
|
|
475
|
-
var o, y;
|
|
476
|
-
let u = (y = (o = n.key.split("(")) == null ? void 0 : o[1]) == null ? void 0 : y.trim();
|
|
477
|
-
return u == null ? void 0 : u.slice(0, u.length - 1);
|
|
478
|
-
})) == null ? void 0 : c.filter((n) => n), s = [];
|
|
479
|
-
a == null || a.forEach((n) => {
|
|
480
|
-
var y;
|
|
481
|
-
const u = C(n).replaceAll("{", "").replaceAll("}", "").trim();
|
|
482
|
-
let o = [];
|
|
483
|
-
u.split(":").forEach((f) => {
|
|
484
|
-
var g;
|
|
485
|
-
if (f.includes("[")) {
|
|
486
|
-
const P = (g = f.slice(1, f.length - 1)) == null ? void 0 : g.split(",");
|
|
487
|
-
o.push(P);
|
|
488
|
-
} else
|
|
489
|
-
o.push(f);
|
|
490
|
-
}), (y = ke(o)) == null || y.forEach((f) => {
|
|
491
|
-
s.push(f);
|
|
492
|
-
});
|
|
493
|
-
});
|
|
494
|
-
const r = (t = s == null ? void 0 : s.filter((n) => n.length !== 0)) == null ? void 0 : t.map((n) => {
|
|
495
|
-
let u = "";
|
|
496
|
-
return n.forEach((o) => {
|
|
497
|
-
o.includes("{") || (u = u === "" ? u + C(o) : u + "/" + C(o));
|
|
498
|
-
}), u;
|
|
499
|
-
});
|
|
500
|
-
return ea([...new Set(r)]);
|
|
501
|
-
}, ka = (e) => {
|
|
502
|
-
var n, u;
|
|
503
|
-
if (!e) return;
|
|
504
|
-
let a = [];
|
|
505
|
-
const s = aa(e), r = C(s).replaceAll("{", "").replaceAll("}", "").trim();
|
|
506
|
-
let c = [];
|
|
507
|
-
return r.split(":").forEach((o) => {
|
|
508
|
-
var y;
|
|
509
|
-
if (o.includes("[")) {
|
|
510
|
-
const f = (y = o.slice(1, o.length - 1)) == null ? void 0 : y.split(",");
|
|
511
|
-
c.push(f);
|
|
512
|
-
} else
|
|
513
|
-
c.push(o);
|
|
514
|
-
}), (n = ke(c)) == null || n.forEach((o) => {
|
|
515
|
-
a.push(o);
|
|
516
|
-
}), (u = a == null ? void 0 : a.filter((o) => o.length !== 0)) == null ? void 0 : u.map((o) => {
|
|
517
|
-
let y = "";
|
|
518
|
-
return o.forEach((f) => {
|
|
519
|
-
f.includes("{") || (y = y === "" ? y + C(f) : y + "/" + C(f));
|
|
520
|
-
}), y;
|
|
521
|
-
});
|
|
522
|
-
}, Sa = (e) => ({
|
|
523
|
-
comp: "MenuTop",
|
|
524
|
-
compData: [
|
|
525
|
-
{
|
|
526
|
-
key: "menuContents",
|
|
527
|
-
contents: JSON.parse(e == null ? void 0 : e.value.trim().replaceAll("'", '"'))
|
|
528
|
-
}
|
|
529
|
-
],
|
|
530
|
-
name: ""
|
|
531
|
-
}), ba = (e) => {
|
|
532
|
-
const a = [], s = ka(e == null ? void 0 : e.key);
|
|
533
|
-
return s && (s == null ? void 0 : s.length) > 0 && (s == null || s.forEach((c) => {
|
|
534
|
-
a.push([{
|
|
535
|
-
key: "contentPath",
|
|
536
|
-
value: c
|
|
537
|
-
}]);
|
|
538
|
-
})), ha(e == null ? void 0 : e.value, a);
|
|
539
|
-
}, Aa = (e) => {
|
|
540
|
-
const a = [];
|
|
541
|
-
let s = [];
|
|
542
|
-
return e == null || e.forEach((r, c) => {
|
|
543
|
-
var t;
|
|
544
|
-
(s == null ? void 0 : s.length) === 0 ? s.push(r) : (s.push(r), ((t = e[c + 1]) == null ? void 0 : t.key) === "groupName" && (a.push(s), s = []));
|
|
545
|
-
}), a.push(s), a;
|
|
546
|
-
}, Da = (e) => {
|
|
547
|
-
var s;
|
|
548
|
-
return (s = C(e)) == null ? void 0 : s.map((r) => {
|
|
549
|
-
var n, u;
|
|
550
|
-
let c = [];
|
|
551
|
-
return (n = Aa(r == null ? void 0 : r.filter((o) => (o == null ? void 0 : o.key) !== "contentPath"))) == null || n.forEach((o) => {
|
|
552
|
-
var g, P, h, T, J, b, d, w, j, V, B;
|
|
553
|
-
let y = [];
|
|
554
|
-
if (o.length === 0)
|
|
555
|
-
return;
|
|
556
|
-
let f = Array.isArray((g = o.find((k) => (k == null ? void 0 : k.key) === "tableColumn")) == null ? void 0 : g.value) ? (h = (P = o.find((k) => (k == null ? void 0 : k.key) === "tableColumn")) == null ? void 0 : P.value) == null ? void 0 : h.map((k) => ({
|
|
557
|
-
label: k
|
|
558
|
-
})) : [(T = o.find((k) => (k == null ? void 0 : k.key) === "tableColumn")) == null ? void 0 : T.value].map((k) => ({
|
|
559
|
-
label: k
|
|
560
|
-
}));
|
|
561
|
-
if ((J = o == null ? void 0 : o.find((k) => (k == null ? void 0 : k.key) === "tablePath")) != null && J.value && f.push({
|
|
562
|
-
columnPath: (b = o == null ? void 0 : o.find((k) => (k == null ? void 0 : k.key) === "tablePath")) == null ? void 0 : b.value
|
|
563
|
-
}), f = f == null ? void 0 : f.map((k) => {
|
|
564
|
-
var R, E, v, S, p, K, l, i;
|
|
565
|
-
return k != null && k.label && !((R = k == null ? void 0 : k.label) != null && R.includes("[")) ? k : {
|
|
566
|
-
label: (v = (E = C(k == null ? void 0 : k.label)) == null ? void 0 : E.split("[")) == null ? void 0 : v[0],
|
|
567
|
-
formMenuSelect: (i = (l = (K = (p = (S = C(k == null ? void 0 : k.label)) == null ? void 0 : S.split("[")) == null ? void 0 : p[1]) == null ? void 0 : K.split("]")) == null ? void 0 : l[0]) == null ? void 0 : i.split("/"),
|
|
568
|
-
columnPath: k == null ? void 0 : k.columnPath
|
|
569
|
-
};
|
|
570
|
-
}), f = f == null ? void 0 : f.filter((k) => (k == null ? void 0 : k.label) !== void 0 || (k == null ? void 0 : k.columnPath) !== void 0), f.length !== 0 && f.push({
|
|
571
|
-
label: "操作"
|
|
572
|
-
}), o != null && o.find((k) => (k == null ? void 0 : k.key) === "formContent")) {
|
|
573
|
-
const k = (d = o.find((E) => (E == null ? void 0 : E.key) === "formContent")) == null ? void 0 : d.value;
|
|
574
|
-
let R = [];
|
|
575
|
-
Array.isArray(k) && k.forEach((E) => {
|
|
576
|
-
E.forEach((v) => {
|
|
577
|
-
var S, p;
|
|
578
|
-
Ke.value++, R.push({
|
|
579
|
-
id: Ke.value,
|
|
580
|
-
key: (S = Object.keys(v)) == null ? void 0 : S[0],
|
|
581
|
-
value: (p = Object.values(v)) == null ? void 0 : p[0],
|
|
582
|
-
width: E.length
|
|
583
|
-
});
|
|
584
|
-
});
|
|
585
|
-
}), y.push({
|
|
586
|
-
key: "formFlex",
|
|
587
|
-
contents: ""
|
|
588
|
-
}), y.push({
|
|
589
|
-
key: "formContent",
|
|
590
|
-
contents: R
|
|
591
|
-
}), c.push({
|
|
592
|
-
comp: "Form",
|
|
593
|
-
compData: C(y),
|
|
594
|
-
name: (w = o.find((E) => (E == null ? void 0 : E.key) === "groupName")) == null ? void 0 : w.value
|
|
595
|
-
});
|
|
596
|
-
}
|
|
597
|
-
f.length !== 0 && (y.push({
|
|
598
|
-
key: "header",
|
|
599
|
-
contents: f
|
|
600
|
-
}), y.push({
|
|
601
|
-
key: "tableContents",
|
|
602
|
-
contents: (j = o.find((k) => (k == null ? void 0 : k.key) === "tableContents")) == null ? void 0 : j.value
|
|
603
|
-
}), y.push({
|
|
604
|
-
key: "extraButton",
|
|
605
|
-
contents: [{ label: "新增" }]
|
|
606
|
-
}), y.push({
|
|
607
|
-
key: "rowButton",
|
|
608
|
-
contents: [{ label: "查看" }, { label: "编辑" }, { label: "删除" }]
|
|
609
|
-
}), c.push({
|
|
610
|
-
comp: "Table",
|
|
611
|
-
compData: y,
|
|
612
|
-
name: (B = (V = o.find((k) => (k == null ? void 0 : k.key) === "groupName")) == null ? void 0 : V.value) == null ? void 0 : B.replaceAll("'", "")
|
|
613
|
-
}));
|
|
614
|
-
}), {
|
|
615
|
-
comp: "Group",
|
|
616
|
-
compData: [{
|
|
617
|
-
key: "groupContents",
|
|
618
|
-
contents: c
|
|
619
|
-
}],
|
|
620
|
-
name: (u = r == null ? void 0 : r.find((o) => (o == null ? void 0 : o.key) === "contentPath")) == null ? void 0 : u.value
|
|
621
|
-
};
|
|
622
|
-
});
|
|
623
|
-
}, Ca = (e) => {
|
|
624
|
-
var c;
|
|
625
|
-
let a = [];
|
|
626
|
-
a.push({
|
|
627
|
-
comp: "Menu",
|
|
628
|
-
compData: [{
|
|
629
|
-
contents: ia(C(e)),
|
|
630
|
-
key: "menuContents"
|
|
631
|
-
}],
|
|
632
|
-
name: ""
|
|
633
|
-
}), e != null && e.find((t) => {
|
|
634
|
-
var n;
|
|
635
|
-
return !((n = t == null ? void 0 : t.key) != null && n.includes("("));
|
|
636
|
-
}) && ((c = e == null ? void 0 : e.filter((t) => {
|
|
637
|
-
var n;
|
|
638
|
-
return !((n = t == null ? void 0 : t.key) != null && n.includes("("));
|
|
639
|
-
})) == null || c.forEach((t) => {
|
|
640
|
-
var n, u;
|
|
641
|
-
q(t.value.replaceAll("'", '"')) && Array.isArray(JSON.parse(t.value.replaceAll("'", '"'))) && ((n = JSON.parse(t.value.replaceAll("'", '"'))) != null && n.every((o) => typeof o == "string")) ? a.push(Sa(t)) : (u = JSON.parse(t.value.replaceAll("'", '"'))) == null || u.forEach((o) => {
|
|
642
|
-
var y, f, g, P;
|
|
643
|
-
((y = Object.keys(o)) == null ? void 0 : y[0]) === "类型" ? a.push({
|
|
644
|
-
comp: "System",
|
|
645
|
-
compData: [
|
|
646
|
-
{
|
|
647
|
-
key: "type",
|
|
648
|
-
contents: [(f = Object.values(o)) == null ? void 0 : f[0]]
|
|
649
|
-
}
|
|
650
|
-
]
|
|
651
|
-
}) : ((g = Object.keys(o)) == null ? void 0 : g[0]) === "名称" && a.push({
|
|
652
|
-
comp: "System",
|
|
653
|
-
compData: [
|
|
654
|
-
{
|
|
655
|
-
key: "name",
|
|
656
|
-
contents: [(P = Object.values(o)) == null ? void 0 : P[0]]
|
|
657
|
-
}
|
|
658
|
-
]
|
|
659
|
-
});
|
|
660
|
-
});
|
|
661
|
-
}));
|
|
662
|
-
const s = e == null ? void 0 : e.filter((t) => {
|
|
663
|
-
var n;
|
|
664
|
-
return (n = t == null ? void 0 : t.key) == null ? void 0 : n.includes("(");
|
|
665
|
-
}).map((t) => ba(t)).filter((t) => (t == null ? void 0 : t.length) !== 0);
|
|
666
|
-
let r = [];
|
|
667
|
-
return s == null || s.forEach((t) => {
|
|
668
|
-
t == null || t.forEach((n) => {
|
|
669
|
-
r != null && r.find((u) => {
|
|
670
|
-
var o, y;
|
|
671
|
-
return ((o = u == null ? void 0 : u.find((f) => (f == null ? void 0 : f.key) === "contentPath")) == null ? void 0 : o.value) === ((y = n == null ? void 0 : n.find((f) => (f == null ? void 0 : f.key) === "contentPath")) == null ? void 0 : y.value);
|
|
672
|
-
}) ? r = r == null ? void 0 : r.map((u) => {
|
|
673
|
-
var y, f;
|
|
674
|
-
return ((y = u == null ? void 0 : u.find((g) => (g == null ? void 0 : g.key) === "contentPath")) == null ? void 0 : y.value) === ((f = n == null ? void 0 : n.find((g) => (g == null ? void 0 : g.key) === "contentPath")) == null ? void 0 : f.value) && (u = [...u, ...n.filter((g) => (g == null ? void 0 : g.key) !== "contentPath")]), u;
|
|
675
|
-
}) : r.push(n);
|
|
676
|
-
});
|
|
677
|
-
}), a = [...a, ...Da(r)], a;
|
|
678
|
-
}, qa = (e) => {
|
|
679
|
-
var c, t, n, u, o;
|
|
680
|
-
const a = (n = ye((t = (c = C(e)) == null ? void 0 : c.replace("(", "(")) == null ? void 0 : t.replace(")", ")"))) == null ? void 0 : n.filter((y) => y !== ""), s = (o = (u = C(a)) == null ? void 0 : u.filter((y) => !y.includes("/*"))) == null ? void 0 : o.map((y) => me(y));
|
|
681
|
-
return Ca(s);
|
|
682
|
-
}, Ea = je(), { loginUserInfo: Oe, cryptoInfo: m } = ee(Ea), F = Ge(ie), { itemData: Ma, curStructureCompIds: Ne, isSubmitCurStructure: da, isRefreshCurStructure: Ka } = ee(F), Fe = he(ie), { activeMenuPath: Q, buttonTriggerType: Pa, cacheStructures: Ta } = ee(Fe), W = _e(ie), { selectTitle: I } = ee(W), za = () => {
|
|
683
|
-
F.setIsEdit("edit"), F.setSubmitCurStructure(Q.value !== "/平台管理/菜单管理");
|
|
684
|
-
}, Wa = () => {
|
|
685
|
-
F.setIsEdit("view"), F.setRefreshCurStructure(!0);
|
|
686
|
-
}, Qa = async (e) => {
|
|
687
|
-
var a;
|
|
688
|
-
if ((e == null ? void 0 : e.key) === "main" || I.value.length === 1)
|
|
689
|
-
x.value = await ue(Q.value, sessionStorage.getItem("systemKey")), W.setSelectIndex(""), W.setSelectMenu(""), W.setSelectTitle([]);
|
|
690
|
-
else {
|
|
691
|
-
const s = [], r = (e == null ? void 0 : e.key) === "" || !(e != null && e.key) ? "" : parseInt(e == null ? void 0 : e.key);
|
|
692
|
-
x.value = await ue(Q.value, sessionStorage.getItem("systemKey"), r);
|
|
693
|
-
let c = -1;
|
|
694
|
-
(a = I.value) == null || a.forEach((t, n) => {
|
|
695
|
-
(t == null ? void 0 : t.key) === (e == null ? void 0 : e.key) && (c = n), (c === -1 || c >= n) && s.push(t);
|
|
696
|
-
}), W.setSelectTitle(s), r !== "" ? W.setSelectMenu(e == null ? void 0 : e.key) : (W.setSelectIndex(""), W.setSelectMenu(""));
|
|
697
|
-
}
|
|
698
|
-
F.setItemData(x.value), F.setOriginalData(x.value);
|
|
699
|
-
}, ce = async (e, a, s, r = "contentConfig") => {
|
|
700
|
-
var c, t, n;
|
|
701
|
-
try {
|
|
702
|
-
let u, o;
|
|
703
|
-
a === "create" ? (u = {
|
|
704
|
-
key: {
|
|
705
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
706
|
-
pageKey: s,
|
|
707
|
-
type: "structure",
|
|
708
|
-
structureBelong: r,
|
|
709
|
-
parentTable: "",
|
|
710
|
-
version: 1
|
|
711
|
-
},
|
|
712
|
-
value: {
|
|
713
|
-
pageData: {
|
|
714
|
-
...e,
|
|
715
|
-
compData: (c = e == null ? void 0 : e.compData) == null ? void 0 : c.filter((f) => (f == null ? void 0 : f.key) !== "tableContents")
|
|
716
|
-
}
|
|
717
|
-
}
|
|
718
|
-
}, o = re) : a === "update" ? (u = {
|
|
719
|
-
id: e == null ? void 0 : e.id,
|
|
720
|
-
key: {
|
|
721
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
722
|
-
pageKey: s,
|
|
723
|
-
type: "structure",
|
|
724
|
-
structureBelong: r,
|
|
725
|
-
parentTable: "",
|
|
726
|
-
version: 1
|
|
727
|
-
},
|
|
728
|
-
value: {
|
|
729
|
-
pageData: {
|
|
730
|
-
...e,
|
|
731
|
-
compData: (t = e == null ? void 0 : e.compData) == null ? void 0 : t.filter((f) => (f == null ? void 0 : f.key) !== "tableContents")
|
|
732
|
-
}
|
|
733
|
-
}
|
|
734
|
-
}, o = ne) : a === "delete" && (u = {
|
|
735
|
-
id: e,
|
|
736
|
-
key: {
|
|
737
|
-
systemKey: sessionStorage.getItem("systemKey"),
|
|
738
|
-
pageKey: s,
|
|
739
|
-
type: "structure",
|
|
740
|
-
structureBelong: r,
|
|
741
|
-
parentTable: "",
|
|
742
|
-
version: 1
|
|
743
|
-
}
|
|
744
|
-
}, o = ve);
|
|
745
|
-
const y = await o(u);
|
|
746
|
-
if (((n = y == null ? void 0 : y.data) == null ? void 0 : n.code) === 200)
|
|
747
|
-
return y.data.result;
|
|
748
|
-
throw ae.error("保存响应失败"), new Error("保存响应失败");
|
|
749
|
-
} catch {
|
|
750
|
-
ae.error("保存响应失败");
|
|
751
|
-
}
|
|
752
|
-
}, oe = Z([]), Xa = async (e) => {
|
|
753
|
-
var y;
|
|
754
|
-
const a = JSON.parse(C(JSON.stringify(Ma.value)));
|
|
755
|
-
if (!da.value)
|
|
756
|
-
return oe.value.push({
|
|
757
|
-
key: Pa.value,
|
|
758
|
-
data: a
|
|
759
|
-
}), ae.success("已暂存");
|
|
760
|
-
const s = a == null ? void 0 : a.map((f) => f.id), r = s.filter((f) => {
|
|
761
|
-
var g;
|
|
762
|
-
return !((g = Ne.value) != null && g.includes(f));
|
|
763
|
-
}), c = (y = Ne.value) == null ? void 0 : y.filter((f) => !s.includes(f)), t = [...r, ...c], n = a == null ? void 0 : a.filter((f) => !f.id), u = a == null ? void 0 : a.filter((f) => f.id);
|
|
764
|
-
let o = [];
|
|
765
|
-
t && (t == null ? void 0 : t.length) > 0 && (t == null || t.forEach((f) => {
|
|
766
|
-
f && o.push(ce(f, "delete", e));
|
|
767
|
-
})), n && (n == null ? void 0 : n.length) > 0 && (n == null || n.forEach((f) => {
|
|
768
|
-
f && o.push(ce(f, "create", e));
|
|
769
|
-
})), u && (u == null ? void 0 : u.length) > 0 && (u == null || u.forEach((f) => {
|
|
770
|
-
s != null && s.includes(f.id) && (console.log("clickSavePage5", "包含"), f && o.push(ce(f, "update", e)));
|
|
771
|
-
})), Promise.all(o).then(() => {
|
|
772
|
-
ae.success("保存成功"), F.setRefreshCurStructure(!0);
|
|
773
|
-
}).catch((f) => {
|
|
774
|
-
ae.success(f);
|
|
775
|
-
});
|
|
776
|
-
};
|
|
777
|
-
se(() => {
|
|
778
|
-
var e;
|
|
779
|
-
return (e = oe.value) == null ? void 0 : e.length;
|
|
780
|
-
}, (e) => {
|
|
781
|
-
e && Fe.setCacheStructures(oe.value);
|
|
782
|
-
}, { immediate: !0 });
|
|
783
|
-
se(() => {
|
|
784
|
-
var e;
|
|
785
|
-
return (e = Ta.value) == null ? void 0 : e.length;
|
|
786
|
-
}, (e) => {
|
|
787
|
-
e === 0 && oe.value.splice(0);
|
|
788
|
-
}, { immediate: !0 });
|
|
789
|
-
const Za = (e) => sa(e), x = Z([]), Ia = async (e, a = "data") => {
|
|
790
|
-
var r, c, t, n, u, o;
|
|
791
|
-
if ((e == null ? void 0 : e.type) === "delete")
|
|
792
|
-
await Ye((r = e == null ? void 0 : e.singleContent) == null ? void 0 : r.id);
|
|
793
|
-
else if ((e == null ? void 0 : e.buttonName) === "新增") {
|
|
794
|
-
let y = {};
|
|
795
|
-
for (let f in e == null ? void 0 : e.singleContent)
|
|
796
|
-
f !== "id" && f !== "index" && (y[f] = e == null ? void 0 : e.singleContent[f]);
|
|
797
|
-
await qe(
|
|
798
|
-
a,
|
|
799
|
-
Q.value,
|
|
800
|
-
e == null ? void 0 : e.index,
|
|
801
|
-
sessionStorage.getItem("systemKey"),
|
|
802
|
-
Object.values(y),
|
|
803
|
-
e == null ? void 0 : e.column
|
|
804
|
-
);
|
|
805
|
-
} else if ((e == null ? void 0 : e.buttonName) === "编辑") {
|
|
806
|
-
let y = {}, f = (c = e == null ? void 0 : e.singleContent) == null ? void 0 : c.id;
|
|
807
|
-
for (let g in e == null ? void 0 : e.singleContent)
|
|
808
|
-
g !== "id" && g !== "index" && (y[g] = e == null ? void 0 : e.singleContent[g]);
|
|
809
|
-
await ze(
|
|
810
|
-
a,
|
|
811
|
-
Q.value,
|
|
812
|
-
e == null ? void 0 : e.index,
|
|
813
|
-
f,
|
|
814
|
-
sessionStorage.getItem("systemKey"),
|
|
815
|
-
Object.values(y),
|
|
816
|
-
e == null ? void 0 : e.column
|
|
817
|
-
);
|
|
818
|
-
}
|
|
819
|
-
let s = (n = (t = I.value) == null ? void 0 : t[I.value.length - 1]) != null && n.key ? parseInt((o = (u = I.value) == null ? void 0 : u[I.value.length - 1]) == null ? void 0 : o.key) : "";
|
|
820
|
-
x.value = await ue(Q.value, sessionStorage.getItem("systemKey"), s), F.setItemData(x.value), F.setOriginalData(x.value);
|
|
821
|
-
}, Oa = async (e) => {
|
|
822
|
-
var s, r, c, t, n;
|
|
823
|
-
const a = await le({
|
|
824
|
-
id: e
|
|
825
|
-
});
|
|
826
|
-
return (n = (t = (c = (r = (s = a == null ? void 0 : a.data) == null ? void 0 : s.result) == null ? void 0 : r[0]) == null ? void 0 : c.value) == null ? void 0 : t.pageData) == null ? void 0 : n.name;
|
|
827
|
-
}, ma = async (e) => {
|
|
828
|
-
var r, c;
|
|
829
|
-
const a = await Oa(e == null ? void 0 : e.index);
|
|
830
|
-
await He(e == null ? void 0 : e.index, {
|
|
831
|
-
comp: "Form",
|
|
832
|
-
compData: (r = C(e == null ? void 0 : e.contents)) == null ? void 0 : r.filter((t) => t.contents),
|
|
833
|
-
name: a
|
|
834
|
-
});
|
|
835
|
-
const s = (c = C(x.value)) == null ? void 0 : c.map((t) => ((t == null ? void 0 : t.id) === (e == null ? void 0 : e.index) && (t.compData = e == null ? void 0 : e.contents), t));
|
|
836
|
-
F.setItemData(s), F.setOriginalData(s);
|
|
837
|
-
}, es = (e) => {
|
|
838
|
-
x.value = e, F.setItemData(x.value), F.setOriginalData(x.value);
|
|
839
|
-
}, Ue = (e) => {
|
|
840
|
-
var a, s, r;
|
|
841
|
-
return ((s = (a = Oe.value) == null ? void 0 : a.layer) == null ? void 0 : s.toUpperCase()) === "SUPERADMIN" ? !0 : ((r = Oe.value) == null ? void 0 : r.account) === (e == null ? void 0 : e.account);
|
|
842
|
-
}, Je = async (e, a, s) => {
|
|
843
|
-
const r = Ae("/系统管理/角色管理"), c = Ae("/系统管理/部门管理");
|
|
844
|
-
return await Promise.all([r, c]).then((n) => {
|
|
845
|
-
var y, f;
|
|
846
|
-
const u = (y = n == null ? void 0 : n[0]) == null ? void 0 : y.map((g) => ({
|
|
847
|
-
label: g == null ? void 0 : g.roleName,
|
|
848
|
-
value: g == null ? void 0 : g.roleName
|
|
849
|
-
})), o = (f = n == null ? void 0 : n[1]) == null ? void 0 : f.map((g) => ({
|
|
850
|
-
label: g == null ? void 0 : g.deptName,
|
|
851
|
-
value: g == null ? void 0 : g.deptName
|
|
852
|
-
}));
|
|
853
|
-
return s ? e == null ? void 0 : e.map((g) => {
|
|
854
|
-
var P;
|
|
855
|
-
return {
|
|
856
|
-
...g,
|
|
857
|
-
compData: (P = g == null ? void 0 : g.compData) == null ? void 0 : P.map((h) => {
|
|
858
|
-
var T, J;
|
|
859
|
-
return (h == null ? void 0 : h.key) === "header" ? {
|
|
860
|
-
...h,
|
|
861
|
-
contents: (T = h == null ? void 0 : h.contents) == null ? void 0 : T.map((b) => b.prop === "userDept" ? {
|
|
862
|
-
...b,
|
|
863
|
-
options: o
|
|
864
|
-
} : b.prop === "userRoles" ? {
|
|
865
|
-
...b,
|
|
866
|
-
options: u
|
|
867
|
-
} : b)
|
|
868
|
-
} : (h == null ? void 0 : h.key) === "tableContents" ? {
|
|
869
|
-
...h,
|
|
870
|
-
contents: (J = h == null ? void 0 : h.contents) == null ? void 0 : J.map((b) => {
|
|
871
|
-
var d;
|
|
872
|
-
return {
|
|
873
|
-
...b,
|
|
874
|
-
password: Ue(b) ? be(b == null ? void 0 : b.password, (d = m == null ? void 0 : m.value) == null ? void 0 : d.privateKey) : b == null ? void 0 : b.password
|
|
875
|
-
};
|
|
876
|
-
})
|
|
877
|
-
} : h;
|
|
878
|
-
})
|
|
879
|
-
};
|
|
880
|
-
}) : e == null ? void 0 : e.map((g) => {
|
|
881
|
-
var P;
|
|
882
|
-
return {
|
|
883
|
-
...g,
|
|
884
|
-
compData: (P = g == null ? void 0 : g.compData) == null ? void 0 : P.map((h) => {
|
|
885
|
-
var T, J, b;
|
|
886
|
-
return (h == null ? void 0 : h.key) === "rowButton" || (h == null ? void 0 : h.key) === "extraButton" ? {
|
|
887
|
-
...h,
|
|
888
|
-
contents: (T = h == null ? void 0 : h.contents) == null ? void 0 : T.filter((d) => a == null ? void 0 : a.includes(d == null ? void 0 : d.label))
|
|
889
|
-
} : (h == null ? void 0 : h.key) === "header" ? {
|
|
890
|
-
...h,
|
|
891
|
-
contents: (J = h == null ? void 0 : h.contents) == null ? void 0 : J.map((d) => d.prop === "userDept" ? {
|
|
892
|
-
...d,
|
|
893
|
-
options: o
|
|
894
|
-
} : d.prop === "userRoles" ? {
|
|
895
|
-
...d,
|
|
896
|
-
options: u
|
|
897
|
-
} : d)
|
|
898
|
-
} : (h == null ? void 0 : h.key) === "tableContents" ? {
|
|
899
|
-
...h,
|
|
900
|
-
contents: (b = h == null ? void 0 : h.contents) == null ? void 0 : b.map((d) => {
|
|
901
|
-
var w;
|
|
902
|
-
return {
|
|
903
|
-
...d,
|
|
904
|
-
password: Ue(d) ? be(d == null ? void 0 : d.password, (w = m == null ? void 0 : m.value) == null ? void 0 : w.privateKey) : d == null ? void 0 : d.password
|
|
905
|
-
};
|
|
906
|
-
})
|
|
907
|
-
} : h;
|
|
908
|
-
})
|
|
909
|
-
};
|
|
910
|
-
});
|
|
911
|
-
});
|
|
912
|
-
};
|
|
913
|
-
se(
|
|
914
|
-
() => [Q.value, Ka.value],
|
|
915
|
-
async (e) => {
|
|
916
|
-
var r;
|
|
917
|
-
const a = e == null ? void 0 : e[0], s = e == null ? void 0 : e[1];
|
|
918
|
-
if (x.value = [], a || s) {
|
|
919
|
-
we(), sessionStorage.setItem("pageKey", Q.value);
|
|
920
|
-
const c = await ue(a, sessionStorage.getItem("systemKey"), "", Q.value);
|
|
921
|
-
F.setExtraContents([]);
|
|
922
|
-
const t = sessionStorage.getItem("authority"), n = JSON.parse(t || "");
|
|
923
|
-
if (Array.isArray(n)) {
|
|
924
|
-
const u = Array.isArray(n) && (n == null ? void 0 : n.filter((y) => y == null ? void 0 : y.includes(a))), o = u == null ? void 0 : u.map((y) => {
|
|
925
|
-
var f;
|
|
926
|
-
return ((f = y == null ? void 0 : y.split("/")) == null ? void 0 : f.pop()) || "";
|
|
927
|
-
});
|
|
928
|
-
x.value = a === "/系统管理/用户管理" ? await Je(c, o, !1) : c == null ? void 0 : c.map((y) => {
|
|
929
|
-
var f;
|
|
930
|
-
return {
|
|
931
|
-
...y,
|
|
932
|
-
compData: (f = y == null ? void 0 : y.compData) == null ? void 0 : f.map((g) => {
|
|
933
|
-
var P;
|
|
934
|
-
return (g == null ? void 0 : g.key) === "rowButton" || (g == null ? void 0 : g.key) === "extraButton" ? {
|
|
935
|
-
...g,
|
|
936
|
-
contents: (P = g == null ? void 0 : g.contents) == null ? void 0 : P.filter((h) => o == null ? void 0 : o.includes(h == null ? void 0 : h.label))
|
|
937
|
-
} : g;
|
|
938
|
-
})
|
|
939
|
-
};
|
|
940
|
-
});
|
|
941
|
-
} else typeof n == "string" && (n == null ? void 0 : n.toUpperCase()) === "SUPERADMIN" ? x.value = a === "/系统管理/用户管理" ? await Je(c, null, !0) : c : x.value = [];
|
|
942
|
-
W.setSelectTitle([]), W.setSelectIndex(""), W.setSelectMenu(""), F.setItemData(x.value), F.setOriginalData(x.value), F.setCurStructureCompIds((r = x.value) == null ? void 0 : r.map((u) => u == null ? void 0 : u.id)), F.setRefreshCurStructure(!1), I.value = Q.value.split("/").filter((u) => u !== "").map((u) => ({ value: u.trim() }));
|
|
943
|
-
}
|
|
944
|
-
},
|
|
945
|
-
{
|
|
946
|
-
immediate: !0
|
|
947
|
-
}
|
|
948
|
-
);
|
|
949
|
-
const as = $e({
|
|
950
|
-
name: "menu",
|
|
951
|
-
components: {
|
|
952
|
-
ssMenu: la,
|
|
953
|
-
DynamicIcon: ra
|
|
954
|
-
},
|
|
955
|
-
setup() {
|
|
956
|
-
const e = xe({
|
|
957
|
-
mode: {
|
|
958
|
-
type: String,
|
|
959
|
-
default: "vertical"
|
|
960
|
-
}
|
|
961
|
-
}), a = Z("sub-menu-more"), s = he(), r = Z(0), c = oa(), { rawMenus: t, menuTriggerType: n, permissionSideMenus: u, platform: o } = ee(s), y = je(), { structureData: f } = ee(y), g = Z([]), P = pe(() => e == null ? void 0 : e.mode), h = (l) => {
|
|
962
|
-
let i = [], A = [];
|
|
963
|
-
return l == null || l.forEach((M) => {
|
|
964
|
-
i = T(M, A);
|
|
965
|
-
}), i;
|
|
966
|
-
}, T = (l, i) => {
|
|
967
|
-
const A = i, M = [];
|
|
968
|
-
l == null || l.forEach((O) => {
|
|
969
|
-
Array.isArray(O) ? M.push({ children: T(O, []) }) : M.push({ title: O });
|
|
970
|
-
});
|
|
971
|
-
let D = M.reduce((O, L) => (Object.entries(L).forEach(([N, U]) => {
|
|
972
|
-
O[N] === void 0 ? U != null && U.title ? O[N] = [U] : O[N] = U : (Array.isArray(O[N]) || (O[N] = [{ title: O[N] }]), U != null && U.title || Array.isArray(U) ? O[N].push(U) : O[N].push({ title: U }));
|
|
973
|
-
}), O), {});
|
|
974
|
-
return D = J(C(D)), A.push(D), Array.isArray(A) && (A == null ? void 0 : A.length) > 1 ? A : A == null ? void 0 : A[0];
|
|
975
|
-
}, J = (l) => {
|
|
976
|
-
var i, A, M;
|
|
977
|
-
return Array.isArray(l == null ? void 0 : l.title) && ((i = l == null ? void 0 : l.title) == null ? void 0 : i.length) === ((M = (A = l == null ? void 0 : l.title) == null ? void 0 : A.filter((D) => D.title)) == null ? void 0 : M.length) ? l == null ? void 0 : l.title : Array.isArray(l == null ? void 0 : l.children) ? b(l) : l;
|
|
978
|
-
}, b = (l) => {
|
|
979
|
-
var A;
|
|
980
|
-
const i = l;
|
|
981
|
-
return i.children = (A = i.children) == null ? void 0 : A.map((M) => {
|
|
982
|
-
var D;
|
|
983
|
-
return (D = M == null ? void 0 : M.title) != null && D.children ? M == null ? void 0 : M.title : M;
|
|
984
|
-
}), i;
|
|
985
|
-
}, d = (l) => l == null ? void 0 : l.map((i) => i.children && i.children.length > 0 ? {
|
|
986
|
-
...i,
|
|
987
|
-
children: i.level === 0 ? [] : i.children,
|
|
988
|
-
childMenus: d(i.children)
|
|
989
|
-
} : i), w = Z(["gongjianku", "shebeiku", "fangfaku", "guocheng", "Fold", "Fold"]), j = (l, i) => l === 0 ? w.value[i] ?? "Fold" : l === 1 ? "wenjianjia" : "wenjian", V = (l, i = "", A = 0) => {
|
|
990
|
-
var L;
|
|
991
|
-
let M, D = C(l);
|
|
992
|
-
const O = (L = f.value) == null ? void 0 : L.map((N) => {
|
|
993
|
-
var U;
|
|
994
|
-
return (U = N == null ? void 0 : N.key) == null ? void 0 : U.pageKey;
|
|
995
|
-
});
|
|
996
|
-
return Array.isArray(D) || (D = [D]), M = D == null ? void 0 : D.map((N, U) => {
|
|
997
|
-
const _ = i ? `${i}/${N.title}` : N.title, H = {
|
|
998
|
-
...N,
|
|
999
|
-
path: _,
|
|
1000
|
-
level: A,
|
|
1001
|
-
show: !0,
|
|
1002
|
-
// icon: Icon[`${level}`],
|
|
1003
|
-
icon: j(A, U),
|
|
1004
|
-
carryData: O == null ? void 0 : O.includes(_),
|
|
1005
|
-
// carryData: true,
|
|
1006
|
-
isPenultimate: !N.children
|
|
1007
|
-
//便于角色授权菜单那里给叶子节点添加按钮节点
|
|
1008
|
-
};
|
|
1009
|
-
return N.children && N.children.length > 0 && (H.children = V(N.children, _, A + 1)), H;
|
|
1010
|
-
}), M;
|
|
1011
|
-
}, B = pe(() => {
|
|
1012
|
-
let l = V(g.value);
|
|
1013
|
-
if (l = [...l, ...u.value], (l == null ? void 0 : l.length) === 0)
|
|
1014
|
-
return c.push("/"), [];
|
|
1015
|
-
const i = K(l, S.value);
|
|
1016
|
-
i.isFlag || (l = i == null ? void 0 : i.data);
|
|
1017
|
-
const A = d(l);
|
|
1018
|
-
return o.value === "client" ? (s.setMenus(A), A) : l;
|
|
1019
|
-
}), k = async (l) => {
|
|
1020
|
-
s.setMenuTriggerType("click"), o.value === "client" && (l != null && l.childMenus) && s.setAsideMenus(l == null ? void 0 : l.childMenus), l.isRouter ? c.push(l.path) : c.push("/");
|
|
1021
|
-
}, R = (l) => {
|
|
1022
|
-
n.value === "click" ? r.value === 1 ? s.setActiveMenuPath(sessionStorage.getItem("pageKey")) : l !== a.value && s.setActiveMenuPath(l) : s.setMenuTriggerType("click"), l != null && l.startsWith("/") ? c.push(l) : c.push("/"), r.value++;
|
|
1023
|
-
}, E = (l) => {
|
|
1024
|
-
l !== a.value && s.setActiveMenuPath(l);
|
|
1025
|
-
}, v = (l) => {
|
|
1026
|
-
const i = document.documentElement;
|
|
1027
|
-
l == null || l.forEach((A) => {
|
|
1028
|
-
i.style.setProperty(A.name, A.value);
|
|
1029
|
-
});
|
|
1030
|
-
};
|
|
1031
|
-
Ve(() => {
|
|
1032
|
-
r.value = 1;
|
|
1033
|
-
});
|
|
1034
|
-
const S = pe(() => {
|
|
1035
|
-
const l = sessionStorage.getItem("authority");
|
|
1036
|
-
return l ? JSON.parse(l) : [];
|
|
1037
|
-
});
|
|
1038
|
-
se(() => o.value, (l) => {
|
|
1039
|
-
l === "browser" ? v(ta) : l === "client" && (v(na), v(ua));
|
|
1040
|
-
}, { immediate: !0 }), se(() => t.value, (l) => {
|
|
1041
|
-
if (l) {
|
|
1042
|
-
const i = l;
|
|
1043
|
-
g.value = h(i);
|
|
1044
|
-
} else
|
|
1045
|
-
s.setActiveMenuPath("");
|
|
1046
|
-
}, {
|
|
1047
|
-
immediate: !0
|
|
1048
|
-
});
|
|
1049
|
-
const p = (l, i) => {
|
|
1050
|
-
function A(M) {
|
|
1051
|
-
M == null || M.forEach((D) => {
|
|
1052
|
-
D.show = i == null ? void 0 : i.some((O) => O == null ? void 0 : O.includes(D.path)), D.children && A(D.children);
|
|
1053
|
-
});
|
|
1054
|
-
}
|
|
1055
|
-
return A(l), l;
|
|
1056
|
-
}, K = (l, i) => {
|
|
1057
|
-
if (Array.isArray(i)) {
|
|
1058
|
-
const A = Array.from(new Set(i == null ? void 0 : i.map((M) => M.substring(0, M.lastIndexOf("/")))));
|
|
1059
|
-
return {
|
|
1060
|
-
data: p(l, A),
|
|
1061
|
-
isFlag: !1
|
|
1062
|
-
};
|
|
1063
|
-
} else
|
|
1064
|
-
return {
|
|
1065
|
-
isFlag: (i == null ? void 0 : i.toUpperCase()) === "SUPERADMIN"
|
|
1066
|
-
};
|
|
1067
|
-
};
|
|
1068
|
-
return {
|
|
1069
|
-
mode: P,
|
|
1070
|
-
renderMenuList: B,
|
|
1071
|
-
clickMenu: k,
|
|
1072
|
-
openMenu: R,
|
|
1073
|
-
closeMenu: E,
|
|
1074
|
-
changeMenuStyle: v
|
|
1075
|
-
};
|
|
1076
|
-
}
|
|
1077
|
-
});
|
|
1078
|
-
export {
|
|
1079
|
-
as as _,
|
|
1080
|
-
Qa as a,
|
|
1081
|
-
za as b,
|
|
1082
|
-
Xa as c,
|
|
1083
|
-
es as d,
|
|
1084
|
-
ma as e,
|
|
1085
|
-
Ia as f,
|
|
1086
|
-
Za as g,
|
|
1087
|
-
qa as h,
|
|
1088
|
-
Ya as i,
|
|
1089
|
-
Wa as o,
|
|
1090
|
-
x as s
|
|
1091
|
-
};
|