ss-component-new 1.2.3 → 1.2.4
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-C0QRmW6_.js → OrbitControls-DA4VpOM_.js} +1 -1
- package/dist/{STLLoader-CiUjaQtA.js → STLLoader-DmGTF0Nv.js} +1 -1
- package/dist/{animationData-8FTxP8vs.js → animationData-9n1X4UvO.js} +14 -14
- package/dist/animationData-CfT99nMO.cjs +1 -0
- package/dist/array-BPHS7JFA.cjs +11 -0
- package/dist/array-pg68Qbs1.js +1207 -0
- package/dist/config.js +1 -1
- package/dist/{iconfont-pt17sMx3.js → iconfont-ljBfzBSE.js} +2 -2
- package/dist/{index-DnDcbPOW.js → index---6UATT0.js} +5 -5
- package/dist/{index-D4F0CrLQ.cjs → index-1DtctdYW.cjs} +1 -1
- package/dist/index-5hLZZ6t-.cjs +1 -0
- package/dist/{index-CEdmOpLw.js → index-8CcD03tl.js} +6 -6
- package/dist/{index-BkoHg0EZ.js → index-B5gNufYw.js} +5 -5
- package/dist/{index-CwFSFQX2.js → index-B5srJr0o.js} +6 -6
- package/dist/{index-Kn3M4A0O.cjs → index-B5vIeQUq.cjs} +1 -1
- package/dist/{index-CSeo-uxt.cjs → index-B8J_v2Ky.cjs} +1 -1
- package/dist/{index-CgqgVzlH.cjs → index-B9nZeing.cjs} +1 -1
- package/dist/{index-CH7Xo-Sp.js → index-BAj0dyBF.js} +3 -3
- package/dist/{index-BileCy93.js → index-BEJOd_29.js} +4 -4
- package/dist/{index-kGrlXtNc.cjs → index-BKhDFqMM.cjs} +1 -1
- package/dist/{index-CfduEaC5.js → index-BNNxPuEV.js} +1 -1
- package/dist/{index-CoR64Xpr.cjs → index-BOVdAFDH.cjs} +1 -1
- package/dist/{index-BS8EpPTs.cjs → index-Bi7yv8jC.cjs} +1 -1
- package/dist/{index-Be9Zt5tl.js → index-BjXcyVvp.js} +2 -2
- package/dist/{index-CxnH4vfV.cjs → index-BrsIZVyD.cjs} +1 -1
- package/dist/index-Bsdjuxq1.cjs +1 -0
- package/dist/{index-CvrTrN91.js → index-BuKHInQb.js} +1 -1
- package/dist/{index-DeuO5bnv.cjs → index-Bx4qIiIa.cjs} +1 -1
- package/dist/{index-CpaF7pM_.cjs → index-C-AOuDkl.cjs} +1 -1
- package/dist/{index-DJ40Hyyr.cjs → index-C0HHmjrg.cjs} +1 -1
- package/dist/{index-sB_mbukA.js → index-C1lB8apW.js} +4 -4
- package/dist/{index-C_AbUtWk.cjs → index-CAHYTZ1Q.cjs} +1 -1
- package/dist/{index-Ct9LJbIa.cjs → index-CCIJ-P3X.cjs} +1 -1
- package/dist/{index-hOfuCmcV.js → index-CCsSOTaB.js} +2 -2
- package/dist/{index-CjqqJUqa.js → index-CDXq3gs4.js} +1013 -1010
- package/dist/{index-BAkiJ74E.cjs → index-CK_O7QdV.cjs} +1 -1
- package/dist/{index-D6k9CkOL.js → index-CLtFz5gE.js} +13 -13
- package/dist/{index-DyLtJwnU.cjs → index-CMlYJD5U.cjs} +1 -1
- package/dist/index-CdPbJekh.js +7294 -0
- package/dist/{index-CjI5pDiU.cjs → index-CmlXlH2b.cjs} +1 -1
- package/dist/{index-BcyUCzHm.js → index-CpE8hbs0.js} +6 -6
- package/dist/{index-7XENlCpz.cjs → index-CxNBcsll.cjs} +1 -1
- package/dist/{index-ClODZ600.js → index-CyP2hcVu.js} +6 -6
- package/dist/{index-flJIivzF.cjs → index-D-r_YKrq.cjs} +13 -13
- package/dist/{index-CElxXJY-.js → index-D0_4keB8.js} +7 -7
- package/dist/index-DBScQH7L.js +2643 -0
- package/dist/{index-BNO8srTI.cjs → index-DCf7Tz40.cjs} +1 -1
- package/dist/{index-Da8foj5C.js → index-DEwcUkb-.js} +5 -5
- package/dist/{index-Bfs3oOac.js → index-DFg-bhPI.js} +1 -1
- package/dist/{index-BqB108UB.cjs → index-DJ1PTHpx.cjs} +1 -1
- package/dist/{index-BGr_ESuH.cjs → index-DOlPMLvf.cjs} +1 -1
- package/dist/{index-BnGZhWPa.cjs → index-DPaTtF3h.cjs} +1 -1
- package/dist/{index-Bzf_z3RK.cjs → index-DPyzaxnq.cjs} +1 -1
- package/dist/{index-DkcEb3i0.js → index-DS5z17Mc.js} +2123 -2130
- package/dist/{index-D7Z7_kkD.js → index-DSsZtYMz.js} +2 -2
- package/dist/{index-hm9E8BQd.js → index-Dk8D9SRm.js} +1 -1
- package/dist/{index-CDcMFEYg.js → index-DsHRVZ0E.js} +2 -2
- package/dist/{index-ZP8xxEio.cjs → index-DszzdQnM.cjs} +1 -1
- package/dist/{index-CKHNyMzP.js → index-FxX6NP0J.js} +1 -1
- package/dist/{index-BhmbDqk0.cjs → index-LXb5DfDE.cjs} +1 -1
- package/dist/{index-BFjyLFP1.cjs → index-NFCeQcv4.cjs} +1 -1
- package/dist/{index-BCqSX1fo.js → index-PIEkAjRf.js} +12 -12
- package/dist/{index-DbzvXPKu.js → index-UN4JU0ly.js} +176 -176
- package/dist/{index-Bry_sSrG.js → index-Y7MUJdPv.js} +4 -4
- package/dist/{index-CISjtweI.js → index-bj8hK6Pe.js} +24 -24
- package/dist/{index-1z9RrjZc.cjs → index-d6tSWKtY.cjs} +1 -1
- package/dist/{index-CiktIOnl.cjs → index-nUEWiqy9.cjs} +1 -1
- package/dist/{index-Bmv3M7uZ.js → index-pLeOyTaj.js} +6 -6
- package/dist/{index-D0FR_AhB.js → index-xHEf6hcO.js} +2 -2
- package/dist/index-zQVJFawn.cjs +1 -0
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BnK7zR_5.js → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BTu7I4mn.js} +10362 -10383
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-C5Xqazal.cjs → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-Cmc1oALS.cjs} +123 -123
- package/dist/{index.vue_vue_type_style_index_0_scoped_92477073_lang-Bu0MMp-F.js → index.vue_vue_type_style_index_0_scoped_92477073_lang-Bg_c-oAL.js} +6 -6
- package/dist/{index.vue_vue_type_style_index_0_scoped_92477073_lang-D-u_Cg-8.cjs → index.vue_vue_type_style_index_0_scoped_92477073_lang-C795GAHK.cjs} +1 -1
- package/dist/index.vue_vue_type_style_index_0_scoped_bcdf4fb0_lang-9kDr7Iek.js +37436 -0
- package/dist/index.vue_vue_type_style_index_0_scoped_bcdf4fb0_lang-Bn5qXF4J.cjs +56 -0
- package/dist/{index.vue_vue_type_style_index_1_lang-Ca71BDvm.cjs → index.vue_vue_type_style_index_1_lang-Bn7P4fYM.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_1_lang-DMTvCBLP.js → index.vue_vue_type_style_index_1_lang-D1n_3_F6.js} +5 -5
- package/dist/index.vue_vue_type_style_index_1_lang-Exyt6qTf.js +7798 -0
- package/dist/index.vue_vue_type_style_index_1_lang-zN5mc8b0.cjs +32 -0
- package/dist/{isString-CZMLuMzD.js → isString-BAN9KLwf.js} +1 -1
- package/dist/{isString-BmAegMGI.cjs → isString-ChvWbctO.cjs} +1 -1
- package/dist/{main-gNJqytEB.cjs → main-BUEuCNq-.cjs} +1 -1
- package/dist/{main-Dji-qcpb.js → main-Dk3BZDsa.js} +5 -5
- 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/{three-viewport-gizmo-CkQ98n-T.js → three-viewport-gizmo-BHznJ6W3.js} +2 -2
- package/dist/{threeLatheView-BmVBnC8n.js → threeLatheView-DcuDjVv0.js} +4 -4
- package/dist/{threeLatheView-CZdorls1.cjs → threeLatheView-DfSxRY8B.cjs} +1 -1
- package/dist/{threeModel-AI7JwNc8.cjs → threeModel-DjjtL0-a.cjs} +1 -1
- package/dist/{threeModel-ejibS2N7.js → threeModel-YRFvkgXU.js} +5 -5
- package/dist/{threePreview-C_mY_TBC.cjs → threePreview-ByUYJkts.cjs} +1 -1
- package/dist/{threePreview-CYX5wKoL.js → threePreview-CyYfnbB6.js} +4 -4
- package/dist/threeSceneView-mhrcH0WG.cjs +5 -0
- package/dist/threeSceneView-zvyCHrp1.js +1469 -0
- package/dist/{threeSceneViewForCPMPIP-OOuWUtK1.cjs → threeSceneViewForCPMPIP-DA-twBdG.cjs} +3 -3
- package/dist/{threeSceneViewForCPMPIP-CDxxtlbo.js → threeSceneViewForCPMPIP-axjwKt9X.js} +85 -86
- package/dist/threeViewerHost-B02OtfCk.cjs +1 -0
- package/dist/{threeViewerHost-DTgKwwlG.js → threeViewerHost-D7L1FW__.js} +65 -78
- package/dist/{useRayCaster-5KTcOfSB.js → useRayCaster-CAqupK7D.js} +5 -5
- package/dist/useRayCaster-ClcofJkf.cjs +1 -0
- package/package.json +1 -1
- package/public/config.js +1 -1
- package/dist/animationData-C3K2hxaU.cjs +0 -1
- package/dist/array-B-rkzr_a.js +0 -1142
- package/dist/array-DRbhAcfX.cjs +0 -11
- package/dist/index-0Pm0ddJB.cjs +0 -1
- package/dist/index-8qtn1JAM.cjs +0 -1
- package/dist/index-BTh-u_yw.js +0 -3370
- package/dist/index-CYNps_oO.js +0 -7210
- package/dist/index-DlDK9CYq.cjs +0 -1
- package/dist/index-HrI-8Xdy.cjs +0 -1
- package/dist/index-hol6Hhnu.js +0 -2567
- package/dist/index.vue_vue_type_style_index_0_scoped_bcdf4fb0_lang-BDNNr7wB.cjs +0 -56
- package/dist/index.vue_vue_type_style_index_0_scoped_bcdf4fb0_lang-BqbQkXoK.js +0 -34117
- package/dist/index.vue_vue_type_style_index_1_lang-BayGiM6k.cjs +0 -32
- package/dist/index.vue_vue_type_style_index_1_lang-bErlZPyW.js +0 -8085
- package/dist/isUndefined-ClRzgwTy.cjs +0 -1
- package/dist/isUndefined-chfCDxUU.js +0 -84
- package/dist/obj/model.mtl +0 -42
- package/dist/obj/model.obj +0 -26110
- package/dist/threeSceneView-BO8STZl6.js +0 -1472
- package/dist/threeSceneView-CXqoIpeL.cjs +0 -5
- package/dist/threeViewerHost-ChVCHaag.cjs +0 -1
- package/dist/useRayCaster-C428LZl9.cjs +0 -1
- package/public/obj/model.mtl +0 -42
- package/public/obj/model.obj +0 -26110
|
@@ -0,0 +1,2643 @@
|
|
|
1
|
+
import { ref as R, watch as Fe, nextTick as Il, resolveComponent as Ke, createBlock as $e, openBlock as ne, withCtx as re, createElementVNode as ve, renderSlot as $a, onMounted as ha, createElementBlock as Te, normalizeStyle as kl, normalizeClass as Ra, toDisplayString as Ce, createCommentVNode as Le, createVNode as ie, unref as Ye, Fragment as cl, renderList as dl, createTextVNode as el, defineComponent as qa, reactive as Ql, inject as qr, provide as Hr, onBeforeUnmount as Xr, computed as Ba, onUnmounted as Qr, createSlots as Yr } from "vue";
|
|
2
|
+
import { bh as Zr, as as Vr, c as J, E as xe, b$ as ya, p as tl, s as bl, u as Ir, bt as Yl, d as pa, b as Sl, g as $l, bu as en, f as ln, c3 as an } from "./index-UN4JU0ly.js";
|
|
3
|
+
import { d as Ma, S as rn } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BTu7I4mn.js";
|
|
4
|
+
import { c as la, _ as nn, h as sn, e as un, E as on } from "./index-DS5z17Mc.js";
|
|
5
|
+
import { a as tn, T as cn, d as fa } from "./threeViewerHost-D7L1FW__.js";
|
|
6
|
+
import { aH as ea, aC as dn, k as pn, j as fn, u as gn, aG as hn, a as yn, i as we, aV as Na, aW as wa, aX as vn, aY as bn, l as Zl, E as Fa, aE as za, aZ as Sn } from "./index.vue_vue_type_style_index_1_lang-Exyt6qTf.js";
|
|
7
|
+
import { r as kn, a as Bl, w as mn } from "./index.vue_vue_type_style_index_1_lang-D1n_3_F6.js";
|
|
8
|
+
import { _ as aa } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
9
|
+
import "./three-viewport-gizmo-BHznJ6W3.js";
|
|
10
|
+
import { s as Vl } from "./index-Dk8D9SRm.js";
|
|
11
|
+
import "./index-B5gNufYw.js";
|
|
12
|
+
import { i as Ja } from "./isString-BAN9KLwf.js";
|
|
13
|
+
const Wa = (K) => K.match(/\((.*)\)/)[1], Tn = {
|
|
14
|
+
__name: "index",
|
|
15
|
+
props: {
|
|
16
|
+
isVisible: {
|
|
17
|
+
type: Boolean,
|
|
18
|
+
default: !1
|
|
19
|
+
},
|
|
20
|
+
title: {
|
|
21
|
+
type: String,
|
|
22
|
+
default: ""
|
|
23
|
+
},
|
|
24
|
+
placement: {
|
|
25
|
+
type: String,
|
|
26
|
+
default: "bottom"
|
|
27
|
+
},
|
|
28
|
+
width: {
|
|
29
|
+
type: Number,
|
|
30
|
+
default: 200
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
setup(K) {
|
|
34
|
+
const V = K, Q = R(null), j = R(!1), L = R(null);
|
|
35
|
+
return Fe(
|
|
36
|
+
() => V == null ? void 0 : V.isVisible,
|
|
37
|
+
() => {
|
|
38
|
+
j.value = V == null ? void 0 : V.isVisible;
|
|
39
|
+
},
|
|
40
|
+
{ deep: !0, immediate: !0 }
|
|
41
|
+
), Fe(
|
|
42
|
+
() => L.value,
|
|
43
|
+
() => {
|
|
44
|
+
Il(() => {
|
|
45
|
+
var t, le;
|
|
46
|
+
(le = (t = Q.value) == null ? void 0 : t.updatePopper) == null || le.call(t);
|
|
47
|
+
});
|
|
48
|
+
},
|
|
49
|
+
{ deep: !0, immediate: !0 }
|
|
50
|
+
), (t, le) => {
|
|
51
|
+
const he = Ke("el-popover");
|
|
52
|
+
return ne(), $e(he, {
|
|
53
|
+
visible: j.value,
|
|
54
|
+
title: V == null ? void 0 : V.title,
|
|
55
|
+
placement: V == null ? void 0 : V.placement,
|
|
56
|
+
width: V == null ? void 0 : V.width,
|
|
57
|
+
ref_key: "popOverRef",
|
|
58
|
+
ref: Q
|
|
59
|
+
}, {
|
|
60
|
+
reference: re(() => [
|
|
61
|
+
ve("div", null, [
|
|
62
|
+
$a(t.$slots, "reference", {
|
|
63
|
+
ref_key: "referenceRef",
|
|
64
|
+
ref: L
|
|
65
|
+
})
|
|
66
|
+
])
|
|
67
|
+
]),
|
|
68
|
+
default: re(() => [
|
|
69
|
+
ve("div", null, [
|
|
70
|
+
$a(t.$slots, "content")
|
|
71
|
+
])
|
|
72
|
+
]),
|
|
73
|
+
_: 3
|
|
74
|
+
}, 8, ["visible", "title", "placement", "width"]);
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
}, An = { class: "extra-button-content" }, Un = { class: "table-operator-wrap" }, _n = { class: "extra-button-filter" }, On = { class: "form-content-value" }, Cn = {
|
|
78
|
+
key: 0,
|
|
79
|
+
class: "extra-header"
|
|
80
|
+
}, En = {
|
|
81
|
+
class: "drop-menu",
|
|
82
|
+
style: { width: "120px" }
|
|
83
|
+
}, Dn = { key: 0 }, xn = { key: 1 }, Ln = {
|
|
84
|
+
__name: "header",
|
|
85
|
+
props: {
|
|
86
|
+
lockingPage: Boolean,
|
|
87
|
+
level: {
|
|
88
|
+
type: Number,
|
|
89
|
+
default: 1
|
|
90
|
+
},
|
|
91
|
+
compName: {
|
|
92
|
+
type: String,
|
|
93
|
+
default: "表格名称",
|
|
94
|
+
required: !1
|
|
95
|
+
},
|
|
96
|
+
isDevMode: Boolean,
|
|
97
|
+
selectNums: Number,
|
|
98
|
+
dataNums: Number,
|
|
99
|
+
filterValues: Array,
|
|
100
|
+
buttons: {
|
|
101
|
+
type: Array,
|
|
102
|
+
default: () => []
|
|
103
|
+
},
|
|
104
|
+
columns: {
|
|
105
|
+
type: Array,
|
|
106
|
+
default: () => []
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
emits: ["buttonClick", "filter", "getImportData"],
|
|
110
|
+
setup(K, { emit: V }) {
|
|
111
|
+
const Q = V, j = K, L = R(""), t = R(!1), le = R([]), he = R([{ label: "取消", background: "#999999" }, {
|
|
112
|
+
label: "清空",
|
|
113
|
+
background: "#999999"
|
|
114
|
+
}, { label: "确认" }]), je = (M) => {
|
|
115
|
+
const B = M.raw;
|
|
116
|
+
if (!B) return;
|
|
117
|
+
const ke = new FileReader();
|
|
118
|
+
ke.onload = (ae) => {
|
|
119
|
+
try {
|
|
120
|
+
const me = new Uint8Array(ae.target.result), Pe = kn(me, { type: "array" }), pl = Pe.SheetNames[0], ze = Pe.Sheets[pl], z = Bl.decode_range(ze["!ref"]).e.c + 1, ye = new Array(z).fill(""), ge = [];
|
|
121
|
+
for (const _e in ze) {
|
|
122
|
+
if (_e[0] === "!") continue;
|
|
123
|
+
const { r: Xe, c: fl } = Bl.decode_cell(_e);
|
|
124
|
+
let de = ze[_e].v;
|
|
125
|
+
if (ze[_e].t === "n" && de > 0 && de < 1e6 && (de = new Date((de - 25569) * 86400 * 1e3).toISOString().split("T")[0]), (de == null || de === "") && (de = ""), Xe === 0)
|
|
126
|
+
ye[fl] = de;
|
|
127
|
+
else {
|
|
128
|
+
if (!ge[Xe - 1]) {
|
|
129
|
+
ge[Xe - 1] = {};
|
|
130
|
+
for (let te = 0; te < z; te++)
|
|
131
|
+
ge[Xe - 1][`col_${te}`] = "";
|
|
132
|
+
}
|
|
133
|
+
ge[Xe - 1][`col_${fl}`] = de;
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
for (let _e = 0; _e < z; _e++)
|
|
137
|
+
ye[_e] === void 0 && (ye[_e] = "");
|
|
138
|
+
const se = ge == null ? void 0 : ge[0];
|
|
139
|
+
if (!(se != null && se.hasOwnProperty("col_0"))) return xe.error("导入的数据列不匹配,请检查是否错位");
|
|
140
|
+
Q("getImportData", ye, ge);
|
|
141
|
+
} catch (me) {
|
|
142
|
+
throw xe.error(me.message), new Error(me.message);
|
|
143
|
+
}
|
|
144
|
+
}, ke.readAsArrayBuffer(B);
|
|
145
|
+
}, q = (M) => {
|
|
146
|
+
var ke;
|
|
147
|
+
const B = (ke = le.value) == null ? void 0 : ke.reduce((ae, me, Pe) => (Pe === 0 ? ae[me.label] = M : ae[me.label] = me == null ? void 0 : me.value, ae), {});
|
|
148
|
+
Q("filter", B, M, !0);
|
|
149
|
+
}, Be = (M) => {
|
|
150
|
+
Q("buttonClick", M);
|
|
151
|
+
}, ll = (M) => {
|
|
152
|
+
var B, ke;
|
|
153
|
+
le.value = (ke = (B = ea(J(M))) == null ? void 0 : B.filter((ae) => (ae == null ? void 0 : ae.label) !== "" && (ae == null ? void 0 : ae.label) !== "操作")) == null ? void 0 : ke.map((ae) => ({
|
|
154
|
+
label: (ae == null ? void 0 : ae.label) ?? "",
|
|
155
|
+
value: "",
|
|
156
|
+
name: (ae == null ? void 0 : ae.label) ?? "",
|
|
157
|
+
isFormColHidden: ae == null ? void 0 : ae.isTableColHidden,
|
|
158
|
+
width: 2
|
|
159
|
+
}));
|
|
160
|
+
}, Ue = R(!1), al = (M) => {
|
|
161
|
+
var B;
|
|
162
|
+
if ((M == null ? void 0 : M.buttonName) === "确认" && (Q("filter", M == null ? void 0 : M.content), Ue.value = (M == null ? void 0 : M.content) && Object.values(M == null ? void 0 : M.content).length > 0), (M == null ? void 0 : M.buttonName) === "清空") {
|
|
163
|
+
const ke = J(M == null ? void 0 : M.content);
|
|
164
|
+
for (const ae in ke)
|
|
165
|
+
ke[ae] = "";
|
|
166
|
+
le.value = (B = le.value) == null ? void 0 : B.map((ae) => ({
|
|
167
|
+
...ae,
|
|
168
|
+
value: ""
|
|
169
|
+
})), Q("filter", ke), Ue.value = !1;
|
|
170
|
+
}
|
|
171
|
+
t.value = !1;
|
|
172
|
+
}, Ae = () => {
|
|
173
|
+
var B, ke;
|
|
174
|
+
le.value = (B = le.value) == null ? void 0 : B.map((ae) => ({
|
|
175
|
+
...ae,
|
|
176
|
+
value: ""
|
|
177
|
+
}));
|
|
178
|
+
const M = (ke = le.value) == null ? void 0 : ke.reduce((ae, me) => (ae[me.label] = me.value, ae), {});
|
|
179
|
+
Q("filter", M);
|
|
180
|
+
};
|
|
181
|
+
return ha(() => {
|
|
182
|
+
ll(j.columns);
|
|
183
|
+
}), Fe(
|
|
184
|
+
() => j.columns,
|
|
185
|
+
() => {
|
|
186
|
+
ll(j.columns);
|
|
187
|
+
},
|
|
188
|
+
{ deep: !0, immediate: !0 }
|
|
189
|
+
), (M, B) => {
|
|
190
|
+
var ze, Je;
|
|
191
|
+
const ke = Ke("el-icon"), ae = Ke("svg-icon"), me = Ke("el-input"), Pe = Ke("el-button"), pl = Ke("el-upload");
|
|
192
|
+
return ne(), Te("div", An, [
|
|
193
|
+
ve("div", {
|
|
194
|
+
class: Ra(K.compName ? "table-name-wrap" : ""),
|
|
195
|
+
style: kl({
|
|
196
|
+
background: (j == null ? void 0 : j.level) > 1 ? "transparent" : "var(--ssgroup-background)",
|
|
197
|
+
paddingLeft: (j == null ? void 0 : j.level) > 1 ? "0px" : "8px",
|
|
198
|
+
fontWeight: 600 - ((j == null ? void 0 : j.level) - 1) * 100 >= 400 ? 600 - ((j == null ? void 0 : j.level) - 1) * 100 : 400,
|
|
199
|
+
fontSize: 17 - (j == null ? void 0 : j.level) >= 14 ? 17 - (j == null ? void 0 : j.level) + "px" : "14px"
|
|
200
|
+
})
|
|
201
|
+
}, Ce(K.compName), 7),
|
|
202
|
+
ve("div", Un, [
|
|
203
|
+
ve("div", _n, [
|
|
204
|
+
ie(Tn, {
|
|
205
|
+
title: "",
|
|
206
|
+
width: 800,
|
|
207
|
+
placement: "bottom-start",
|
|
208
|
+
isVisible: t.value
|
|
209
|
+
}, {
|
|
210
|
+
reference: re(() => {
|
|
211
|
+
var z, ye, ge, se;
|
|
212
|
+
return [
|
|
213
|
+
ie(me, {
|
|
214
|
+
modelValue: L.value,
|
|
215
|
+
"onUpdate:modelValue": B[1] || (B[1] = (_e) => L.value = _e),
|
|
216
|
+
style: { "min-width": "80px" },
|
|
217
|
+
placeholder: Ue.value ? (ge = (ye = (z = K.filterValues) == null ? void 0 : z.filter((_e) => _e)) == null ? void 0 : ye.slice(0, 3)) == null ? void 0 : ge.join("/") : "搜索",
|
|
218
|
+
"prefix-icon": Ye(Zr),
|
|
219
|
+
clearable: "",
|
|
220
|
+
onInput: q,
|
|
221
|
+
disabled: ((se = le.value) == null ? void 0 : se.length) === 0
|
|
222
|
+
}, {
|
|
223
|
+
suffix: re(() => {
|
|
224
|
+
var _e, Xe;
|
|
225
|
+
return [
|
|
226
|
+
!L.value && ((Xe = (_e = K.filterValues) == null ? void 0 : _e.filter((fl) => fl)) != null && Xe.join("/")) ? (ne(), $e(ke, {
|
|
227
|
+
key: 0,
|
|
228
|
+
style: { cursor: "pointer" },
|
|
229
|
+
onClick: Ae
|
|
230
|
+
}, {
|
|
231
|
+
default: re(() => [
|
|
232
|
+
ie(Ye(Vr))
|
|
233
|
+
]),
|
|
234
|
+
_: 1
|
|
235
|
+
})) : Le("", !0)
|
|
236
|
+
];
|
|
237
|
+
}),
|
|
238
|
+
append: re(() => [
|
|
239
|
+
ve("span", {
|
|
240
|
+
title: "条件查询",
|
|
241
|
+
onClick: B[0] || (B[0] = (_e) => t.value = !t.value)
|
|
242
|
+
}, [
|
|
243
|
+
ie(ae, {
|
|
244
|
+
name: "query",
|
|
245
|
+
style: { width: "15px", height: "15px", cursor: "pointer" }
|
|
246
|
+
})
|
|
247
|
+
])
|
|
248
|
+
]),
|
|
249
|
+
_: 1
|
|
250
|
+
}, 8, ["modelValue", "placeholder", "prefix-icon", "disabled"])
|
|
251
|
+
];
|
|
252
|
+
}),
|
|
253
|
+
content: re(() => [
|
|
254
|
+
ve("div", On, [
|
|
255
|
+
(ne(), $e(la, {
|
|
256
|
+
rowContents: le.value,
|
|
257
|
+
buttonValue: he.value,
|
|
258
|
+
isRowFlex: !0,
|
|
259
|
+
isEnableWrap: !1,
|
|
260
|
+
isButtonRow: !1,
|
|
261
|
+
key: he.value,
|
|
262
|
+
isStartJustify: !1,
|
|
263
|
+
onOnButtonClick: al
|
|
264
|
+
}, null, 8, ["rowContents", "buttonValue"]))
|
|
265
|
+
])
|
|
266
|
+
]),
|
|
267
|
+
_: 1
|
|
268
|
+
}, 8, ["isVisible"])
|
|
269
|
+
]),
|
|
270
|
+
K.buttons && ((ze = K.buttons) == null ? void 0 : ze.length) > 0 ? (ne(), Te("div", Cn, [
|
|
271
|
+
(ne(!0), Te(cl, null, dl((Je = K.buttons) == null ? void 0 : Je.filter((z) => K.isDevMode || (z == null ? void 0 : z.label) !== "修改模板"), (z, ye) => (ne(), Te("div", {
|
|
272
|
+
class: "extra-contents",
|
|
273
|
+
key: ye
|
|
274
|
+
}, [
|
|
275
|
+
(z == null ? void 0 : z.type) === "upload" ? (ne(), $e(pl, {
|
|
276
|
+
key: 0,
|
|
277
|
+
class: "upload-button-wrap",
|
|
278
|
+
"on-change": je,
|
|
279
|
+
accept: ".xlsx,.xls",
|
|
280
|
+
"auto-upload": !1,
|
|
281
|
+
action: "#",
|
|
282
|
+
"show-file-list": !1,
|
|
283
|
+
disabled: !!K.lockingPage
|
|
284
|
+
}, {
|
|
285
|
+
default: re(() => [
|
|
286
|
+
ie(Pe, {
|
|
287
|
+
disabled: !!K.lockingPage,
|
|
288
|
+
style: kl({ background: (z == null ? void 0 : z.background) ?? "var(--ssbutton-theme-bg)", color: (z == null ? void 0 : z.color) ?? "var(--ssbutton-theme-color)" })
|
|
289
|
+
}, {
|
|
290
|
+
default: re(() => [
|
|
291
|
+
el(Ce(z == null ? void 0 : z.label), 1)
|
|
292
|
+
]),
|
|
293
|
+
_: 2
|
|
294
|
+
}, 1032, ["disabled", "style"])
|
|
295
|
+
]),
|
|
296
|
+
_: 2
|
|
297
|
+
}, 1032, ["disabled"])) : Le("", !0),
|
|
298
|
+
(z == null ? void 0 : z.type) === "popover" ? (ne(), $e(nn, { key: 1 }, {
|
|
299
|
+
dropTitle: re(() => [
|
|
300
|
+
(z == null ? void 0 : z.type) === "popover" ? (ne(), $e(Pe, {
|
|
301
|
+
key: 0,
|
|
302
|
+
disabled: !!K.lockingPage,
|
|
303
|
+
style: kl({ background: (z == null ? void 0 : z.background) ?? "var(--ssbutton-theme-bg)", color: (z == null ? void 0 : z.color) ?? "var(--ssbutton-theme-color)" })
|
|
304
|
+
}, {
|
|
305
|
+
default: re(() => [
|
|
306
|
+
el(Ce(z == null ? void 0 : z.label), 1)
|
|
307
|
+
]),
|
|
308
|
+
_: 2
|
|
309
|
+
}, 1032, ["disabled", "style"])) : Le("", !0)
|
|
310
|
+
]),
|
|
311
|
+
dropMenu: re(() => [
|
|
312
|
+
ve("div", En, [
|
|
313
|
+
(ne(!0), Te(cl, null, dl(z == null ? void 0 : z.contents, (ge) => (ne(), $e(Pe, {
|
|
314
|
+
key: ge == null ? void 0 : ge.label,
|
|
315
|
+
disabled: !!K.lockingPage,
|
|
316
|
+
style: { width: "100%", margin: "0", border: "none", display: "flex", "justify-content": "flex-start" },
|
|
317
|
+
onClick: (se) => Be(ge == null ? void 0 : ge.label)
|
|
318
|
+
}, {
|
|
319
|
+
default: re(() => {
|
|
320
|
+
var se, _e;
|
|
321
|
+
return [
|
|
322
|
+
el(Ce(ge == null ? void 0 : ge.label), 1),
|
|
323
|
+
(se = ge == null ? void 0 : ge.label) != null && se.includes("选中") ? (ne(), Te("span", Dn, "(" + Ce(K.selectNums) + ")", 1)) : Le("", !0),
|
|
324
|
+
(_e = ge == null ? void 0 : ge.label) != null && _e.includes("全部") ? (ne(), Te("span", xn, "(" + Ce(K.dataNums) + ")", 1)) : Le("", !0)
|
|
325
|
+
];
|
|
326
|
+
}),
|
|
327
|
+
_: 2
|
|
328
|
+
}, 1032, ["disabled", "onClick"]))), 128))
|
|
329
|
+
])
|
|
330
|
+
]),
|
|
331
|
+
_: 2
|
|
332
|
+
}, 1024)) : Le("", !0),
|
|
333
|
+
z != null && z.type ? Le("", !0) : (ne(), $e(Pe, {
|
|
334
|
+
key: 2,
|
|
335
|
+
id: "themeButton",
|
|
336
|
+
disabled: !!K.lockingPage,
|
|
337
|
+
style: kl({ background: (z == null ? void 0 : z.background) ?? "var(--ssbutton-theme-bg)", color: (z == null ? void 0 : z.color) ?? "var(--ssbutton-theme-color)" }),
|
|
338
|
+
onClick: (ge) => Be(z == null ? void 0 : z.label)
|
|
339
|
+
}, {
|
|
340
|
+
default: re(() => [
|
|
341
|
+
el(Ce(z == null ? void 0 : z.label), 1)
|
|
342
|
+
]),
|
|
343
|
+
_: 2
|
|
344
|
+
}, 1032, ["disabled", "style", "onClick"]))
|
|
345
|
+
]))), 128))
|
|
346
|
+
])) : Le("", !0)
|
|
347
|
+
])
|
|
348
|
+
]);
|
|
349
|
+
};
|
|
350
|
+
}
|
|
351
|
+
}, jn = /* @__PURE__ */ aa(Ln, [["__scopeId", "data-v-0f9ba5cc"]]), Pn = /* @__PURE__ */ qa({
|
|
352
|
+
__name: "batch",
|
|
353
|
+
props: {
|
|
354
|
+
lockingPage: Boolean,
|
|
355
|
+
buttons: {
|
|
356
|
+
type: Array,
|
|
357
|
+
default: () => []
|
|
358
|
+
},
|
|
359
|
+
selectTableItems: {
|
|
360
|
+
type: Array,
|
|
361
|
+
default: () => []
|
|
362
|
+
},
|
|
363
|
+
columns: {
|
|
364
|
+
type: Array,
|
|
365
|
+
default: () => []
|
|
366
|
+
}
|
|
367
|
+
},
|
|
368
|
+
emits: ["buttonClick"],
|
|
369
|
+
setup(K, { emit: V }) {
|
|
370
|
+
const Q = K, j = V, L = (le) => {
|
|
371
|
+
j("buttonClick", le);
|
|
372
|
+
}, t = (le) => {
|
|
373
|
+
var he;
|
|
374
|
+
return le != null && le.includes("删除") ? ((he = Q.selectTableItems) == null ? void 0 : he.length) > 0 ? "warning-active-type" : "warning-type" : "default-type";
|
|
375
|
+
};
|
|
376
|
+
return (le, he) => {
|
|
377
|
+
const je = Ke("el-button");
|
|
378
|
+
return ne(), Te("div", null, [
|
|
379
|
+
(ne(!0), Te(cl, null, dl(K.buttons, (q) => (ne(), $e(je, {
|
|
380
|
+
key: q == null ? void 0 : q.label,
|
|
381
|
+
disabled: !!K.lockingPage,
|
|
382
|
+
class: Ra(t(q == null ? void 0 : q.label)),
|
|
383
|
+
onClick: (Be) => L(q == null ? void 0 : q.label)
|
|
384
|
+
}, {
|
|
385
|
+
default: re(() => [
|
|
386
|
+
el(Ce(q == null ? void 0 : q.label), 1)
|
|
387
|
+
]),
|
|
388
|
+
_: 2
|
|
389
|
+
}, 1032, ["disabled", "class", "onClick"]))), 128))
|
|
390
|
+
]);
|
|
391
|
+
};
|
|
392
|
+
}
|
|
393
|
+
}), Kn = /* @__PURE__ */ aa(Pn, [["__scopeId", "data-v-70b12973"]]), $n = ya("formToTableComp", {
|
|
394
|
+
state: () => ({
|
|
395
|
+
selectArray: [],
|
|
396
|
+
selectString: ""
|
|
397
|
+
}),
|
|
398
|
+
actions: {
|
|
399
|
+
setSelectArray(K) {
|
|
400
|
+
this.selectArray = K;
|
|
401
|
+
},
|
|
402
|
+
setSelectString(K) {
|
|
403
|
+
this.selectString = K;
|
|
404
|
+
}
|
|
405
|
+
}
|
|
406
|
+
}), Bn = { class: "calculator-content" }, Mn = { class: "calculator-child" }, Nn = { class: "calculator-child" }, wn = /* @__PURE__ */ qa({
|
|
407
|
+
__name: "calculator",
|
|
408
|
+
setup(K) {
|
|
409
|
+
const V = R(), Q = R();
|
|
410
|
+
return ha(() => {
|
|
411
|
+
V.value = [
|
|
412
|
+
{
|
|
413
|
+
type: "Upload",
|
|
414
|
+
label: "输入",
|
|
415
|
+
name: "input"
|
|
416
|
+
}
|
|
417
|
+
], Q.value = [
|
|
418
|
+
{
|
|
419
|
+
type: "Upload",
|
|
420
|
+
label: "输出",
|
|
421
|
+
name: "output"
|
|
422
|
+
}
|
|
423
|
+
];
|
|
424
|
+
}), (j, L) => (ne(), Te("div", Bn, [
|
|
425
|
+
ve("div", Mn, [
|
|
426
|
+
ie(la, {
|
|
427
|
+
rowContents: V.value,
|
|
428
|
+
isRowFlex: !0
|
|
429
|
+
}, null, 8, ["rowContents"])
|
|
430
|
+
]),
|
|
431
|
+
ve("div", Nn, [
|
|
432
|
+
ie(la, {
|
|
433
|
+
rowContents: Q.value,
|
|
434
|
+
isEdit: !1,
|
|
435
|
+
isRowFlex: !0
|
|
436
|
+
}, null, 8, ["rowContents"])
|
|
437
|
+
])
|
|
438
|
+
]));
|
|
439
|
+
}
|
|
440
|
+
}), Fn = /* @__PURE__ */ aa(wn, [["__scopeId", "data-v-73db0fe7"]]), zn = ya("unit", {
|
|
441
|
+
state: () => ({
|
|
442
|
+
selectIndex: "",
|
|
443
|
+
selectMenu: "",
|
|
444
|
+
selectTitle: []
|
|
445
|
+
}),
|
|
446
|
+
actions: {
|
|
447
|
+
setSelectIndex(K) {
|
|
448
|
+
this.selectIndex = K;
|
|
449
|
+
},
|
|
450
|
+
setSelectMenu(K) {
|
|
451
|
+
this.selectMenu = K;
|
|
452
|
+
},
|
|
453
|
+
setSelectTitle(K) {
|
|
454
|
+
this.selectTitle = K;
|
|
455
|
+
}
|
|
456
|
+
}
|
|
457
|
+
}), ga = (K, V) => {
|
|
458
|
+
let Q = K, j = V;
|
|
459
|
+
return Array.isArray(Q) && (Q = Q == null ? void 0 : Q.map((L, t) => {
|
|
460
|
+
if (Array.isArray(L)) {
|
|
461
|
+
let le = {};
|
|
462
|
+
return L = L == null ? void 0 : L.forEach((he, je) => {
|
|
463
|
+
var q;
|
|
464
|
+
(q = j == null ? void 0 : j[je]) != null && q.prop ? le[j[je].prop] = he : Array.isArray(he) && (le.children = ga(he, j));
|
|
465
|
+
}), Object.assign(le, { id: t });
|
|
466
|
+
} else
|
|
467
|
+
return L;
|
|
468
|
+
})), Q;
|
|
469
|
+
}, Ha = (K, V, Q) => {
|
|
470
|
+
let j = K, L = V;
|
|
471
|
+
return j = j == null ? void 0 : j.map((t, le) => {
|
|
472
|
+
var he, je;
|
|
473
|
+
return !Array.isArray(t) || !((he = L == null ? void 0 : L[le]) != null && he.label) && !Q || (t.unshift(((je = L == null ? void 0 : L[le]) == null ? void 0 : je.label) ?? ""), t.some((q) => Array.isArray(q)) && (t = t == null ? void 0 : t.map((q) => {
|
|
474
|
+
var Be;
|
|
475
|
+
return Array.isArray(q) && (q = Ha(q, (Be = L == null ? void 0 : L[le]) == null ? void 0 : Be.children, Q)), q;
|
|
476
|
+
}))), t;
|
|
477
|
+
}), j;
|
|
478
|
+
}, Jn = (K, V, Q) => {
|
|
479
|
+
if (V === "")
|
|
480
|
+
return K == null ? void 0 : K.filter((j) => (j == null ? void 0 : j.id) !== Q);
|
|
481
|
+
{
|
|
482
|
+
const j = V.split("-");
|
|
483
|
+
return Wn(K, j, Q);
|
|
484
|
+
}
|
|
485
|
+
}, Wn = (K, V, Q) => {
|
|
486
|
+
let j = K, L = V;
|
|
487
|
+
return (L == null ? void 0 : L.length) === 0 ? j = j == null ? void 0 : j.filter((t) => t.id !== Q) : j = j == null ? void 0 : j.map((t) => (t.id.toString() === (L == null ? void 0 : L[0]) && (L == null || L.shift(), t = Xa(t, L, Q)), t)), j;
|
|
488
|
+
}, Xa = (K, V, Q) => {
|
|
489
|
+
var t, le;
|
|
490
|
+
let j = K, L = V;
|
|
491
|
+
return (L == null ? void 0 : L.length) === 0 ? j.children = (t = j.children) == null ? void 0 : t.filter((he) => he.id !== Q) : j.children = (le = j.children) == null ? void 0 : le.map((he) => (he.id.toString() === (L == null ? void 0 : L[0]) && (L == null || L.shift(), he = Xa(he, L, Q)), he)), j;
|
|
492
|
+
}, Gn = (K, V, Q) => {
|
|
493
|
+
if (V === "")
|
|
494
|
+
return Q;
|
|
495
|
+
{
|
|
496
|
+
const j = V.split("-");
|
|
497
|
+
return Rn(K, j, Q);
|
|
498
|
+
}
|
|
499
|
+
}, Rn = (K, V, Q) => {
|
|
500
|
+
let j = K, L = V;
|
|
501
|
+
return (L == null ? void 0 : L.length) === 0 ? j = Q : j = j == null ? void 0 : j.map((t) => (t.id.toString() === (L == null ? void 0 : L[0]) && (L == null || L.shift(), t = Qa(t, L, Q)), t)), j;
|
|
502
|
+
}, Qa = (K, V, Q) => {
|
|
503
|
+
var t;
|
|
504
|
+
let j = K, L = V;
|
|
505
|
+
return (L == null ? void 0 : L.length) === 0 ? j.children = Q : j.children = (t = j.children) == null ? void 0 : t.map((le) => (le.id.toString() === (L == null ? void 0 : L[0]) && (L == null || L.shift(), le = Qa(le, L, Q)), le)), j;
|
|
506
|
+
}, qn = ya("formComp", {
|
|
507
|
+
state: () => ({
|
|
508
|
+
objUrl: [],
|
|
509
|
+
blobUrls: []
|
|
510
|
+
}),
|
|
511
|
+
actions: {
|
|
512
|
+
setObjUrl(K) {
|
|
513
|
+
this.objUrl = K;
|
|
514
|
+
},
|
|
515
|
+
setBlobUrls(K) {
|
|
516
|
+
this.blobUrls = K;
|
|
517
|
+
}
|
|
518
|
+
}
|
|
519
|
+
}), Ga = async (K) => {
|
|
520
|
+
var t, le, he, je, q, Be, ll;
|
|
521
|
+
let V = (le = (t = J(K)) == null ? void 0 : t.optionUrl) == null ? void 0 : le.menuSelect, Q = [];
|
|
522
|
+
V == null || V.forEach((Ue) => {
|
|
523
|
+
});
|
|
524
|
+
let j = "";
|
|
525
|
+
const L = await dn(V);
|
|
526
|
+
if (L == null || L.forEach((Ue) => {
|
|
527
|
+
var al, Ae, M, B;
|
|
528
|
+
(Ue == null ? void 0 : Ue.name) === (((B = (M = (Ae = (al = J(K)) == null ? void 0 : al.optionUrl) == null ? void 0 : Ae.groupSelect) == null ? void 0 : M[0]) == null ? void 0 : B.replaceAll("'", "")) ?? "") && (j = Ue == null ? void 0 : Ue.id);
|
|
529
|
+
}), j !== "") {
|
|
530
|
+
const Ue = (he = L == null ? void 0 : L.find((M) => {
|
|
531
|
+
var B, ke, ae, me;
|
|
532
|
+
return (M == null ? void 0 : M.name) === (((ke = (B = K == null ? void 0 : K.groupSelect) == null ? void 0 : B.split(":")) == null ? void 0 : ke[0]) || ((me = (ae = K == null ? void 0 : K.optionUrl) == null ? void 0 : ae.groupSelect) == null ? void 0 : me[0]));
|
|
533
|
+
})) == null ? void 0 : he.compData;
|
|
534
|
+
let al = (q = (je = Ue == null ? void 0 : Ue.find((M) => (M == null ? void 0 : M.key) === "header")) == null ? void 0 : je.contents) == null ? void 0 : q.map((M) => M == null ? void 0 : M.label), Ae = (ll = (Be = Ue == null ? void 0 : Ue.find((M) => (M == null ? void 0 : M.key) === "tableContents")) == null ? void 0 : Be.contents) == null ? void 0 : ll.map((M) => (M = M == null ? void 0 : M.filter((B) => !(B != null && B.id)), M));
|
|
535
|
+
Ae == null || Ae.forEach((M) => {
|
|
536
|
+
Q.push(pn(M, al));
|
|
537
|
+
});
|
|
538
|
+
}
|
|
539
|
+
return Q;
|
|
540
|
+
}, Hn = { class: "table-content" }, Xn = { class: "menu-config-wrap" }, Qn = ["onClick"], Yn = {
|
|
541
|
+
key: 0,
|
|
542
|
+
class: "viewport-wrap"
|
|
543
|
+
}, Zn = ["onClick"], Vn = { title: "选择显示列信息" }, In = {
|
|
544
|
+
class: "menu-config-wrap",
|
|
545
|
+
style: { padding: "0 0 0 16px", "box-sizing": "border-box", "min-height": "200px", width: "400px", overflow: "auto", position: "relative" }
|
|
546
|
+
}, es = ["title"], ls = { class: "col-operate-wrap" }, as = {
|
|
547
|
+
title: "拖拽排序列",
|
|
548
|
+
style: { cursor: "move", color: "grey", position: "absolute", right: "15px" }
|
|
549
|
+
}, rs = { class: "pop-view" }, ns = { class: "pop-wrapper" }, ss = { class: "file-list-pop" }, us = ["title", "onClick"], is = ["onClick"], os = ["onClick"], ts = { class: "form-content" }, cs = {
|
|
550
|
+
key: 0,
|
|
551
|
+
class: "dialog-footer"
|
|
552
|
+
}, ds = { class: "dialog-footer" }, ps = {
|
|
553
|
+
__name: "index",
|
|
554
|
+
props: {
|
|
555
|
+
level: {
|
|
556
|
+
type: Number,
|
|
557
|
+
default: 1
|
|
558
|
+
},
|
|
559
|
+
compName: {
|
|
560
|
+
type: String,
|
|
561
|
+
default: "",
|
|
562
|
+
required: !1
|
|
563
|
+
},
|
|
564
|
+
operatingForm: {
|
|
565
|
+
type: Object,
|
|
566
|
+
default: () => {
|
|
567
|
+
}
|
|
568
|
+
},
|
|
569
|
+
cacheNewData: {
|
|
570
|
+
type: Object,
|
|
571
|
+
default: () => {
|
|
572
|
+
}
|
|
573
|
+
},
|
|
574
|
+
parentTableId: {
|
|
575
|
+
type: Number,
|
|
576
|
+
default: 0
|
|
577
|
+
},
|
|
578
|
+
itemData: {
|
|
579
|
+
type: Array,
|
|
580
|
+
default: () => []
|
|
581
|
+
},
|
|
582
|
+
childItemData: {
|
|
583
|
+
type: Array,
|
|
584
|
+
default: () => []
|
|
585
|
+
},
|
|
586
|
+
index: Number,
|
|
587
|
+
isDevMode: Boolean,
|
|
588
|
+
changedContent: {
|
|
589
|
+
type: Object,
|
|
590
|
+
default: () => {
|
|
591
|
+
}
|
|
592
|
+
},
|
|
593
|
+
showHeader: {
|
|
594
|
+
type: Boolean,
|
|
595
|
+
default: !0
|
|
596
|
+
},
|
|
597
|
+
allowSelect: {
|
|
598
|
+
type: Boolean,
|
|
599
|
+
default: !0
|
|
600
|
+
},
|
|
601
|
+
allowOperate: {
|
|
602
|
+
type: Boolean,
|
|
603
|
+
default: !0
|
|
604
|
+
},
|
|
605
|
+
allMapContents: {
|
|
606
|
+
type: Object,
|
|
607
|
+
default: () => {
|
|
608
|
+
}
|
|
609
|
+
}
|
|
610
|
+
},
|
|
611
|
+
emits: ["change", "contentChange", "onButtonClick", "contentClick", "pageChange", "rowClick", "routeUrl"],
|
|
612
|
+
setup(K, { emit: V }) {
|
|
613
|
+
const Q = R([]), j = qn(tl), L = R(null), t = K, le = R([
|
|
614
|
+
{
|
|
615
|
+
label: "排序",
|
|
616
|
+
value: "sortable",
|
|
617
|
+
checked: !1
|
|
618
|
+
},
|
|
619
|
+
{
|
|
620
|
+
label: "筛选",
|
|
621
|
+
value: "filterable",
|
|
622
|
+
checked: !1
|
|
623
|
+
},
|
|
624
|
+
{
|
|
625
|
+
label: "合计",
|
|
626
|
+
value: "showSummary",
|
|
627
|
+
checked: !1
|
|
628
|
+
},
|
|
629
|
+
{
|
|
630
|
+
label: "编辑",
|
|
631
|
+
value: "operable",
|
|
632
|
+
checked: !1
|
|
633
|
+
}
|
|
634
|
+
]), he = fn(tl), { originalPath: je } = bl(he), q = je.value, Be = R(!1), ll = R(!1), Ue = R(!1), al = Ql({
|
|
635
|
+
column: {},
|
|
636
|
+
status: !1,
|
|
637
|
+
text: "合计"
|
|
638
|
+
}), Ae = Ql({
|
|
639
|
+
currentPage: 1,
|
|
640
|
+
pageSize: 10,
|
|
641
|
+
total: 0,
|
|
642
|
+
pageSizes: [5, 10, 20, 50, 100]
|
|
643
|
+
}), M = V, B = R([]), ke = Ql({ prop: "", order: null }), ae = R([]), me = R(!1), Pe = R(!1), pl = R(null);
|
|
644
|
+
tn();
|
|
645
|
+
const ze = R([]), Je = R(!1), z = R(), ye = gn(), { importLoading: ge, activeMenuPath: se, contentLoading: _e, linkMenuInfo: Xe } = bl(ye), fl = hn(tl), de = yn(tl), { extraContents: te, cacheUpdatingData: ml, tableViewContents: Tl, tableLoading: fs, pageMapState: rl, lockingPage: Ml } = bl(de), Z = R([]), Nl = R([]), wl = R(/* @__PURE__ */ new Map());
|
|
646
|
+
R(!1);
|
|
647
|
+
const Qe = R("");
|
|
648
|
+
R();
|
|
649
|
+
const ra = R(!0), gl = R(0), va = R(!0), We = R(""), Ze = R(!1), Ya = R({
|
|
650
|
+
label: "查看三维模型"
|
|
651
|
+
}), Fl = R(!1), na = R(), Me = R([]), nl = R([]), zl = R(!1), Al = R([]), hl = R([]), sl = R([]), Ve = R([]), Ge = R(), Ee = R(), Za = $n(tl), Jl = R(), sa = R(0), Wl = zn(tl), { selectIndex: Va, selectMenu: Ie, selectTitle: ua } = bl(Wl), { selectString: ul } = bl(Za), Ia = Ir(tl), { loginUserInfo: ce } = bl(Ia), er = R(720), il = R(!1), Gl = R(!1), Re = R([]), ol = R(), Ul = R(!0), ba = R(!0), Rl = R([]), lr = qr("contentRef");
|
|
652
|
+
Hr("contentRef", lr), Fe(() => {
|
|
653
|
+
var e;
|
|
654
|
+
return (e = Z.value) == null ? void 0 : e.length;
|
|
655
|
+
}, (e) => {
|
|
656
|
+
Ae.total = e;
|
|
657
|
+
}), Fe(
|
|
658
|
+
() => Tl.value,
|
|
659
|
+
async () => {
|
|
660
|
+
var u, c, o, p, b, s, T, v, m, C, D, S, w, _, x, k, f, g;
|
|
661
|
+
if (((u = Tl.value) == null ? void 0 : u.length) === 0 || !((c = t == null ? void 0 : t.itemData) != null && c.find((i) => (i == null ? void 0 : i.key) === "columnPath")) || !((o = t == null ? void 0 : t.itemData) != null && o.find((i) => (i == null ? void 0 : i.key) === "pageColumn"))) return;
|
|
662
|
+
let e = (m = (v = (T = (s = (b = (p = t == null ? void 0 : t.itemData) == null ? void 0 : p.find((i) => (i == null ? void 0 : i.key) === "pageColumn")) == null ? void 0 : b.contents) == null ? void 0 : s.split("[")) == null ? void 0 : T[1]) == null ? void 0 : v.split("]")) == null ? void 0 : m[0], l = ((w = (S = (D = (C = t == null ? void 0 : t.itemData) == null ? void 0 : C.find((i) => (i == null ? void 0 : i.key) === "pageColumn")) == null ? void 0 : D.contents) == null ? void 0 : S.split("[")) == null ? void 0 : w[0]) + ((x = (_ = Tl.value) == null ? void 0 : _.find((i) => (i == null ? void 0 : i.key) === e)) == null ? void 0 : x.value), r = ((f = (k = t == null ? void 0 : t.itemData) == null ? void 0 : k.find((i) => (i == null ? void 0 : i.key) === "pageGroup")) == null ? void 0 : f.contents) ?? "", a = await we(l, sessionStorage.getItem("systemKey"), ""), n = (g = a == null ? void 0 : a.find((i) => (i == null ? void 0 : i.name) === (r === "" ? t == null ? void 0 : t.compName : r))) == null ? void 0 : g.compData;
|
|
663
|
+
Pa(n, t.allMapContents);
|
|
664
|
+
},
|
|
665
|
+
{ deep: !0 }
|
|
666
|
+
);
|
|
667
|
+
const ar = async (e, l) => {
|
|
668
|
+
var r, a, n, u, c;
|
|
669
|
+
try {
|
|
670
|
+
const o = await $l({ id: (t == null ? void 0 : t.parentTableId) || (t == null ? void 0 : t.index) });
|
|
671
|
+
let p;
|
|
672
|
+
((r = o == null ? void 0 : o.data) == null ? void 0 : r.code) === 200 && (p = ((n = (a = o == null ? void 0 : o.data) == null ? void 0 : a.result) == null ? void 0 : n[0]) || null);
|
|
673
|
+
const b = {
|
|
674
|
+
type: "data",
|
|
675
|
+
pageKey: t != null && t.parentTableId ? (u = p == null ? void 0 : p.key) == null ? void 0 : u.pageKey : se.value,
|
|
676
|
+
tableId: (t == null ? void 0 : t.parentTableId) || (t == null ? void 0 : t.index),
|
|
677
|
+
systemKey: sessionStorage.getItem("systemKey")
|
|
678
|
+
}, s = l == null ? void 0 : l.map((m) => {
|
|
679
|
+
const C = Object.keys(m), D = {};
|
|
680
|
+
return C.forEach((S, w) => {
|
|
681
|
+
D[e[w]] = m[S];
|
|
682
|
+
}), D;
|
|
683
|
+
}), T = s == null ? void 0 : s.map((m) => ({
|
|
684
|
+
key: b,
|
|
685
|
+
value: {
|
|
686
|
+
tableData: m
|
|
687
|
+
}
|
|
688
|
+
})), v = await Yl({ dataList: T });
|
|
689
|
+
((c = v == null ? void 0 : v.data) == null ? void 0 : c.code) === 200 ? (de.setRefreshCurStructure(!0), xe.success("导入数据成功")) : xe.error("导入数据响应失败");
|
|
690
|
+
} catch (o) {
|
|
691
|
+
throw xe.error("导入数据处理失败"), new Error(o);
|
|
692
|
+
}
|
|
693
|
+
}, rr = async (e) => {
|
|
694
|
+
var l, r;
|
|
695
|
+
if (e != null && e.includes(".txt") || e != null && e.includes(".cpt") || e != null && e.includes(".cyd")) {
|
|
696
|
+
const a = await Sl.get(e, {
|
|
697
|
+
responseType: "blob",
|
|
698
|
+
// 必须设置
|
|
699
|
+
headers: {
|
|
700
|
+
"Content-Type": "application/json"
|
|
701
|
+
}
|
|
702
|
+
}), n = new Blob([a.data], {
|
|
703
|
+
type: "application/octet-stream;charset=UTF-8"
|
|
704
|
+
});
|
|
705
|
+
let u = URL.createObjectURL(n);
|
|
706
|
+
z.value = [{
|
|
707
|
+
name: (r = e == null ? void 0 : e.split("/")) == null ? void 0 : r[((l = e == null ? void 0 : e.split("/")) == null ? void 0 : l.length) - 1],
|
|
708
|
+
blobUrl: u
|
|
709
|
+
}], Je.value = !0;
|
|
710
|
+
}
|
|
711
|
+
};
|
|
712
|
+
Xr(() => {
|
|
713
|
+
ba.value = !1;
|
|
714
|
+
let e = sa.value;
|
|
715
|
+
sa.value = e + 1;
|
|
716
|
+
});
|
|
717
|
+
const Sa = Ba(() => {
|
|
718
|
+
var a, n;
|
|
719
|
+
const e = (Ae.currentPage - 1) * Ae.pageSize, l = e + Ae.pageSize, r = (a = B.value) == null ? void 0 : a.find((u) => {
|
|
720
|
+
var c;
|
|
721
|
+
return (u == null ? void 0 : u.sortable) && ((c = u == null ? void 0 : u.label) == null ? void 0 : c.includes("时间"));
|
|
722
|
+
});
|
|
723
|
+
return r && (ke.order = "descending", ke.prop = r == null ? void 0 : r.prop), (n = Z.value) == null ? void 0 : n.slice(e, l);
|
|
724
|
+
}), nr = (e) => {
|
|
725
|
+
Ae.currentPage = e;
|
|
726
|
+
}, sr = (e) => {
|
|
727
|
+
var l;
|
|
728
|
+
Ae.pageSize = e, e * Ae.currentPage > ((l = Z.value) == null ? void 0 : l.length) && (Ae.currentPage = 1, xe.warning("分页无效,返回第一页"));
|
|
729
|
+
}, ur = (e, l) => {
|
|
730
|
+
var c, o;
|
|
731
|
+
const r = (o = (c = B.value) == null ? void 0 : c.map((p) => p == null ? void 0 : p.prop)) == null ? void 0 : o.filter((p) => p !== "operate");
|
|
732
|
+
let a;
|
|
733
|
+
const n = (e == null ? void 0 : e.length) === (r == null ? void 0 : r.length);
|
|
734
|
+
if (e != null && e.includes("序号")) return xe.error("导入的数据不需要包含序号列");
|
|
735
|
+
if (a = n ? e : e.slice(0, r == null ? void 0 : r.length), !(a == null ? void 0 : a.every((p) => r == null ? void 0 : r.find((b) => p === b)))) return xe.error("导入的数据表头不匹配");
|
|
736
|
+
ar(a, l);
|
|
737
|
+
}, ir = (e, l) => {
|
|
738
|
+
var r;
|
|
739
|
+
de.setRefreshCurStructure(!1), ((r = B.value) == null ? void 0 : r.length) === 0 || ur(e, l);
|
|
740
|
+
}, or = (e, l, r, a) => {
|
|
741
|
+
const n = [], u = [], c = (b) => Object.keys(b).length;
|
|
742
|
+
for (const b in e)
|
|
743
|
+
if (e[b] !== void 0) {
|
|
744
|
+
const s = e[b], T = [];
|
|
745
|
+
for (const [v, m] of Object.entries(s))
|
|
746
|
+
T.push(m), u.length < c(s) && u.push(v);
|
|
747
|
+
n.push(T);
|
|
748
|
+
}
|
|
749
|
+
n.unshift(u);
|
|
750
|
+
const o = Bl.aoa_to_sheet(n), p = Bl.book_new();
|
|
751
|
+
Bl.book_append_sheet(p, o, a), mn(p, `${l}.xlsx`), Re.value = [];
|
|
752
|
+
}, ql = async (e, l, r, a = !1, n) => {
|
|
753
|
+
var u, c, o, p, b, s, T, v;
|
|
754
|
+
try {
|
|
755
|
+
de.setRefreshCurStructure(!1);
|
|
756
|
+
const m = await $l({
|
|
757
|
+
id: t == null ? void 0 : t.index
|
|
758
|
+
});
|
|
759
|
+
if (((u = m == null ? void 0 : m.data) == null ? void 0 : u.code) === 200) {
|
|
760
|
+
let C = (b = (p = (o = (c = m == null ? void 0 : m.data) == null ? void 0 : c.result) == null ? void 0 : o[0]) == null ? void 0 : p.value) == null ? void 0 : b.pageData;
|
|
761
|
+
a ? C = {
|
|
762
|
+
...C,
|
|
763
|
+
compData: (T = C == null ? void 0 : C.compData) == null ? void 0 : T.map((S) => {
|
|
764
|
+
var w;
|
|
765
|
+
return (S == null ? void 0 : S.key) === "header" ? {
|
|
766
|
+
...S,
|
|
767
|
+
contents: (w = S == null ? void 0 : S.contents) == null ? void 0 : w.map((_) => ({
|
|
768
|
+
..._,
|
|
769
|
+
[e]: r
|
|
770
|
+
}))
|
|
771
|
+
} : S;
|
|
772
|
+
})
|
|
773
|
+
} : C = {
|
|
774
|
+
...C,
|
|
775
|
+
compData: (s = C == null ? void 0 : C.compData) == null ? void 0 : s.map((S) => {
|
|
776
|
+
var w, _;
|
|
777
|
+
return (S == null ? void 0 : S.key) === "header" ? {
|
|
778
|
+
...S,
|
|
779
|
+
contents: (w = S == null ? void 0 : S.contents) == null ? void 0 : w.map((x) => (x == null ? void 0 : x.prop) === (l == null ? void 0 : l.prop) ? {
|
|
780
|
+
...x,
|
|
781
|
+
[e]: r
|
|
782
|
+
} : x)
|
|
783
|
+
} : (S == null ? void 0 : S.key) === "tableToForm" && n ? {
|
|
784
|
+
...S,
|
|
785
|
+
contents: (_ = S == null ? void 0 : S.contents) == null ? void 0 : _.map((x) => (x == null ? void 0 : x.prop) === (l == null ? void 0 : l.prop) ? {
|
|
786
|
+
...x,
|
|
787
|
+
[n]: r
|
|
788
|
+
} : x)
|
|
789
|
+
} : S;
|
|
790
|
+
})
|
|
791
|
+
};
|
|
792
|
+
const D = await ln({
|
|
793
|
+
id: t == null ? void 0 : t.index,
|
|
794
|
+
value: {
|
|
795
|
+
pageData: C
|
|
796
|
+
}
|
|
797
|
+
});
|
|
798
|
+
((v = D == null ? void 0 : D.data) == null ? void 0 : v.code) === 200 ? (xe.success("编辑成功"), de.setRefreshCurStructure(!0)) : xe.error("编辑响应失败");
|
|
799
|
+
}
|
|
800
|
+
} catch (m) {
|
|
801
|
+
xe.error(m);
|
|
802
|
+
}
|
|
803
|
+
}, tr = async (e, l) => {
|
|
804
|
+
await ql("label", l, e);
|
|
805
|
+
}, cr = async (e, l) => {
|
|
806
|
+
await ql("columnType", l, e, !1, "type");
|
|
807
|
+
}, dr = () => {
|
|
808
|
+
ml.value ? il.value = !1 : Ka();
|
|
809
|
+
}, pr = (e) => {
|
|
810
|
+
Re.value = e;
|
|
811
|
+
}, fr = (e, l) => {
|
|
812
|
+
ol.value === l ? Ul.value = !1 : Ul.value = !0, ol.value = l == null ? void 0 : l.changeProp;
|
|
813
|
+
}, _l = Ba(() => {
|
|
814
|
+
var r, a, n;
|
|
815
|
+
const e = (r = B.value) == null ? void 0 : r.some((u) => u == null ? void 0 : u.filterable);
|
|
816
|
+
return document.documentElement.style.setProperty("--ssTable-header-filter-display", e ? "inline-block" : "none"), (n = (a = B.value) == null ? void 0 : a.filter((u) => (u == null ? void 0 : u.label) !== "操作")) == null ? void 0 : n.map((u) => ({
|
|
817
|
+
...u,
|
|
818
|
+
filterable: !!(u != null && u.filterable),
|
|
819
|
+
showSummary: !!(u != null && u.showSummary),
|
|
820
|
+
operable: !!(u != null && u.operable)
|
|
821
|
+
}));
|
|
822
|
+
}), gr = async (e, l, r) => {
|
|
823
|
+
const a = J(B.value);
|
|
824
|
+
await Il(), B.value = a == null ? void 0 : a.map((n) => (r == null ? void 0 : r.label) === (n == null ? void 0 : n.label) ? {
|
|
825
|
+
...n,
|
|
826
|
+
[l]: e
|
|
827
|
+
} : n), await ql(l, r, e);
|
|
828
|
+
}, ia = async (e, l) => {
|
|
829
|
+
await ql(l, null, e, !0);
|
|
830
|
+
}, hr = () => {
|
|
831
|
+
Ze.value = !1;
|
|
832
|
+
}, yr = (e) => {
|
|
833
|
+
M("clickTrigger", e);
|
|
834
|
+
}, ka = async (e) => {
|
|
835
|
+
var u, c, o, p, b, s, T, v, m, C, D, S, w, _, x;
|
|
836
|
+
const l = e == null ? void 0 : e.row, r = e == null ? void 0 : e.rowData, a = e == null ? void 0 : e.suffix;
|
|
837
|
+
if ((u = l == null ? void 0 : l.toString()) != null && u.includes(".urdf") || e != null && e.isUrdf || a != null && a.includes(".urdf")) {
|
|
838
|
+
if (l.includes(",")) {
|
|
839
|
+
xe.error("当前版本仅允许单个urdf预览!");
|
|
840
|
+
return;
|
|
841
|
+
}
|
|
842
|
+
Al.value = [l], Pe.value = !0, pl.value = {
|
|
843
|
+
data: J(r)
|
|
844
|
+
}, me.value = !0;
|
|
845
|
+
return;
|
|
846
|
+
}
|
|
847
|
+
let n = [];
|
|
848
|
+
if ((c = l == null ? void 0 : l.toString()) != null && c.includes(".stl") || (o = l == null ? void 0 : l.toString()) != null && o.includes(".STL") || (p = l == null ? void 0 : l.toString()) != null && p.includes(".obj") || (b = l == null ? void 0 : l.toString()) != null && b.includes(".mtl")) {
|
|
849
|
+
Al.value = (s = l == null ? void 0 : l.toString()) == null ? void 0 : s.split(","), Pe.value = !1, me.value = !0;
|
|
850
|
+
return;
|
|
851
|
+
}
|
|
852
|
+
if ((T = l == null ? void 0 : l.toString()) != null && T.includes(".stl") || (v = l == null ? void 0 : l.toString()) != null && v.includes(".STL") || (m = l == null ? void 0 : l.toString()) != null && m.includes(".obj") || (C = l == null ? void 0 : l.toString()) != null && C.includes(".mtl") || a != null && a.includes(".stl") || a != null && a.includes(".STL") || a != null && a.includes(".obj") || a != null && a.includes(".mtl")) {
|
|
853
|
+
let k, f = [], g = {};
|
|
854
|
+
if (Array.isArray(l) ? k = l : k = l == null ? void 0 : l.split(","), k == null || k.forEach((i) => {
|
|
855
|
+
i.includes(".mtl") ? f.push(i) : g.blob = g.blob ? g.blob + "," + i : i;
|
|
856
|
+
}), (f == null ? void 0 : f.length) > 0 && (g.mtlBlobs = f), a && (g.suffix = a), (S = (D = Object.values(g)) == null ? void 0 : D[0]) != null && S.includes("http:"))
|
|
857
|
+
n.push(g);
|
|
858
|
+
else {
|
|
859
|
+
const i = new Blob([g.blob], {
|
|
860
|
+
type: "application/octet-stream;charset=UTF-8"
|
|
861
|
+
});
|
|
862
|
+
let h = URL.createObjectURL(i), $ = "";
|
|
863
|
+
(w = l == null ? void 0 : l.split("/")) == null || w.forEach((A, X) => {
|
|
864
|
+
var I;
|
|
865
|
+
X === ((I = l == null ? void 0 : l.split("/")) == null ? void 0 : I.length) - 1 && ($ = A);
|
|
866
|
+
}), (_ = g.blob) != null && _.includes(".stl") && ($ = ($ == null ? void 0 : $.replaceAll(">", "")) + ".urdf"), z.value = [{
|
|
867
|
+
name: $,
|
|
868
|
+
blobUrl: h
|
|
869
|
+
}], Je.value = !0;
|
|
870
|
+
}
|
|
871
|
+
} else {
|
|
872
|
+
const k = await Sl.get(l, {
|
|
873
|
+
responseType: "blob",
|
|
874
|
+
headers: {
|
|
875
|
+
"Content-Type": "application/json"
|
|
876
|
+
}
|
|
877
|
+
}), f = new Blob([k.data], {
|
|
878
|
+
type: "application/octet-stream;charset=UTF-8"
|
|
879
|
+
});
|
|
880
|
+
let g = URL.createObjectURL(f), i = "";
|
|
881
|
+
(x = l == null ? void 0 : l.split("/")) == null || x.forEach((h, $) => {
|
|
882
|
+
var A;
|
|
883
|
+
$ === ((A = l == null ? void 0 : l.split("/")) == null ? void 0 : A.length) - 1 && (i = h);
|
|
884
|
+
}), z.value = [{
|
|
885
|
+
name: i,
|
|
886
|
+
blobUrl: g
|
|
887
|
+
}], Je.value = !0;
|
|
888
|
+
}
|
|
889
|
+
(n == null ? void 0 : n.length) > 0 && j.setBlobUrls(n);
|
|
890
|
+
}, Hl = (e) => {
|
|
891
|
+
var a, n, u, c;
|
|
892
|
+
if (e != null && e.downloadUrl)
|
|
893
|
+
return e == null ? void 0 : e.name;
|
|
894
|
+
const l = (c = (a = e == null ? void 0 : e.url) == null ? void 0 : a.split(".")) == null ? void 0 : c[((u = (n = e == null ? void 0 : e.url) == null ? void 0 : n.split(".")) == null ? void 0 : u.length) - 1];
|
|
895
|
+
return (e == null ? void 0 : e.name) + "." + l;
|
|
896
|
+
}, vr = async (e) => {
|
|
897
|
+
let l = null, r = null, a = null;
|
|
898
|
+
if (e != null && e.downloadUrl) {
|
|
899
|
+
const u = await oa(), c = on.service({
|
|
900
|
+
lock: !0,
|
|
901
|
+
text: "Loading",
|
|
902
|
+
background: "rgba(0, 0, 0, 0.7)"
|
|
903
|
+
}), o = await Sl.post(e == null ? void 0 : e.url, null, {
|
|
904
|
+
responseType: "blob",
|
|
905
|
+
// 必须设置
|
|
906
|
+
headers: {
|
|
907
|
+
Authorization: u,
|
|
908
|
+
baseURL: "http://139.196.154.85:20025",
|
|
909
|
+
"Content-Type": "application/json"
|
|
910
|
+
}
|
|
911
|
+
}).finally(() => {
|
|
912
|
+
c.close();
|
|
913
|
+
}), p = new Blob([o.data], {
|
|
914
|
+
type: "application/octet-stream;charset=UTF-8"
|
|
915
|
+
});
|
|
916
|
+
l = URL.createObjectURL(p), r = e == null ? void 0 : e.name;
|
|
917
|
+
const b = r == null ? void 0 : r.lastIndexOf(".");
|
|
918
|
+
a = r == null ? void 0 : r.slice(b);
|
|
919
|
+
} else {
|
|
920
|
+
const u = await fa({
|
|
921
|
+
url: e == null ? void 0 : e.url
|
|
922
|
+
});
|
|
923
|
+
!e.url.toUpperCase().includes(".OBJ") && !e.url.toUpperCase().includes(".STL") && !e.url.toUpperCase().includes(".MTL") && !e.url.toUpperCase().includes(".URDF") ? (l = URL.createObjectURL(u.data), r = Hl(e)) : l = e == null ? void 0 : e.url;
|
|
924
|
+
}
|
|
925
|
+
if (a != null && a.includes(".urdf") || a != null && a.includes(".stl") || a != null && a.includes(".STL") || a != null && a.includes(".obj") || a != null && a.includes(".mtl")) {
|
|
926
|
+
const u = {
|
|
927
|
+
row: `${l}`,
|
|
928
|
+
suffix: a
|
|
929
|
+
};
|
|
930
|
+
ka(u);
|
|
931
|
+
return;
|
|
932
|
+
}
|
|
933
|
+
const n = {
|
|
934
|
+
name: r,
|
|
935
|
+
blobUrl: l
|
|
936
|
+
};
|
|
937
|
+
z.value = [n], Je.value = !0;
|
|
938
|
+
}, br = async (e) => {
|
|
939
|
+
let l = null, r = null;
|
|
940
|
+
if (e != null && e.downloadUrl) {
|
|
941
|
+
const u = await oa(), c = await Sl.post(e == null ? void 0 : e.url, null, {
|
|
942
|
+
responseType: "blob",
|
|
943
|
+
// 必须设置
|
|
944
|
+
headers: {
|
|
945
|
+
Authorization: u,
|
|
946
|
+
baseURL: "http://139.196.154.85:20025",
|
|
947
|
+
"Content-Type": "application/json"
|
|
948
|
+
}
|
|
949
|
+
}), o = new Blob([c.data], {
|
|
950
|
+
type: "application/octet-stream;charset=UTF-8"
|
|
951
|
+
});
|
|
952
|
+
l = URL.createObjectURL(o), r = e == null ? void 0 : e.name;
|
|
953
|
+
} else {
|
|
954
|
+
const u = await fa({
|
|
955
|
+
url: e == null ? void 0 : e.url
|
|
956
|
+
});
|
|
957
|
+
l = URL.createObjectURL(u.data), r = Hl(e);
|
|
958
|
+
}
|
|
959
|
+
const a = {
|
|
960
|
+
name: r,
|
|
961
|
+
blobUrl: l
|
|
962
|
+
}, n = document.createElement("a");
|
|
963
|
+
n.href = a.blobUrl, n.download = a.name, n.style.display = "none", document.body.appendChild(n), n.click(), setTimeout(() => {
|
|
964
|
+
document.body.removeChild(n);
|
|
965
|
+
}, 100);
|
|
966
|
+
}, Sr = (e, l) => {
|
|
967
|
+
if (Object.values(l).length !== 0)
|
|
968
|
+
return Object.values(l).find((r) => {
|
|
969
|
+
var a, n, u;
|
|
970
|
+
return ((a = r == null ? void 0 : r.toString()) == null ? void 0 : a.includes(".txt")) || ((n = r == null ? void 0 : r.toString()) == null ? void 0 : n.includes(".cpt")) || ((u = r == null ? void 0 : r.toString()) == null ? void 0 : u.includes(".obj"));
|
|
971
|
+
}) ? [...e, Ya.value] : e;
|
|
972
|
+
}, kr = (e, l = {}) => [...e == null ? void 0 : e.values()].filter((r) => Object.keys(l).every((a) => {
|
|
973
|
+
var c;
|
|
974
|
+
const n = r[a], u = (c = l[a]) == null ? void 0 : c.toLowerCase();
|
|
975
|
+
return u && n && typeof n == "string" ? n.toLowerCase().includes(u) : !0;
|
|
976
|
+
})), ma = R([]), mr = async (e, l, r = !1) => {
|
|
977
|
+
var a;
|
|
978
|
+
if (e) {
|
|
979
|
+
if (de.setTableLoading(!0), ma.value = Object.values(e), e && ((a = Object.values(e)) != null && a.every((n) => !n)))
|
|
980
|
+
return Z.value = Nl.value;
|
|
981
|
+
if (r) {
|
|
982
|
+
Z.value = [...wl.value.values()].filter((n) => Object.values(n).some((u) => typeof u == "string" ? u == null ? void 0 : u.toLowerCase().includes(l == null ? void 0 : l.toLowerCase()) : !1));
|
|
983
|
+
return;
|
|
984
|
+
}
|
|
985
|
+
Z.value = kr(wl.value, e), de.setTableLoading(!1);
|
|
986
|
+
}
|
|
987
|
+
}, Tr = async (e) => {
|
|
988
|
+
var c, o, p, b, s, T, v, m, C, D, S, w, _, x, k;
|
|
989
|
+
const l = await $l({
|
|
990
|
+
keyLikes: {
|
|
991
|
+
pageKey: `loading${((c = ce.value) == null ? void 0 : c.account) || ((o = ce.value) == null ? void 0 : o.账号)}`,
|
|
992
|
+
systemKey: sessionStorage.getItem("systemKey")
|
|
993
|
+
}
|
|
994
|
+
}), r = await $l({
|
|
995
|
+
keyLikes: {
|
|
996
|
+
pageKey: `updateLoading${((p = ce.value) == null ? void 0 : p.account) || ((b = ce.value) == null ? void 0 : b.账号)}`,
|
|
997
|
+
systemKey: sessionStorage.getItem("systemKey")
|
|
998
|
+
}
|
|
999
|
+
});
|
|
1000
|
+
let a = (T = (s = l == null ? void 0 : l.data) == null ? void 0 : s.result) == null ? void 0 : T.map((f) => f == null ? void 0 : f.id);
|
|
1001
|
+
const n = (m = (v = r == null ? void 0 : r.data) == null ? void 0 : v.result) == null ? void 0 : m.map((f) => f == null ? void 0 : f.id);
|
|
1002
|
+
a = [...J(a), ...n], (a == null ? void 0 : a.length) > 0 && (a != null && a.every((f) => f !== null && f)) && await pa({
|
|
1003
|
+
ids: a
|
|
1004
|
+
});
|
|
1005
|
+
let u = await we(se.value, sessionStorage.getItem("systemKey"), e.id);
|
|
1006
|
+
if (u = u == null ? void 0 : u.filter((f) => f.comp !== "methodButton"), u && u.length > 0) {
|
|
1007
|
+
const f = !Array.isArray(ua.value) && ((C = ua.value) == null ? void 0 : C.key) !== "main" ? [] : ua.value;
|
|
1008
|
+
f.push({
|
|
1009
|
+
key: Ie.value === "" ? (D = e == null ? void 0 : e.id) == null ? void 0 : D.toString() : Ie.value + "-" + ((S = e == null ? void 0 : e.id) == null ? void 0 : S.toString()),
|
|
1010
|
+
value: e[(w = Object.keys(e)) == null ? void 0 : w.filter((g) => g !== "index" && g !== "id")[0]]
|
|
1011
|
+
}), Wl.setSelectMenu(Ie.value === "" ? (_ = e == null ? void 0 : e.id) == null ? void 0 : _.toString() : Ie.value + "-" + ((x = e == null ? void 0 : e.id) == null ? void 0 : x.toString())), Wl.setSelectTitle(f), Wl.setSelectIndex((k = e == null ? void 0 : e.id) == null ? void 0 : k.toString()), M("pageChange", u);
|
|
1012
|
+
}
|
|
1013
|
+
}, Ta = async (e, l, r, a) => {
|
|
1014
|
+
var u, c, o, p, b, s, T, v, m, C, D, S, w, _, x, k, f, g, i, h, $, A, X, I, Y;
|
|
1015
|
+
if ((a == null ? void 0 : a.isExistChild) === !0) {
|
|
1016
|
+
let W = (c = (u = B.value) == null ? void 0 : u.find((F) => (F == null ? void 0 : F.isMainKey) === !0)) == null ? void 0 : c.prop, H = (o = a == null ? void 0 : a.rowContent) == null ? void 0 : o[W], O = (b = (p = a == null ? void 0 : a.columnType) == null ? void 0 : p.childPath) == null ? void 0 : b.split(q), P = [];
|
|
1017
|
+
O == null || O.forEach((F, d) => {
|
|
1018
|
+
(O == null ? void 0 : O.length) - 1 === d && P.push(H), P.push(F);
|
|
1019
|
+
}), P = P.join(q);
|
|
1020
|
+
let G = await we(P, sessionStorage.getItem("systemKey"), ""), ee = await we((s = a == null ? void 0 : a.columnType) == null ? void 0 : s.childPath, sessionStorage.getItem("systemKey"), "");
|
|
1021
|
+
if (!G || (G == null ? void 0 : G.length) === 0) {
|
|
1022
|
+
let F = [];
|
|
1023
|
+
ee == null || ee.forEach((N) => {
|
|
1024
|
+
var Se, fe, U, y;
|
|
1025
|
+
let E = {
|
|
1026
|
+
type: "structure",
|
|
1027
|
+
pageKey: P,
|
|
1028
|
+
version: 1,
|
|
1029
|
+
systemKey: sessionStorage.getItem("systemKey"),
|
|
1030
|
+
parentTable: "",
|
|
1031
|
+
createUserId: (Se = ce.value) == null ? void 0 : Se.id,
|
|
1032
|
+
parentPageKey: "",
|
|
1033
|
+
createUserLayer: ((fe = ce.value) == null ? void 0 : fe.dept) || ((U = ce.value) == null ? void 0 : U.部门名称)
|
|
1034
|
+
}, be = {
|
|
1035
|
+
pageData: {
|
|
1036
|
+
comp: N == null ? void 0 : N.comp,
|
|
1037
|
+
compData: (y = N == null ? void 0 : N.compData) == null ? void 0 : y.filter((ue) => (ue == null ? void 0 : ue.key) !== "tableContents"),
|
|
1038
|
+
name: N == null ? void 0 : N.name,
|
|
1039
|
+
isShow: N == null ? void 0 : N.isShow
|
|
1040
|
+
}
|
|
1041
|
+
};
|
|
1042
|
+
F.push({
|
|
1043
|
+
key: E,
|
|
1044
|
+
value: be
|
|
1045
|
+
});
|
|
1046
|
+
}), (F == null ? void 0 : F.length) > 0 && await Yl({
|
|
1047
|
+
dataList: F
|
|
1048
|
+
});
|
|
1049
|
+
let d = await we(P, sessionStorage.getItem("systemKey"), "");
|
|
1050
|
+
Rl.value = d;
|
|
1051
|
+
} else
|
|
1052
|
+
Rl.value = G;
|
|
1053
|
+
M("routeUrl", Rl.value, {
|
|
1054
|
+
isEdit: !0,
|
|
1055
|
+
routerUrl: P
|
|
1056
|
+
});
|
|
1057
|
+
return;
|
|
1058
|
+
}
|
|
1059
|
+
if ((a == null ? void 0 : a.data) === "查看" && (e != null && e.every((W) => (W == null ? void 0 : W.url) && (W == null ? void 0 : W.name)))) {
|
|
1060
|
+
let W = J(e);
|
|
1061
|
+
W = await ((T = J(W)) == null ? void 0 : T.map(async (O) => {
|
|
1062
|
+
var ee, F, d, N;
|
|
1063
|
+
const P = await fa({
|
|
1064
|
+
url: O == null ? void 0 : O.url
|
|
1065
|
+
});
|
|
1066
|
+
let G = URL.createObjectURL(P.data);
|
|
1067
|
+
return {
|
|
1068
|
+
name: (O == null ? void 0 : O.name) + "." + ((N = (ee = O == null ? void 0 : O.url) == null ? void 0 : ee.split(".")) == null ? void 0 : N[((d = (F = O == null ? void 0 : O.url) == null ? void 0 : F.split(".")) == null ? void 0 : d.length) - 1]),
|
|
1069
|
+
blobUrl: G
|
|
1070
|
+
};
|
|
1071
|
+
}));
|
|
1072
|
+
let H = await Promise.all(W);
|
|
1073
|
+
z.value = H, Je.value = !0;
|
|
1074
|
+
}
|
|
1075
|
+
const n = J(B.value);
|
|
1076
|
+
if ((a == null ? void 0 : a.isMainKey) === !0 && (n == null ? void 0 : n.length) > 0) {
|
|
1077
|
+
(v = n == null ? void 0 : n[0]) == null || v.prop;
|
|
1078
|
+
let W = J(se).value + q + (a == null ? void 0 : a.data), H = J(se).value, O = (C = (m = rl.value[W]) == null ? void 0 : m.filter((F) => {
|
|
1079
|
+
var d, N;
|
|
1080
|
+
return ((d = F == null ? void 0 : F.key) == null ? void 0 : d.type) === "structure" && ((N = F == null ? void 0 : F.key) == null ? void 0 : N.parentTable) === "";
|
|
1081
|
+
})) == null ? void 0 : C.map((F) => {
|
|
1082
|
+
var d;
|
|
1083
|
+
return (d = F == null ? void 0 : F.value) == null ? void 0 : d.pageData;
|
|
1084
|
+
}), P = {};
|
|
1085
|
+
(D = B.value) == null || D.forEach((F) => {
|
|
1086
|
+
(F == null ? void 0 : F.label) !== "操作" && (P[F.label] = r[F.prop] ?? r[F.label]);
|
|
1087
|
+
});
|
|
1088
|
+
let G = (w = (S = t == null ? void 0 : t.itemData) == null ? void 0 : S.find((F) => (F == null ? void 0 : F.key) === "mainRouters")) == null ? void 0 : w.contents, ee;
|
|
1089
|
+
if ((G == null ? void 0 : G.length) > 0) {
|
|
1090
|
+
let F = W == null ? void 0 : W.split(q)[((_ = W == null ? void 0 : W.split(q)) == null ? void 0 : _.length) - 1], d = G == null ? void 0 : G.find((N) => (N == null ? void 0 : N.key) === F);
|
|
1091
|
+
ee = (d == null ? void 0 : d.routerContent) + q + (d == null ? void 0 : d.key);
|
|
1092
|
+
}
|
|
1093
|
+
if ((O == null ? void 0 : O.length) > 0)
|
|
1094
|
+
await we(W + q + `updateLoading${((x = ce.value) == null ? void 0 : x.account) || ((k = ce.value) == null ? void 0 : k.账号)}`, sessionStorage.getItem("systemKey"), "") || await Zl(W, W + q + `updateLoading${((f = ce.value) == null ? void 0 : f.account) || ((g = ce.value) == null ? void 0 : g.账号)}`, P, ee), de.setRouteToChildPath(H), ye.setActiveMenuPath(W + q + `updateLoading${((i = ce.value) == null ? void 0 : i.account) || ((h = ce.value) == null ? void 0 : h.账号)}`);
|
|
1095
|
+
else {
|
|
1096
|
+
($ = n == null ? void 0 : n[0]) == null || $.prop;
|
|
1097
|
+
let F = J(se).value + q + (a == null ? void 0 : a.data), d = J(se).value;
|
|
1098
|
+
await we(d + q, sessionStorage.getItem("systemKey"), ""), await Zl(d + q, F, P), await Zl(F, F + q + `updateLoading${((A = ce.value) == null ? void 0 : A.account) || ((X = ce.value) == null ? void 0 : X.账号)}`, P, ee), de.setRouteToChildPath(d), ye.setActiveMenuPath(F + q + `updateLoading${((I = ce.value) == null ? void 0 : I.account) || ((Y = ce.value) == null ? void 0 : Y.账号)}`);
|
|
1099
|
+
}
|
|
1100
|
+
}
|
|
1101
|
+
}, Ar = () => {
|
|
1102
|
+
Je.value = !1;
|
|
1103
|
+
}, Ur = (e) => {
|
|
1104
|
+
M("rowClick", e);
|
|
1105
|
+
};
|
|
1106
|
+
Fe(
|
|
1107
|
+
() => t.changedContent,
|
|
1108
|
+
() => {
|
|
1109
|
+
var r, a;
|
|
1110
|
+
if (!t.changedContent) return;
|
|
1111
|
+
let e = (r = Z.value) == null ? void 0 : r.map((n) => {
|
|
1112
|
+
var u;
|
|
1113
|
+
return n.id === ((u = t.changedContent) == null ? void 0 : u.id) && (n = {
|
|
1114
|
+
...t.changedContent,
|
|
1115
|
+
id: t.changedContent.newId ? t.changedContent.newId : t.changedContent.id
|
|
1116
|
+
}, delete n.newId), n;
|
|
1117
|
+
});
|
|
1118
|
+
const l = (a = t.itemData) == null ? void 0 : a.map((n) => ((n == null ? void 0 : n.key) === "tableContents" && (n.contents = e), n));
|
|
1119
|
+
Z.value = e, M("contentChange", {
|
|
1120
|
+
contents: l,
|
|
1121
|
+
index: t.index
|
|
1122
|
+
}), M("change", {
|
|
1123
|
+
content: e,
|
|
1124
|
+
index: t == null ? void 0 : t.index,
|
|
1125
|
+
buttonName: "",
|
|
1126
|
+
id: t == null ? void 0 : t.index
|
|
1127
|
+
});
|
|
1128
|
+
},
|
|
1129
|
+
{ deep: !0, immediate: !0 }
|
|
1130
|
+
);
|
|
1131
|
+
const _r = () => {
|
|
1132
|
+
}, Or = async () => {
|
|
1133
|
+
const e = se.value, l = sessionStorage.getItem("systemKey"), r = await we(e, l, ""), a = r == null ? void 0 : r.find((o) => (o == null ? void 0 : o.name) === "方法明细"), n = (a == null ? void 0 : a.compData) || [], u = n == null ? void 0 : n.find((o) => (o == null ? void 0 : o.key) === "formContent");
|
|
1134
|
+
return u == null ? void 0 : u.contents;
|
|
1135
|
+
}, oa = async () => `Bearer ${an.get("access-token")}`, Cr = async (e, { token: l, inputData: r } = {}) => await Sl.post(e, r, {
|
|
1136
|
+
headers: {
|
|
1137
|
+
Authorization: l
|
|
1138
|
+
}
|
|
1139
|
+
}).catch((n) => (ye.setImportLoading(!1), Promise.reject(n))), Er = (e) => {
|
|
1140
|
+
var a;
|
|
1141
|
+
let l = {};
|
|
1142
|
+
const r = [];
|
|
1143
|
+
return l.form = {}, (a = J(e)) == null || a.forEach((n, u) => {
|
|
1144
|
+
var c, o, p, b, s, T, v, m, C, D, S, w, _, x;
|
|
1145
|
+
if ((n == null ? void 0 : n.comp) === "Table") {
|
|
1146
|
+
(o = (c = n == null ? void 0 : n.compData) == null ? void 0 : c.find((i) => (i == null ? void 0 : i.key) === "header")) == null || o.contents;
|
|
1147
|
+
let k = (s = (b = (p = n == null ? void 0 : n.compData) == null ? void 0 : p.find((i) => (i == null ? void 0 : i.key) === "tableContents")) == null ? void 0 : b.contents) == null ? void 0 : s.map((i) => i.slice(1));
|
|
1148
|
+
(D = (C = (m = (v = (T = n == null ? void 0 : n.compData) == null ? void 0 : T.find((i) => (i == null ? void 0 : i.key) === "header")) == null ? void 0 : v.contents) == null ? void 0 : m[0]) == null ? void 0 : C[0]) == null || D.label;
|
|
1149
|
+
let f = (w = (S = n == null ? void 0 : n.compData) == null ? void 0 : S.find((i) => (i == null ? void 0 : i.key) === "header")) == null ? void 0 : w.contents, g = [];
|
|
1150
|
+
k == null || k.forEach((i) => {
|
|
1151
|
+
let h = [];
|
|
1152
|
+
i == null || i.forEach(($, A) => {
|
|
1153
|
+
var I;
|
|
1154
|
+
let X = {};
|
|
1155
|
+
((I = f[A]) == null ? void 0 : I.label) !== "操作" && (X[f[A].label] = $, h.push(X));
|
|
1156
|
+
}), g.push(h);
|
|
1157
|
+
}), l[n.name] = g;
|
|
1158
|
+
} else {
|
|
1159
|
+
const k = (x = (_ = n.compData) == null ? void 0 : _.find((f) => (f == null ? void 0 : f.key) === "formContent")) == null ? void 0 : x.contents;
|
|
1160
|
+
k == null || k.forEach((f) => {
|
|
1161
|
+
var g, i;
|
|
1162
|
+
if (f.prop !== "") {
|
|
1163
|
+
let h = f == null ? void 0 : f.value;
|
|
1164
|
+
Array.isArray(h) ? h = ((g = h == null ? void 0 : h[0]) == null ? void 0 : g.oldUrl) || "http://222.92.178.198:62009/" + ((i = h == null ? void 0 : h[0]) == null ? void 0 : i.url) : h = h.toString(), f = {
|
|
1165
|
+
key: (f == null ? void 0 : f.prop) ?? (f == null ? void 0 : f.label),
|
|
1166
|
+
value: h
|
|
1167
|
+
}, r.push(f);
|
|
1168
|
+
}
|
|
1169
|
+
});
|
|
1170
|
+
}
|
|
1171
|
+
}), l.form = Sn(r), l;
|
|
1172
|
+
}, Dr = async (e, l, r) => {
|
|
1173
|
+
var $, A, X, I, Y, W, H, O, P, G, ee, F;
|
|
1174
|
+
ye.setImportLoading(!0);
|
|
1175
|
+
const a = await Or().catch((d) => (ye.setImportLoading(!1), Promise.reject(d))), n = a == null ? void 0 : a.find((d) => (d == null ? void 0 : d.key) === "算法体"), u = n == null ? void 0 : n.value;
|
|
1176
|
+
if (!u) {
|
|
1177
|
+
console.log("未搜索到isMain, 缺少算法执行接口"), ye.setImportLoading(!1);
|
|
1178
|
+
return;
|
|
1179
|
+
}
|
|
1180
|
+
const c = B.value || [], o = c.find((d) => (d == null ? void 0 : d.prop) === "输入"), p = o == null ? void 0 : o.prop;
|
|
1181
|
+
let b = l == null ? void 0 : l[p];
|
|
1182
|
+
const s = await oa().catch((d) => (ye.setImportLoading(!1), Promise.reject(d)));
|
|
1183
|
+
let T = !1, v = "";
|
|
1184
|
+
($ = B.value) == null || $.forEach((d) => {
|
|
1185
|
+
(d == null ? void 0 : d.prop) === p && (T = !!(d != null && d.childPath), v = d == null ? void 0 : d.childPath);
|
|
1186
|
+
});
|
|
1187
|
+
let m = "", C = "";
|
|
1188
|
+
if (T) {
|
|
1189
|
+
let d = (X = (A = B.value) == null ? void 0 : A.find((Se) => (Se == null ? void 0 : Se.isMainKey) === !0)) == null ? void 0 : X.prop;
|
|
1190
|
+
C = l == null ? void 0 : l[d];
|
|
1191
|
+
let N = v == null ? void 0 : v.split(q), E = [];
|
|
1192
|
+
N == null || N.forEach((Se, fe) => {
|
|
1193
|
+
(N == null ? void 0 : N.length) - 1 === fe && E.push(C), E.push(Se);
|
|
1194
|
+
}), E = E.join(q), m = E;
|
|
1195
|
+
let be = await we(E, sessionStorage.getItem("systemKey"), "");
|
|
1196
|
+
b = Er(be);
|
|
1197
|
+
}
|
|
1198
|
+
const D = await Cr(u, {
|
|
1199
|
+
token: s,
|
|
1200
|
+
inputData: b
|
|
1201
|
+
}).catch((d) => (ye.setImportLoading(!1), Promise.reject(d))), S = (I = D == null ? void 0 : D.data) == null ? void 0 : I.data, w = a == null ? void 0 : a.find((d) => (d == null ? void 0 : d.prop) === "算法名称");
|
|
1202
|
+
w == null || w.value;
|
|
1203
|
+
const _ = c.find((d) => (d == null ? void 0 : d.prop) === "输出"), x = _ == null ? void 0 : _.directiveLabel;
|
|
1204
|
+
m = m == null ? void 0 : m.replaceAll(o == null ? void 0 : o.directiveLabel, x);
|
|
1205
|
+
const k = (Y = J(m)) == null ? void 0 : Y.replaceAll(q + C, "");
|
|
1206
|
+
let f = await we(m, sessionStorage.getItem("systemKey"), ""), g = await we(k, sessionStorage.getItem("systemKey"), "");
|
|
1207
|
+
if (f) {
|
|
1208
|
+
let d = [], N = [];
|
|
1209
|
+
f == null || f.forEach((E) => {
|
|
1210
|
+
var be, Se;
|
|
1211
|
+
if ((E == null ? void 0 : E.comp) === "Table")
|
|
1212
|
+
(be = E == null ? void 0 : E.compData) == null || be.forEach((fe) => {
|
|
1213
|
+
var U;
|
|
1214
|
+
(fe == null ? void 0 : fe.key) === "tableContents" && ((U = fe == null ? void 0 : fe.contents) == null || U.forEach((y) => {
|
|
1215
|
+
var ue, oe;
|
|
1216
|
+
(ue = y == null ? void 0 : y[0]) != null && ue.id && d.push((oe = y == null ? void 0 : y[0]) == null ? void 0 : oe.id);
|
|
1217
|
+
}));
|
|
1218
|
+
});
|
|
1219
|
+
else if ((E == null ? void 0 : E.comp) === "Form") {
|
|
1220
|
+
E.compData = (Se = E == null ? void 0 : E.compData) == null ? void 0 : Se.map((U) => {
|
|
1221
|
+
var y;
|
|
1222
|
+
return (U == null ? void 0 : U.key) === "formContent" && (U.contents = (y = U == null ? void 0 : U.contents) == null ? void 0 : y.map((ue) => {
|
|
1223
|
+
var oe, pe;
|
|
1224
|
+
return (oe = S == null ? void 0 : S.form) != null && oe[ue.prop] && (ue.value = (pe = S == null ? void 0 : S.form) == null ? void 0 : pe[ue.prop]), ue;
|
|
1225
|
+
})), U;
|
|
1226
|
+
});
|
|
1227
|
+
let fe = {
|
|
1228
|
+
pageData: {
|
|
1229
|
+
comp: E == null ? void 0 : E.comp,
|
|
1230
|
+
name: E == null ? void 0 : E.name,
|
|
1231
|
+
isShow: E == null ? void 0 : E.isShow,
|
|
1232
|
+
compData: E == null ? void 0 : E.compData
|
|
1233
|
+
}
|
|
1234
|
+
};
|
|
1235
|
+
N.push({
|
|
1236
|
+
id: E == null ? void 0 : E.id,
|
|
1237
|
+
value: fe
|
|
1238
|
+
});
|
|
1239
|
+
}
|
|
1240
|
+
}), (N == null ? void 0 : N.length) > 0 && await en({
|
|
1241
|
+
dataList: N
|
|
1242
|
+
}), d = [...new Set(d)], (d == null ? void 0 : d.length) > 0 && await pa({
|
|
1243
|
+
ids: d
|
|
1244
|
+
});
|
|
1245
|
+
} else {
|
|
1246
|
+
let d = [];
|
|
1247
|
+
if (S != null && S.table) {
|
|
1248
|
+
let N = {
|
|
1249
|
+
type: "structure",
|
|
1250
|
+
systemKey: sessionStorage.getItem("systemKey"),
|
|
1251
|
+
pageKey: m,
|
|
1252
|
+
parentTable: "",
|
|
1253
|
+
createUserId: (W = ce.value) == null ? void 0 : W.id,
|
|
1254
|
+
createUserOrg: ((H = ce.value) == null ? void 0 : H.dept) || ((O = ce.value) == null ? void 0 : O.部门名称)
|
|
1255
|
+
};
|
|
1256
|
+
g == null || g.forEach((E) => {
|
|
1257
|
+
let Se = {
|
|
1258
|
+
pageData: {
|
|
1259
|
+
comp: E == null ? void 0 : E.comp,
|
|
1260
|
+
name: E == null ? void 0 : E.name,
|
|
1261
|
+
isShow: E == null ? void 0 : E.isShow,
|
|
1262
|
+
compData: E == null ? void 0 : E.compData
|
|
1263
|
+
}
|
|
1264
|
+
};
|
|
1265
|
+
d.push({
|
|
1266
|
+
key: N,
|
|
1267
|
+
value: Se
|
|
1268
|
+
});
|
|
1269
|
+
});
|
|
1270
|
+
}
|
|
1271
|
+
if (S != null && S.form) {
|
|
1272
|
+
let N = {
|
|
1273
|
+
type: "structure",
|
|
1274
|
+
pageKey: m,
|
|
1275
|
+
systemKey: sessionStorage.getItem("systemKey"),
|
|
1276
|
+
parentTable: "",
|
|
1277
|
+
createUserId: (P = ce.value) == null ? void 0 : P.id,
|
|
1278
|
+
parentPageKey: "",
|
|
1279
|
+
createUserLayer: ((G = ce.value) == null ? void 0 : G.dept) || ((ee = ce.value) == null ? void 0 : ee.部门名称)
|
|
1280
|
+
};
|
|
1281
|
+
g == null || g.forEach((E) => {
|
|
1282
|
+
var U;
|
|
1283
|
+
let be = (U = E == null ? void 0 : E.compData) == null ? void 0 : U.map((y) => {
|
|
1284
|
+
var ue;
|
|
1285
|
+
return (y == null ? void 0 : y.key) === "formContent" && (y.contents = (ue = y.contents) == null ? void 0 : ue.map((oe) => {
|
|
1286
|
+
var pe, Oe;
|
|
1287
|
+
return (pe = S == null ? void 0 : S.form) != null && pe[oe.prop] && (oe.value = (Oe = S == null ? void 0 : S.form) == null ? void 0 : Oe[oe.prop]), oe;
|
|
1288
|
+
})), y;
|
|
1289
|
+
}), fe = {
|
|
1290
|
+
pageData: {
|
|
1291
|
+
comp: E == null ? void 0 : E.comp,
|
|
1292
|
+
name: E == null ? void 0 : E.name,
|
|
1293
|
+
isShow: E == null ? void 0 : E.isShow,
|
|
1294
|
+
compData: be
|
|
1295
|
+
}
|
|
1296
|
+
};
|
|
1297
|
+
d.push({
|
|
1298
|
+
key: N,
|
|
1299
|
+
value: fe
|
|
1300
|
+
});
|
|
1301
|
+
});
|
|
1302
|
+
}
|
|
1303
|
+
(d == null ? void 0 : d.length) > 0 && await Yl({
|
|
1304
|
+
dataList: d
|
|
1305
|
+
});
|
|
1306
|
+
}
|
|
1307
|
+
let i = await we(m, sessionStorage.getItem("systemKey"), ""), h = [];
|
|
1308
|
+
S != null && S.table && ((F = S == null ? void 0 : S.table) == null || F.forEach((d) => {
|
|
1309
|
+
var be, Se, fe, U;
|
|
1310
|
+
let N = {
|
|
1311
|
+
type: "data",
|
|
1312
|
+
pageKey: m,
|
|
1313
|
+
tableId: (be = i == null ? void 0 : i[0]) == null ? void 0 : be.id,
|
|
1314
|
+
systemKey: sessionStorage.getItem("systemKey"),
|
|
1315
|
+
createUserId: (Se = ce.value) == null ? void 0 : Se.id,
|
|
1316
|
+
createUserOrg: ((fe = ce.value) == null ? void 0 : fe.dept) || ((U = ce.value) == null ? void 0 : U.部门名称)
|
|
1317
|
+
}, E = {
|
|
1318
|
+
tableData: d
|
|
1319
|
+
};
|
|
1320
|
+
h.push({
|
|
1321
|
+
key: N,
|
|
1322
|
+
value: E
|
|
1323
|
+
});
|
|
1324
|
+
})), (h == null ? void 0 : h.length) > 0 && await Yl({
|
|
1325
|
+
dataList: h
|
|
1326
|
+
}), El(!0), ye.setImportLoading(!1);
|
|
1327
|
+
}, Aa = (e, l) => (e = e == null ? void 0 : e.map((r) => {
|
|
1328
|
+
var a, n;
|
|
1329
|
+
return r != null && r.children && ((a = r.children) != null && a.find((u) => u.id === (l == null ? void 0 : l.id)) ? r.children = (n = r.children) == null ? void 0 : n.filter((u) => (u == null ? void 0 : u.id) !== (l == null ? void 0 : l.id)) : r.children = Aa(r.children, l)), r;
|
|
1330
|
+
}), e), Xl = async (e, l, r) => {
|
|
1331
|
+
var a, n, u, c, o, p, b, s, T, v, m, C, D, S, w;
|
|
1332
|
+
if (Qe.value = "", zl.value = !0, ra.value = !0, M("onButtonClick", e, l), e === "删除")
|
|
1333
|
+
Fa.confirm("是否确认删除", "温馨提示", {
|
|
1334
|
+
confirmButtonText: "确认",
|
|
1335
|
+
cancelButtonText: "取消",
|
|
1336
|
+
type: "warning"
|
|
1337
|
+
}).then(() => {
|
|
1338
|
+
var _, x;
|
|
1339
|
+
(_ = Z.value) != null && _.find((k) => (k == null ? void 0 : k.id) === (l == null ? void 0 : l.id)) ? Z.value = (x = J(Z.value)) == null ? void 0 : x.filter((k) => (k == null ? void 0 : k.id) !== (l == null ? void 0 : l.id)) : Z.value = Aa(J(Z.value), l), Jn(Jl.value, Ie.value, l == null ? void 0 : l.id), de.setTableLoading(t == null ? void 0 : t.index), M("change", {
|
|
1340
|
+
content: Z.value,
|
|
1341
|
+
singleContent: l,
|
|
1342
|
+
index: t == null ? void 0 : t.index,
|
|
1343
|
+
type: "delete",
|
|
1344
|
+
buttonName: e,
|
|
1345
|
+
column: B.value
|
|
1346
|
+
});
|
|
1347
|
+
});
|
|
1348
|
+
else if (e === "批量删除") {
|
|
1349
|
+
if (((a = Re.value) == null ? void 0 : a.length) === 0)
|
|
1350
|
+
return xe.warning("请先勾选操作的数据");
|
|
1351
|
+
Fa.confirm("是否确认删除", "温馨提示", {
|
|
1352
|
+
confirmButtonText: "确认",
|
|
1353
|
+
cancelButtonText: "取消",
|
|
1354
|
+
type: "warning"
|
|
1355
|
+
}).then(
|
|
1356
|
+
() => {
|
|
1357
|
+
var x, k;
|
|
1358
|
+
const _ = (x = Re.value) == null ? void 0 : x.map((f) => f.id);
|
|
1359
|
+
Z.value = (k = J(Z.value)) == null ? void 0 : k.filter((f) => !(_ != null && _.includes(f.id))), de.setTableLoading(t == null ? void 0 : t.index), M("change", {
|
|
1360
|
+
content: Z.value,
|
|
1361
|
+
singleContent: null,
|
|
1362
|
+
selectItems: Re.value,
|
|
1363
|
+
index: t == null ? void 0 : t.index,
|
|
1364
|
+
type: "batchDelete",
|
|
1365
|
+
buttonName: e,
|
|
1366
|
+
column: B.value
|
|
1367
|
+
});
|
|
1368
|
+
}
|
|
1369
|
+
);
|
|
1370
|
+
} else if (e === "复制新增") {
|
|
1371
|
+
We.value = "新增";
|
|
1372
|
+
const _ = J(l), x = (n = B.value) == null ? void 0 : n.find((g) => g == null ? void 0 : g.isMainKey), k = x || ((u = B.value) == null ? void 0 : u[0]), f = (c = sl.value) == null ? void 0 : c.find((g) => (g == null ? void 0 : g.label) === "新建");
|
|
1373
|
+
await _a(!0, f, { data: _, firstCol: k });
|
|
1374
|
+
} else if (e === "新增")
|
|
1375
|
+
We.value = "新增", Cl(""), Ze.value = !0;
|
|
1376
|
+
else if (e === "编辑")
|
|
1377
|
+
We.value = "编辑", Cl(l), Ze.value = !0;
|
|
1378
|
+
else if (e === "查看")
|
|
1379
|
+
We.value = "查看", Cl(l), zl.value = !1, ra.value = !1, Ze.value = !0;
|
|
1380
|
+
else if (e === "查看三维模型") {
|
|
1381
|
+
const _ = {};
|
|
1382
|
+
for (let k in l)
|
|
1383
|
+
k !== "id" && (_[k] = l[k]);
|
|
1384
|
+
let x = (o = Object.values(_)) == null ? void 0 : o[1];
|
|
1385
|
+
fl.setTableShowThree(x);
|
|
1386
|
+
} else if (((p = r == null ? void 0 : r.extra) == null ? void 0 : p.type) === "modelExample")
|
|
1387
|
+
We.value = e, Fl.value = !0;
|
|
1388
|
+
else if (e === "新建") {
|
|
1389
|
+
let _ = rl.value, x = [];
|
|
1390
|
+
for (let h in _)
|
|
1391
|
+
h != null && h.includes(`loading${((b = ce.value) == null ? void 0 : b.account) || ((s = ce.value) == null ? void 0 : s.账号)}`) && (x = [...x, ...h]);
|
|
1392
|
+
let k = [];
|
|
1393
|
+
for (let h in _)
|
|
1394
|
+
h != null && h.includes(`updateLoading${((T = ce.value) == null ? void 0 : T.account) || ((v = ce.value) == null ? void 0 : v.账号)}`) && (k = [...k, ...h]);
|
|
1395
|
+
let f = x == null ? void 0 : x.map((h) => h == null ? void 0 : h.id);
|
|
1396
|
+
const g = k == null ? void 0 : k.map((h) => h == null ? void 0 : h.id);
|
|
1397
|
+
f = [...J(f), ...g], (f == null ? void 0 : f.length) > 0 && (f != null && f.every((h) => h !== null && h)) && await pa({
|
|
1398
|
+
ids: f
|
|
1399
|
+
});
|
|
1400
|
+
const i = (m = sl.value) == null ? void 0 : m.find((h) => (h == null ? void 0 : h.label) === "新建");
|
|
1401
|
+
await _a(!1, i);
|
|
1402
|
+
} else if (e === "修改模板") {
|
|
1403
|
+
let _ = J(se).value;
|
|
1404
|
+
de.setRouteToChildPath(_), ye.setActiveMenuPath(_ + q);
|
|
1405
|
+
} else if (e === "执行")
|
|
1406
|
+
Dr(e, l);
|
|
1407
|
+
else if (e != null && e.includes("导出")) {
|
|
1408
|
+
if (e === "导出选中" && ((C = Re.value) == null ? void 0 : C.length) === 0)
|
|
1409
|
+
return xe.warning(`请先勾选${e}的数据`);
|
|
1410
|
+
if (e === "导出全部" && ((D = Z.value) == null ? void 0 : D.length) === 0)
|
|
1411
|
+
return xe.warning("暂无数据导出");
|
|
1412
|
+
const _ = (w = (S = B.value) == null ? void 0 : S.map((k) => k == null ? void 0 : k.label)) == null ? void 0 : w.filter((k) => k !== "操作"), x = e === "导出全部" ? J(Z.value) : J(Re.value);
|
|
1413
|
+
x == null || x.forEach((k) => {
|
|
1414
|
+
k == null || delete k.id;
|
|
1415
|
+
}), or(x, t == null ? void 0 : t.compName, _, t == null ? void 0 : t.compName);
|
|
1416
|
+
}
|
|
1417
|
+
}, xr = async (e) => {
|
|
1418
|
+
var r, a, n, u, c, o;
|
|
1419
|
+
const l = await $l({
|
|
1420
|
+
key: {
|
|
1421
|
+
pageKey: e,
|
|
1422
|
+
type: "structure",
|
|
1423
|
+
systemKey: sessionStorage.getItem("systemKey")
|
|
1424
|
+
}
|
|
1425
|
+
});
|
|
1426
|
+
if (((r = l == null ? void 0 : l.data) == null ? void 0 : r.code) === 200)
|
|
1427
|
+
return Array.isArray((a = l == null ? void 0 : l.data) == null ? void 0 : a.result) && ((u = (n = l == null ? void 0 : l.data) == null ? void 0 : n.result) == null ? void 0 : u.length) > 0 ? (o = (c = l == null ? void 0 : l.data) == null ? void 0 : c.result) == null ? void 0 : o.map((p) => {
|
|
1428
|
+
var b;
|
|
1429
|
+
return {
|
|
1430
|
+
id: p == null ? void 0 : p.id,
|
|
1431
|
+
...(b = p == null ? void 0 : p.value) == null ? void 0 : b.pageData
|
|
1432
|
+
};
|
|
1433
|
+
}) : [];
|
|
1434
|
+
}, Lr = async (e, l) => {
|
|
1435
|
+
var r, a, n, u, c, o, p, b, s, T, v, m, C, D, S, w, _, x, k, f;
|
|
1436
|
+
try {
|
|
1437
|
+
let g, i;
|
|
1438
|
+
const h = (r = rl.value[se.value + q]) == null ? void 0 : r.filter((O) => {
|
|
1439
|
+
var P;
|
|
1440
|
+
return ((P = O == null ? void 0 : O.key) == null ? void 0 : P.type) === "structureMethod";
|
|
1441
|
+
}), $ = (a = rl.value[se.value + q]) == null ? void 0 : a.filter((O) => {
|
|
1442
|
+
var P;
|
|
1443
|
+
return ((P = O == null ? void 0 : O.key) == null ? void 0 : P.type) === "structure";
|
|
1444
|
+
}), A = h == null ? void 0 : h.find((O) => {
|
|
1445
|
+
var P, G;
|
|
1446
|
+
return ((G = (P = O == null ? void 0 : O.value) == null ? void 0 : P.pageData) == null ? void 0 : G.method) === "保存";
|
|
1447
|
+
});
|
|
1448
|
+
if (!A) return;
|
|
1449
|
+
const X = (o = (c = rl.value[(u = (n = A == null ? void 0 : A.value) == null ? void 0 : n.pageData) == null ? void 0 : u.path]) == null ? void 0 : c.filter((O) => {
|
|
1450
|
+
var P;
|
|
1451
|
+
return ((P = O == null ? void 0 : O.key) == null ? void 0 : P.type) === "data";
|
|
1452
|
+
})) == null ? void 0 : o.find((O) => {
|
|
1453
|
+
var P, G, ee, F;
|
|
1454
|
+
return ((G = (P = O == null ? void 0 : O.value) == null ? void 0 : P.tableData) == null ? void 0 : G.算法名称) === ((F = (ee = A == null ? void 0 : A.value) == null ? void 0 : ee.pageData) == null ? void 0 : F.method);
|
|
1455
|
+
});
|
|
1456
|
+
if (!X) return;
|
|
1457
|
+
const I = {
|
|
1458
|
+
buttonName: (b = (p = A == null ? void 0 : A.value) == null ? void 0 : p.pageData) == null ? void 0 : b.method,
|
|
1459
|
+
api: (T = (s = X == null ? void 0 : X.value) == null ? void 0 : s.tableData) == null ? void 0 : T.算法体,
|
|
1460
|
+
content: $ == null ? void 0 : $.map((O) => {
|
|
1461
|
+
var P;
|
|
1462
|
+
return (P = O == null ? void 0 : O.value) == null ? void 0 : P.pageData;
|
|
1463
|
+
}),
|
|
1464
|
+
extraContent: [],
|
|
1465
|
+
extraValues: (m = (v = A == null ? void 0 : A.value) == null ? void 0 : v.pageData) == null ? void 0 : m.data,
|
|
1466
|
+
methodName: (D = (C = A == null ? void 0 : A.value) == null ? void 0 : C.pageData) == null ? void 0 : D.path
|
|
1467
|
+
};
|
|
1468
|
+
if (!e) return;
|
|
1469
|
+
const Y = {
|
|
1470
|
+
...e,
|
|
1471
|
+
compData: (S = e == null ? void 0 : e.compData) == null ? void 0 : S.map((O) => {
|
|
1472
|
+
var P;
|
|
1473
|
+
return (O == null ? void 0 : O.key) === "formContent" ? {
|
|
1474
|
+
...O,
|
|
1475
|
+
contents: (P = O == null ? void 0 : O.contents) == null ? void 0 : P.map((G) => (G == null ? void 0 : G.prop) === l ? {
|
|
1476
|
+
...G,
|
|
1477
|
+
value: ""
|
|
1478
|
+
} : G)
|
|
1479
|
+
} : O;
|
|
1480
|
+
})
|
|
1481
|
+
}, W = {
|
|
1482
|
+
key: {
|
|
1483
|
+
pageKey: se.value + q,
|
|
1484
|
+
parentTable: "",
|
|
1485
|
+
systemKey: sessionStorage.getItem("systemKey"),
|
|
1486
|
+
type: "structure"
|
|
1487
|
+
},
|
|
1488
|
+
value: {
|
|
1489
|
+
pageData: Y
|
|
1490
|
+
}
|
|
1491
|
+
}, H = await Sl.post(I.api, W, {
|
|
1492
|
+
headers: {
|
|
1493
|
+
"Content-Type": "application/json"
|
|
1494
|
+
}
|
|
1495
|
+
});
|
|
1496
|
+
return ((w = H == null ? void 0 : H.data) == null ? void 0 : w.code) === 200 && (g = (x = (_ = H == null ? void 0 : H.data) == null ? void 0 : _.result) == null ? void 0 : x.latestReportCode, i = (f = (k = H == null ? void 0 : H.data) == null ? void 0 : k.result) == null ? void 0 : f.status), {
|
|
1497
|
+
newMainKeyValue: g,
|
|
1498
|
+
newStatus: i
|
|
1499
|
+
};
|
|
1500
|
+
} catch (g) {
|
|
1501
|
+
throw xe.error(g), new Error(g);
|
|
1502
|
+
}
|
|
1503
|
+
}, Ua = (e, l, r, a) => {
|
|
1504
|
+
var n;
|
|
1505
|
+
M("contentChange", {
|
|
1506
|
+
contents: (n = e == null ? void 0 : e.compData) == null ? void 0 : n.map((u) => {
|
|
1507
|
+
var c;
|
|
1508
|
+
return (u == null ? void 0 : u.key) === "formContent" ? {
|
|
1509
|
+
...u,
|
|
1510
|
+
contents: (c = u == null ? void 0 : u.contents) == null ? void 0 : c.map((o) => (o == null ? void 0 : o.key) === l ? {
|
|
1511
|
+
...o,
|
|
1512
|
+
value: r
|
|
1513
|
+
} : Ol.value && (o == null ? void 0 : o.prop) === Ol.prop ? {
|
|
1514
|
+
...o,
|
|
1515
|
+
value: Ol.value
|
|
1516
|
+
} : o)
|
|
1517
|
+
} : u;
|
|
1518
|
+
}),
|
|
1519
|
+
index: e == null ? void 0 : e.id
|
|
1520
|
+
}, a);
|
|
1521
|
+
}, Ol = Ql({
|
|
1522
|
+
prop: "状态",
|
|
1523
|
+
value: ""
|
|
1524
|
+
}), jr = R(["系统自动生成信息", "审批意见"]), Pr = async (e, l, r) => {
|
|
1525
|
+
var p, b;
|
|
1526
|
+
let a = e == null ? void 0 : e[l == null ? void 0 : l.prop], n = 1, u, c;
|
|
1527
|
+
const o = J(se).value + q + a;
|
|
1528
|
+
if (o) {
|
|
1529
|
+
Ol.value = "", u = (p = rl.value[o]) == null ? void 0 : p.filter((v) => {
|
|
1530
|
+
var m;
|
|
1531
|
+
return ((m = v == null ? void 0 : v.key) == null ? void 0 : m.type) === "structure";
|
|
1532
|
+
});
|
|
1533
|
+
const s = u == null ? void 0 : u.find((v) => {
|
|
1534
|
+
var m, C, D;
|
|
1535
|
+
return ((D = (C = (m = v == null ? void 0 : v.value) == null ? void 0 : m.pageData) == null ? void 0 : C.comp) == null ? void 0 : D.toUpperCase()) === "FORM";
|
|
1536
|
+
});
|
|
1537
|
+
c = {
|
|
1538
|
+
...(b = s == null ? void 0 : s.value) == null ? void 0 : b.pageData,
|
|
1539
|
+
id: s == null ? void 0 : s.id
|
|
1540
|
+
};
|
|
1541
|
+
const T = await Lr(c, l == null ? void 0 : l.prop);
|
|
1542
|
+
if (Ol.value = T == null ? void 0 : T.newStatus, T != null && T.newMainKeyValue) return T == null ? void 0 : T.newMainKeyValue;
|
|
1543
|
+
}
|
|
1544
|
+
if (Z.value.some((s) => (s == null ? void 0 : s[l == null ? void 0 : l.prop]) === a)) {
|
|
1545
|
+
const s = a;
|
|
1546
|
+
for (; Z.value.some((T) => (T == null ? void 0 : T[l == null ? void 0 : l.prop]) === `${s}(${n})`); )
|
|
1547
|
+
n++;
|
|
1548
|
+
a = `${s}(${n})`;
|
|
1549
|
+
}
|
|
1550
|
+
return a;
|
|
1551
|
+
}, _a = async (e, l, r) => {
|
|
1552
|
+
var c, o, p, b, s, T, v, m;
|
|
1553
|
+
let a, n;
|
|
1554
|
+
const u = await Pr(r == null ? void 0 : r.data, r == null ? void 0 : r.firstCol);
|
|
1555
|
+
if (e ? (a = J(se).value + q + ((b = r == null ? void 0 : r.data) == null ? void 0 : b[(p = r == null ? void 0 : r.firstCol) == null ? void 0 : p.prop]), n = J(se).value + q + u) : (a = J(se).value + q, n = J(a) + `loading${((c = ce.value) == null ? void 0 : c.account) || ((o = ce.value) == null ? void 0 : o.账号)}`), l) {
|
|
1556
|
+
const C = (T = (s = rl.value[n]) == null ? void 0 : s.filter((D) => {
|
|
1557
|
+
var S;
|
|
1558
|
+
return ((S = D == null ? void 0 : D.key) == null ? void 0 : S.parentTable) === "";
|
|
1559
|
+
})) == null ? void 0 : T.map((D) => {
|
|
1560
|
+
var S;
|
|
1561
|
+
return {
|
|
1562
|
+
id: D == null ? void 0 : D.id,
|
|
1563
|
+
...(S = D == null ? void 0 : D.value) == null ? void 0 : S.pageData
|
|
1564
|
+
};
|
|
1565
|
+
});
|
|
1566
|
+
if ((C == null ? void 0 : C.length) > 0)
|
|
1567
|
+
if (e) {
|
|
1568
|
+
const D = C == null ? void 0 : C.find((S) => {
|
|
1569
|
+
var w;
|
|
1570
|
+
return ((w = S == null ? void 0 : S.comp) == null ? void 0 : w.toUpperCase()) === "FORM";
|
|
1571
|
+
});
|
|
1572
|
+
D && Ua(D, (v = r == null ? void 0 : r.firstCol) == null ? void 0 : v.label, u, se.value);
|
|
1573
|
+
} else
|
|
1574
|
+
de.setRouteToChildPath(J(se).value), ye.setActiveMenuPath(n);
|
|
1575
|
+
else if (await Zl(a, n, null, null, jr.value), e) {
|
|
1576
|
+
const D = await xr(n);
|
|
1577
|
+
if ((D == null ? void 0 : D.length) > 0) {
|
|
1578
|
+
const S = D == null ? void 0 : D.find((w) => {
|
|
1579
|
+
var _;
|
|
1580
|
+
return ((_ = w == null ? void 0 : w.comp) == null ? void 0 : _.toUpperCase()) === "FORM";
|
|
1581
|
+
});
|
|
1582
|
+
S && Ua(S, (m = r == null ? void 0 : r.firstCol) == null ? void 0 : m.label, u, se.value);
|
|
1583
|
+
}
|
|
1584
|
+
} else
|
|
1585
|
+
de.setRouteToChildPath(J(se).value), ye.setActiveMenuPath(n);
|
|
1586
|
+
} else
|
|
1587
|
+
e ? (Qe.value = "", Ee.value = r == null ? void 0 : r.data, El(!0, r == null ? void 0 : r.firstCol, u)) : (de.setRouteToChildPath(J(se).value), ye.setActiveMenuPath(n));
|
|
1588
|
+
}, Kr = () => {
|
|
1589
|
+
me.value = !1, Al.value = [], Pe.value = !1;
|
|
1590
|
+
}, Cl = (e) => {
|
|
1591
|
+
var n, u, c, o, p, b;
|
|
1592
|
+
const l = [];
|
|
1593
|
+
let r = [];
|
|
1594
|
+
for (let s in e)
|
|
1595
|
+
Array.isArray(e == null ? void 0 : e[s]) && r.push(s);
|
|
1596
|
+
ae.value = J(B.value), (u = ea((n = J(B.value)) == null ? void 0 : n.filter((s) => (s == null ? void 0 : s.label) !== "操作"))) == null || u.forEach((s, T) => {
|
|
1597
|
+
var v;
|
|
1598
|
+
r.find((m) => m === (s == null ? void 0 : s.prop)) || (s != null && s.formType && ((v = s == null ? void 0 : s.formType) == null ? void 0 : v.toUpperCase()) === "SELECT" ? l.push({
|
|
1599
|
+
label: (s == null ? void 0 : s.prop) || (s == null ? void 0 : s.label) || "",
|
|
1600
|
+
name: (s == null ? void 0 : s.prop) ?? "t" + T,
|
|
1601
|
+
prop: s == null ? void 0 : s.prop,
|
|
1602
|
+
type: !(s != null && s.formType) || (s == null ? void 0 : s.formType) === "" ? "Input" : s == null ? void 0 : s.formType,
|
|
1603
|
+
value: (e == null ? void 0 : e[s == null ? void 0 : s.prop]) ?? (s == null ? void 0 : s.value) ?? "",
|
|
1604
|
+
id: (s == null ? void 0 : s.id) ?? T,
|
|
1605
|
+
contents: (s == null ? void 0 : s.options) ?? [],
|
|
1606
|
+
width: 1,
|
|
1607
|
+
isFormColHidden: s == null ? void 0 : s.isFormColHidden,
|
|
1608
|
+
disabled: s == null ? void 0 : s.disabled,
|
|
1609
|
+
optionUrl: {
|
|
1610
|
+
groupSelect: s == null ? void 0 : s.groupSelect,
|
|
1611
|
+
menuSelect: s == null ? void 0 : s.formMenuSelect,
|
|
1612
|
+
type: "Select",
|
|
1613
|
+
selectRelateType: s == null ? void 0 : s.selectRelateType
|
|
1614
|
+
}
|
|
1615
|
+
}) : l.push({
|
|
1616
|
+
label: (s == null ? void 0 : s.prop) || (s == null ? void 0 : s.label) || "",
|
|
1617
|
+
prop: s == null ? void 0 : s.prop,
|
|
1618
|
+
name: (s == null ? void 0 : s.prop) ?? "t" + T,
|
|
1619
|
+
type: !(s != null && s.formType) || (s == null ? void 0 : s.formType) === "" ? "Input" : s == null ? void 0 : s.formType,
|
|
1620
|
+
value: (e == null ? void 0 : e[s == null ? void 0 : s.prop]) ?? (s == null ? void 0 : s.value) ?? "",
|
|
1621
|
+
id: (s == null ? void 0 : s.id) ?? T,
|
|
1622
|
+
contents: (s == null ? void 0 : s.options) ?? [],
|
|
1623
|
+
width: 1,
|
|
1624
|
+
isFormColHidden: s == null ? void 0 : s.isFormColHidden,
|
|
1625
|
+
disabled: s == null ? void 0 : s.disabled
|
|
1626
|
+
}));
|
|
1627
|
+
}), e === "" || !e || (Qe.value = (e == null ? void 0 : e.id) ?? "");
|
|
1628
|
+
let a = ea((c = J(B.value)) == null ? void 0 : c.filter((s) => (s == null ? void 0 : s.label) !== "操作"));
|
|
1629
|
+
Me.value && ((o = Me.value) == null ? void 0 : o.length) > 0 && (Me.value = (p = J(Me).value) == null ? void 0 : p.map((s) => {
|
|
1630
|
+
var v;
|
|
1631
|
+
let T = (s == null ? void 0 : s.prop) || ((v = a == null ? void 0 : a.find((m) => (m == null ? void 0 : m.label) === (s == null ? void 0 : s.label))) == null ? void 0 : v.prop);
|
|
1632
|
+
return T && (s.value = e[T]), s;
|
|
1633
|
+
})), Ve.value = Me.value && ((b = Me.value) == null ? void 0 : b.length) > 0 ? bn(Me.value) : l;
|
|
1634
|
+
}, $r = () => {
|
|
1635
|
+
var l;
|
|
1636
|
+
const e = (l = L.value) == null ? void 0 : l.$el;
|
|
1637
|
+
e && rn.create(e, {
|
|
1638
|
+
animation: 150,
|
|
1639
|
+
handle: ".col-drag-icon",
|
|
1640
|
+
ghostClass: "sortable-ghost",
|
|
1641
|
+
onEnd: (r) => {
|
|
1642
|
+
var c;
|
|
1643
|
+
const { oldIndex: a, newIndex: n } = r;
|
|
1644
|
+
if (a === n) return;
|
|
1645
|
+
const u = _l.value.splice(a, 1)[0];
|
|
1646
|
+
_l.value.splice(n, 0, u), B.value = (c = B.value) == null ? void 0 : c.slice().sort((o, p) => {
|
|
1647
|
+
if (o.label === "操作") return 1;
|
|
1648
|
+
if (p.label === "操作") return -1;
|
|
1649
|
+
const b = _l.value.findIndex((T) => T.label === o.label), s = _l.value.findIndex((T) => T.label === p.label);
|
|
1650
|
+
return b - s;
|
|
1651
|
+
});
|
|
1652
|
+
}
|
|
1653
|
+
});
|
|
1654
|
+
};
|
|
1655
|
+
ha(() => {
|
|
1656
|
+
na.value = window.innerWidth - 240 * 2;
|
|
1657
|
+
});
|
|
1658
|
+
const Br = () => {
|
|
1659
|
+
Il(() => {
|
|
1660
|
+
$r();
|
|
1661
|
+
});
|
|
1662
|
+
}, ta = (e, l) => {
|
|
1663
|
+
var a;
|
|
1664
|
+
if (!e && !(e != null && e.children)) return {
|
|
1665
|
+
contents: e,
|
|
1666
|
+
currentSelectContents: void 0
|
|
1667
|
+
};
|
|
1668
|
+
let r;
|
|
1669
|
+
return e.children = (a = e.children) == null ? void 0 : a.map((n) => {
|
|
1670
|
+
var u, c;
|
|
1671
|
+
if ((n == null ? void 0 : n.id) === Qe.value) {
|
|
1672
|
+
let o = {};
|
|
1673
|
+
for (let p in n) {
|
|
1674
|
+
let b = (u = l == null ? void 0 : l.find((s) => (s == null ? void 0 : s.prop) === p)) == null ? void 0 : u.label;
|
|
1675
|
+
b ? o[p] = (c = Ee.value) == null ? void 0 : c[b] : o[p] = n[p];
|
|
1676
|
+
}
|
|
1677
|
+
n = Object.assign(o, Ee.value), r = n;
|
|
1678
|
+
} else {
|
|
1679
|
+
let o = ta(n, l);
|
|
1680
|
+
n = o == null ? void 0 : o.contents, r = o == null ? void 0 : o.currentSelectContents;
|
|
1681
|
+
}
|
|
1682
|
+
return n;
|
|
1683
|
+
}), {
|
|
1684
|
+
contents: e,
|
|
1685
|
+
currentSelectContents: r
|
|
1686
|
+
};
|
|
1687
|
+
}, Oa = (e, l) => {
|
|
1688
|
+
let r, a;
|
|
1689
|
+
return e != null && e.find((n) => (n == null ? void 0 : n.id) === Qe.value) ? r = e == null ? void 0 : e.map((n) => {
|
|
1690
|
+
var u, c;
|
|
1691
|
+
if ((n == null ? void 0 : n.id) === Qe.value) {
|
|
1692
|
+
let o = {};
|
|
1693
|
+
for (let p in n) {
|
|
1694
|
+
let b = (u = l == null ? void 0 : l.find((s) => (s == null ? void 0 : s.prop) === p)) == null ? void 0 : u.label;
|
|
1695
|
+
b ? o[p] = (c = Ee.value) == null ? void 0 : c[b] : o[p] = n[p];
|
|
1696
|
+
}
|
|
1697
|
+
n = Object.assign(o, Ee.value), a = n;
|
|
1698
|
+
}
|
|
1699
|
+
return n;
|
|
1700
|
+
}) : r = e == null ? void 0 : e.map((n) => {
|
|
1701
|
+
var u, c, o, p;
|
|
1702
|
+
if ((n == null ? void 0 : n.id) === Qe.value) {
|
|
1703
|
+
let b = {};
|
|
1704
|
+
for (let s in n) {
|
|
1705
|
+
let T = (u = l == null ? void 0 : l.find((v) => (v == null ? void 0 : v.prop) === s)) == null ? void 0 : u.label;
|
|
1706
|
+
T ? b[s] = (c = Ee.value) == null ? void 0 : c[T] : b[s] = n[s];
|
|
1707
|
+
}
|
|
1708
|
+
n = Object.assign(b, Ee.value), a = n;
|
|
1709
|
+
} else
|
|
1710
|
+
n = (o = ta(n, l)) == null ? void 0 : o.contents, a = (p = ta(n, l)) == null ? void 0 : p.currentSelectContents;
|
|
1711
|
+
return n;
|
|
1712
|
+
}), {
|
|
1713
|
+
newContents: r,
|
|
1714
|
+
currentSelectContents: a
|
|
1715
|
+
};
|
|
1716
|
+
}, Ca = (e, l, r) => {
|
|
1717
|
+
var a, n;
|
|
1718
|
+
return e[l == null ? void 0 : l.prop] = r, typeof e.id == "number" && (e.id = (a = e.id) == null ? void 0 : a.toString()), e.children && ((n = e.children) == null ? void 0 : n.length) > 0 && (e.children = e.children.map(Ca)), e;
|
|
1719
|
+
}, ca = (e) => {
|
|
1720
|
+
var r;
|
|
1721
|
+
const l = [];
|
|
1722
|
+
return l.push({ ...e }), e != null && e.children && Array.isArray(e.children) && ((r = e.children) == null || r.forEach((a) => {
|
|
1723
|
+
l.push(...ca(a));
|
|
1724
|
+
})), (l == null ? void 0 : l.length) > 0 ? l == null ? void 0 : l.map((a) => {
|
|
1725
|
+
const n = { ...a };
|
|
1726
|
+
return delete n.children, n;
|
|
1727
|
+
}) : [];
|
|
1728
|
+
}, El = (e = !0, l, r) => {
|
|
1729
|
+
var b, s, T, v, m, C, D, S, w;
|
|
1730
|
+
let a = ea((b = J(B.value)) == null ? void 0 : b.filter((_) => (_ == null ? void 0 : _.label) !== "操作")), n, u = J(Z.value);
|
|
1731
|
+
if (!Ee.value) {
|
|
1732
|
+
Ze.value = !1;
|
|
1733
|
+
return;
|
|
1734
|
+
}
|
|
1735
|
+
if (Qe.value === "") {
|
|
1736
|
+
gl.value++;
|
|
1737
|
+
let _;
|
|
1738
|
+
l && r ? _ = {
|
|
1739
|
+
id: gl.value.toString(),
|
|
1740
|
+
[l == null ? void 0 : l.prop]: r,
|
|
1741
|
+
children: Ee.value.children
|
|
1742
|
+
} : _ = { id: gl.value.toString() }, _ != null && _.children && (_ = {
|
|
1743
|
+
..._,
|
|
1744
|
+
children: (s = _.children) == null ? void 0 : s.map((x) => Ca(x, l, r))
|
|
1745
|
+
}), u.push(Object.assign(Ee.value, _)), n = Object.assign(Ee.value, _);
|
|
1746
|
+
} else
|
|
1747
|
+
u = (T = Oa(u, a)) == null ? void 0 : T.newContents, n = (v = Oa(u, a)) == null ? void 0 : v.currentSelectContents;
|
|
1748
|
+
const c = (m = t.itemData) == null ? void 0 : m.filter((_) => (_ == null ? void 0 : _.key) === "childTree")[0];
|
|
1749
|
+
if (((C = c == null ? void 0 : c.contents) == null ? void 0 : C.length) > 0) {
|
|
1750
|
+
We.value = "编辑";
|
|
1751
|
+
const _ = [];
|
|
1752
|
+
u == null || u.forEach((x, k) => {
|
|
1753
|
+
var g;
|
|
1754
|
+
let f = {};
|
|
1755
|
+
if (Array.isArray(x)) {
|
|
1756
|
+
let i = [];
|
|
1757
|
+
x == null || x.filter((h) => !(h != null && h.id)).forEach((h, $) => {
|
|
1758
|
+
var A, X, I, Y, W, H, O;
|
|
1759
|
+
if ((X = (A = Ge.value) == null ? void 0 : A[$]) != null && X.prop && !Array.isArray(h)) {
|
|
1760
|
+
let P = {};
|
|
1761
|
+
P[Ge.value[$].column] = h, te != null && te.value && ((I = te == null ? void 0 : te.value) == null ? void 0 : I.length) > 0 && ((Y = te == null ? void 0 : te.value) != null && Y.find((G) => JSON.stringify(G == null ? void 0 : G[0]) === JSON.stringify(P))) && (i = (W = te == null ? void 0 : te.value) == null ? void 0 : W.find((G) => JSON.stringify(G == null ? void 0 : G[0]) === JSON.stringify(P))), i && i.length > 0 ? f[Ge.value[$].prop] = i != null && i.find((G) => {
|
|
1762
|
+
var ee;
|
|
1763
|
+
return ((ee = Object.keys(G)) == null ? void 0 : ee[0]) === Ge.value[$].column;
|
|
1764
|
+
}) ? (H = i == null ? void 0 : i.find((G) => {
|
|
1765
|
+
var ee;
|
|
1766
|
+
return ((ee = Object.keys(G)) == null ? void 0 : ee[0]) === Ge.value[$].column;
|
|
1767
|
+
})) == null ? void 0 : H[Ge.value[$].column] : h : f[Ge.value[$].prop] = h;
|
|
1768
|
+
} else Array.isArray(h) && ((O = Ge.value[$]) != null && O.prop ? f[Ge.value[$].prop] = h : f.children = ga(h, Ge.value));
|
|
1769
|
+
});
|
|
1770
|
+
} else
|
|
1771
|
+
f = x;
|
|
1772
|
+
Array.isArray(x) && x.some((i) => i == null ? void 0 : i.id) ? _.push(Object.assign(f, { id: (g = x == null ? void 0 : x.find((i) => i.id)) == null ? void 0 : g.id })) : f.id ? _.push(f) : _.push(Object.assign(f, { id: k.toString() }));
|
|
1773
|
+
}), Z.value = ja(_, c, B.value);
|
|
1774
|
+
} else
|
|
1775
|
+
Z.value = u;
|
|
1776
|
+
xa(Z.value), Jl.value = Z.value;
|
|
1777
|
+
const o = Gn(Jl.value, Ie.value, u);
|
|
1778
|
+
let p = [];
|
|
1779
|
+
if (ml.value ? (p = (D = J(ml).value.singleContent) == null ? void 0 : D.filter((_) => (_ == null ? void 0 : _.id) !== (n == null ? void 0 : n.id)), p.push(n)) : p = [n], il.value) {
|
|
1780
|
+
const _ = {
|
|
1781
|
+
content: o,
|
|
1782
|
+
singleContent: ((S = c == null ? void 0 : c.contents) == null ? void 0 : S.length) > 0 ? p == null ? void 0 : p.flatMap(ca) : p,
|
|
1783
|
+
index: t == null ? void 0 : t.index,
|
|
1784
|
+
buttonName: "编辑",
|
|
1785
|
+
column: B.value,
|
|
1786
|
+
parentTableId: t == null ? void 0 : t.parentTableId
|
|
1787
|
+
};
|
|
1788
|
+
de.setCacheUpdatingData(_);
|
|
1789
|
+
}
|
|
1790
|
+
if (e) {
|
|
1791
|
+
const _ = {
|
|
1792
|
+
content: o,
|
|
1793
|
+
singleContent: ((w = c == null ? void 0 : c.contents) == null ? void 0 : w.length) > 0 ? ca(n) : n,
|
|
1794
|
+
index: t == null ? void 0 : t.index,
|
|
1795
|
+
buttonName: We.value,
|
|
1796
|
+
column: B.value,
|
|
1797
|
+
parentTableId: t == null ? void 0 : t.parentTableId
|
|
1798
|
+
};
|
|
1799
|
+
de.setTableLoading(t == null ? void 0 : t.index), Ze.value = !1, Ee.value = void 0, M("change", _);
|
|
1800
|
+
}
|
|
1801
|
+
};
|
|
1802
|
+
Qr(() => {
|
|
1803
|
+
B.value = [], Z.value = [], ae.value = [], ze.value = [], Me.value = [], nl.value = [], Al.value = [], hl.value = [], Ve.value = [], Re.value = [], L.value = null;
|
|
1804
|
+
});
|
|
1805
|
+
const Ea = async (e, l, r) => {
|
|
1806
|
+
var b, s, T, v, m, C, D, S, w, _, x;
|
|
1807
|
+
ol.value = r == null ? void 0 : r.prop;
|
|
1808
|
+
const a = J(t.itemData), n = a == null ? void 0 : a.map((k) => {
|
|
1809
|
+
var f;
|
|
1810
|
+
return (k == null ? void 0 : k.key) === "header" && ((f = k.contents) == null || f.map((g, i) => {
|
|
1811
|
+
var h, $, A, X, I, Y, W, H, O, P, G, ee, F, d, N, E, be, Se, fe;
|
|
1812
|
+
return g.type = g != null && g.type ? g.type : (X = (A = ($ = (h = g == null ? void 0 : g.key) == null ? void 0 : h.split("$")) == null ? void 0 : $[1]) == null ? void 0 : A.split("(")) != null && X[0] ? (Y = (I = za) == null ? void 0 : I.find((U) => {
|
|
1813
|
+
var y, ue, oe, pe;
|
|
1814
|
+
return (U == null ? void 0 : U.key) === ((pe = (oe = (ue = (y = g == null ? void 0 : g.key) == null ? void 0 : y.split("$")) == null ? void 0 : ue[1]) == null ? void 0 : oe.split("(")) == null ? void 0 : pe[0]);
|
|
1815
|
+
})) == null ? void 0 : Y.value : "Input", g.options = g != null && g.options ? g.options : ((O = (H = (W = g == null ? void 0 : g.key) == null ? void 0 : W.split("$")) == null ? void 0 : H[1]) == null ? void 0 : O.length) > 0 ? (F = (ee = Wa((G = (P = g == null ? void 0 : g.key) == null ? void 0 : P.split("$")) == null ? void 0 : G[1])) == null ? void 0 : ee.split(",")) == null ? void 0 : F.map((U) => ({
|
|
1816
|
+
label: U,
|
|
1817
|
+
value: U
|
|
1818
|
+
})) : [], (d = g == null ? void 0 : g.key) != null && d.includes("$") && (g.key = (E = (N = g == null ? void 0 : g.key) == null ? void 0 : N.split("$")) == null ? void 0 : E[0]), g.value = (be = Object.values(l)) == null ? void 0 : be[i], g.optionUrl = g != null && g.formMenuSelect && ((Se = g == null ? void 0 : g.formMenuSelect) == null ? void 0 : Se.length) > 0 ? {
|
|
1819
|
+
groupSelect: (fe = g == null ? void 0 : g.groupSelect) == null ? void 0 : fe.split(/[::]/).map((U) => U.trim()),
|
|
1820
|
+
menuSelect: g == null ? void 0 : g.formMenuSelect,
|
|
1821
|
+
selectRelateType: "",
|
|
1822
|
+
type: (g == null ? void 0 : g.formType) ?? (g != null && g.groupSelect ? "Select" : "")
|
|
1823
|
+
} : null, g;
|
|
1824
|
+
})), k;
|
|
1825
|
+
});
|
|
1826
|
+
let u = J(Ve.value), c = (s = (b = J(n)) == null ? void 0 : b.find((k) => (k == null ? void 0 : k.key) === "header")) == null ? void 0 : s.contents;
|
|
1827
|
+
u = u == null ? void 0 : u.map((k) => {
|
|
1828
|
+
var f;
|
|
1829
|
+
return k.value = (f = c == null ? void 0 : c.find((g, i) => i === (k == null ? void 0 : k.id))) == null ? void 0 : f.value, k;
|
|
1830
|
+
});
|
|
1831
|
+
let o = "", p = (m = (v = (T = J(n)) == null ? void 0 : T.find((k) => (k == null ? void 0 : k.key) === "header")) == null ? void 0 : v.contents) == null ? void 0 : m.find((k, f) => {
|
|
1832
|
+
var g, i, h;
|
|
1833
|
+
return (k == null ? void 0 : k.label) === ol.value || (f == null ? void 0 : f.toString()) === ((h = (i = (g = ol.value) == null ? void 0 : g.split("a")) == null ? void 0 : i[1]) == null ? void 0 : h.toString());
|
|
1834
|
+
});
|
|
1835
|
+
if ((S = (D = (C = J(n)) == null ? void 0 : C.find((k) => (k == null ? void 0 : k.key) === "header")) == null ? void 0 : D.contents) == null || S.forEach((k) => {
|
|
1836
|
+
var f, g, i, h, $;
|
|
1837
|
+
o === "" && ((i = (g = (f = k == null ? void 0 : k.optionUrl) == null ? void 0 : f.groupSelect) == null ? void 0 : g[1]) != null && i.includes("[")) && (o = ($ = (h = k == null ? void 0 : k.optionUrl) == null ? void 0 : h.groupSelect) == null ? void 0 : $[1]);
|
|
1838
|
+
}), (w = p == null ? void 0 : p.optionUrl) != null && w.menuSelect) {
|
|
1839
|
+
let k = await Ga(p), f;
|
|
1840
|
+
if (k == null || k.forEach((g) => {
|
|
1841
|
+
var i, h, $, A, X, I, Y, W, H, O;
|
|
1842
|
+
o === ((h = (i = p == null ? void 0 : p.optionUrl) == null ? void 0 : i.groupSelect) == null ? void 0 : h[1]) && ((X = (A = ($ = p == null ? void 0 : p.optionUrl) == null ? void 0 : $.groupSelect) == null ? void 0 : A[1]) != null && X.includes("[")) && ((O = J(g)) == null ? void 0 : O[(H = (W = (Y = (I = p == null ? void 0 : p.optionUrl) == null ? void 0 : I.groupSelect) == null ? void 0 : Y[1]) == null ? void 0 : W.replaceAll("[", "")) == null ? void 0 : H.replaceAll("]", "")]) === (p == null ? void 0 : p.value) && (f = g);
|
|
1843
|
+
}), f) {
|
|
1844
|
+
let g = J(u);
|
|
1845
|
+
g = g == null ? void 0 : g.map((h) => {
|
|
1846
|
+
var $, A, X, I, Y, W, H, O, P, G, ee;
|
|
1847
|
+
return (f != null && f[h == null ? void 0 : h.label] || f != null && f[(I = (X = (A = ($ = h == null ? void 0 : h.optionUrl) == null ? void 0 : $.groupSelect) == null ? void 0 : A[1]) == null ? void 0 : X.replaceAll("[", "")) == null ? void 0 : I.replaceAll("]", "")]) && ((H = (W = (Y = h == null ? void 0 : h.optionUrl) == null ? void 0 : Y.groupSelect) == null ? void 0 : W[1]) != null && H.includes("[")) && (h.value = (f == null ? void 0 : f[h == null ? void 0 : h.label]) || (f == null ? void 0 : f[(ee = (G = (P = (O = h == null ? void 0 : h.optionUrl) == null ? void 0 : O.groupSelect) == null ? void 0 : P[1]) == null ? void 0 : G.replaceAll("[", "")) == null ? void 0 : ee.replaceAll("]", "")])), h;
|
|
1848
|
+
}), Z.value = (_ = J(Z.value)) == null ? void 0 : _.map((h) => {
|
|
1849
|
+
if ((h == null ? void 0 : h.id) === (l == null ? void 0 : l.id)) {
|
|
1850
|
+
const $ = {};
|
|
1851
|
+
return g == null || g.forEach((A) => {
|
|
1852
|
+
$[A.name] = A.value;
|
|
1853
|
+
}), $.id = h == null ? void 0 : h.id, $;
|
|
1854
|
+
}
|
|
1855
|
+
return h;
|
|
1856
|
+
});
|
|
1857
|
+
let i = J(g);
|
|
1858
|
+
i = i == null ? void 0 : i.map((h) => {
|
|
1859
|
+
var $, A, X, I;
|
|
1860
|
+
return (A = ($ = h == null ? void 0 : h.optionUrl) == null ? void 0 : $.menuSelect) != null && A.some((Y) => Y == null ? void 0 : Y.includes) && (h.optionUrl.menuSelect = (I = (X = h == null ? void 0 : h.optionUrl) == null ? void 0 : X.menuSelect) == null ? void 0 : I.map((Y) => {
|
|
1861
|
+
var W, H, O, P;
|
|
1862
|
+
if (Y != null && Y.includes("[")) {
|
|
1863
|
+
let G = (H = (W = Y == null ? void 0 : Y.replaceAll("[", "").replaceAll("]", "")) == null ? void 0 : W.split(":")) == null ? void 0 : H[1];
|
|
1864
|
+
Y = (P = (O = J(g)) == null ? void 0 : O.find((ee) => (ee == null ? void 0 : ee.label) === G)) == null ? void 0 : P.value;
|
|
1865
|
+
}
|
|
1866
|
+
return Y;
|
|
1867
|
+
})), h;
|
|
1868
|
+
}), Z.value = (x = J(Z.value)) == null ? void 0 : x.map((h) => {
|
|
1869
|
+
if ((h == null ? void 0 : h.id) === (l == null ? void 0 : l.id)) {
|
|
1870
|
+
const $ = {};
|
|
1871
|
+
return i == null || i.forEach((A) => {
|
|
1872
|
+
$[A.name] = A.value;
|
|
1873
|
+
}), $.id = h == null ? void 0 : h.id, $;
|
|
1874
|
+
}
|
|
1875
|
+
return h;
|
|
1876
|
+
});
|
|
1877
|
+
}
|
|
1878
|
+
}
|
|
1879
|
+
}, Mr = async (e) => {
|
|
1880
|
+
var b, s, T, v, m, C, D, S, w, _, x, k;
|
|
1881
|
+
if (!e) return;
|
|
1882
|
+
Ee.value = e;
|
|
1883
|
+
const l = J(t.itemData);
|
|
1884
|
+
let r = l == null ? void 0 : l.map((f) => {
|
|
1885
|
+
var g;
|
|
1886
|
+
return (f == null ? void 0 : f.key) === "header" && ((g = f.contents) == null || g.map((i, h) => {
|
|
1887
|
+
var $, A, X, I, Y, W, H, O, P, G, ee, F, d, N, E, be, Se, fe, U;
|
|
1888
|
+
return i.type = i != null && i.type ? i.type : (I = (X = (A = ($ = i == null ? void 0 : i.key) == null ? void 0 : $.split("$")) == null ? void 0 : A[1]) == null ? void 0 : X.split("(")) != null && I[0] ? (W = (Y = za) == null ? void 0 : Y.find((y) => {
|
|
1889
|
+
var ue, oe, pe, Oe;
|
|
1890
|
+
return (y == null ? void 0 : y.key) === ((Oe = (pe = (oe = (ue = i == null ? void 0 : i.key) == null ? void 0 : ue.split("$")) == null ? void 0 : oe[1]) == null ? void 0 : pe.split("(")) == null ? void 0 : Oe[0]);
|
|
1891
|
+
})) == null ? void 0 : W.value : "Input", i.options = i != null && i.options ? i.options : ((P = (O = (H = i == null ? void 0 : i.key) == null ? void 0 : H.split("$")) == null ? void 0 : O[1]) == null ? void 0 : P.length) > 0 ? (d = (F = Wa((ee = (G = i == null ? void 0 : i.key) == null ? void 0 : G.split("$")) == null ? void 0 : ee[1])) == null ? void 0 : F.split(",")) == null ? void 0 : d.map((y) => ({
|
|
1892
|
+
label: y,
|
|
1893
|
+
value: y
|
|
1894
|
+
})) : [], (N = i == null ? void 0 : i.key) != null && N.includes("$") && (i.key = (be = (E = i == null ? void 0 : i.key) == null ? void 0 : E.split("$")) == null ? void 0 : be[0]), i.value = (Se = Object.values(e)) == null ? void 0 : Se[h], i.optionUrl = i != null && i.formMenuSelect && ((fe = i == null ? void 0 : i.formMenuSelect) == null ? void 0 : fe.length) > 0 ? {
|
|
1895
|
+
groupSelect: (U = i == null ? void 0 : i.groupSelect) == null ? void 0 : U.split(/[::]/).map((y) => y.trim()),
|
|
1896
|
+
menuSelect: i == null ? void 0 : i.formMenuSelect,
|
|
1897
|
+
selectRelateType: "",
|
|
1898
|
+
type: (i == null ? void 0 : i.formType) ?? (i != null && i.groupSelect ? "Select" : "")
|
|
1899
|
+
} : null, i;
|
|
1900
|
+
})), f;
|
|
1901
|
+
}), a = Ve.value, n = (s = (b = J(r)) == null ? void 0 : b.find((f) => (f == null ? void 0 : f.key) === "header")) == null ? void 0 : s.contents;
|
|
1902
|
+
if (a = a == null ? void 0 : a.map((f) => {
|
|
1903
|
+
var g;
|
|
1904
|
+
return f.value = (g = n == null ? void 0 : n.find((i, h) => (i == null ? void 0 : i.prop) === (f == null ? void 0 : f.name))) == null ? void 0 : g.value, f;
|
|
1905
|
+
}), !Ul.value) return;
|
|
1906
|
+
let u = "", c = (m = (v = (T = J(r)) == null ? void 0 : T.find((f) => (f == null ? void 0 : f.key) === "header")) == null ? void 0 : v.contents) == null ? void 0 : m.find((f, g) => {
|
|
1907
|
+
var i, h, $;
|
|
1908
|
+
return (f == null ? void 0 : f.label) === ol.value || (g == null ? void 0 : g.toString()) === (($ = (h = (i = ol.value) == null ? void 0 : i.split("a")) == null ? void 0 : h[1]) == null ? void 0 : $.toString());
|
|
1909
|
+
}), o = (C = c == null ? void 0 : c.optionUrl) == null ? void 0 : C.menuSelect, p = !0;
|
|
1910
|
+
if ((w = (S = (D = J(r)) == null ? void 0 : D.find((f) => (f == null ? void 0 : f.key) === "header")) == null ? void 0 : S.contents) == null || w.forEach((f) => {
|
|
1911
|
+
var g, i, h, $, A, X;
|
|
1912
|
+
p && ((h = (i = (g = f == null ? void 0 : f.optionUrl) == null ? void 0 : g.groupSelect) == null ? void 0 : i[1]) != null && h.includes("[")) && (u = (A = ($ = f == null ? void 0 : f.optionUrl) == null ? void 0 : $.groupSelect) == null ? void 0 : A[1], JSON.stringify(o) === JSON.stringify((X = f == null ? void 0 : f.optionUrl) == null ? void 0 : X.menuSelect) && (p = !1));
|
|
1913
|
+
}), (_ = c == null ? void 0 : c.optionUrl) != null && _.menuSelect && Ul.value) {
|
|
1914
|
+
let f = await Ga(c), g;
|
|
1915
|
+
if ((x = c == null ? void 0 : c.optionUrl) == null || x.menuSelect, f == null || f.forEach((i) => {
|
|
1916
|
+
var h, $, A, X, I, Y, W, H, O, P;
|
|
1917
|
+
u === (($ = (h = c == null ? void 0 : c.optionUrl) == null ? void 0 : h.groupSelect) == null ? void 0 : $[1]) && ((I = (X = (A = c == null ? void 0 : c.optionUrl) == null ? void 0 : A.groupSelect) == null ? void 0 : X[1]) != null && I.includes("[")) && ((P = J(i)) == null ? void 0 : P[(O = (H = (W = (Y = c == null ? void 0 : c.optionUrl) == null ? void 0 : Y.groupSelect) == null ? void 0 : W[1]) == null ? void 0 : H.replaceAll("[", "")) == null ? void 0 : O.replaceAll("]", "")]) === (c == null ? void 0 : c.value) && (g = i);
|
|
1918
|
+
}), g) {
|
|
1919
|
+
let i = J(a);
|
|
1920
|
+
i = i == null ? void 0 : i.map((A) => {
|
|
1921
|
+
var X, I, Y, W, H, O, P, G, ee, F, d;
|
|
1922
|
+
return (g != null && g[A == null ? void 0 : A.label] || g != null && g[(W = (Y = (I = (X = A == null ? void 0 : A.optionUrl) == null ? void 0 : X.groupSelect) == null ? void 0 : I[1]) == null ? void 0 : Y.replaceAll("[", "")) == null ? void 0 : W.replaceAll("]", "")]) && ((P = (O = (H = A == null ? void 0 : A.optionUrl) == null ? void 0 : H.groupSelect) == null ? void 0 : O[1]) != null && P.includes("[")) && (A.value = (g == null ? void 0 : g[A == null ? void 0 : A.label]) || (g == null ? void 0 : g[(d = (F = (ee = (G = A == null ? void 0 : A.optionUrl) == null ? void 0 : G.groupSelect) == null ? void 0 : ee[1]) == null ? void 0 : F.replaceAll("[", "")) == null ? void 0 : d.replaceAll("]", "")])), A;
|
|
1923
|
+
}), Ve.value = J(i);
|
|
1924
|
+
let h = J(i);
|
|
1925
|
+
h = h == null ? void 0 : h.map((A) => {
|
|
1926
|
+
var X, I, Y, W, H, O;
|
|
1927
|
+
return (I = (X = A == null ? void 0 : A.optionUrl) == null ? void 0 : X.menuSelect) != null && I.some((P) => P == null ? void 0 : P.includes("[")) && (A.optionUrl.oldMenuSelect = (W = (Y = J(A)) == null ? void 0 : Y.optionUrl) == null ? void 0 : W.menuSelect, A.optionUrl.menuSelect = (O = (H = A == null ? void 0 : A.optionUrl) == null ? void 0 : H.menuSelect) == null ? void 0 : O.map((P) => {
|
|
1928
|
+
var G, ee, F, d;
|
|
1929
|
+
if (P != null && P.includes("[")) {
|
|
1930
|
+
let N = (ee = (G = P == null ? void 0 : P.replaceAll("[", "").replaceAll("]", "")) == null ? void 0 : G.split(":")) == null ? void 0 : ee[1];
|
|
1931
|
+
P = (d = (F = J(i)) == null ? void 0 : F.find((E) => (E == null ? void 0 : E.label) === N)) == null ? void 0 : d.value;
|
|
1932
|
+
}
|
|
1933
|
+
return P;
|
|
1934
|
+
})), A;
|
|
1935
|
+
}), Ve.value = h;
|
|
1936
|
+
let $ = {};
|
|
1937
|
+
(k = Ve.value) == null || k.forEach((A) => {
|
|
1938
|
+
$[A.prop] = A == null ? void 0 : A.value;
|
|
1939
|
+
}), Ee.value = $;
|
|
1940
|
+
}
|
|
1941
|
+
}
|
|
1942
|
+
Ul.value = !1;
|
|
1943
|
+
}, Nr = (e) => e ? (e == null ? void 0 : e.toUpperCase()) === "INPUT" ? "TEXTAREA" : e : "TEXTAREA", wr = (e) => {
|
|
1944
|
+
var u, c;
|
|
1945
|
+
const l = (c = (u = Me.value) == null ? void 0 : u.find((o) => (o == null ? void 0 : o.label) === (e == null ? void 0 : e.label))) == null ? void 0 : c.multiple, r = e == null ? void 0 : e.prop;
|
|
1946
|
+
if ((e == null ? void 0 : e.formType) != "Select")
|
|
1947
|
+
return;
|
|
1948
|
+
Z.value.forEach((o) => {
|
|
1949
|
+
const p = o == null ? void 0 : o[r];
|
|
1950
|
+
l && Ja(p) && (o[r] = [p]), !l && !Ja(p) && (o[r] = "");
|
|
1951
|
+
});
|
|
1952
|
+
}, Da = (e, l) => {
|
|
1953
|
+
var r;
|
|
1954
|
+
return l == null || l.forEach((a) => {
|
|
1955
|
+
e[a == null ? void 0 : a.prop] = a == null ? void 0 : a.value;
|
|
1956
|
+
}), e.children && ((r = e.children) == null ? void 0 : r.length) > 0 && (e.children = e.children.map((a) => Da(a, l))), e;
|
|
1957
|
+
}, da = (e) => {
|
|
1958
|
+
var r, a, n, u, c, o;
|
|
1959
|
+
Cl("");
|
|
1960
|
+
const l = (r = Ve.value) == null ? void 0 : r.reduce((p, b) => (p[b.name] = b.value, p), {});
|
|
1961
|
+
if (((a = Object.keys(l)) == null ? void 0 : a.length) > 0) {
|
|
1962
|
+
Ee.value = l, Qe.value = "", gl.value = (n = Z.value) == null ? void 0 : n.length, hl.value = (u = sl.value) == null ? void 0 : u.filter((b) => (b == null ? void 0 : b.label) !== "新增");
|
|
1963
|
+
const p = (o = (c = ae.value) == null ? void 0 : c.filter((b) => (b == null ? void 0 : b.label) !== "操作")) == null ? void 0 : o.map((b) => {
|
|
1964
|
+
var T, v, m;
|
|
1965
|
+
const s = (v = (T = Me.value) == null ? void 0 : T.find((C) => (C == null ? void 0 : C.label) === (b == null ? void 0 : b.label))) == null ? void 0 : v.multiple;
|
|
1966
|
+
return wr(b), {
|
|
1967
|
+
...b,
|
|
1968
|
+
contents: (b == null ? void 0 : b.options) ?? [],
|
|
1969
|
+
// type: 'edit',
|
|
1970
|
+
optionUrl: b != null && b.formMenuSelect && ((m = b == null ? void 0 : b.formMenuSelect) == null ? void 0 : m.length) > 0 ? {
|
|
1971
|
+
groupSelect: b == null ? void 0 : b.groupSelect,
|
|
1972
|
+
menuSelect: b == null ? void 0 : b.formMenuSelect,
|
|
1973
|
+
selectRelateType: "",
|
|
1974
|
+
type: b == null ? void 0 : b.formType,
|
|
1975
|
+
multiple: s
|
|
1976
|
+
} : null
|
|
1977
|
+
// 表格编辑视图组件类型:兼容表头类型切换逻辑,优先模型里定义的类型,其次是手动配置的类型
|
|
1978
|
+
// columnType: convertColType(col?.formType) || col?.columnType
|
|
1979
|
+
};
|
|
1980
|
+
});
|
|
1981
|
+
B.value = p == null ? void 0 : p.map((b) => Da(b, [{
|
|
1982
|
+
prop: "type",
|
|
1983
|
+
value: "edit"
|
|
1984
|
+
}, { prop: "columnType", value: Nr(b == null ? void 0 : b.formType) || (b == null ? void 0 : b.columnType) }])), e === "createClick" && El(!1);
|
|
1985
|
+
}
|
|
1986
|
+
}, yl = {
|
|
1987
|
+
START: "开始时间",
|
|
1988
|
+
END: "结束时间",
|
|
1989
|
+
HOURS: "工时"
|
|
1990
|
+
}, Fr = (e, l) => Number(Ma(l).diff(Ma(e), "day", !0).toFixed(1)), xa = (e) => {
|
|
1991
|
+
var u;
|
|
1992
|
+
const l = t.itemData, r = (u = l == null ? void 0 : l.find((c) => (c == null ? void 0 : c.key) === "header")) == null ? void 0 : u.contents, a = /* @__PURE__ */ new Map();
|
|
1993
|
+
return r == null || r.forEach((c, o) => {
|
|
1994
|
+
const { label: p } = c;
|
|
1995
|
+
a.set(p, o);
|
|
1996
|
+
}), !a.has(yl.START) || !a.has(yl.END) || !a.has(yl.HOURS) ? e : e == null ? void 0 : e.map((c) => {
|
|
1997
|
+
const o = c == null ? void 0 : c[yl.START], p = c == null ? void 0 : c[yl.END], b = Fr(o, p);
|
|
1998
|
+
return o && p && (c[yl.HOURS] = `${b}天`), c;
|
|
1999
|
+
});
|
|
2000
|
+
}, La = (e, l, r = 0) => {
|
|
2001
|
+
if (r > ((l == null ? void 0 : l.length) ?? "")) return e;
|
|
2002
|
+
const a = l == null ? void 0 : l[r], n = /* @__PURE__ */ new Map();
|
|
2003
|
+
for (const c of e) {
|
|
2004
|
+
const o = c[a];
|
|
2005
|
+
n.has(o) || n.set(o, []), n.get(o) && n.get(o).push(c);
|
|
2006
|
+
}
|
|
2007
|
+
const u = [];
|
|
2008
|
+
for (const [c, o] of n) {
|
|
2009
|
+
const [p, ...b] = o, s = { ...p };
|
|
2010
|
+
r + 1 === ((l == null ? void 0 : l.length) ?? "") ? s.children = o == null ? void 0 : o.map((T) => (T.level = J(r) + 1, T)).filter((T, v) => v !== 0) : b.length > 0 && (s.children = La(b, l, r + 1)), s.level = r, u.push(s);
|
|
2011
|
+
}
|
|
2012
|
+
return u;
|
|
2013
|
+
}, ja = (e, l, r) => {
|
|
2014
|
+
var n;
|
|
2015
|
+
if (!(l != null && l.contents) || ((n = l == null ? void 0 : l.contents) == null ? void 0 : n.length) === 0)
|
|
2016
|
+
return e;
|
|
2017
|
+
let a = [];
|
|
2018
|
+
return a = La(e, l == null ? void 0 : l.contents, 0), a;
|
|
2019
|
+
}, Pa = (e, l) => {
|
|
2020
|
+
var v, m, C, D, S, w, _, x, k, f, g, i, h, $, A, X, I, Y, W, H, O, P, G, ee, F;
|
|
2021
|
+
const r = e == null ? void 0 : e.filter((d) => (d == null ? void 0 : d.key) === "header");
|
|
2022
|
+
e == null || e.filter((d) => (d == null ? void 0 : d.key) === "tableIndexColumn")[0];
|
|
2023
|
+
const a = e == null ? void 0 : e.filter((d) => (d == null ? void 0 : d.key) === "childTree")[0];
|
|
2024
|
+
let n = l;
|
|
2025
|
+
const u = e == null ? void 0 : e.find((d) => (d == null ? void 0 : d.key) === "page"), c = e == null ? void 0 : e.find((d) => (d == null ? void 0 : d.key) === "rowButton"), o = e == null ? void 0 : e.find((d) => (d == null ? void 0 : d.key) === "extraButton"), p = e == null ? void 0 : e.filter((d) => (d == null ? void 0 : d.key) === "tableContents"), b = e == null ? void 0 : e.filter((d) => (d == null ? void 0 : d.key) === "tableIndex");
|
|
2026
|
+
Me.value = (m = (v = e == null ? void 0 : e.filter((d) => (d == null ? void 0 : d.key) === "tableToForm")) == null ? void 0 : v[0]) == null ? void 0 : m.contents, va.value = (u == null ? void 0 : u.contents) ?? !0;
|
|
2027
|
+
let s = [];
|
|
2028
|
+
ul.value === "" ? s = r == null ? void 0 : r[0] : s = (r == null ? void 0 : r.find((d) => (d == null ? void 0 : d.selectLabel) === "(" + ul.value + ")")) ?? (r == null ? void 0 : r.find((d) => !(d != null && d.selectLabel)));
|
|
2029
|
+
let T = [];
|
|
2030
|
+
if (ul.value === "" ? T = b == null ? void 0 : b[0] : T = (b == null ? void 0 : b.find((d) => (d == null ? void 0 : d.selectLabel) === "(" + ul.value + ")")) ?? (b == null ? void 0 : b.find((d) => !(d != null && d.selectLabel))), ((C = s == null ? void 0 : s.contents) == null ? void 0 : C.length) > 0) {
|
|
2031
|
+
let d = [];
|
|
2032
|
+
if (s != null && s.contents.some((U) => Array.isArray(U) && (U == null ? void 0 : U.find((y) => y.children))))
|
|
2033
|
+
Ie.value === "" ? d = (S = (D = Na(s == null ? void 0 : s.contents)) == null ? void 0 : D[0]) == null ? void 0 : S.filter((U) => !Array.isArray(U)) : (Ie.value.split("-"), d = (w = Na(s == null ? void 0 : s.contents)) == null ? void 0 : w[0]);
|
|
2034
|
+
else {
|
|
2035
|
+
let U = s != null && s.contents.some((y) => Array.isArray(y)) ? (_ = s == null ? void 0 : s.contents) == null ? void 0 : _[0] : s == null ? void 0 : s.contents;
|
|
2036
|
+
U == null || U.forEach((y, ue) => {
|
|
2037
|
+
var Oe, Ne, Dl, xl;
|
|
2038
|
+
let oe = "";
|
|
2039
|
+
(Ne = (Oe = se.value) == null ? void 0 : Oe.split("/")) == null || Ne.forEach((qe) => {
|
|
2040
|
+
var Ll, jl, Pl;
|
|
2041
|
+
if (qe !== "") {
|
|
2042
|
+
let vl = (Pl = (jl = (Ll = qe == null ? void 0 : qe.split(q + "updateLoading")) == null ? void 0 : Ll[0]) == null ? void 0 : jl.split(q + "loading")) == null ? void 0 : Pl[0];
|
|
2043
|
+
oe = oe === "" ? oe + vl : oe + "/" + vl;
|
|
2044
|
+
}
|
|
2045
|
+
}), oe = oe + q + (y == null ? void 0 : y.directiveLabel);
|
|
2046
|
+
const pe = (Dl = Me.value) == null ? void 0 : Dl.find((qe) => (qe == null ? void 0 : qe.prop) === (y == null ? void 0 : y.prop));
|
|
2047
|
+
d.push({
|
|
2048
|
+
label: (y == null ? void 0 : y.label) ?? "",
|
|
2049
|
+
prop: (y == null ? void 0 : y.label) === "操作" ? "operate" : (y == null ? void 0 : y.prop) ?? "a" + ue,
|
|
2050
|
+
// width: t?.label === '操作' ? '200' : (t?.width ? parseInt(t.width) : ''),
|
|
2051
|
+
width: y != null && y.width ? parseInt(y.width) : "",
|
|
2052
|
+
fixed: (y == null ? void 0 : y.fixed) ?? void 0,
|
|
2053
|
+
sortable: (y == null ? void 0 : y.sortable) ?? !1,
|
|
2054
|
+
filterable: (y == null ? void 0 : y.filterable) ?? !1,
|
|
2055
|
+
operable: (y == null ? void 0 : y.operable) ?? !1,
|
|
2056
|
+
showSummary: (y == null ? void 0 : y.showSummary) ?? !1,
|
|
2057
|
+
align: (y == null ? void 0 : y.align) ?? "left",
|
|
2058
|
+
showOverflowTooltip: (y == null ? void 0 : y.showOverflowTooltip) ?? !0,
|
|
2059
|
+
isNotDrag: (y == null ? void 0 : y.isNotDrag) ?? !1,
|
|
2060
|
+
isEditCol: (y == null ? void 0 : y.isEditCol) ?? !1,
|
|
2061
|
+
isOperate: (y == null ? void 0 : y.isOperate) ?? !1,
|
|
2062
|
+
id: (y == null ? void 0 : y.id) ?? ue,
|
|
2063
|
+
type: (y == null ? void 0 : y.label) === "操作" ? "operate" : void 0,
|
|
2064
|
+
formType: (y == null ? void 0 : y.formType) ?? (y != null && y.groupSelect ? "Select" : ""),
|
|
2065
|
+
isTableColHidden: y == null ? void 0 : y.isTableColHidden,
|
|
2066
|
+
isFormColHidden: y == null ? void 0 : y.isFormColHidden,
|
|
2067
|
+
disabled: y == null ? void 0 : y.disabled,
|
|
2068
|
+
options: (y == null ? void 0 : y.options) ?? [],
|
|
2069
|
+
value: (y == null ? void 0 : y.value) ?? "",
|
|
2070
|
+
formMenuSelect: (y == null ? void 0 : y.formMenuSelect) ?? [],
|
|
2071
|
+
isRoute: (y == null ? void 0 : y.isRoute) ?? !1,
|
|
2072
|
+
groupSelect: y != null && y.groupSelect ? (xl = y == null ? void 0 : y.groupSelect) == null ? void 0 : xl.replaceAll('"', "").split(":") : [],
|
|
2073
|
+
isMainKey: (y == null ? void 0 : y.isMainKey) || (y == null ? void 0 : y.directiveLabel) && !n[oe],
|
|
2074
|
+
// 同步弹窗列类型到表格列类型
|
|
2075
|
+
columnType: (pe == null ? void 0 : pe.type) || (y == null ? void 0 : y.columnType) || "TEXTAREA",
|
|
2076
|
+
directiveLabel: y == null ? void 0 : y.directiveLabel,
|
|
2077
|
+
isExistChild: !!(y != null && y.directiveLabel && n[oe]),
|
|
2078
|
+
childPath: oe
|
|
2079
|
+
});
|
|
2080
|
+
});
|
|
2081
|
+
}
|
|
2082
|
+
B.value = wa(d), ze.value = wa(d), Q.value = (x = B.value) == null ? void 0 : x.map((U) => U == null ? void 0 : U.label), ll.value = (k = B.value) == null ? void 0 : k.every((U) => U == null ? void 0 : U.filterable), Ue.value = (f = B.value) == null ? void 0 : f.every((U) => U == null ? void 0 : U.operable), Be.value = (g = B.value) == null ? void 0 : g.every((U) => U == null ? void 0 : U.sortable);
|
|
2083
|
+
let N = (h = (i = vn(B.value)) == null ? void 0 : i.filter((U) => (U == null ? void 0 : U.type) !== "operate")) == null ? void 0 : h.map((U, y) => ({
|
|
2084
|
+
prop: (U == null ? void 0 : U.prop) ?? "a" + y,
|
|
2085
|
+
column: U.label
|
|
2086
|
+
}));
|
|
2087
|
+
Ge.value = N;
|
|
2088
|
+
let E = [];
|
|
2089
|
+
ul.value === "" ? E = p == null ? void 0 : p[0] : E = (p == null ? void 0 : p.find((U) => (U == null ? void 0 : U.selectLabel) === "(" + ul.value + ")")) ?? (p == null ? void 0 : p.find((U) => !(U != null && U.selectLabel)));
|
|
2090
|
+
let be = Array.isArray(($ = E == null ? void 0 : E.contents) == null ? void 0 : $[0]) && ((A = E == null ? void 0 : E.contents) != null && A[0].every((U) => Array.isArray(U))) ? (X = E == null ? void 0 : E.contents) == null ? void 0 : X[0] : E == null ? void 0 : E.contents;
|
|
2091
|
+
T != null && T.contents && ((I = T == null ? void 0 : T.contents) == null ? void 0 : I.length) !== 0 && (be = (Y = J(be)) == null ? void 0 : Y.map((U, y) => {
|
|
2092
|
+
if (!Array.isArray(U)) {
|
|
2093
|
+
let ue = {};
|
|
2094
|
+
for (let oe in U)
|
|
2095
|
+
oe !== "id" && oe !== "index" && (ue[oe] = U[oe]);
|
|
2096
|
+
U = Object.values(ue);
|
|
2097
|
+
}
|
|
2098
|
+
return U;
|
|
2099
|
+
}));
|
|
2100
|
+
const Se = !!((W = B.value) != null && W.find((U) => U.prop === "index"));
|
|
2101
|
+
be = Ha(be, T == null ? void 0 : T.contents, Se);
|
|
2102
|
+
const fe = [];
|
|
2103
|
+
be == null || be.forEach((U, y) => {
|
|
2104
|
+
var oe;
|
|
2105
|
+
let ue = {};
|
|
2106
|
+
if (Array.isArray(U)) {
|
|
2107
|
+
let pe = [];
|
|
2108
|
+
U == null || U.filter((Oe) => !(Oe != null && Oe.id)).forEach((Oe, Ne) => {
|
|
2109
|
+
var Dl, xl, qe, Ll, jl, Pl;
|
|
2110
|
+
if ((Dl = N == null ? void 0 : N[Ne]) != null && Dl.prop && !Array.isArray(Oe)) {
|
|
2111
|
+
let vl = {};
|
|
2112
|
+
vl[N[Ne].column] = Oe, te != null && te.value && ((xl = te == null ? void 0 : te.value) == null ? void 0 : xl.length) > 0 && ((qe = te == null ? void 0 : te.value) != null && qe.find((He) => JSON.stringify(He == null ? void 0 : He[0]) === JSON.stringify(vl))) && (pe = (Ll = te == null ? void 0 : te.value) == null ? void 0 : Ll.find((He) => JSON.stringify(He == null ? void 0 : He[0]) === JSON.stringify(vl))), pe && pe.length > 0 ? ue[N[Ne].prop] = pe != null && pe.find((He) => {
|
|
2113
|
+
var Kl;
|
|
2114
|
+
return ((Kl = Object.keys(He)) == null ? void 0 : Kl[0]) === N[Ne].column;
|
|
2115
|
+
}) ? (jl = pe == null ? void 0 : pe.find((He) => {
|
|
2116
|
+
var Kl;
|
|
2117
|
+
return ((Kl = Object.keys(He)) == null ? void 0 : Kl[0]) === N[Ne].column;
|
|
2118
|
+
})) == null ? void 0 : jl[N[Ne].column] : Oe : ue[N[Ne].prop] = Oe;
|
|
2119
|
+
} else Array.isArray(Oe) && ((Pl = N[Ne]) != null && Pl.prop ? ue[N[Ne].prop] = Oe : ue.children = ga(Oe, N));
|
|
2120
|
+
});
|
|
2121
|
+
} else
|
|
2122
|
+
ue = U;
|
|
2123
|
+
Array.isArray(U) && U.some((pe) => pe == null ? void 0 : pe.id) ? fe.push(Object.assign(ue, { id: (oe = U == null ? void 0 : U.find((pe) => pe.id)) == null ? void 0 : oe.id })) : ue.id ? fe.push(ue) : fe.push(Object.assign(ue, { id: y.toString() }));
|
|
2124
|
+
}), Z.value = ja(fe, a, B.value), Nl.value = fe, (H = Nl.value) == null || H.forEach((U) => {
|
|
2125
|
+
var y;
|
|
2126
|
+
(y = wl.value) == null || y.set(U.id, U);
|
|
2127
|
+
});
|
|
2128
|
+
} else
|
|
2129
|
+
B.value = [], ae.value = [], Z.value = [], Nl.value = [], wl.value = /* @__PURE__ */ new Map();
|
|
2130
|
+
((O = c == null ? void 0 : c.contents) == null ? void 0 : O.length) > 0 ? nl.value = c == null ? void 0 : c.contents : nl.value = [], ((P = o == null ? void 0 : o.contents) == null ? void 0 : P.length) > 0 ? (hl.value = o == null ? void 0 : o.contents, sl.value = o == null ? void 0 : o.contents) : (hl.value = [], sl.value = []), gl.value = ((G = Z == null ? void 0 : Z.value) == null ? void 0 : G.length) ?? 0, xa(Z.value), Jl.value = Z.value, il.value && (B.value = (F = (ee = ae.value) == null ? void 0 : ee.filter((d) => (d == null ? void 0 : d.label) !== "操作")) == null ? void 0 : F.map((d) => {
|
|
2131
|
+
var N;
|
|
2132
|
+
return {
|
|
2133
|
+
...d,
|
|
2134
|
+
type: "edit",
|
|
2135
|
+
optionUrl: d != null && d.formMenuSelect && ((N = d == null ? void 0 : d.formMenuSelect) == null ? void 0 : N.length) > 0 ? {
|
|
2136
|
+
groupSelect: d == null ? void 0 : d.groupSelect,
|
|
2137
|
+
menuSelect: d == null ? void 0 : d.formMenuSelect,
|
|
2138
|
+
selectRelateType: "",
|
|
2139
|
+
type: d == null ? void 0 : d.formType
|
|
2140
|
+
} : null
|
|
2141
|
+
};
|
|
2142
|
+
}), da());
|
|
2143
|
+
};
|
|
2144
|
+
Fe(
|
|
2145
|
+
() => [t.itemData, ul.value, Va.value, Ie.value, te == null ? void 0 : te.value],
|
|
2146
|
+
async () => {
|
|
2147
|
+
var e, l, r, a, n, u;
|
|
2148
|
+
if ((e = t == null ? void 0 : t.itemData) != null && e.find((c) => (c == null ? void 0 : c.key) === "columnPath") && !((l = Tl.value) != null && l.find((c) => {
|
|
2149
|
+
var o, p;
|
|
2150
|
+
return (c == null ? void 0 : c.key) === ((p = (o = t == null ? void 0 : t.itemData) == null ? void 0 : o.find((b) => (b == null ? void 0 : b.key) === "columnPath")) == null ? void 0 : p.contents);
|
|
2151
|
+
}))) {
|
|
2152
|
+
let c = Tl.value, o = {
|
|
2153
|
+
key: (a = (r = t == null ? void 0 : t.itemData) == null ? void 0 : r.find((p) => (p == null ? void 0 : p.key) === "columnPath")) == null ? void 0 : a.contents,
|
|
2154
|
+
value: (u = (n = t == null ? void 0 : t.itemData) == null ? void 0 : n.find((p) => (p == null ? void 0 : p.key) === "columnUsingPath")) == null ? void 0 : u.contents
|
|
2155
|
+
};
|
|
2156
|
+
c != null && c.find((p) => (p == null ? void 0 : p.key) === (o == null ? void 0 : o.key)) ? c = c == null ? void 0 : c.map((p) => ((p == null ? void 0 : p.key) === (o == null ? void 0 : o.key) && (p.value = o.value), p)) : c.push(o), de.setTableViewContents(c);
|
|
2157
|
+
}
|
|
2158
|
+
Pa(t.itemData, t.allMapContents);
|
|
2159
|
+
},
|
|
2160
|
+
{ deep: !0, immediate: !0 }
|
|
2161
|
+
), Fe(() => t == null ? void 0 : t.operatingForm, (e) => {
|
|
2162
|
+
e != null && e.form && (Cl(e == null ? void 0 : e.form), We.value = e == null ? void 0 : e.dialogTitle, zl.value = !0, Ze.value = !0);
|
|
2163
|
+
}, { immediate: !0, deep: !0 });
|
|
2164
|
+
const Ka = () => {
|
|
2165
|
+
il.value = !il.value;
|
|
2166
|
+
}, zr = () => {
|
|
2167
|
+
Gl.value = !Gl.value;
|
|
2168
|
+
};
|
|
2169
|
+
Fe(() => il.value, (e) => {
|
|
2170
|
+
e ? (da("viewChange"), de.setCacheUpdatingData(null)) : (hl.value = sl.value, B.value = ze.value, ml.value && (de.setTableLoading(t == null ? void 0 : t.index), M("change", ml.value)));
|
|
2171
|
+
}, { immediate: !0 }), Fe(() => {
|
|
2172
|
+
var e;
|
|
2173
|
+
return (e = Sa.value) == null ? void 0 : e.length;
|
|
2174
|
+
}, (e) => {
|
|
2175
|
+
e === 0 && (Ae.currentPage = 1);
|
|
2176
|
+
}), R(!1);
|
|
2177
|
+
const Jr = (e, l) => {
|
|
2178
|
+
var r;
|
|
2179
|
+
da("createClick"), l === Ae.pageSize && (Ae.currentPage = Math.ceil(((r = Z.value) == null ? void 0 : r.length) / Ae.pageSize));
|
|
2180
|
+
}, Wr = (e, l, r) => {
|
|
2181
|
+
var a;
|
|
2182
|
+
Ea(r, e, l), Ee.value = J(e), Qe.value = e == null ? void 0 : e.id, gl.value = (a = Z.value) == null ? void 0 : a.length, We.value = typeof (e == null ? void 0 : e.id) == "string" ? "新增" : "编辑", El(!1);
|
|
2183
|
+
}, De = (e) => {
|
|
2184
|
+
var p, b, s, T, v, m, C, D, S, w;
|
|
2185
|
+
const { row: l, column: r, item: a, slotData: n } = e;
|
|
2186
|
+
let u = l != null && l[r == null ? void 0 : r.prop] || (l == null ? void 0 : l[r == null ? void 0 : r.prop]) === 0 ? ((b = (p = l == null ? void 0 : l[r == null ? void 0 : r.prop]) == null ? void 0 : p[0]) == null ? void 0 : b.contents) ?? ((l == null ? void 0 : l[r == null ? void 0 : r.prop]) === 0 ? "0" : l == null ? void 0 : l[r == null ? void 0 : r.prop]) : ((T = (s = l == null ? void 0 : l[a == null ? void 0 : a.prop]) == null ? void 0 : s[0]) == null ? void 0 : T.contents) ?? (l == null ? void 0 : l[a == null ? void 0 : a.prop]) ?? ((m = (v = n == null ? void 0 : n[a == null ? void 0 : a.prop]) == null ? void 0 : v[0]) == null ? void 0 : m.contents) ?? (n == null ? void 0 : n[a == null ? void 0 : a.prop]) ?? ((S = (D = l == null ? void 0 : l[(C = a == null ? void 0 : a.child) == null ? void 0 : C.prop]) == null ? void 0 : D[0]) == null ? void 0 : S.contents) ?? (l == null ? void 0 : l[(w = a == null ? void 0 : a.child) == null ? void 0 : w.prop]), o = Array.isArray(u) && !(u != null && u.every((_) => typeof _ == "string" || typeof _ == "number")) ? "查看" : u;
|
|
2187
|
+
return o = Array.isArray(o) ? o.join(",") : o, o;
|
|
2188
|
+
}, Gr = (e) => {
|
|
2189
|
+
var b, s, T, v, m, C, D, S, w, _;
|
|
2190
|
+
const { row: l, column: r, item: a, slotData: n } = e;
|
|
2191
|
+
let u = l != null && l[r == null ? void 0 : r.prop] ? ((s = (b = l == null ? void 0 : l[r == null ? void 0 : r.prop]) == null ? void 0 : b[0]) == null ? void 0 : s.contents) ?? (l == null ? void 0 : l[r == null ? void 0 : r.prop]) : ((v = (T = l == null ? void 0 : l[a == null ? void 0 : a.prop]) == null ? void 0 : T[0]) == null ? void 0 : v.contents) ?? (l == null ? void 0 : l[a == null ? void 0 : a.prop]) ?? ((C = (m = n == null ? void 0 : n[a == null ? void 0 : a.prop]) == null ? void 0 : m[0]) == null ? void 0 : C.contents) ?? (n == null ? void 0 : n[a == null ? void 0 : a.prop]) ?? ((w = (S = l == null ? void 0 : l[(D = a == null ? void 0 : a.child) == null ? void 0 : D.prop]) == null ? void 0 : S[0]) == null ? void 0 : w.contents) ?? (l == null ? void 0 : l[(_ = a == null ? void 0 : a.child) == null ? void 0 : _.prop]);
|
|
2192
|
+
const o = Array.isArray(u) && !(u != null && u.every((x) => typeof x == "string" || typeof x == "number")), p = Array.isArray(u) && (u == null ? void 0 : u.find((x) => x == null ? void 0 : x.url));
|
|
2193
|
+
return o && p;
|
|
2194
|
+
}, Rr = (e, l) => e.find((r) => Object.values(r).some((a) => a === l));
|
|
2195
|
+
return Fe(() => Xe.value, async (e) => {
|
|
2196
|
+
if (e) {
|
|
2197
|
+
ye.setContentLoading(!0), await Il();
|
|
2198
|
+
const l = Rr(Z.value, e == null ? void 0 : e.data);
|
|
2199
|
+
if (!l) return ye.setContentLoading(!1);
|
|
2200
|
+
await Ta(e == null ? void 0 : e.data, null, l, { data: e == null ? void 0 : e.data, isMainKey: !0 }), ye.setContentLoading(!1);
|
|
2201
|
+
}
|
|
2202
|
+
}, { deep: !0, immediate: !0 }), Fe(() => t == null ? void 0 : t.cacheNewData, (e) => {
|
|
2203
|
+
var l;
|
|
2204
|
+
e && (Array.isArray(e) || (e == null ? void 0 : e.compId) === (t == null ? void 0 : t.index) && (Z.value = (l = Z.value) == null ? void 0 : l.map((r) => {
|
|
2205
|
+
var a;
|
|
2206
|
+
return (r == null ? void 0 : r.id) === ((a = e == null ? void 0 : e.data) == null ? void 0 : a.id) ? {
|
|
2207
|
+
...r,
|
|
2208
|
+
id: e == null ? void 0 : e.resId
|
|
2209
|
+
} : r;
|
|
2210
|
+
})));
|
|
2211
|
+
}, { immediate: !0, deep: !0 }), (e, l) => {
|
|
2212
|
+
var b, s, T;
|
|
2213
|
+
const r = Ke("svg-icon"), a = Ke("el-popover"), n = Ke("el-switch"), u = Ke("el-checkbox"), c = Ke("el-checkbox-group"), o = Ke("el-button"), p = Ke("LookComponent");
|
|
2214
|
+
return ne(), Te("div", Hn, [
|
|
2215
|
+
ba.value ? (ne(), $e(sn, {
|
|
2216
|
+
id: "excel-table",
|
|
2217
|
+
pageObj: Ae,
|
|
2218
|
+
summaryInfo: al,
|
|
2219
|
+
columns: B.value,
|
|
2220
|
+
defaultSort: ke,
|
|
2221
|
+
isCardViewport: Gl.value,
|
|
2222
|
+
checkedColumns: Q.value,
|
|
2223
|
+
key: sa.value + JSON.stringify(B.value),
|
|
2224
|
+
tableData: Sa.value,
|
|
2225
|
+
isEditViewport: il.value,
|
|
2226
|
+
isShowPagination: va.value,
|
|
2227
|
+
isShowEdit: !1,
|
|
2228
|
+
isShowDelete: !1,
|
|
2229
|
+
allowSelect: K.allowSelect,
|
|
2230
|
+
onDbClickRow: Tr,
|
|
2231
|
+
extraButton: hl.value,
|
|
2232
|
+
rowButton: nl.value,
|
|
2233
|
+
cacheExtraButtons: sl.value,
|
|
2234
|
+
isClearSelection: ((b = Re.value) == null ? void 0 : b.length) === 0,
|
|
2235
|
+
onDoCurrentChange: nr,
|
|
2236
|
+
onDoSizeChange: sr,
|
|
2237
|
+
onContentClick: Ta,
|
|
2238
|
+
onRowClick: Ur,
|
|
2239
|
+
onSelectChange: pr,
|
|
2240
|
+
onCellChange: Wr,
|
|
2241
|
+
onChange: Ea,
|
|
2242
|
+
onPreview: ka,
|
|
2243
|
+
onSubmitEditingTable: dr,
|
|
2244
|
+
onHandleColEditChange: tr,
|
|
2245
|
+
onHandleColTypeChange: cr,
|
|
2246
|
+
onClickButton: Xl
|
|
2247
|
+
}, Yr({
|
|
2248
|
+
headerButton: re((v) => {
|
|
2249
|
+
var m, C;
|
|
2250
|
+
return [
|
|
2251
|
+
K.showHeader ? (ne(), $e(jn, {
|
|
2252
|
+
key: 0,
|
|
2253
|
+
lockingPage: Ye(Ml) === Ye(se),
|
|
2254
|
+
filterValues: ma.value,
|
|
2255
|
+
selectNums: (m = Re.value) == null ? void 0 : m.length,
|
|
2256
|
+
dataNums: (C = Z.value) == null ? void 0 : C.length,
|
|
2257
|
+
compName: K.compName,
|
|
2258
|
+
isDevMode: K.isDevMode,
|
|
2259
|
+
buttons: v.buttons,
|
|
2260
|
+
onButtonClick: l[0] || (l[0] = (D) => Xl(D, "", {})),
|
|
2261
|
+
columns: B.value,
|
|
2262
|
+
onFilter: mr,
|
|
2263
|
+
onGetImportData: ir,
|
|
2264
|
+
level: K.level
|
|
2265
|
+
}, null, 8, ["lockingPage", "filterValues", "selectNums", "dataNums", "compName", "isDevMode", "buttons", "columns", "level"])) : Le("", !0)
|
|
2266
|
+
];
|
|
2267
|
+
}),
|
|
2268
|
+
viewport: re(() => {
|
|
2269
|
+
var v, m;
|
|
2270
|
+
return [
|
|
2271
|
+
((v = Z.value) == null ? void 0 : v.length) > 0 && K.allowOperate ? (ne(), Te("div", Yn, [
|
|
2272
|
+
(m = nl.value) != null && m.some((C) => (C == null ? void 0 : C.label) === "编辑") && !Gl.value && Ye(Ml) !== Ye(se) ? (ne(), Te("span", {
|
|
2273
|
+
key: 0,
|
|
2274
|
+
title: "编辑表格",
|
|
2275
|
+
onClick: Ka
|
|
2276
|
+
}, [
|
|
2277
|
+
ie(r, {
|
|
2278
|
+
name: "editTable",
|
|
2279
|
+
class: "view-icon"
|
|
2280
|
+
})
|
|
2281
|
+
])) : Le("", !0),
|
|
2282
|
+
ve("span", {
|
|
2283
|
+
title: "卡片视图",
|
|
2284
|
+
onClick: zr
|
|
2285
|
+
}, [
|
|
2286
|
+
ie(r, {
|
|
2287
|
+
name: "cardViewport",
|
|
2288
|
+
class: "view-icon"
|
|
2289
|
+
})
|
|
2290
|
+
])
|
|
2291
|
+
])) : Le("", !0)
|
|
2292
|
+
];
|
|
2293
|
+
}),
|
|
2294
|
+
rowCreate: re(({ row: v, index: m }) => [
|
|
2295
|
+
ve("span", {
|
|
2296
|
+
title: "新增",
|
|
2297
|
+
class: "row-create-wrap",
|
|
2298
|
+
onClick: (C) => Jr(v, m)
|
|
2299
|
+
}, [
|
|
2300
|
+
ie(r, {
|
|
2301
|
+
name: "rowCreate",
|
|
2302
|
+
style: { width: "10px", height: "10px" }
|
|
2303
|
+
})
|
|
2304
|
+
], 8, Zn)
|
|
2305
|
+
]),
|
|
2306
|
+
operateCol: re(() => [
|
|
2307
|
+
ie(a, {
|
|
2308
|
+
title: "选择显示列信息",
|
|
2309
|
+
placement: "left-start",
|
|
2310
|
+
"popper-class": "menu-operate-popover",
|
|
2311
|
+
trigger: "hover",
|
|
2312
|
+
onShow: Br
|
|
2313
|
+
}, {
|
|
2314
|
+
reference: re(() => [
|
|
2315
|
+
ve("span", Vn, [
|
|
2316
|
+
ie(r, {
|
|
2317
|
+
name: "operate",
|
|
2318
|
+
style: { width: "15px", height: "15px", cursor: "pointer" }
|
|
2319
|
+
})
|
|
2320
|
+
])
|
|
2321
|
+
]),
|
|
2322
|
+
default: re(() => [
|
|
2323
|
+
ve("div", In, [
|
|
2324
|
+
l[11] || (l[11] = ve("div", { class: "group-title" }, "表格操作", -1)),
|
|
2325
|
+
ie(n, {
|
|
2326
|
+
"model-value": Be.value,
|
|
2327
|
+
"active-text": "排序",
|
|
2328
|
+
"inactive-text": "",
|
|
2329
|
+
style: { "margin-right": "8px" },
|
|
2330
|
+
onChange: l[2] || (l[2] = (v) => ia(v, "sortable"))
|
|
2331
|
+
}, null, 8, ["model-value"]),
|
|
2332
|
+
ie(n, {
|
|
2333
|
+
"model-value": ll.value,
|
|
2334
|
+
"active-text": "筛选",
|
|
2335
|
+
"inactive-text": "",
|
|
2336
|
+
style: { "margin-right": "8px" },
|
|
2337
|
+
onChange: l[3] || (l[3] = (v) => ia(v, "filterable"))
|
|
2338
|
+
}, null, 8, ["model-value"]),
|
|
2339
|
+
ie(n, {
|
|
2340
|
+
"model-value": Ue.value,
|
|
2341
|
+
"active-text": "编辑所有表头",
|
|
2342
|
+
"inactive-text": "",
|
|
2343
|
+
onChange: l[4] || (l[4] = (v) => ia(v, "operable"))
|
|
2344
|
+
}, null, 8, ["model-value"]),
|
|
2345
|
+
l[12] || (l[12] = ve("div", { class: "group-title" }, "表格列操作", -1)),
|
|
2346
|
+
ie(c, {
|
|
2347
|
+
modelValue: Q.value,
|
|
2348
|
+
"onUpdate:modelValue": l[5] || (l[5] = (v) => Q.value = v),
|
|
2349
|
+
style: { height: "100%" },
|
|
2350
|
+
min: 2,
|
|
2351
|
+
ref_key: "checkboxGroupRef",
|
|
2352
|
+
ref: L
|
|
2353
|
+
}, {
|
|
2354
|
+
default: re(() => [
|
|
2355
|
+
(ne(!0), Te(cl, null, dl(_l.value, (v) => (ne(), Te("div", {
|
|
2356
|
+
style: { display: "flex", "align-items": "center" },
|
|
2357
|
+
key: v.label
|
|
2358
|
+
}, [
|
|
2359
|
+
ie(u, {
|
|
2360
|
+
value: v.label,
|
|
2361
|
+
style: { width: "100%", marginRight: 0 }
|
|
2362
|
+
}, {
|
|
2363
|
+
default: re(() => [
|
|
2364
|
+
ve("span", {
|
|
2365
|
+
title: v.label,
|
|
2366
|
+
style: { display: "inline-block", width: "250px", overflow: "hidden", "text-overflow": "ellipsis", "white-space": "nowrap" }
|
|
2367
|
+
}, Ce(v.label), 9, es)
|
|
2368
|
+
]),
|
|
2369
|
+
_: 2
|
|
2370
|
+
}, 1032, ["value"]),
|
|
2371
|
+
ie(a, {
|
|
2372
|
+
title: "列操作",
|
|
2373
|
+
placement: "left",
|
|
2374
|
+
teleported: !1,
|
|
2375
|
+
trigger: "hover"
|
|
2376
|
+
}, {
|
|
2377
|
+
reference: re(() => [
|
|
2378
|
+
ie(r, {
|
|
2379
|
+
name: "colOperate",
|
|
2380
|
+
style: { width: "15px", height: "15px", cursor: "pointer", color: "grey", position: "absolute", right: "40px" }
|
|
2381
|
+
})
|
|
2382
|
+
]),
|
|
2383
|
+
default: re(() => {
|
|
2384
|
+
var m;
|
|
2385
|
+
return [
|
|
2386
|
+
ve("div", ls, [
|
|
2387
|
+
(ne(!0), Te(cl, null, dl((m = Object.keys(v)) == null ? void 0 : m.filter((C) => {
|
|
2388
|
+
var D;
|
|
2389
|
+
return (D = le.value) == null ? void 0 : D.find((S) => (S == null ? void 0 : S.value) === C);
|
|
2390
|
+
}), (C) => {
|
|
2391
|
+
var D, S;
|
|
2392
|
+
return ne(), Te("div", { key: C }, [
|
|
2393
|
+
ie(n, {
|
|
2394
|
+
"model-value": v == null ? void 0 : v[C],
|
|
2395
|
+
"active-text": (S = (D = le.value) == null ? void 0 : D.find((w) => (w == null ? void 0 : w.value) === C)) == null ? void 0 : S.label,
|
|
2396
|
+
onChange: (w) => gr(w, C, v)
|
|
2397
|
+
}, null, 8, ["model-value", "active-text", "onChange"])
|
|
2398
|
+
]);
|
|
2399
|
+
}), 128))
|
|
2400
|
+
])
|
|
2401
|
+
];
|
|
2402
|
+
}),
|
|
2403
|
+
_: 2
|
|
2404
|
+
}, 1024),
|
|
2405
|
+
ve("span", as, [
|
|
2406
|
+
ie(r, {
|
|
2407
|
+
name: "drag",
|
|
2408
|
+
class: "col-drag-icon",
|
|
2409
|
+
style: { width: "15px", height: "15px" }
|
|
2410
|
+
})
|
|
2411
|
+
])
|
|
2412
|
+
]))), 128))
|
|
2413
|
+
]),
|
|
2414
|
+
_: 1
|
|
2415
|
+
}, 8, ["modelValue"])
|
|
2416
|
+
])
|
|
2417
|
+
]),
|
|
2418
|
+
_: 1
|
|
2419
|
+
})
|
|
2420
|
+
]),
|
|
2421
|
+
content: re((v) => {
|
|
2422
|
+
var m, C, D, S, w, _, x, k, f, g, i, h, $, A, X, I, Y, W;
|
|
2423
|
+
return [
|
|
2424
|
+
Gr(v) ? (ne(), $e(a, {
|
|
2425
|
+
key: 0,
|
|
2426
|
+
"popper-class": "file-popover",
|
|
2427
|
+
placement: "right",
|
|
2428
|
+
trigger: "hover",
|
|
2429
|
+
effect: "light",
|
|
2430
|
+
width: "auto"
|
|
2431
|
+
}, {
|
|
2432
|
+
reference: re(() => [
|
|
2433
|
+
ve("span", rs, Ce(De(v)), 1)
|
|
2434
|
+
]),
|
|
2435
|
+
default: re(() => {
|
|
2436
|
+
var H;
|
|
2437
|
+
return [
|
|
2438
|
+
ve("div", ns, [
|
|
2439
|
+
(ne(!0), Te(cl, null, dl(v == null ? void 0 : v.row[(H = v == null ? void 0 : v.column) == null ? void 0 : H.prop], (O) => (ne(), Te("div", ss, [
|
|
2440
|
+
ve("div", {
|
|
2441
|
+
class: "prop-url",
|
|
2442
|
+
title: Hl(O),
|
|
2443
|
+
onClick: (P) => vr(O)
|
|
2444
|
+
}, Ce(Hl(O)), 9, us),
|
|
2445
|
+
ve("div", {
|
|
2446
|
+
class: "prop-download",
|
|
2447
|
+
onClick: (P) => br(O)
|
|
2448
|
+
}, " 下载 ", 8, is)
|
|
2449
|
+
]))), 256))
|
|
2450
|
+
])
|
|
2451
|
+
];
|
|
2452
|
+
}),
|
|
2453
|
+
_: 2
|
|
2454
|
+
}, 1024)) : (ne(), Te("div", {
|
|
2455
|
+
key: 1,
|
|
2456
|
+
style: kl({
|
|
2457
|
+
color: !Array.isArray(De(v)) && ((C = (m = De(v)) == null ? void 0 : m.toString()) != null && C.includes(".txt") || (S = (D = De(v)) == null ? void 0 : D.toString()) != null && S.includes(".cpt") || (_ = (w = De(v)) == null ? void 0 : w.toString()) != null && _.includes(".cyd")) ? "var(--vertical-menuitem-active-bg)" : "",
|
|
2458
|
+
textDecoration: !Array.isArray(De(v)) && ((k = (x = De(v)) == null ? void 0 : x.toString()) != null && k.includes(".txt") || (g = (f = De(v)) == null ? void 0 : f.toString()) != null && g.includes(".cpt") || (h = (i = De(v)) == null ? void 0 : i.toString()) != null && h.includes(".cyd")) ? "underline" : "",
|
|
2459
|
+
cursor: !Array.isArray(De(v)) && ((A = ($ = De(v)) == null ? void 0 : $.toString()) != null && A.includes(".txt") || (I = (X = De(v)) == null ? void 0 : X.toString()) != null && I.includes(".cpt") || (W = (Y = De(v)) == null ? void 0 : Y.toString()) != null && W.includes(".cyd")) ? "pointer" : "",
|
|
2460
|
+
marginLeft: (v == null ? void 0 : v.colIndex) === 0 ? `${((v == null ? void 0 : v.level) ?? 0) * 20}px` : 0
|
|
2461
|
+
}),
|
|
2462
|
+
onClick: (H) => rr(De(v))
|
|
2463
|
+
}, Ce(De(v) === 0 ? "0" : De(v)), 13, os))
|
|
2464
|
+
];
|
|
2465
|
+
}),
|
|
2466
|
+
_: 2
|
|
2467
|
+
}, [
|
|
2468
|
+
((s = nl.value) == null ? void 0 : s.length) > 0 && Ye(Ml) !== Ye(se) ? {
|
|
2469
|
+
name: "actions",
|
|
2470
|
+
fn: re(({ item: v }) => [
|
|
2471
|
+
ie(a, {
|
|
2472
|
+
title: "",
|
|
2473
|
+
placement: "left-start",
|
|
2474
|
+
"popper-class": "menu-operate-popover"
|
|
2475
|
+
}, {
|
|
2476
|
+
reference: re(() => [
|
|
2477
|
+
ie(r, {
|
|
2478
|
+
name: "more",
|
|
2479
|
+
style: { cursor: "pointer", width: "15px", height: "15px" }
|
|
2480
|
+
})
|
|
2481
|
+
]),
|
|
2482
|
+
default: re(() => [
|
|
2483
|
+
ve("div", Xn, [
|
|
2484
|
+
(ne(!0), Te(cl, null, dl(Sr(nl.value, v), (m, C) => (ne(), Te("div", {
|
|
2485
|
+
class: "menu-config-item",
|
|
2486
|
+
key: C,
|
|
2487
|
+
onClick: (D) => Xl(m == null ? void 0 : m.label, v, { extra: m })
|
|
2488
|
+
}, [
|
|
2489
|
+
ve("div", {
|
|
2490
|
+
style: kl({ color: m == null ? void 0 : m.textColor }),
|
|
2491
|
+
class: "extra-button-label"
|
|
2492
|
+
}, Ce(m == null ? void 0 : m.label), 5)
|
|
2493
|
+
], 8, Qn))), 128))
|
|
2494
|
+
])
|
|
2495
|
+
]),
|
|
2496
|
+
_: 2
|
|
2497
|
+
}, 1024)
|
|
2498
|
+
]),
|
|
2499
|
+
key: "0"
|
|
2500
|
+
} : void 0,
|
|
2501
|
+
((T = Z.value) == null ? void 0 : T.length) > 0 ? {
|
|
2502
|
+
name: "batchButton",
|
|
2503
|
+
fn: re((v) => [
|
|
2504
|
+
ie(Kn, {
|
|
2505
|
+
lockingPage: Ye(Ml) === Ye(se),
|
|
2506
|
+
buttons: v.buttons,
|
|
2507
|
+
selectTableItems: Re.value,
|
|
2508
|
+
onButtonClick: l[1] || (l[1] = (m) => Xl(m, "", {}))
|
|
2509
|
+
}, null, 8, ["lockingPage", "buttons", "selectTableItems"])
|
|
2510
|
+
]),
|
|
2511
|
+
key: "1"
|
|
2512
|
+
} : void 0
|
|
2513
|
+
]), 1032, ["pageObj", "summaryInfo", "columns", "defaultSort", "isCardViewport", "checkedColumns", "tableData", "isEditViewport", "isShowPagination", "allowSelect", "extraButton", "rowButton", "cacheExtraButtons", "isClearSelection"])) : Le("", !0),
|
|
2514
|
+
ie(Vl, {
|
|
2515
|
+
title: We.value,
|
|
2516
|
+
visible: Ze.value,
|
|
2517
|
+
width: er.value,
|
|
2518
|
+
onBeforeDestroy: hr,
|
|
2519
|
+
style: { height: "74%" }
|
|
2520
|
+
}, {
|
|
2521
|
+
default: re(() => [
|
|
2522
|
+
ve("div", ts, [
|
|
2523
|
+
ie(la, {
|
|
2524
|
+
rowContents: Ve.value,
|
|
2525
|
+
isEnableWrap: !1,
|
|
2526
|
+
showOperator: !1,
|
|
2527
|
+
onChange: Mr,
|
|
2528
|
+
onClickTrigger: yr,
|
|
2529
|
+
isEdit: ra.value,
|
|
2530
|
+
onBlurChange: fr
|
|
2531
|
+
}, null, 8, ["rowContents", "isEdit"])
|
|
2532
|
+
])
|
|
2533
|
+
]),
|
|
2534
|
+
footer: re(() => [
|
|
2535
|
+
zl.value ? (ne(), Te("div", cs, [
|
|
2536
|
+
ie(o, {
|
|
2537
|
+
onClick: l[6] || (l[6] = (v) => Ze.value = !1),
|
|
2538
|
+
id: "themeBorderButton"
|
|
2539
|
+
}, {
|
|
2540
|
+
default: re(() => l[13] || (l[13] = [
|
|
2541
|
+
el(Ce("取消"))
|
|
2542
|
+
])),
|
|
2543
|
+
_: 1,
|
|
2544
|
+
__: [13]
|
|
2545
|
+
}),
|
|
2546
|
+
ie(o, {
|
|
2547
|
+
class: "ok-button",
|
|
2548
|
+
onClick: l[7] || (l[7] = (v) => El(!0)),
|
|
2549
|
+
id: "themeButton"
|
|
2550
|
+
}, {
|
|
2551
|
+
default: re(() => l[14] || (l[14] = [
|
|
2552
|
+
el(Ce("确认"))
|
|
2553
|
+
])),
|
|
2554
|
+
_: 1,
|
|
2555
|
+
__: [14]
|
|
2556
|
+
})
|
|
2557
|
+
])) : Le("", !0)
|
|
2558
|
+
]),
|
|
2559
|
+
_: 1
|
|
2560
|
+
}, 8, ["title", "visible", "width"]),
|
|
2561
|
+
ie(Vl, {
|
|
2562
|
+
title: We.value,
|
|
2563
|
+
visible: Fl.value,
|
|
2564
|
+
width: na.value,
|
|
2565
|
+
onBeforeDestroy: l[9] || (l[9] = (v) => Fl.value = !1)
|
|
2566
|
+
}, {
|
|
2567
|
+
default: re(() => [
|
|
2568
|
+
ie(Fn)
|
|
2569
|
+
]),
|
|
2570
|
+
footer: re(() => [
|
|
2571
|
+
ve("div", ds, [
|
|
2572
|
+
ie(o, {
|
|
2573
|
+
onClick: l[8] || (l[8] = (v) => Fl.value = !1),
|
|
2574
|
+
class: "cancel-button",
|
|
2575
|
+
id: "themeBorderButton"
|
|
2576
|
+
}, {
|
|
2577
|
+
default: re(() => l[15] || (l[15] = [
|
|
2578
|
+
el(Ce("取消"))
|
|
2579
|
+
])),
|
|
2580
|
+
_: 1,
|
|
2581
|
+
__: [15]
|
|
2582
|
+
}),
|
|
2583
|
+
ie(o, {
|
|
2584
|
+
class: "ok-button",
|
|
2585
|
+
onClick: _r,
|
|
2586
|
+
id: "themeButton"
|
|
2587
|
+
}, {
|
|
2588
|
+
default: re(() => l[16] || (l[16] = [
|
|
2589
|
+
el(Ce("确认"))
|
|
2590
|
+
])),
|
|
2591
|
+
_: 1,
|
|
2592
|
+
__: [16]
|
|
2593
|
+
})
|
|
2594
|
+
])
|
|
2595
|
+
]),
|
|
2596
|
+
_: 1
|
|
2597
|
+
}, 8, ["title", "visible", "width"]),
|
|
2598
|
+
Je.value ? (ne(), $e(un, {
|
|
2599
|
+
key: 1,
|
|
2600
|
+
fileDataList: z.value,
|
|
2601
|
+
onDestroy: Ar
|
|
2602
|
+
}, null, 8, ["fileDataList"])) : Le("", !0),
|
|
2603
|
+
me.value ? (ne(), $e(Vl, {
|
|
2604
|
+
key: 2,
|
|
2605
|
+
visible: me.value,
|
|
2606
|
+
onBeforeDestroy: Kr,
|
|
2607
|
+
style: { height: "80vh", width: "80vw" },
|
|
2608
|
+
"body-class": "three-dialog-body",
|
|
2609
|
+
"footer-class": "three-dialog-footer"
|
|
2610
|
+
}, {
|
|
2611
|
+
default: re(() => [
|
|
2612
|
+
ie(cn, {
|
|
2613
|
+
"file-urls": Al.value,
|
|
2614
|
+
isThreeScene: Pe.value,
|
|
2615
|
+
isSelfWindow: !0,
|
|
2616
|
+
threeData: pl.value
|
|
2617
|
+
}, null, 8, ["file-urls", "isThreeScene", "threeData"])
|
|
2618
|
+
]),
|
|
2619
|
+
_: 1
|
|
2620
|
+
}, 8, ["visible"])) : Le("", !0),
|
|
2621
|
+
ie(Vl, {
|
|
2622
|
+
visible: e.componentVisible,
|
|
2623
|
+
onBeforeDestroy: l[10] || (l[10] = (v) => e.componentVisible = !1),
|
|
2624
|
+
width: na.value,
|
|
2625
|
+
style: { height: "70vh" }
|
|
2626
|
+
}, {
|
|
2627
|
+
default: re(() => [
|
|
2628
|
+
ie(p, { dialogItem: Rl.value }, null, 8, ["dialogItem"])
|
|
2629
|
+
]),
|
|
2630
|
+
_: 1
|
|
2631
|
+
}, 8, ["visible", "width"])
|
|
2632
|
+
]);
|
|
2633
|
+
};
|
|
2634
|
+
}
|
|
2635
|
+
}, Os = /* @__PURE__ */ aa(ps, [["__scopeId", "data-v-666b2bd5"]]);
|
|
2636
|
+
export {
|
|
2637
|
+
qn as a,
|
|
2638
|
+
$n as b,
|
|
2639
|
+
Wa as f,
|
|
2640
|
+
Ga as g,
|
|
2641
|
+
Os as s,
|
|
2642
|
+
zn as u
|
|
2643
|
+
};
|