joy-admin-components 0.2.16 → 0.2.19
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/joy-admin-components.es.js +1106 -992
- package/dist/joy-admin-components.umd.js +2 -2
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,194 +1,194 @@
|
|
|
1
|
-
import { ElForm as
|
|
2
|
-
import { defineComponent as
|
|
3
|
-
import { saveAs as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import { createI18n as
|
|
7
|
-
import { debounce as
|
|
8
|
-
import { useRoute as
|
|
9
|
-
import { createNamespacedHelpers as
|
|
10
|
-
import { VxeUI as
|
|
11
|
-
const
|
|
1
|
+
import { ElForm as _t, ElRow as $t, ElCol as St, ElMessageBox as Et, ElInputNumber as It, ElText as Lt, ElLink as Je } from "element-plus";
|
|
2
|
+
import { defineComponent as ot, ref as R, onMounted as lt, h as Te, mergeModels as Xe, useAttrs as Ft, useModel as Tt, computed as re, watch as Pe, resolveComponent as z, unref as H, openBlock as L, createBlock as B, mergeProps as he, createSlots as at, withCtx as D, createElementVNode as ae, toDisplayString as J, renderSlot as X, createVNode as q, createTextVNode as Q, createCommentVNode as ce, createElementBlock as se, Fragment as Oe, renderList as rt, withModifiers as Me, nextTick as Se, resolveDynamicComponent as st, withKeys as Dt, normalizeStyle as zt, normalizeClass as Ve, reactive as $e, onUpdated as Ot, onUnmounted as Mt, withDirectives as Vt, isVNode as qt } from "vue";
|
|
3
|
+
import { saveAs as it } from "file-saver";
|
|
4
|
+
import Ee from "exceljs";
|
|
5
|
+
import ke from "dayjs";
|
|
6
|
+
import { createI18n as At, useI18n as me } from "vue-i18n";
|
|
7
|
+
import { debounce as Re, cloneDeep as ct, isArray as Qe } from "lodash";
|
|
8
|
+
import { useRoute as jt, useRouter as Ut } from "vue-router";
|
|
9
|
+
import { createNamespacedHelpers as Be, useStore as ut, mapState as Pt, mapGetters as Rt, mapActions as Bt } from "vuex";
|
|
10
|
+
import { VxeUI as xe } from "vxe-pc-ui";
|
|
11
|
+
const Vn = ot({
|
|
12
12
|
name: "LayOutForm",
|
|
13
|
-
setup(t, { slots: e, attrs: n, emit:
|
|
14
|
-
const
|
|
15
|
-
(
|
|
16
|
-
var
|
|
17
|
-
return
|
|
18
|
-
|
|
19
|
-
{ span: ((
|
|
13
|
+
setup(t, { slots: e, attrs: n, emit: a }) {
|
|
14
|
+
const r = R(null), o = () => e.default ? e.default().filter((s) => s.type !== Symbol.for("v-cmt")).map((s) => s.type === Symbol.for("v-fgt") ? s.children : s).flat().map(
|
|
15
|
+
(s) => {
|
|
16
|
+
var i;
|
|
17
|
+
return Te(
|
|
18
|
+
St,
|
|
19
|
+
{ span: ((i = s.props) == null ? void 0 : i.span) || 24 },
|
|
20
20
|
{
|
|
21
|
-
default: () =>
|
|
21
|
+
default: () => s
|
|
22
22
|
}
|
|
23
23
|
);
|
|
24
24
|
}
|
|
25
25
|
) : null;
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
lt(() => {
|
|
27
|
+
a("ref", r.value);
|
|
28
28
|
});
|
|
29
|
-
function
|
|
30
|
-
return
|
|
31
|
-
|
|
32
|
-
{ ...n, ref:
|
|
33
|
-
() =>
|
|
29
|
+
function l() {
|
|
30
|
+
return Te(
|
|
31
|
+
_t,
|
|
32
|
+
{ ...n, ref: r },
|
|
33
|
+
() => Te($t, { gutter: n.gutter ?? 20 }, { default: () => o() })
|
|
34
34
|
);
|
|
35
35
|
}
|
|
36
|
-
return
|
|
36
|
+
return l;
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
|
-
var
|
|
40
|
-
function
|
|
39
|
+
var dt = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
40
|
+
function ft(t) {
|
|
41
41
|
return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
|
|
42
42
|
}
|
|
43
|
-
var
|
|
43
|
+
var ht = { exports: {} };
|
|
44
44
|
(function(t, e) {
|
|
45
|
-
(function(n,
|
|
46
|
-
t.exports =
|
|
47
|
-
})(
|
|
48
|
-
var n = "minute",
|
|
49
|
-
return function(o,
|
|
50
|
-
var
|
|
51
|
-
|
|
52
|
-
var
|
|
53
|
-
return new
|
|
54
|
-
},
|
|
55
|
-
var
|
|
56
|
-
return
|
|
57
|
-
},
|
|
58
|
-
return
|
|
45
|
+
(function(n, a) {
|
|
46
|
+
t.exports = a();
|
|
47
|
+
})(dt, function() {
|
|
48
|
+
var n = "minute", a = /[+-]\d\d(?::?\d\d)?/g, r = /([+-]|\d\d)/g;
|
|
49
|
+
return function(o, l, s) {
|
|
50
|
+
var i = l.prototype;
|
|
51
|
+
s.utc = function(u) {
|
|
52
|
+
var h = { date: u, utc: !0, args: arguments };
|
|
53
|
+
return new l(h);
|
|
54
|
+
}, i.utc = function(u) {
|
|
55
|
+
var h = s(this.toDate(), { locale: this.$L, utc: !0 });
|
|
56
|
+
return u ? h.add(this.utcOffset(), n) : h;
|
|
57
|
+
}, i.local = function() {
|
|
58
|
+
return s(this.toDate(), { locale: this.$L, utc: !1 });
|
|
59
59
|
};
|
|
60
|
-
var
|
|
61
|
-
|
|
62
|
-
|
|
60
|
+
var v = i.parse;
|
|
61
|
+
i.parse = function(u) {
|
|
62
|
+
u.utc && (this.$u = !0), this.$utils().u(u.$offset) || (this.$offset = u.$offset), v.call(this, u);
|
|
63
63
|
};
|
|
64
|
-
var
|
|
65
|
-
|
|
64
|
+
var w = i.init;
|
|
65
|
+
i.init = function() {
|
|
66
66
|
if (this.$u) {
|
|
67
|
-
var
|
|
68
|
-
this.$y =
|
|
67
|
+
var u = this.$d;
|
|
68
|
+
this.$y = u.getUTCFullYear(), this.$M = u.getUTCMonth(), this.$D = u.getUTCDate(), this.$W = u.getUTCDay(), this.$H = u.getUTCHours(), this.$m = u.getUTCMinutes(), this.$s = u.getUTCSeconds(), this.$ms = u.getUTCMilliseconds();
|
|
69
69
|
} else
|
|
70
|
-
|
|
70
|
+
w.call(this);
|
|
71
71
|
};
|
|
72
|
-
var
|
|
73
|
-
|
|
74
|
-
var
|
|
75
|
-
if (
|
|
76
|
-
return this.$u ? 0 :
|
|
77
|
-
if (typeof
|
|
72
|
+
var b = i.utcOffset;
|
|
73
|
+
i.utcOffset = function(u, h) {
|
|
74
|
+
var k = this.$utils().u;
|
|
75
|
+
if (k(u))
|
|
76
|
+
return this.$u ? 0 : k(this.$offset) ? b.call(this) : this.$offset;
|
|
77
|
+
if (typeof u == "string" && (u = function(E) {
|
|
78
78
|
E === void 0 && (E = "");
|
|
79
|
-
var
|
|
80
|
-
if (!
|
|
79
|
+
var Y = E.match(a);
|
|
80
|
+
if (!Y)
|
|
81
81
|
return null;
|
|
82
|
-
var
|
|
83
|
-
return
|
|
84
|
-
}(
|
|
82
|
+
var F = ("" + Y[0]).match(r) || ["-", 0, 0], d = F[0], x = 60 * +F[1] + +F[2];
|
|
83
|
+
return x === 0 ? 0 : d === "+" ? x : -x;
|
|
84
|
+
}(u), u === null))
|
|
85
85
|
return this;
|
|
86
|
-
var
|
|
87
|
-
if (
|
|
88
|
-
return this.utc(
|
|
89
|
-
var
|
|
90
|
-
if (
|
|
91
|
-
return
|
|
92
|
-
var
|
|
93
|
-
return (
|
|
86
|
+
var _ = Math.abs(u) <= 16 ? 60 * u : u;
|
|
87
|
+
if (_ === 0)
|
|
88
|
+
return this.utc(h);
|
|
89
|
+
var C = this.clone();
|
|
90
|
+
if (h)
|
|
91
|
+
return C.$offset = _, C.$u = !1, C;
|
|
92
|
+
var S = this.$u ? this.toDate().getTimezoneOffset() : -1 * this.utcOffset();
|
|
93
|
+
return (C = this.local().add(_ + S, n)).$offset = _, C.$x.$localOffset = S, C;
|
|
94
94
|
};
|
|
95
|
-
var
|
|
96
|
-
|
|
97
|
-
var
|
|
98
|
-
return
|
|
99
|
-
},
|
|
100
|
-
var
|
|
101
|
-
return this.$d.valueOf() - 6e4 *
|
|
102
|
-
},
|
|
95
|
+
var p = i.format;
|
|
96
|
+
i.format = function(u) {
|
|
97
|
+
var h = u || (this.$u ? "YYYY-MM-DDTHH:mm:ss[Z]" : "");
|
|
98
|
+
return p.call(this, h);
|
|
99
|
+
}, i.valueOf = function() {
|
|
100
|
+
var u = this.$utils().u(this.$offset) ? 0 : this.$offset + (this.$x.$localOffset || this.$d.getTimezoneOffset());
|
|
101
|
+
return this.$d.valueOf() - 6e4 * u;
|
|
102
|
+
}, i.isUTC = function() {
|
|
103
103
|
return !!this.$u;
|
|
104
|
-
},
|
|
104
|
+
}, i.toISOString = function() {
|
|
105
105
|
return this.toDate().toISOString();
|
|
106
|
-
},
|
|
106
|
+
}, i.toString = function() {
|
|
107
107
|
return this.toDate().toUTCString();
|
|
108
108
|
};
|
|
109
|
-
var g =
|
|
110
|
-
|
|
111
|
-
return
|
|
109
|
+
var g = i.toDate;
|
|
110
|
+
i.toDate = function(u) {
|
|
111
|
+
return u === "s" && this.$offset ? s(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate() : g.call(this);
|
|
112
112
|
};
|
|
113
|
-
var
|
|
114
|
-
|
|
115
|
-
if (
|
|
116
|
-
return
|
|
117
|
-
var
|
|
118
|
-
return
|
|
113
|
+
var m = i.diff;
|
|
114
|
+
i.diff = function(u, h, k) {
|
|
115
|
+
if (u && this.$u === u.$u)
|
|
116
|
+
return m.call(this, u, h, k);
|
|
117
|
+
var _ = this.local(), C = s(u).local();
|
|
118
|
+
return m.call(_, C, h, k);
|
|
119
119
|
};
|
|
120
120
|
};
|
|
121
121
|
});
|
|
122
|
-
})(
|
|
123
|
-
var
|
|
124
|
-
const
|
|
125
|
-
var
|
|
122
|
+
})(ht);
|
|
123
|
+
var Yt = ht.exports;
|
|
124
|
+
const Kt = /* @__PURE__ */ ft(Yt);
|
|
125
|
+
var mt = { exports: {} };
|
|
126
126
|
(function(t, e) {
|
|
127
|
-
(function(n,
|
|
128
|
-
t.exports =
|
|
129
|
-
})(
|
|
130
|
-
var n = { year: 0, month: 1, day: 2, hour: 3, minute: 4, second: 5 },
|
|
131
|
-
return function(
|
|
132
|
-
var
|
|
133
|
-
|
|
134
|
-
var
|
|
135
|
-
|
|
136
|
-
var
|
|
137
|
-
return E || (E = new Intl.DateTimeFormat("en-US", { hour12: !1, timeZone:
|
|
138
|
-
}(g,
|
|
139
|
-
return
|
|
140
|
-
},
|
|
141
|
-
for (var
|
|
142
|
-
var
|
|
143
|
-
|
|
127
|
+
(function(n, a) {
|
|
128
|
+
t.exports = a();
|
|
129
|
+
})(dt, function() {
|
|
130
|
+
var n = { year: 0, month: 1, day: 2, hour: 3, minute: 4, second: 5 }, a = {};
|
|
131
|
+
return function(r, o, l) {
|
|
132
|
+
var s, i = function(p, g, m) {
|
|
133
|
+
m === void 0 && (m = {});
|
|
134
|
+
var u = new Date(p), h = function(k, _) {
|
|
135
|
+
_ === void 0 && (_ = {});
|
|
136
|
+
var C = _.timeZoneName || "short", S = k + "|" + C, E = a[S];
|
|
137
|
+
return E || (E = new Intl.DateTimeFormat("en-US", { hour12: !1, timeZone: k, year: "numeric", month: "2-digit", day: "2-digit", hour: "2-digit", minute: "2-digit", second: "2-digit", timeZoneName: C }), a[S] = E), E;
|
|
138
|
+
}(g, m);
|
|
139
|
+
return h.formatToParts(u);
|
|
140
|
+
}, v = function(p, g) {
|
|
141
|
+
for (var m = i(p, g), u = [], h = 0; h < m.length; h += 1) {
|
|
142
|
+
var k = m[h], _ = k.type, C = k.value, S = n[_];
|
|
143
|
+
S >= 0 && (u[S] = parseInt(C, 10));
|
|
144
144
|
}
|
|
145
|
-
var E =
|
|
146
|
-
return (
|
|
147
|
-
},
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
var
|
|
151
|
-
if (!Number(
|
|
152
|
-
|
|
153
|
-
else if (
|
|
154
|
-
var
|
|
155
|
-
|
|
145
|
+
var E = u[3], Y = E === 24 ? 0 : E, F = u[0] + "-" + u[1] + "-" + u[2] + " " + Y + ":" + u[4] + ":" + u[5] + ":000", d = +p;
|
|
146
|
+
return (l.utc(F).valueOf() - (d -= d % 1e3)) / 6e4;
|
|
147
|
+
}, w = o.prototype;
|
|
148
|
+
w.tz = function(p, g) {
|
|
149
|
+
p === void 0 && (p = s);
|
|
150
|
+
var m, u = this.utcOffset(), h = this.toDate(), k = h.toLocaleString("en-US", { timeZone: p }), _ = Math.round((h - new Date(k)) / 1e3 / 60), C = 15 * -Math.round(h.getTimezoneOffset() / 15) - _;
|
|
151
|
+
if (!Number(C))
|
|
152
|
+
m = this.utcOffset(0, g);
|
|
153
|
+
else if (m = l(k, { locale: this.$L }).$set("millisecond", this.$ms).utcOffset(C, !0), g) {
|
|
154
|
+
var S = m.utcOffset();
|
|
155
|
+
m = m.add(u - S, "minute");
|
|
156
156
|
}
|
|
157
|
-
return
|
|
158
|
-
},
|
|
159
|
-
var g = this.$x.$timezone ||
|
|
160
|
-
return
|
|
157
|
+
return m.$x.$timezone = p, m;
|
|
158
|
+
}, w.offsetName = function(p) {
|
|
159
|
+
var g = this.$x.$timezone || l.tz.guess(), m = i(this.valueOf(), g, { timeZoneName: p }).find(function(u) {
|
|
160
|
+
return u.type.toLowerCase() === "timezonename";
|
|
161
161
|
});
|
|
162
|
-
return
|
|
162
|
+
return m && m.value;
|
|
163
163
|
};
|
|
164
|
-
var
|
|
165
|
-
|
|
164
|
+
var b = w.startOf;
|
|
165
|
+
w.startOf = function(p, g) {
|
|
166
166
|
if (!this.$x || !this.$x.$timezone)
|
|
167
|
-
return
|
|
168
|
-
var
|
|
169
|
-
return
|
|
170
|
-
},
|
|
171
|
-
var
|
|
172
|
-
if (typeof
|
|
173
|
-
return
|
|
174
|
-
var
|
|
175
|
-
var
|
|
176
|
-
if (
|
|
177
|
-
return [
|
|
178
|
-
var
|
|
179
|
-
return
|
|
180
|
-
}(
|
|
181
|
-
return E.$x.$timezone =
|
|
182
|
-
},
|
|
167
|
+
return b.call(this, p, g);
|
|
168
|
+
var m = l(this.format("YYYY-MM-DD HH:mm:ss:SSS"), { locale: this.$L });
|
|
169
|
+
return b.call(m, p, g).tz(this.$x.$timezone, !0);
|
|
170
|
+
}, l.tz = function(p, g, m) {
|
|
171
|
+
var u = m && g, h = m || g || s, k = v(+l(), h);
|
|
172
|
+
if (typeof p != "string")
|
|
173
|
+
return l(p).tz(h);
|
|
174
|
+
var _ = function(Y, F, d) {
|
|
175
|
+
var x = Y - 60 * F * 1e3, O = v(x, d);
|
|
176
|
+
if (F === O)
|
|
177
|
+
return [x, F];
|
|
178
|
+
var A = v(x -= 60 * (O - F) * 1e3, d);
|
|
179
|
+
return O === A ? [x, O] : [Y - 60 * Math.min(O, A) * 1e3, Math.max(O, A)];
|
|
180
|
+
}(l.utc(p, u).valueOf(), k, h), C = _[0], S = _[1], E = l(C).utcOffset(S);
|
|
181
|
+
return E.$x.$timezone = h, E;
|
|
182
|
+
}, l.tz.guess = function() {
|
|
183
183
|
return Intl.DateTimeFormat().resolvedOptions().timeZone;
|
|
184
|
-
},
|
|
185
|
-
|
|
184
|
+
}, l.tz.setDefault = function(p) {
|
|
185
|
+
s = p;
|
|
186
186
|
};
|
|
187
187
|
};
|
|
188
188
|
});
|
|
189
|
-
})(
|
|
190
|
-
var
|
|
191
|
-
const
|
|
189
|
+
})(mt);
|
|
190
|
+
var Ht = mt.exports;
|
|
191
|
+
const Nt = /* @__PURE__ */ ft(Ht), qe = {
|
|
192
192
|
// 组件通用文本
|
|
193
193
|
"dao-ru": "导入",
|
|
194
194
|
"quan-xuan": "全选",
|
|
@@ -206,6 +206,7 @@ const Kt = /* @__PURE__ */ ut(Yt), Ve = {
|
|
|
206
206
|
"ti-jiao": "提交",
|
|
207
207
|
"que-ding": "确定",
|
|
208
208
|
"que-ding-guan-bi-ma": "确定关闭吗",
|
|
209
|
+
"xia-zai-dao-ru-mo-ban": "下载导入模板",
|
|
209
210
|
// Excel 工具相关
|
|
210
211
|
excel: {
|
|
211
212
|
fieldsMappingRequired: "请输入列字段映射",
|
|
@@ -222,7 +223,7 @@ const Kt = /* @__PURE__ */ ut(Yt), Ve = {
|
|
|
222
223
|
tools: {
|
|
223
224
|
keysLengthError: "keys 长度必须大于2 默认前两位为 label value"
|
|
224
225
|
}
|
|
225
|
-
},
|
|
226
|
+
}, Ae = {
|
|
226
227
|
// Common component text
|
|
227
228
|
"dao-ru": "Import",
|
|
228
229
|
"quan-xuan": "Select All",
|
|
@@ -240,6 +241,7 @@ const Kt = /* @__PURE__ */ ut(Yt), Ve = {
|
|
|
240
241
|
"ti-jiao": "Submit",
|
|
241
242
|
"que-ding": "Confirm",
|
|
242
243
|
"que-ding-guan-bi-ma": "Are you sure to close?",
|
|
244
|
+
"xia-zai-dao-ru-mo-ban": "Download Import Template",
|
|
243
245
|
// Excel utilities
|
|
244
246
|
excel: {
|
|
245
247
|
fieldsMappingRequired: "Please enter column field mapping",
|
|
@@ -256,137 +258,237 @@ const Kt = /* @__PURE__ */ ut(Yt), Ve = {
|
|
|
256
258
|
tools: {
|
|
257
259
|
keysLengthError: "Keys length must be greater than 2, default first two are label and value"
|
|
258
260
|
}
|
|
259
|
-
},
|
|
260
|
-
zh_cn:
|
|
261
|
-
en_us:
|
|
261
|
+
}, Wt = {
|
|
262
|
+
zh_cn: qe,
|
|
263
|
+
en_us: Ae
|
|
262
264
|
};
|
|
263
265
|
let ye = null;
|
|
264
|
-
function
|
|
266
|
+
function Zt(t = null) {
|
|
265
267
|
if (t) {
|
|
266
268
|
const { global: e } = t;
|
|
267
|
-
return e.messages.value.zh_cn ? e.mergeLocaleMessage("zh_cn",
|
|
269
|
+
return e.messages.value.zh_cn ? e.mergeLocaleMessage("zh_cn", qe) : e.setLocaleMessage("zh_cn", qe), e.messages.value.en_us ? e.mergeLocaleMessage("en_us", Ae) : e.setLocaleMessage("en_us", Ae), ye = t, t;
|
|
268
270
|
}
|
|
269
|
-
return ye || (ye =
|
|
271
|
+
return ye || (ye = At({
|
|
270
272
|
legacy: !1,
|
|
271
273
|
locale: "zh_cn",
|
|
272
274
|
fallbackLocale: "zh_cn",
|
|
273
|
-
messages:
|
|
275
|
+
messages: Wt
|
|
274
276
|
})), ye;
|
|
275
277
|
}
|
|
276
|
-
function
|
|
277
|
-
return ye ||
|
|
278
|
+
function Ye() {
|
|
279
|
+
return ye || Zt();
|
|
278
280
|
}
|
|
279
|
-
function
|
|
280
|
-
return
|
|
281
|
+
function ve() {
|
|
282
|
+
return Ye().global.t;
|
|
281
283
|
}
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
async function
|
|
285
|
-
const { fields: n, range:
|
|
284
|
+
ke.extend(Kt);
|
|
285
|
+
ke.extend(Nt);
|
|
286
|
+
async function qn(t, e) {
|
|
287
|
+
const { fields: n, range: a = 1 } = e;
|
|
286
288
|
if (!n) {
|
|
287
|
-
const
|
|
288
|
-
throw new Error(
|
|
289
|
+
const l = ve();
|
|
290
|
+
throw new Error(l("excel.fieldsMappingRequired"));
|
|
289
291
|
}
|
|
290
|
-
let
|
|
291
|
-
await
|
|
292
|
+
let r = new Ee.Workbook();
|
|
293
|
+
await r.xlsx.load(t);
|
|
292
294
|
const o = {};
|
|
293
|
-
return
|
|
294
|
-
const
|
|
295
|
-
|
|
296
|
-
if (
|
|
297
|
-
let
|
|
295
|
+
return r.eachSheet(function(l, s) {
|
|
296
|
+
const i = [];
|
|
297
|
+
l.eachRow(function(v, w) {
|
|
298
|
+
if (w > a) {
|
|
299
|
+
let b = {}, p = !0;
|
|
298
300
|
Object.keys(n).forEach((g) => {
|
|
299
|
-
const
|
|
300
|
-
|
|
301
|
-
}),
|
|
301
|
+
const m = v.getCell(n[g]).value;
|
|
302
|
+
b[g] = m, m && (p = !1);
|
|
303
|
+
}), p || i.push(b);
|
|
302
304
|
}
|
|
303
|
-
}), o[
|
|
304
|
-
}),
|
|
305
|
+
}), o[l._name] = i;
|
|
306
|
+
}), r = null, o;
|
|
305
307
|
}
|
|
306
|
-
const
|
|
308
|
+
const gt = {
|
|
307
309
|
columnWidth: 30
|
|
308
310
|
};
|
|
309
|
-
async function
|
|
311
|
+
async function An(t, e, n = [], a = {}) {
|
|
310
312
|
if (!t || !e)
|
|
311
313
|
return;
|
|
312
|
-
const { columnStyle:
|
|
313
|
-
e.forEach((
|
|
314
|
-
|
|
314
|
+
const { columnStyle: r } = a, { columnWidth: o } = gt;
|
|
315
|
+
e.forEach((i) => {
|
|
316
|
+
i.width = i.width ? i.width : o;
|
|
315
317
|
});
|
|
316
|
-
const { workbook:
|
|
317
|
-
|
|
318
|
+
const { workbook: l, worksheet: s } = Gt();
|
|
319
|
+
s.columns = e, s.addRows(n), r && await Jt(l, s, r);
|
|
318
320
|
try {
|
|
319
|
-
const
|
|
321
|
+
const i = await l.xlsx.writeBuffer(), v = new File([i], t, {
|
|
320
322
|
type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
|
|
321
323
|
});
|
|
322
|
-
|
|
323
|
-
} catch (
|
|
324
|
-
console.log(
|
|
324
|
+
it(v);
|
|
325
|
+
} catch (i) {
|
|
326
|
+
console.log(i);
|
|
325
327
|
}
|
|
326
328
|
}
|
|
327
|
-
function
|
|
328
|
-
const t = new
|
|
329
|
+
function Gt() {
|
|
330
|
+
const t = new Ee.Workbook();
|
|
329
331
|
t.creator = "distributor System", t.lastModifiedBy = "distributor System", t.created = /* @__PURE__ */ new Date(), t.modified = /* @__PURE__ */ new Date(), t.lastPrinted = /* @__PURE__ */ new Date();
|
|
330
332
|
const e = t.addWorksheet("Sheet1");
|
|
331
333
|
return { workbook: t, worksheet: e };
|
|
332
334
|
}
|
|
333
335
|
async function Jt(t, e, n) {
|
|
334
|
-
const
|
|
335
|
-
for (const
|
|
336
|
-
const o = n[
|
|
337
|
-
switch (
|
|
336
|
+
const a = Object.keys(n);
|
|
337
|
+
for (const r of a) {
|
|
338
|
+
const o = n[r], { type: l } = o;
|
|
339
|
+
switch (l) {
|
|
338
340
|
case "IMG":
|
|
339
|
-
await Xt(t, e,
|
|
341
|
+
await Xt(t, e, r);
|
|
340
342
|
break;
|
|
341
343
|
}
|
|
342
344
|
}
|
|
343
345
|
}
|
|
344
|
-
async function Xt(t, e, n,
|
|
345
|
-
const
|
|
346
|
-
e.getColumn(n).width = 20, e.eachRow((
|
|
347
|
-
|
|
346
|
+
async function Xt(t, e, n, a) {
|
|
347
|
+
const r = e.getColumn(n), o = r.values;
|
|
348
|
+
e.getColumn(n).width = 20, e.eachRow((l, s) => {
|
|
349
|
+
s > 1 && (l.height = 40);
|
|
348
350
|
});
|
|
349
|
-
for (let
|
|
350
|
-
if (
|
|
351
|
+
for (let l = 0, s = o.length; l < s; l++) {
|
|
352
|
+
if (l < 2)
|
|
351
353
|
continue;
|
|
352
|
-
let
|
|
353
|
-
|
|
354
|
+
let i = o[l];
|
|
355
|
+
i && (e.getCell(r.letter + l).value = "", await Qt(t, e, i, {
|
|
354
356
|
width: 100,
|
|
355
357
|
height: 50,
|
|
356
|
-
col:
|
|
357
|
-
row:
|
|
358
|
+
col: r._number - 1,
|
|
359
|
+
row: l - 1
|
|
358
360
|
}));
|
|
359
361
|
}
|
|
360
362
|
}
|
|
361
|
-
async function Qt(t, e, n,
|
|
362
|
-
const { col:
|
|
363
|
-
if (
|
|
364
|
-
const
|
|
365
|
-
base64:
|
|
363
|
+
async function Qt(t, e, n, a) {
|
|
364
|
+
const { col: r, row: o, width: l, height: s } = a, { success: i, base64: v } = await en(n, 0.3);
|
|
365
|
+
if (i) {
|
|
366
|
+
const w = t.addImage({
|
|
367
|
+
base64: v,
|
|
366
368
|
extension: "jpeg"
|
|
367
369
|
});
|
|
368
|
-
e.addImage(
|
|
369
|
-
tl: { col:
|
|
370
|
-
ext: { width:
|
|
370
|
+
e.addImage(w, {
|
|
371
|
+
tl: { col: r, row: o },
|
|
372
|
+
ext: { width: l, height: s }
|
|
371
373
|
});
|
|
372
374
|
}
|
|
373
375
|
}
|
|
374
376
|
function en(t, e = 1) {
|
|
375
377
|
const n = new Image();
|
|
376
|
-
return n.setAttribute("crossOrigin", "anonymous"), n.crossOrigin = "anonymous", n.src = t, new Promise((
|
|
378
|
+
return n.setAttribute("crossOrigin", "anonymous"), n.crossOrigin = "anonymous", n.src = t, new Promise((a, r) => {
|
|
377
379
|
n.onload = () => {
|
|
378
380
|
const o = document.createElement("canvas");
|
|
379
|
-
o.width = n.width, o.height = n.height, o.getContext("2d").drawImage(n, 0, 0, o.width, o.height),
|
|
381
|
+
o.width = n.width, o.height = n.height, o.getContext("2d").drawImage(n, 0, 0, o.width, o.height), a({
|
|
380
382
|
success: !0,
|
|
381
383
|
//canvas.toDataURL的方法将图片的绝对路径转换为base64编码
|
|
382
384
|
base64: o.toDataURL("image/jpeg", e)
|
|
383
385
|
});
|
|
384
386
|
}, n.onerror = () => {
|
|
385
|
-
|
|
387
|
+
a({ success: !1 });
|
|
386
388
|
};
|
|
387
389
|
});
|
|
388
390
|
}
|
|
389
|
-
|
|
391
|
+
const je = "---";
|
|
392
|
+
async function tn(t, e) {
|
|
393
|
+
const { fields: n, range: a = 1 } = e;
|
|
394
|
+
if (!n) {
|
|
395
|
+
const l = ve();
|
|
396
|
+
throw new Error(l("excel.fieldsMappingRequired"));
|
|
397
|
+
}
|
|
398
|
+
let r = new Ee.Workbook();
|
|
399
|
+
await r.xlsx.load(t);
|
|
400
|
+
const o = {};
|
|
401
|
+
return r.eachSheet(function(l, s) {
|
|
402
|
+
if (l.state == "visible") {
|
|
403
|
+
const i = [], v = n[l._name];
|
|
404
|
+
if (v) {
|
|
405
|
+
let w = Object.values(v).some((p) => p.includes("image")), b = {};
|
|
406
|
+
w && (l.getImages().forEach((g) => {
|
|
407
|
+
const { tl: m } = g.range, u = r.model.media.find((h) => h.index === g.imageId);
|
|
408
|
+
if (u) {
|
|
409
|
+
const h = u.buffer.toString("base64"), k = `data:image/${u.extension};base64,${h}`, _ = `${Math.ceil(m.row)}_${Math.ceil(m.col)}`;
|
|
410
|
+
b[_] ? b[_].push(k) : b[_] = [k];
|
|
411
|
+
}
|
|
412
|
+
}), console.log("withImages-imageMap", b)), l.eachRow(function(p, g) {
|
|
413
|
+
if (g > a) {
|
|
414
|
+
let m = {}, u = !0;
|
|
415
|
+
Object.keys(v).forEach((h) => {
|
|
416
|
+
var E;
|
|
417
|
+
let [k, _] = v[h].split(je);
|
|
418
|
+
const C = p.getCell(k);
|
|
419
|
+
let S;
|
|
420
|
+
if (_ == "image" && w) {
|
|
421
|
+
const Y = C._column._number, F = `${g}_${Y}`;
|
|
422
|
+
S = b[F] || "";
|
|
423
|
+
} else
|
|
424
|
+
C.result != null ? S = C.result : (E = C.value) != null && E.richText ? S = C.value.richText.reduce((Y, F) => Y + F.text, "") : C.type == 4 && C.value ? S = ke(C.value).utc().format("YYYY-MM-DD HH:mm:ss") : S = C.value;
|
|
425
|
+
S && _ == "option" && (S = S.split(je)[1]), m[h] = S, S && (u = !1);
|
|
426
|
+
}), u || i.push(m);
|
|
427
|
+
}
|
|
428
|
+
}), o[l._name] = i;
|
|
429
|
+
}
|
|
430
|
+
}
|
|
431
|
+
}), r = null, o;
|
|
432
|
+
}
|
|
433
|
+
async function nn(t, e) {
|
|
434
|
+
if (!t || e.length == 0)
|
|
435
|
+
return;
|
|
436
|
+
const n = on(e);
|
|
437
|
+
n.eachSheet(function(a, r) {
|
|
438
|
+
const { columnWidth: o } = gt, { tableHeader: l, tableData: s } = e[a._name];
|
|
439
|
+
l.forEach((i) => {
|
|
440
|
+
if (i.required) {
|
|
441
|
+
const v = i.style || {}, { font: w = {} } = v;
|
|
442
|
+
i.style = {
|
|
443
|
+
...v,
|
|
444
|
+
font: {
|
|
445
|
+
...w,
|
|
446
|
+
color: {
|
|
447
|
+
argb: "FFFF0000"
|
|
448
|
+
}
|
|
449
|
+
}
|
|
450
|
+
};
|
|
451
|
+
}
|
|
452
|
+
}), a.columns = l, a.addRows(s), l.forEach((i) => {
|
|
453
|
+
const { header: v, key: w, width: b, option: p } = i, g = a.getColumn(w);
|
|
454
|
+
if (g.width = b || o, p) {
|
|
455
|
+
const m = n.addWorksheet(w);
|
|
456
|
+
m.state = "hidden", m.getColumn(1).values = p.map((u) => `${u.label}${je}${u.value}`), Array(100).fill("").forEach((u, h) => {
|
|
457
|
+
if (h > 0) {
|
|
458
|
+
const k = ve();
|
|
459
|
+
a.getCell(`${g.letter}${h}`).dataValidation = {
|
|
460
|
+
type: "list",
|
|
461
|
+
formulae: [`${w}!$A$1:$A$${p.length}`],
|
|
462
|
+
showErrorMessage: !0,
|
|
463
|
+
error: k("excel.invalidInput"),
|
|
464
|
+
errorStyle: "stop",
|
|
465
|
+
errorMessage: k("excel.invalidOption")
|
|
466
|
+
};
|
|
467
|
+
}
|
|
468
|
+
});
|
|
469
|
+
}
|
|
470
|
+
});
|
|
471
|
+
});
|
|
472
|
+
try {
|
|
473
|
+
const a = await n.xlsx.writeBuffer(), r = new File([a], t, {
|
|
474
|
+
type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
|
|
475
|
+
});
|
|
476
|
+
it(r);
|
|
477
|
+
} catch (a) {
|
|
478
|
+
console.log(a);
|
|
479
|
+
}
|
|
480
|
+
}
|
|
481
|
+
function on(t) {
|
|
482
|
+
const e = ve(), n = new Ee.Workbook();
|
|
483
|
+
return n.creator = "distributor System", n.lastModifiedBy = "distributor System", n.created = /* @__PURE__ */ new Date(), n.modified = /* @__PURE__ */ new Date(), n.lastPrinted = /* @__PURE__ */ new Date(), Object.keys(t).sort((r, o) => {
|
|
484
|
+
const l = t[r].sort ?? 0, s = t[o].sort ?? 0;
|
|
485
|
+
return l - s;
|
|
486
|
+
}).forEach((r) => {
|
|
487
|
+
let o = r, l = !1;
|
|
488
|
+
/[\\/:*?\[\]]/g.test(r) && (r = r.replace(/[\\/:*?\[\]]/g, ""), l = !0), r.length > 31 && (r = r.substring(0, 31).trim(), l = !0, console.warn(e("excel.sheetNameTooLong", [o, r]))), l && (t[r] = t[o], delete t[o]), n.addWorksheet(r);
|
|
489
|
+
}), n;
|
|
490
|
+
}
|
|
491
|
+
function ln(t) {
|
|
390
492
|
if (t < 26)
|
|
391
493
|
return String.fromCharCode(65 + t);
|
|
392
494
|
{
|
|
@@ -394,48 +496,48 @@ function tn(t) {
|
|
|
394
496
|
return e + n;
|
|
395
497
|
}
|
|
396
498
|
}
|
|
397
|
-
function
|
|
499
|
+
function jn(t) {
|
|
398
500
|
return new Promise((e) => {
|
|
399
501
|
setTimeout(() => {
|
|
400
502
|
e();
|
|
401
503
|
}, t);
|
|
402
504
|
});
|
|
403
505
|
}
|
|
404
|
-
function
|
|
506
|
+
function Un(t) {
|
|
405
507
|
return JSON.parse(JSON.stringify(t));
|
|
406
508
|
}
|
|
407
|
-
function
|
|
408
|
-
let e = [], n = {},
|
|
409
|
-
for (const
|
|
410
|
-
n[
|
|
411
|
-
...
|
|
509
|
+
function Pn(t) {
|
|
510
|
+
let e = [], n = {}, a = (r, o) => Object.prototype.hasOwnProperty.call(r, o);
|
|
511
|
+
for (const r of t) {
|
|
512
|
+
n[r.id] = {
|
|
513
|
+
...r,
|
|
412
514
|
// 判断当前项的子项 如果map有存储就用存储的子项 否则初始化
|
|
413
|
-
children:
|
|
515
|
+
children: a(n, r.id) ? n[r.id].children : []
|
|
414
516
|
};
|
|
415
|
-
const o = n[
|
|
416
|
-
|
|
517
|
+
const o = n[r.id];
|
|
518
|
+
r.pid == -1 ? e.push(o) : (a(n, r.pid) || (n[r.pid] = {
|
|
417
519
|
children: []
|
|
418
|
-
}), n[
|
|
520
|
+
}), n[r.pid].children.push(o));
|
|
419
521
|
}
|
|
420
522
|
return e;
|
|
421
523
|
}
|
|
422
|
-
function
|
|
524
|
+
function pt(t, e = " ") {
|
|
423
525
|
return t ? t.split(e).filter((n) => n.trim()) : [];
|
|
424
526
|
}
|
|
425
|
-
class
|
|
527
|
+
class et {
|
|
426
528
|
constructor(e, n = ["label", "value", "labelEn"]) {
|
|
427
|
-
this.list = e.map((
|
|
428
|
-
...
|
|
429
|
-
label:
|
|
430
|
-
labelEn:
|
|
431
|
-
value:
|
|
432
|
-
})), this.map = new Map(this.list.map((
|
|
529
|
+
this.list = e.map((a) => ({
|
|
530
|
+
...a,
|
|
531
|
+
label: a[n[0]],
|
|
532
|
+
labelEn: a[n[2]] || a[n[0]] || "",
|
|
533
|
+
value: a[n[1]]
|
|
534
|
+
})), this.map = new Map(this.list.map((a) => [a[n[1]], a]));
|
|
433
535
|
}
|
|
434
536
|
getName(e) {
|
|
435
537
|
if (!this.has(e))
|
|
436
538
|
return "-";
|
|
437
|
-
const n =
|
|
438
|
-
return (n.value == "zh_cn" ?
|
|
539
|
+
const n = Ye().global.locale, { label: a, labelEn: r } = this.map.get(e);
|
|
540
|
+
return (n.value == "zh_cn" ? a : r) || a || "-";
|
|
439
541
|
}
|
|
440
542
|
getTag(e) {
|
|
441
543
|
if (!this.has(e))
|
|
@@ -456,52 +558,52 @@ class Xe {
|
|
|
456
558
|
return this.map.has(e);
|
|
457
559
|
}
|
|
458
560
|
}
|
|
459
|
-
function
|
|
561
|
+
function Rn(t, e = [], n = "i18nName") {
|
|
460
562
|
if (t.length == 0)
|
|
461
|
-
return new
|
|
563
|
+
return new et([]);
|
|
462
564
|
if (e.length < 2) {
|
|
463
|
-
const
|
|
464
|
-
throw new Error(
|
|
565
|
+
const r = ve();
|
|
566
|
+
throw new Error(r("tools.keysLengthError"));
|
|
465
567
|
}
|
|
466
|
-
let
|
|
568
|
+
let a = t.map((r) => {
|
|
467
569
|
let o = {};
|
|
468
|
-
return n && (o.labelEn =
|
|
469
|
-
|
|
570
|
+
return n && (o.labelEn = r[n]), e.forEach((l, s) => {
|
|
571
|
+
s === 0 ? o.label = r[l] : s === 1 ? o.value = r[l] : o[l] = r[l];
|
|
470
572
|
}), o;
|
|
471
573
|
});
|
|
472
|
-
return new
|
|
574
|
+
return new et(a);
|
|
473
575
|
}
|
|
474
|
-
function
|
|
576
|
+
function Bn(t) {
|
|
475
577
|
return t ? t.replace(/<[^>]+>/g, "") : "";
|
|
476
578
|
}
|
|
477
|
-
function
|
|
579
|
+
function Yn(t) {
|
|
478
580
|
return t ? (t.includes("\\\\u") && (t = t.replace(/\\/g, "")), t.replace(/\\u[\dA-F]{4}/gi, (e) => String.fromCharCode(parseInt(e.replace(/\\u/g, ""), 16)))) : "";
|
|
479
581
|
}
|
|
480
|
-
function
|
|
582
|
+
function Kn(t, e = 10) {
|
|
481
583
|
let n = 1048576 * e;
|
|
482
584
|
return !(t.size > n);
|
|
483
585
|
}
|
|
484
|
-
function
|
|
485
|
-
return Array.from(10).fill(0).map((n,
|
|
586
|
+
function Hn(t) {
|
|
587
|
+
return Array.from(10).fill(0).map((n, a) => t + "_" + a);
|
|
486
588
|
}
|
|
487
|
-
function
|
|
589
|
+
function Nn(t) {
|
|
488
590
|
let e = {};
|
|
489
|
-
return t.map((n,
|
|
490
|
-
let { key:
|
|
491
|
-
o ? e[
|
|
591
|
+
return t.map((n, a) => {
|
|
592
|
+
let { key: r, option: o, type: l } = n, s = ln(a);
|
|
593
|
+
o ? e[r] = `${s}---option` : l === "image" ? e[r] = `${s}---image` : e[r] = s;
|
|
492
594
|
}), e;
|
|
493
595
|
}
|
|
494
|
-
function
|
|
495
|
-
return e.split(".").reduce((n,
|
|
596
|
+
function Wn(t, e) {
|
|
597
|
+
return e.split(".").reduce((n, a) => n && n[a], t);
|
|
496
598
|
}
|
|
497
|
-
const
|
|
599
|
+
const _e = (t, e) => {
|
|
498
600
|
const n = t.__vccOpts || t;
|
|
499
|
-
for (const [
|
|
500
|
-
n[
|
|
601
|
+
for (const [a, r] of e)
|
|
602
|
+
n[a] = r;
|
|
501
603
|
return n;
|
|
502
|
-
},
|
|
604
|
+
}, an = ["onClick"], rn = {
|
|
503
605
|
__name: "index",
|
|
504
|
-
props: /* @__PURE__ */
|
|
606
|
+
props: /* @__PURE__ */ Xe({
|
|
505
607
|
api: {
|
|
506
608
|
type: Function
|
|
507
609
|
},
|
|
@@ -537,128 +639,128 @@ const xe = (t, e) => {
|
|
|
537
639
|
modelValue: {},
|
|
538
640
|
modelModifiers: {}
|
|
539
641
|
}),
|
|
540
|
-
emits: /* @__PURE__ */
|
|
642
|
+
emits: /* @__PURE__ */ Xe(["success", "change", "changeAll"], ["update:modelValue"]),
|
|
541
643
|
setup(t, { emit: e }) {
|
|
542
|
-
const n = t,
|
|
543
|
-
if (
|
|
644
|
+
const n = t, a = Ft(), { t: r, locale: o } = me(), l = Tt(t, "modelValue"), s = re(() => a["value-key"] != null), i = R(""), v = re(() => {
|
|
645
|
+
if (a.remote !== void 0)
|
|
544
646
|
return n.data;
|
|
545
|
-
const
|
|
546
|
-
if (
|
|
547
|
-
return
|
|
548
|
-
const { label: oe, labelEn: ue } =
|
|
549
|
-
let
|
|
550
|
-
return
|
|
551
|
-
(ie) => ie[
|
|
552
|
-
) :
|
|
647
|
+
const d = pt(i.value), { data: x, labelValue: O } = n, A = x || p.value;
|
|
648
|
+
if (d.length == 0)
|
|
649
|
+
return A;
|
|
650
|
+
const { label: oe, labelEn: ue } = O;
|
|
651
|
+
let y = o.value == "en_us" ? ue || "i18nName" : oe;
|
|
652
|
+
return d.length == 1 ? A.filter(
|
|
653
|
+
(ie) => ie[y].toLowerCase().includes(d[0].toLowerCase())
|
|
654
|
+
) : A.filter((ie) => {
|
|
553
655
|
let pe = !1;
|
|
554
|
-
return pe =
|
|
555
|
-
(
|
|
656
|
+
return pe = d.some(
|
|
657
|
+
(be) => ie[y].toLowerCase() == be.toLowerCase()
|
|
556
658
|
), pe;
|
|
557
659
|
});
|
|
558
|
-
}),
|
|
660
|
+
}), w = re({
|
|
559
661
|
get() {
|
|
560
|
-
return
|
|
662
|
+
return a.multiple == null || l.value == null ? !1 : l.value.length == v.value.length;
|
|
561
663
|
},
|
|
562
|
-
set(
|
|
563
|
-
return
|
|
664
|
+
set(d) {
|
|
665
|
+
return d;
|
|
564
666
|
}
|
|
565
|
-
}),
|
|
566
|
-
const { data:
|
|
567
|
-
|
|
667
|
+
}), b = e, p = R([]), g = async () => {
|
|
668
|
+
const { data: d } = await n.api();
|
|
669
|
+
p.value = [...d], b("success", p);
|
|
568
670
|
};
|
|
569
671
|
n.api && g();
|
|
570
|
-
function
|
|
571
|
-
|
|
672
|
+
function m(d) {
|
|
673
|
+
b("change", d);
|
|
572
674
|
}
|
|
573
|
-
const
|
|
574
|
-
if (
|
|
675
|
+
const u = n.labelValue.label.split("-"), h = (d) => {
|
|
676
|
+
if (u.length == 1) {
|
|
575
677
|
if (n.changeLocal)
|
|
576
|
-
return
|
|
577
|
-
let
|
|
578
|
-
return
|
|
678
|
+
return r(d[n.labelValue.label]);
|
|
679
|
+
let x = o.value == "en_us" ? d[n.labelValue.labelEn || "i18nName"] : d[n.labelValue.label];
|
|
680
|
+
return x = x || d[n.labelValue.label], x;
|
|
579
681
|
} else {
|
|
580
|
-
let
|
|
581
|
-
return
|
|
582
|
-
|
|
583
|
-
}),
|
|
682
|
+
let x = [];
|
|
683
|
+
return u.forEach((O) => {
|
|
684
|
+
x.push(d[O]);
|
|
685
|
+
}), x.join("-");
|
|
584
686
|
}
|
|
585
687
|
};
|
|
586
|
-
function
|
|
587
|
-
let
|
|
588
|
-
|
|
589
|
-
(
|
|
590
|
-
) : [],
|
|
591
|
-
|
|
688
|
+
function k(d) {
|
|
689
|
+
let x = n.data ? n.data : p.value;
|
|
690
|
+
l.value = d ? x.map(
|
|
691
|
+
(O) => s.value ? O : O[n.labelValue.value]
|
|
692
|
+
) : [], Se(() => {
|
|
693
|
+
b("change", l.value), b("changeAll", l.value, x);
|
|
592
694
|
});
|
|
593
695
|
}
|
|
594
|
-
function
|
|
595
|
-
n.optionClick && n.optionClick(
|
|
696
|
+
function _(d) {
|
|
697
|
+
n.optionClick && n.optionClick(d), b("change", s.value ? d : d[n.labelValue.value]);
|
|
596
698
|
}
|
|
597
|
-
function
|
|
598
|
-
return
|
|
699
|
+
function C(d) {
|
|
700
|
+
return l.value.length >= n.maxLimit && !l.value.includes(d[n.labelValue.value]);
|
|
599
701
|
}
|
|
600
|
-
function
|
|
601
|
-
return
|
|
602
|
-
...
|
|
603
|
-
label:
|
|
604
|
-
value:
|
|
702
|
+
function S(d) {
|
|
703
|
+
return d.map((x) => ({
|
|
704
|
+
...x,
|
|
705
|
+
label: h(x),
|
|
706
|
+
value: s.value ? x : x[n.labelValue.value]
|
|
605
707
|
}));
|
|
606
708
|
}
|
|
607
|
-
const E = R([]),
|
|
608
|
-
E.value =
|
|
609
|
-
() => n.data ? n.data :
|
|
610
|
-
(
|
|
611
|
-
var
|
|
612
|
-
const
|
|
613
|
-
if (
|
|
614
|
-
E.value =
|
|
709
|
+
const E = R([]), Y = n.data ? n.data : p.value;
|
|
710
|
+
E.value = S(Y), Pe(
|
|
711
|
+
() => n.data ? n.data : p.value,
|
|
712
|
+
(d) => {
|
|
713
|
+
var O;
|
|
714
|
+
const x = S(d);
|
|
715
|
+
if (x.length !== E.value.length)
|
|
716
|
+
E.value = x;
|
|
615
717
|
else {
|
|
616
|
-
let
|
|
617
|
-
for (let oe = 0; oe <
|
|
618
|
-
if (
|
|
619
|
-
|
|
718
|
+
let A = !1;
|
|
719
|
+
for (let oe = 0; oe < x.length; oe++)
|
|
720
|
+
if (x[oe].value !== ((O = E.value[oe]) == null ? void 0 : O.value)) {
|
|
721
|
+
A = !0;
|
|
620
722
|
break;
|
|
621
723
|
}
|
|
622
|
-
|
|
724
|
+
A && (E.value = x);
|
|
623
725
|
}
|
|
624
726
|
},
|
|
625
727
|
{ deep: !0 }
|
|
626
728
|
);
|
|
627
|
-
const
|
|
628
|
-
return (
|
|
629
|
-
const
|
|
630
|
-
return
|
|
729
|
+
const F = re(() => E.value);
|
|
730
|
+
return (d, x) => {
|
|
731
|
+
const O = z("el-checkbox"), A = z("el-select-v2"), oe = z("el-option"), ue = z("el-select");
|
|
732
|
+
return H(a).v2 != null ? (L(), B(A, he({
|
|
631
733
|
key: 0,
|
|
632
|
-
options:
|
|
633
|
-
modelValue:
|
|
634
|
-
"onUpdate:modelValue":
|
|
635
|
-
},
|
|
734
|
+
options: F.value,
|
|
735
|
+
modelValue: l.value,
|
|
736
|
+
"onUpdate:modelValue": x[1] || (x[1] = (y) => l.value = y)
|
|
737
|
+
}, H(a), {
|
|
636
738
|
filterable: "",
|
|
637
739
|
"collapse-tags": "",
|
|
638
740
|
"collapse-tags-tooltip": "",
|
|
639
741
|
clearable: "",
|
|
640
|
-
onChange:
|
|
641
|
-
onClear:
|
|
642
|
-
}),
|
|
643
|
-
default:
|
|
742
|
+
onChange: m,
|
|
743
|
+
onClear: m
|
|
744
|
+
}), at({
|
|
745
|
+
default: D(({ item: y }) => [
|
|
644
746
|
ae("div", {
|
|
645
|
-
onClick: (ge) =>
|
|
646
|
-
}, J(
|
|
747
|
+
onClick: (ge) => _(y)
|
|
748
|
+
}, J(y.label), 9, an)
|
|
647
749
|
]),
|
|
648
750
|
_: 2
|
|
649
751
|
}, [
|
|
650
|
-
|
|
752
|
+
H(a).multiple != null ? {
|
|
651
753
|
name: "header",
|
|
652
|
-
fn:
|
|
653
|
-
X(
|
|
654
|
-
|
|
754
|
+
fn: D(() => [
|
|
755
|
+
X(d.$slots, "header", {}, () => [
|
|
756
|
+
q(O, {
|
|
655
757
|
class: "mgl20",
|
|
656
|
-
modelValue:
|
|
657
|
-
"onUpdate:modelValue":
|
|
658
|
-
onChange:
|
|
758
|
+
modelValue: w.value,
|
|
759
|
+
"onUpdate:modelValue": x[0] || (x[0] = (y) => w.value = y),
|
|
760
|
+
onChange: k
|
|
659
761
|
}, {
|
|
660
|
-
default:
|
|
661
|
-
Q(J(
|
|
762
|
+
default: D(() => [
|
|
763
|
+
Q(J(d.$t("quan-xuan")), 1)
|
|
662
764
|
]),
|
|
663
765
|
_: 1
|
|
664
766
|
}, 8, ["modelValue"])
|
|
@@ -668,42 +770,42 @@ const xe = (t, e) => {
|
|
|
668
770
|
} : void 0
|
|
669
771
|
]), 1040, ["options", "modelValue"])) : (L(), B(ue, he({
|
|
670
772
|
key: 1,
|
|
671
|
-
modelValue:
|
|
672
|
-
"onUpdate:modelValue":
|
|
773
|
+
modelValue: l.value,
|
|
774
|
+
"onUpdate:modelValue": x[3] || (x[3] = (y) => l.value = y),
|
|
673
775
|
filterable: "",
|
|
674
776
|
"collapse-tags": "",
|
|
675
777
|
"collapse-tags-tooltip": "",
|
|
676
|
-
"filter-method":
|
|
778
|
+
"filter-method": H(a).remote != null ? void 0 : (y) => i.value = y,
|
|
677
779
|
clearable: ""
|
|
678
|
-
},
|
|
679
|
-
default:
|
|
680
|
-
|
|
681
|
-
|
|
780
|
+
}, H(a), { onClear: t.optionClick }), {
|
|
781
|
+
default: D(() => [
|
|
782
|
+
H(a).multiple != null && t.showCheckAll && t.maxLimit == null ? X(d.$slots, "header", { key: 0 }, () => [
|
|
783
|
+
q(O, {
|
|
682
784
|
class: "mgl20",
|
|
683
|
-
modelValue:
|
|
684
|
-
"onUpdate:modelValue":
|
|
685
|
-
onChange:
|
|
785
|
+
modelValue: w.value,
|
|
786
|
+
"onUpdate:modelValue": x[2] || (x[2] = (y) => w.value = y),
|
|
787
|
+
onChange: k
|
|
686
788
|
}, {
|
|
687
|
-
default:
|
|
688
|
-
Q(J(
|
|
789
|
+
default: D(() => [
|
|
790
|
+
Q(J(d.$t("quan-xuan")), 1)
|
|
689
791
|
]),
|
|
690
792
|
_: 1
|
|
691
793
|
}, 8, ["modelValue"])
|
|
692
794
|
], !0) : ce("", !0),
|
|
693
|
-
(L(!0),
|
|
795
|
+
(L(!0), se(Oe, null, rt(v.value, (y, ge) => (L(), B(oe, {
|
|
694
796
|
key: ge,
|
|
695
|
-
label:
|
|
696
|
-
disabled:
|
|
697
|
-
onClick:
|
|
698
|
-
value:
|
|
797
|
+
label: h(y),
|
|
798
|
+
disabled: H(a).multiple != null && t.maxLimit > 0 ? C(y) : !1,
|
|
799
|
+
onClick: Me((ie) => _(y), ["stop"]),
|
|
800
|
+
value: s.value ? y : y[t.labelValue.value]
|
|
699
801
|
}, null, 8, ["label", "disabled", "onClick", "value"]))), 128))
|
|
700
802
|
]),
|
|
701
803
|
_: 3
|
|
702
804
|
}, 16, ["modelValue", "filter-method", "onClear"]));
|
|
703
805
|
};
|
|
704
806
|
}
|
|
705
|
-
},
|
|
706
|
-
const
|
|
807
|
+
}, sn = /* @__PURE__ */ _e(rn, [["__scopeId", "data-v-d12f3c20"]]);
|
|
808
|
+
const cn = ot({
|
|
707
809
|
props: {
|
|
708
810
|
name: {
|
|
709
811
|
tyepe: String,
|
|
@@ -711,32 +813,32 @@ const an = tt({
|
|
|
711
813
|
}
|
|
712
814
|
}
|
|
713
815
|
});
|
|
714
|
-
function
|
|
715
|
-
const
|
|
716
|
-
return L(), B(
|
|
717
|
-
default:
|
|
718
|
-
(L(), B(
|
|
816
|
+
function un(t, e, n, a, r, o) {
|
|
817
|
+
const l = z("el-icon");
|
|
818
|
+
return L(), B(l, { class: "cmp-icon" }, {
|
|
819
|
+
default: D(() => [
|
|
820
|
+
(L(), B(st(t.name)))
|
|
719
821
|
]),
|
|
720
822
|
_: 1
|
|
721
823
|
});
|
|
722
824
|
}
|
|
723
|
-
const
|
|
825
|
+
const yt = /* @__PURE__ */ _e(cn, [["render", un], ["__scopeId", "data-v-733f9daa"]]), Zn = {
|
|
724
826
|
__name: "index",
|
|
725
827
|
emits: ["ok", "no"],
|
|
726
828
|
setup(t, { emit: e }) {
|
|
727
|
-
const n = e,
|
|
829
|
+
const n = e, a = Re(() => {
|
|
728
830
|
n("ok");
|
|
729
831
|
}, 500);
|
|
730
|
-
function
|
|
832
|
+
function r() {
|
|
731
833
|
n("no");
|
|
732
834
|
}
|
|
733
|
-
return (o,
|
|
734
|
-
const
|
|
735
|
-
return L(), B(
|
|
736
|
-
onConfirm:
|
|
737
|
-
onCancel:
|
|
835
|
+
return (o, l) => {
|
|
836
|
+
const s = z("el-popconfirm");
|
|
837
|
+
return L(), B(s, he(o.$attrs, {
|
|
838
|
+
onConfirm: H(a),
|
|
839
|
+
onCancel: r
|
|
738
840
|
}), {
|
|
739
|
-
reference:
|
|
841
|
+
reference: D(() => [
|
|
740
842
|
X(o.$slots, "default")
|
|
741
843
|
]),
|
|
742
844
|
_: 3
|
|
@@ -744,69 +846,81 @@ const mt = /* @__PURE__ */ xe(an, [["render", sn], ["__scopeId", "data-v-733f9da
|
|
|
744
846
|
};
|
|
745
847
|
}
|
|
746
848
|
};
|
|
747
|
-
const
|
|
849
|
+
const dn = ["accept"], fn = {
|
|
748
850
|
__name: "index",
|
|
749
851
|
props: {
|
|
750
852
|
accept: {
|
|
751
853
|
type: String,
|
|
752
854
|
default: ".xlsx,.xls"
|
|
753
855
|
},
|
|
754
|
-
|
|
755
|
-
type:
|
|
756
|
-
default:
|
|
856
|
+
fields: {
|
|
857
|
+
type: Object,
|
|
858
|
+
default: () => ({})
|
|
859
|
+
},
|
|
860
|
+
fileChange: {
|
|
861
|
+
type: Function,
|
|
862
|
+
required: !0
|
|
757
863
|
}
|
|
758
864
|
},
|
|
759
865
|
emits: ["fileChange"],
|
|
760
866
|
setup(t, { emit: e }) {
|
|
761
|
-
const n =
|
|
762
|
-
function
|
|
763
|
-
|
|
764
|
-
|
|
867
|
+
const n = t, a = R(null), r = R(!1);
|
|
868
|
+
async function o(l) {
|
|
869
|
+
r.value = !0;
|
|
870
|
+
let s = l.target.files[0];
|
|
871
|
+
const i = await tn(s, n.fields).catch(() => {
|
|
872
|
+
r.value = !1;
|
|
873
|
+
}).finally(() => {
|
|
874
|
+
a.value.value = null;
|
|
875
|
+
});
|
|
876
|
+
await n.fileChange(i).finally(() => {
|
|
877
|
+
r.value = !1;
|
|
878
|
+
});
|
|
765
879
|
}
|
|
766
|
-
return (
|
|
767
|
-
const
|
|
768
|
-
return L(),
|
|
769
|
-
|
|
770
|
-
loading:
|
|
880
|
+
return (l, s) => {
|
|
881
|
+
const i = z("el-button");
|
|
882
|
+
return L(), se("span", null, [
|
|
883
|
+
q(i, {
|
|
884
|
+
loading: r.value,
|
|
771
885
|
class: "mgr10",
|
|
772
|
-
onClick:
|
|
886
|
+
onClick: s[0] || (s[0] = (v) => a.value.click())
|
|
773
887
|
}, {
|
|
774
|
-
default:
|
|
775
|
-
Q(J(
|
|
888
|
+
default: D(() => [
|
|
889
|
+
Q(J(l.$t("dao-ru")), 1)
|
|
776
890
|
]),
|
|
777
891
|
_: 1
|
|
778
892
|
}, 8, ["loading"]),
|
|
779
893
|
ae("input", {
|
|
780
|
-
onChange:
|
|
894
|
+
onChange: o,
|
|
781
895
|
ref_key: "input",
|
|
782
|
-
ref:
|
|
896
|
+
ref: a,
|
|
783
897
|
accept: t.accept,
|
|
784
898
|
style: { position: "absolute", width: "0px", height: "0px", opacity: "0" },
|
|
785
899
|
type: "file"
|
|
786
|
-
}, null, 40,
|
|
900
|
+
}, null, 40, dn)
|
|
787
901
|
]);
|
|
788
902
|
};
|
|
789
903
|
}
|
|
790
|
-
},
|
|
791
|
-
function
|
|
904
|
+
}, Gn = /* @__PURE__ */ _e(fn, [["__scopeId", "data-v-6f9ede29"]]);
|
|
905
|
+
function Ue(t) {
|
|
792
906
|
let e = {};
|
|
793
907
|
return t.forEach((n) => {
|
|
794
|
-
const { key:
|
|
795
|
-
if (
|
|
796
|
-
if (
|
|
797
|
-
e[
|
|
798
|
-
else if (
|
|
799
|
-
if (
|
|
800
|
-
const [
|
|
801
|
-
let [
|
|
802
|
-
|
|
908
|
+
const { key: a, type: r, option: o = {}, value: l, dateType: s = "date" } = n;
|
|
909
|
+
if (a)
|
|
910
|
+
if (r == "input" && (o != null && o.multiple))
|
|
911
|
+
e[a] = pt(l);
|
|
912
|
+
else if (r == "date")
|
|
913
|
+
if (s.includes("range")) {
|
|
914
|
+
const [i, v] = a;
|
|
915
|
+
let [w, b] = l || [];
|
|
916
|
+
w && s == "daterange" && (w = ke(w).format("YYYY-MM-DD 00:00:00"), b = ke(b).format("YYYY-MM-DD 23:59:59")), e[i] = w, e[v] = b;
|
|
803
917
|
} else
|
|
804
|
-
e[
|
|
918
|
+
e[a] = l;
|
|
805
919
|
else
|
|
806
|
-
e[
|
|
920
|
+
e[a] = l;
|
|
807
921
|
}), e;
|
|
808
922
|
}
|
|
809
|
-
const
|
|
923
|
+
const hn = { key: 0 }, mn = { class: "btns" }, gn = { class: "left" }, pn = { class: "right" }, yn = {
|
|
810
924
|
__name: "index",
|
|
811
925
|
props: {
|
|
812
926
|
form: {
|
|
@@ -816,83 +930,83 @@ const un = { key: 0 }, dn = { class: "btns" }, fn = { class: "left" }, hn = { cl
|
|
|
816
930
|
},
|
|
817
931
|
emits: ["confirm", "reset", "visibleChange"],
|
|
818
932
|
setup(t, { expose: e, emit: n }) {
|
|
819
|
-
const
|
|
820
|
-
function
|
|
821
|
-
|
|
933
|
+
const a = t, r = n, o = R(!0), l = R(null), { t: s } = me(), i = re(() => o.value ? s("guan-bi") : s("zhan-kai"));
|
|
934
|
+
function v() {
|
|
935
|
+
r("confirm");
|
|
822
936
|
}
|
|
823
|
-
function
|
|
824
|
-
|
|
937
|
+
function w(h) {
|
|
938
|
+
h.option.onClear && h.option.onClear(), r("confirm");
|
|
825
939
|
}
|
|
826
|
-
function
|
|
827
|
-
|
|
940
|
+
function b() {
|
|
941
|
+
r("reset");
|
|
828
942
|
}
|
|
829
|
-
function
|
|
830
|
-
|
|
943
|
+
function p() {
|
|
944
|
+
r("confirm");
|
|
831
945
|
}
|
|
832
946
|
function g() {
|
|
833
|
-
return
|
|
947
|
+
return Ue(a.form.items);
|
|
834
948
|
}
|
|
835
|
-
const
|
|
836
|
-
function
|
|
837
|
-
|
|
838
|
-
const
|
|
839
|
-
|
|
949
|
+
const m = ct(a.form.items);
|
|
950
|
+
function u() {
|
|
951
|
+
a.form.items.forEach((h) => {
|
|
952
|
+
const k = m.find((_) => _.key == h.key);
|
|
953
|
+
k && (h.value = k.value);
|
|
840
954
|
});
|
|
841
955
|
}
|
|
842
|
-
return e({ getPrm: g, reset:
|
|
843
|
-
const
|
|
844
|
-
return L(),
|
|
956
|
+
return e({ getPrm: g, reset: u }), (h, k) => {
|
|
957
|
+
const _ = z("el-input"), C = z("el-date-picker"), S = z("el-form-item"), E = z("el-form"), Y = z("el-link"), F = z("el-button");
|
|
958
|
+
return L(), se("div", {
|
|
845
959
|
class: "searchBar-container mgt10 mgb10",
|
|
846
|
-
onKeydown:
|
|
960
|
+
onKeydown: Dt(v, ["enter"])
|
|
847
961
|
}, [
|
|
848
962
|
ae("div", {
|
|
849
963
|
class: "searchBar",
|
|
850
|
-
style:
|
|
964
|
+
style: zt({ height: o.value ? "auto" : "42px" })
|
|
851
965
|
}, [
|
|
852
|
-
|
|
966
|
+
q(E, {
|
|
853
967
|
inline: "",
|
|
854
968
|
model: t.form.data
|
|
855
969
|
}, {
|
|
856
|
-
default:
|
|
857
|
-
(L(!0),
|
|
858
|
-
key:
|
|
970
|
+
default: D(() => [
|
|
971
|
+
(L(!0), se(Oe, null, rt(t.form.items.filter((d) => !d.hidden), (d) => (L(), se(Oe, {
|
|
972
|
+
key: d.key
|
|
859
973
|
}, [
|
|
860
|
-
|
|
974
|
+
d.type == "br" ? (L(), se("br", hn)) : (L(), B(S, {
|
|
861
975
|
key: 1,
|
|
862
|
-
label:
|
|
976
|
+
label: d.name
|
|
863
977
|
}, {
|
|
864
|
-
default:
|
|
865
|
-
var
|
|
978
|
+
default: D(() => {
|
|
979
|
+
var x, O;
|
|
866
980
|
return [
|
|
867
|
-
|
|
981
|
+
d.type === "input" ? (L(), B(_, {
|
|
868
982
|
key: 0,
|
|
869
|
-
modelValue:
|
|
870
|
-
"onUpdate:modelValue": (
|
|
871
|
-
class:
|
|
872
|
-
placeholder:
|
|
983
|
+
modelValue: d.value,
|
|
984
|
+
"onUpdate:modelValue": (A) => d.value = A,
|
|
985
|
+
class: Ve(((x = d.option) == null ? void 0 : x.class) || "w150"),
|
|
986
|
+
placeholder: h.$t("qing-shu-ru"),
|
|
873
987
|
clearable: ""
|
|
874
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "class", "placeholder"])) :
|
|
875
|
-
|
|
988
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "class", "placeholder"])) : d.type === "custom" ? (L(), B(st(d.render), { key: 1 })) : ce("", !0),
|
|
989
|
+
d.type === "select" ? (L(), B(sn, he({
|
|
876
990
|
key: 2,
|
|
877
|
-
class: ((
|
|
878
|
-
modelValue:
|
|
879
|
-
"onUpdate:modelValue": (
|
|
880
|
-
}, { ref_for: !0 },
|
|
881
|
-
onChange:
|
|
882
|
-
onClear: (
|
|
991
|
+
class: ((O = d.option) == null ? void 0 : O.class) || "w150",
|
|
992
|
+
modelValue: d.value,
|
|
993
|
+
"onUpdate:modelValue": (A) => d.value = A
|
|
994
|
+
}, { ref_for: !0 }, d.option, {
|
|
995
|
+
onChange: v,
|
|
996
|
+
onClear: (A) => w(d)
|
|
883
997
|
}), null, 16, ["class", "modelValue", "onUpdate:modelValue", "onClear"])) : ce("", !0),
|
|
884
|
-
|
|
998
|
+
d.type === "date" ? (L(), B(C, {
|
|
885
999
|
key: 3,
|
|
886
|
-
class:
|
|
887
|
-
modelValue:
|
|
888
|
-
"onUpdate:modelValue": (
|
|
889
|
-
"value-format": { datetimerange: "YYYY-MM-DD HH:mm:ss", daterange: "YYYY-MM-DD" }[
|
|
890
|
-
type:
|
|
891
|
-
onFocus: (
|
|
892
|
-
onChange: (
|
|
893
|
-
placeholder:
|
|
894
|
-
"start-placeholder":
|
|
895
|
-
"end-placeholder":
|
|
1000
|
+
class: Ve({ datetimerange: "w300", daterange: "w200" }[d.dateType] || "w100"),
|
|
1001
|
+
modelValue: d.value,
|
|
1002
|
+
"onUpdate:modelValue": (A) => d.value = A,
|
|
1003
|
+
"value-format": { datetimerange: "YYYY-MM-DD HH:mm:ss", daterange: "YYYY-MM-DD" }[d.dateType] || "YYYY-MM-DD",
|
|
1004
|
+
type: d.dateType || "date",
|
|
1005
|
+
onFocus: (A) => l.value = d,
|
|
1006
|
+
onChange: (A) => p(),
|
|
1007
|
+
placeholder: h.$t("qing-xuan-ze"),
|
|
1008
|
+
"start-placeholder": h.$t("kai-shi-shi-jian"),
|
|
1009
|
+
"end-placeholder": h.$t("jie-shu-shi-jian")
|
|
896
1010
|
}, null, 8, ["class", "modelValue", "onUpdate:modelValue", "value-format", "type", "onFocus", "onChange", "placeholder", "start-placeholder", "end-placeholder"])) : ce("", !0)
|
|
897
1011
|
];
|
|
898
1012
|
}),
|
|
@@ -903,51 +1017,51 @@ const un = { key: 0 }, dn = { class: "btns" }, fn = { class: "left" }, hn = { cl
|
|
|
903
1017
|
_: 1
|
|
904
1018
|
}, 8, ["model"])
|
|
905
1019
|
], 4),
|
|
906
|
-
ae("div",
|
|
907
|
-
ae("div",
|
|
908
|
-
X(
|
|
1020
|
+
ae("div", mn, [
|
|
1021
|
+
ae("div", gn, [
|
|
1022
|
+
X(h.$slots, "table-header-left", {}, void 0, !0)
|
|
909
1023
|
]),
|
|
910
|
-
ae("div",
|
|
911
|
-
|
|
1024
|
+
ae("div", pn, [
|
|
1025
|
+
q(Y, {
|
|
912
1026
|
underline: "never",
|
|
913
1027
|
class: "mgr10",
|
|
914
|
-
onClick:
|
|
915
|
-
|
|
1028
|
+
onClick: k[0] || (k[0] = () => {
|
|
1029
|
+
r("visibleChange", !o.value), o.value = !o.value;
|
|
916
1030
|
})
|
|
917
1031
|
}, {
|
|
918
|
-
default:
|
|
919
|
-
|
|
1032
|
+
default: D(() => [
|
|
1033
|
+
q(yt, {
|
|
920
1034
|
name: o.value ? "ArrowUp" : "ArrowDown"
|
|
921
1035
|
}, null, 8, ["name"]),
|
|
922
|
-
Q(" " + J(
|
|
1036
|
+
Q(" " + J(i.value), 1)
|
|
923
1037
|
]),
|
|
924
1038
|
_: 1
|
|
925
1039
|
}),
|
|
926
|
-
|
|
1040
|
+
q(F, {
|
|
927
1041
|
type: "primary",
|
|
928
|
-
onClick:
|
|
1042
|
+
onClick: v
|
|
929
1043
|
}, {
|
|
930
|
-
default:
|
|
931
|
-
Q(J(
|
|
1044
|
+
default: D(() => [
|
|
1045
|
+
Q(J(h.$t("shai-xuan")), 1)
|
|
932
1046
|
]),
|
|
933
1047
|
_: 1
|
|
934
1048
|
}),
|
|
935
|
-
|
|
1049
|
+
q(F, {
|
|
936
1050
|
type: "primary",
|
|
937
|
-
onClick:
|
|
1051
|
+
onClick: b
|
|
938
1052
|
}, {
|
|
939
|
-
default:
|
|
940
|
-
Q(J(
|
|
1053
|
+
default: D(() => [
|
|
1054
|
+
Q(J(h.$t("chong-zhi")), 1)
|
|
941
1055
|
]),
|
|
942
1056
|
_: 1
|
|
943
1057
|
}),
|
|
944
|
-
X(
|
|
1058
|
+
X(h.$slots, "btn", {}, void 0, !0)
|
|
945
1059
|
])
|
|
946
1060
|
])
|
|
947
1061
|
], 32);
|
|
948
1062
|
};
|
|
949
1063
|
}
|
|
950
|
-
},
|
|
1064
|
+
}, vn = /* @__PURE__ */ _e(yn, [["__scopeId", "data-v-3c0a6716"]]), vt = {
|
|
951
1065
|
// 分页参数名
|
|
952
1066
|
pageNoKey: "pageNo",
|
|
953
1067
|
// 页码参数名
|
|
@@ -977,8 +1091,8 @@ const un = { key: 0 }, dn = { class: "btns" }, fn = { class: "left" }, hn = { cl
|
|
|
977
1091
|
enableCellCopy: !0
|
|
978
1092
|
// 是否启用单元格选区复制功能
|
|
979
1093
|
};
|
|
980
|
-
let Ce = { ...
|
|
981
|
-
function
|
|
1094
|
+
let Ce = { ...vt };
|
|
1095
|
+
function Jn(t) {
|
|
982
1096
|
Ce = {
|
|
983
1097
|
...Ce,
|
|
984
1098
|
...t,
|
|
@@ -988,13 +1102,13 @@ function Nn(t) {
|
|
|
988
1102
|
}
|
|
989
1103
|
};
|
|
990
1104
|
}
|
|
991
|
-
function
|
|
1105
|
+
function bn() {
|
|
992
1106
|
return Ce;
|
|
993
1107
|
}
|
|
994
|
-
function
|
|
995
|
-
Ce = { ...
|
|
1108
|
+
function Xn() {
|
|
1109
|
+
Ce = { ...vt };
|
|
996
1110
|
}
|
|
997
|
-
const
|
|
1111
|
+
const wn = { class: "center" }, xn = {
|
|
998
1112
|
__name: "index",
|
|
999
1113
|
props: {
|
|
1000
1114
|
// 表格id 本地存储列设置时使用,不传则使用路由路径自动生成
|
|
@@ -1031,110 +1145,110 @@ const yn = { class: "center" }, vn = {
|
|
|
1031
1145
|
}
|
|
1032
1146
|
},
|
|
1033
1147
|
setup(t, { expose: e }) {
|
|
1034
|
-
const { t: n, locale:
|
|
1035
|
-
|
|
1036
|
-
const
|
|
1037
|
-
const
|
|
1038
|
-
return
|
|
1039
|
-
}),
|
|
1040
|
-
[
|
|
1041
|
-
[
|
|
1148
|
+
const { t: n, locale: a } = me(), r = jt(), o = bn(), l = t, s = R(!1), i = R([]);
|
|
1149
|
+
l.searchForm.showSearch === void 0 && (l.searchForm.showSearch = o.showSearch), l.searchForm.showPage === void 0 && (l.searchForm.showPage = o.showPage), l.searchForm.showShadow === void 0 && (l.searchForm.showShadow = o.showShadow), l.searchForm.showCheckBox === void 0 && (l.searchForm.showCheckBox = o.showCheckBox), l.searchForm.enableCellCopy === void 0 && (l.searchForm.enableCellCopy = o.enableCellCopy), l.searchForm.selections || (l.searchForm.selections = []);
|
|
1150
|
+
const v = re(() => {
|
|
1151
|
+
const f = r.path.replace(/\//g, "-").replace(/^-/, "") || "default-table";
|
|
1152
|
+
return l.id ? `listPageId-${f}-${l.id}` : `listPageId-${f}`;
|
|
1153
|
+
}), w = ct(l.searchForm.items), b = l.searchForm.pageNoKey || o.pageNoKey, p = l.searchForm.pageSizeKey || o.pageSizeKey, g = $e({
|
|
1154
|
+
[b]: 1,
|
|
1155
|
+
[p]: l.searchForm.defaultPageSize || o.defaultPageSize,
|
|
1042
1156
|
total: 0
|
|
1043
|
-
}),
|
|
1044
|
-
|
|
1045
|
-
if (!
|
|
1157
|
+
}), m = R(null), u = R(null), h = R(450), k = Re(() => {
|
|
1158
|
+
Se(() => {
|
|
1159
|
+
if (!u.value)
|
|
1046
1160
|
return;
|
|
1047
|
-
const
|
|
1048
|
-
|
|
1161
|
+
const c = u.value.getBoundingClientRect(), $ = window.innerHeight, T = c.top, U = 100, W = $ - T - U, M = 200;
|
|
1162
|
+
h.value = Math.max(W, M);
|
|
1049
1163
|
});
|
|
1050
|
-
}, 100),
|
|
1051
|
-
|
|
1052
|
-
},
|
|
1053
|
-
if (!
|
|
1164
|
+
}, 100), _ = () => {
|
|
1165
|
+
k();
|
|
1166
|
+
}, C = () => {
|
|
1167
|
+
if (!l.searchForm.enableCellCopy)
|
|
1054
1168
|
return !1;
|
|
1055
|
-
const
|
|
1056
|
-
if (!
|
|
1169
|
+
const f = m.value;
|
|
1170
|
+
if (!f || !f.$el)
|
|
1057
1171
|
return !1;
|
|
1058
|
-
const
|
|
1059
|
-
return
|
|
1172
|
+
const c = f.$el;
|
|
1173
|
+
return c.classList.add("cell-copy-enabled"), c.setAttribute("tabindex", "-1"), c.removeEventListener("mousedown", ie), c.removeEventListener("mousemove", pe), c.removeEventListener("mouseup", be), c.removeEventListener("keydown", Le), c.addEventListener("mousedown", ie), c.addEventListener("mousemove", pe), c.addEventListener("mouseup", be), c.addEventListener("keydown", Le), !0;
|
|
1060
1174
|
};
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1175
|
+
lt(() => {
|
|
1176
|
+
k(), window.addEventListener("resize", _), l.searchForm.enableCellCopy && (document.addEventListener("mouseup", Ne), document.addEventListener("mousedown", We), setTimeout(() => {
|
|
1177
|
+
C();
|
|
1064
1178
|
}, 500));
|
|
1065
|
-
}),
|
|
1066
|
-
|
|
1067
|
-
|
|
1179
|
+
}), Ot(() => {
|
|
1180
|
+
l.searchForm.enableCellCopy && setTimeout(() => {
|
|
1181
|
+
C();
|
|
1068
1182
|
}, 500);
|
|
1069
|
-
}),
|
|
1070
|
-
if (window.removeEventListener("resize",
|
|
1071
|
-
document.removeEventListener("mouseup",
|
|
1072
|
-
const
|
|
1073
|
-
if (
|
|
1074
|
-
const
|
|
1075
|
-
|
|
1183
|
+
}), Mt(() => {
|
|
1184
|
+
if (window.removeEventListener("resize", _), l.searchForm.enableCellCopy) {
|
|
1185
|
+
document.removeEventListener("mouseup", Ne), document.removeEventListener("mousedown", We);
|
|
1186
|
+
const f = m.value;
|
|
1187
|
+
if (f && f.$el) {
|
|
1188
|
+
const c = f.$el;
|
|
1189
|
+
c.removeEventListener("mousedown", ie), c.removeEventListener("mousemove", pe), c.removeEventListener("mouseup", be), c.removeEventListener("keydown", Le);
|
|
1076
1190
|
}
|
|
1077
1191
|
}
|
|
1078
1192
|
});
|
|
1079
|
-
const
|
|
1193
|
+
const S = re(() => ue.value.height || h.value);
|
|
1080
1194
|
let E;
|
|
1081
|
-
async function
|
|
1082
|
-
const { dataFormat:
|
|
1083
|
-
|
|
1084
|
-
const { code:
|
|
1085
|
-
|
|
1195
|
+
async function Y(f) {
|
|
1196
|
+
const { dataFormat: c } = l.tableConfig;
|
|
1197
|
+
f[b] != 1 && (f.nextSearchAfter = E), s.value = !0;
|
|
1198
|
+
const { code: $, data: T = {} } = await l.api(f).finally(() => {
|
|
1199
|
+
s.value = !1, l.searchForm.selections = [];
|
|
1086
1200
|
});
|
|
1087
|
-
if (
|
|
1088
|
-
let
|
|
1089
|
-
for (const
|
|
1090
|
-
if (
|
|
1091
|
-
|
|
1201
|
+
if ($ == 200) {
|
|
1202
|
+
let U = [];
|
|
1203
|
+
for (const M of o.responseDataKeys.rows)
|
|
1204
|
+
if (T[M]) {
|
|
1205
|
+
U = T[M];
|
|
1092
1206
|
break;
|
|
1093
1207
|
}
|
|
1094
|
-
let
|
|
1095
|
-
for (const
|
|
1096
|
-
if (
|
|
1097
|
-
|
|
1208
|
+
let W = 0;
|
|
1209
|
+
for (const M of o.responseDataKeys.total)
|
|
1210
|
+
if (T[M] !== void 0) {
|
|
1211
|
+
W = T[M];
|
|
1098
1212
|
break;
|
|
1099
1213
|
}
|
|
1100
|
-
|
|
1214
|
+
i.value = c ? c(U) : U, g.total = W, E = T.nextSearchAfter, l.searchForm.enableCellCopy && Se(() => {
|
|
1101
1215
|
setTimeout(() => {
|
|
1102
|
-
|
|
1216
|
+
C();
|
|
1103
1217
|
}, 100);
|
|
1104
1218
|
});
|
|
1105
1219
|
}
|
|
1106
1220
|
}
|
|
1107
|
-
function
|
|
1108
|
-
const { searchData:
|
|
1109
|
-
|
|
1221
|
+
function F(f = {}) {
|
|
1222
|
+
const { searchData: c = () => ({}) } = l.tableConfig, $ = c();
|
|
1223
|
+
Y({ ...g, ...Ue(l.searchForm.items), ...f, ...$ });
|
|
1110
1224
|
}
|
|
1111
|
-
function
|
|
1112
|
-
const { reset:
|
|
1113
|
-
|
|
1114
|
-
const
|
|
1115
|
-
|
|
1116
|
-
}),
|
|
1225
|
+
function d() {
|
|
1226
|
+
const { reset: f } = l.tableConfig;
|
|
1227
|
+
f && f(), l.searchForm.items.forEach((c) => {
|
|
1228
|
+
const $ = w.find((T) => Qe(c.key) && Qe(T.key) ? c.key.join(",") == T.key.join(",") : T.key == c.key);
|
|
1229
|
+
$ && (c.value = $.value);
|
|
1230
|
+
}), F();
|
|
1117
1231
|
}
|
|
1118
|
-
|
|
1119
|
-
function
|
|
1120
|
-
return { ...g, ...
|
|
1232
|
+
l.api && l.immediate && F();
|
|
1233
|
+
function x() {
|
|
1234
|
+
return { ...g, ...Ue(l.searchForm.items) };
|
|
1121
1235
|
}
|
|
1122
|
-
const
|
|
1123
|
-
const
|
|
1124
|
-
|
|
1125
|
-
},
|
|
1236
|
+
const O = () => {
|
|
1237
|
+
const f = m.value;
|
|
1238
|
+
f && f.clearSort();
|
|
1239
|
+
}, A = $e({
|
|
1126
1240
|
storage: !0
|
|
1127
|
-
}), oe =
|
|
1241
|
+
}), oe = $e({
|
|
1128
1242
|
drag: !0,
|
|
1129
1243
|
resizable: !0,
|
|
1130
1244
|
maxFixedSize: 0
|
|
1131
|
-
}), ue =
|
|
1132
|
-
const { customConfig:
|
|
1245
|
+
}), ue = re(() => {
|
|
1246
|
+
const { customConfig: f, columnConfig: c, ...$ } = l.tableConfig;
|
|
1133
1247
|
return {
|
|
1134
1248
|
headerAlign: "left",
|
|
1135
1249
|
align: "center",
|
|
1136
|
-
customConfig: { ...
|
|
1137
|
-
columnConfig: { ...oe, ...
|
|
1250
|
+
customConfig: { ...A, ...f },
|
|
1251
|
+
columnConfig: { ...oe, ...c },
|
|
1138
1252
|
// 列过多时 自动宽度 虚拟滚动会闪屏 关闭虚拟滚动
|
|
1139
1253
|
"virtual-x-config": {
|
|
1140
1254
|
enabled: !1,
|
|
@@ -1142,9 +1256,9 @@ const yn = { class: "center" }, vn = {
|
|
|
1142
1256
|
},
|
|
1143
1257
|
// 纵向虚拟滚动 大于100条开启
|
|
1144
1258
|
"virtual-y-config": { enabled: !0, gt: 100 },
|
|
1145
|
-
|
|
1259
|
+
...$
|
|
1146
1260
|
};
|
|
1147
|
-
}),
|
|
1261
|
+
}), y = $e({
|
|
1148
1262
|
isSelecting: !1,
|
|
1149
1263
|
// 是否正在选择
|
|
1150
1264
|
startCell: null,
|
|
@@ -1153,71 +1267,71 @@ const yn = { class: "center" }, vn = {
|
|
|
1153
1267
|
// 结束单元格
|
|
1154
1268
|
selectedCells: []
|
|
1155
1269
|
// 选中的单元格列表 [{ rowIndex, colIndex }]
|
|
1156
|
-
}), ge = (
|
|
1157
|
-
const
|
|
1158
|
-
if (!
|
|
1270
|
+
}), ge = (f) => {
|
|
1271
|
+
const c = f.closest(".vxe-body--column");
|
|
1272
|
+
if (!c || c.classList.contains("col--checkbox") || c.classList.contains("col--seq"))
|
|
1159
1273
|
return null;
|
|
1160
|
-
const
|
|
1161
|
-
if (
|
|
1274
|
+
const $ = c.closest(".vxe-body--row");
|
|
1275
|
+
if (!$)
|
|
1162
1276
|
return null;
|
|
1163
|
-
const
|
|
1164
|
-
if (!
|
|
1277
|
+
const T = m.value;
|
|
1278
|
+
if (!T)
|
|
1165
1279
|
return null;
|
|
1166
|
-
let
|
|
1167
|
-
const
|
|
1168
|
-
if (
|
|
1169
|
-
|
|
1280
|
+
let U = -1;
|
|
1281
|
+
const W = $.getAttribute("data-rowid");
|
|
1282
|
+
if (W != null)
|
|
1283
|
+
U = parseInt(W, 10);
|
|
1170
1284
|
else {
|
|
1171
|
-
const
|
|
1172
|
-
|
|
1285
|
+
const V = $.parentElement;
|
|
1286
|
+
U = Array.from(V.querySelectorAll(".vxe-body--row")).indexOf($);
|
|
1173
1287
|
}
|
|
1174
|
-
if (
|
|
1288
|
+
if (U < 0)
|
|
1175
1289
|
return null;
|
|
1176
|
-
let
|
|
1177
|
-
const le =
|
|
1178
|
-
if (le && (
|
|
1179
|
-
const
|
|
1180
|
-
if (
|
|
1181
|
-
const G = P.filter((
|
|
1182
|
-
|
|
1290
|
+
let M = -1;
|
|
1291
|
+
const le = c.getAttribute("data-colid");
|
|
1292
|
+
if (le && (M = T.getColumns().findIndex((I) => I.id === le)), M < 0) {
|
|
1293
|
+
const I = Array.from($.querySelectorAll(".vxe-body--column")).indexOf(c), K = !!c.closest(".vxe-table--fixed-left-wrapper"), Z = !!c.closest(".vxe-table--fixed-right-wrapper"), P = T.getColumns();
|
|
1294
|
+
if (K) {
|
|
1295
|
+
const G = P.filter((N) => N.fixed === "left");
|
|
1296
|
+
I < G.length && (M = P.indexOf(G[I]));
|
|
1183
1297
|
} else if (Z) {
|
|
1184
|
-
const G = P.filter((
|
|
1185
|
-
|
|
1298
|
+
const G = P.filter((N) => N.fixed === "right");
|
|
1299
|
+
I < G.length && (M = P.indexOf(G[I]));
|
|
1186
1300
|
} else {
|
|
1187
|
-
const G =
|
|
1188
|
-
|
|
1301
|
+
const G = l.searchForm.showCheckBox ? 1 : 0;
|
|
1302
|
+
M = P.filter((ee) => ee.fixed === "left").length + I - G;
|
|
1189
1303
|
}
|
|
1190
1304
|
}
|
|
1191
|
-
return
|
|
1192
|
-
}, ie = (
|
|
1193
|
-
const
|
|
1194
|
-
if (!
|
|
1195
|
-
|
|
1305
|
+
return M < 0 ? null : { rowIndex: U, colIndex: M, cell: c };
|
|
1306
|
+
}, ie = (f) => {
|
|
1307
|
+
const c = ge(f.target);
|
|
1308
|
+
if (!c) {
|
|
1309
|
+
Ie();
|
|
1196
1310
|
return;
|
|
1197
1311
|
}
|
|
1198
|
-
|
|
1199
|
-
rowIndex:
|
|
1200
|
-
colIndex:
|
|
1201
|
-
},
|
|
1202
|
-
}, pe = (
|
|
1203
|
-
if (!
|
|
1312
|
+
y.isSelecting = !0, y.startCell = {
|
|
1313
|
+
rowIndex: c.rowIndex,
|
|
1314
|
+
colIndex: c.colIndex
|
|
1315
|
+
}, y.endCell = { ...y.startCell }, Ke(), He();
|
|
1316
|
+
}, pe = (f) => {
|
|
1317
|
+
if (!y.isSelecting)
|
|
1204
1318
|
return;
|
|
1205
|
-
const
|
|
1206
|
-
|
|
1207
|
-
rowIndex:
|
|
1208
|
-
colIndex:
|
|
1209
|
-
},
|
|
1210
|
-
},
|
|
1211
|
-
|
|
1212
|
-
},
|
|
1213
|
-
|
|
1214
|
-
const
|
|
1215
|
-
if (!
|
|
1319
|
+
const c = ge(f.target);
|
|
1320
|
+
c && (y.endCell = {
|
|
1321
|
+
rowIndex: c.rowIndex,
|
|
1322
|
+
colIndex: c.colIndex
|
|
1323
|
+
}, Ke(), He());
|
|
1324
|
+
}, be = () => {
|
|
1325
|
+
y.isSelecting = !1;
|
|
1326
|
+
}, Ie = () => {
|
|
1327
|
+
y.selectedCells = [], y.startCell = null, y.endCell = null;
|
|
1328
|
+
const f = m.value;
|
|
1329
|
+
if (!f)
|
|
1216
1330
|
return;
|
|
1217
|
-
|
|
1331
|
+
f.$el.querySelectorAll(
|
|
1218
1332
|
".cell-selected, .cell-border-top, .cell-border-right, .cell-border-bottom, .cell-border-left"
|
|
1219
|
-
).forEach((
|
|
1220
|
-
|
|
1333
|
+
).forEach(($) => {
|
|
1334
|
+
$.classList.remove(
|
|
1221
1335
|
"cell-selected",
|
|
1222
1336
|
"cell-border-top",
|
|
1223
1337
|
"cell-border-right",
|
|
@@ -1225,228 +1339,228 @@ const yn = { class: "center" }, vn = {
|
|
|
1225
1339
|
"cell-border-left"
|
|
1226
1340
|
);
|
|
1227
1341
|
});
|
|
1228
|
-
},
|
|
1229
|
-
if (!
|
|
1230
|
-
|
|
1342
|
+
}, Ke = () => {
|
|
1343
|
+
if (!y.startCell || !y.endCell) {
|
|
1344
|
+
y.selectedCells = [];
|
|
1231
1345
|
return;
|
|
1232
1346
|
}
|
|
1233
|
-
const
|
|
1234
|
-
|
|
1235
|
-
for (let
|
|
1236
|
-
for (let
|
|
1237
|
-
|
|
1238
|
-
rowIndex:
|
|
1239
|
-
colIndex:
|
|
1347
|
+
const f = y.startCell.rowIndex, c = y.endCell.rowIndex, $ = y.startCell.colIndex, T = y.endCell.colIndex, U = Math.min(f, c), W = Math.max(f, c), M = Math.min($, T), le = Math.max($, T);
|
|
1348
|
+
y.selectedCells = [];
|
|
1349
|
+
for (let V = U; V <= W; V++)
|
|
1350
|
+
for (let I = M; I <= le; I++)
|
|
1351
|
+
y.selectedCells.push({
|
|
1352
|
+
rowIndex: V,
|
|
1353
|
+
colIndex: I
|
|
1240
1354
|
});
|
|
1241
|
-
},
|
|
1242
|
-
|
|
1243
|
-
const
|
|
1244
|
-
if (!
|
|
1355
|
+
}, He = () => {
|
|
1356
|
+
Se(() => {
|
|
1357
|
+
const f = m.value;
|
|
1358
|
+
if (!f)
|
|
1245
1359
|
return;
|
|
1246
|
-
const
|
|
1247
|
-
if (
|
|
1360
|
+
const c = f.$el;
|
|
1361
|
+
if (c.querySelectorAll(
|
|
1248
1362
|
".cell-selected, .cell-border-top, .cell-border-right, .cell-border-bottom, .cell-border-left"
|
|
1249
|
-
).forEach((
|
|
1250
|
-
|
|
1363
|
+
).forEach((K) => {
|
|
1364
|
+
K.classList.remove(
|
|
1251
1365
|
"cell-selected",
|
|
1252
1366
|
"cell-border-top",
|
|
1253
1367
|
"cell-border-right",
|
|
1254
1368
|
"cell-border-bottom",
|
|
1255
1369
|
"cell-border-left"
|
|
1256
1370
|
);
|
|
1257
|
-
}),
|
|
1371
|
+
}), y.selectedCells.length === 0)
|
|
1258
1372
|
return;
|
|
1259
|
-
const
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1373
|
+
const $ = f.getColumns(), T = y.selectedCells.map((K) => K.rowIndex), U = y.selectedCells.map((K) => K.colIndex), W = Math.min(...T), M = Math.max(...T), le = Math.min(...U), V = Math.max(...U), I = [
|
|
1374
|
+
c.querySelector(".vxe-table--body-wrapper tbody"),
|
|
1375
|
+
c.querySelector(".vxe-table--fixed-left-wrapper tbody"),
|
|
1376
|
+
c.querySelector(".vxe-table--fixed-right-wrapper tbody")
|
|
1263
1377
|
].filter(Boolean);
|
|
1264
|
-
|
|
1265
|
-
const P =
|
|
1378
|
+
y.selectedCells.forEach(({ rowIndex: K, colIndex: Z }) => {
|
|
1379
|
+
const P = $[Z];
|
|
1266
1380
|
if (!P)
|
|
1267
1381
|
return;
|
|
1268
|
-
const G = P.fixed === "left",
|
|
1269
|
-
for (const ee of
|
|
1270
|
-
const
|
|
1271
|
-
if (!
|
|
1382
|
+
const G = P.fixed === "left", N = P.fixed === "right";
|
|
1383
|
+
for (const ee of I) {
|
|
1384
|
+
const we = ee.querySelectorAll(".vxe-body--row")[K];
|
|
1385
|
+
if (!we)
|
|
1272
1386
|
continue;
|
|
1273
|
-
const de = Array.from(
|
|
1274
|
-
let
|
|
1387
|
+
const de = Array.from(we.querySelectorAll(".vxe-body--column"));
|
|
1388
|
+
let j = null;
|
|
1275
1389
|
if (G && ee.closest(".vxe-table--fixed-left-wrapper")) {
|
|
1276
|
-
const te =
|
|
1277
|
-
|
|
1278
|
-
} else if (
|
|
1279
|
-
const te =
|
|
1280
|
-
|
|
1281
|
-
} else if (!G && !
|
|
1282
|
-
const fe =
|
|
1283
|
-
|
|
1390
|
+
const te = $.filter((ne) => ne.fixed === "left").indexOf(P);
|
|
1391
|
+
j = de[te];
|
|
1392
|
+
} else if (N && ee.closest(".vxe-table--fixed-right-wrapper")) {
|
|
1393
|
+
const te = $.filter((ne) => ne.fixed === "right").indexOf(P);
|
|
1394
|
+
j = de[te];
|
|
1395
|
+
} else if (!G && !N && ee.closest(".vxe-table--body-wrapper")) {
|
|
1396
|
+
const fe = l.searchForm.showCheckBox ? 1 : 0, te = $.filter((Fe) => Fe.fixed === "left").length, ne = Z - te;
|
|
1397
|
+
j = de[ne + fe];
|
|
1284
1398
|
}
|
|
1285
|
-
if (
|
|
1286
|
-
|
|
1399
|
+
if (j && !j.classList.contains("col--checkbox") && !j.classList.contains("col--seq")) {
|
|
1400
|
+
j.classList.add("cell-selected"), K === W && j.classList.add("cell-border-top"), K === M && j.classList.add("cell-border-bottom"), Z === le && j.classList.add("cell-border-left"), Z === V && j.classList.add("cell-border-right");
|
|
1287
1401
|
break;
|
|
1288
1402
|
}
|
|
1289
1403
|
}
|
|
1290
1404
|
});
|
|
1291
1405
|
});
|
|
1292
|
-
},
|
|
1293
|
-
if (
|
|
1406
|
+
}, wt = async () => {
|
|
1407
|
+
if (y.selectedCells.length === 0)
|
|
1294
1408
|
return;
|
|
1295
|
-
const
|
|
1296
|
-
if (!
|
|
1409
|
+
const f = m.value;
|
|
1410
|
+
if (!f)
|
|
1297
1411
|
return;
|
|
1298
|
-
const
|
|
1299
|
-
(
|
|
1300
|
-
),
|
|
1301
|
-
(
|
|
1302
|
-
),
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
].filter(Boolean),
|
|
1307
|
-
|
|
1308
|
-
const
|
|
1309
|
-
|
|
1310
|
-
const Z =
|
|
1412
|
+
const c = f.$el, $ = f.getColumns(), T = [...new Set(y.selectedCells.map((V) => V.rowIndex))].sort(
|
|
1413
|
+
(V, I) => V - I
|
|
1414
|
+
), U = [...new Set(y.selectedCells.map((V) => V.colIndex))].sort(
|
|
1415
|
+
(V, I) => V - I
|
|
1416
|
+
), W = [
|
|
1417
|
+
c.querySelector(".vxe-table--body-wrapper tbody"),
|
|
1418
|
+
c.querySelector(".vxe-table--fixed-left-wrapper tbody"),
|
|
1419
|
+
c.querySelector(".vxe-table--fixed-right-wrapper tbody")
|
|
1420
|
+
].filter(Boolean), M = [];
|
|
1421
|
+
T.forEach((V) => {
|
|
1422
|
+
const I = [];
|
|
1423
|
+
U.forEach((K) => {
|
|
1424
|
+
const Z = $[K];
|
|
1311
1425
|
if (!Z) {
|
|
1312
|
-
|
|
1426
|
+
I.push("");
|
|
1313
1427
|
return;
|
|
1314
1428
|
}
|
|
1315
1429
|
const P = Z.fixed === "left", G = Z.fixed === "right";
|
|
1316
|
-
let
|
|
1317
|
-
for (const ee of
|
|
1318
|
-
const
|
|
1319
|
-
if (!
|
|
1430
|
+
let N = "";
|
|
1431
|
+
for (const ee of W) {
|
|
1432
|
+
const we = ee.querySelectorAll(".vxe-body--row")[V];
|
|
1433
|
+
if (!we)
|
|
1320
1434
|
continue;
|
|
1321
|
-
const de = Array.from(
|
|
1322
|
-
let
|
|
1435
|
+
const de = Array.from(we.querySelectorAll(".vxe-body--column"));
|
|
1436
|
+
let j = null;
|
|
1323
1437
|
if (P && ee.closest(".vxe-table--fixed-left-wrapper")) {
|
|
1324
|
-
const te =
|
|
1325
|
-
|
|
1438
|
+
const te = $.filter((ne) => ne.fixed === "left").indexOf(Z);
|
|
1439
|
+
j = de[te];
|
|
1326
1440
|
} else if (G && ee.closest(".vxe-table--fixed-right-wrapper")) {
|
|
1327
|
-
const te =
|
|
1328
|
-
|
|
1441
|
+
const te = $.filter((ne) => ne.fixed === "right").indexOf(Z);
|
|
1442
|
+
j = de[te];
|
|
1329
1443
|
} else if (!P && !G && ee.closest(".vxe-table--body-wrapper")) {
|
|
1330
|
-
const fe =
|
|
1331
|
-
|
|
1444
|
+
const fe = l.searchForm.showCheckBox ? 1 : 0, te = $.filter((Fe) => Fe.fixed === "left").length, ne = K - te;
|
|
1445
|
+
j = de[ne + fe];
|
|
1332
1446
|
}
|
|
1333
|
-
if (
|
|
1334
|
-
|
|
1447
|
+
if (j && !j.classList.contains("col--checkbox") && !j.classList.contains("col--seq")) {
|
|
1448
|
+
N = j.innerText || j.textContent || "", N = N.trim(), N = N.replace(/\n/g, " ").replace(/\s+/g, " ");
|
|
1335
1449
|
break;
|
|
1336
1450
|
}
|
|
1337
1451
|
}
|
|
1338
|
-
|
|
1339
|
-
}),
|
|
1452
|
+
I.push(N);
|
|
1453
|
+
}), M.push(I.join(" "));
|
|
1340
1454
|
});
|
|
1341
|
-
const le =
|
|
1455
|
+
const le = M.join(`
|
|
1342
1456
|
`);
|
|
1343
1457
|
try {
|
|
1344
1458
|
await navigator.clipboard.writeText(le);
|
|
1345
|
-
} catch (
|
|
1346
|
-
console.error("复制失败:",
|
|
1459
|
+
} catch (V) {
|
|
1460
|
+
console.error("复制失败:", V);
|
|
1347
1461
|
}
|
|
1348
|
-
}, Le = (
|
|
1349
|
-
|
|
1350
|
-
},
|
|
1351
|
-
|
|
1352
|
-
},
|
|
1353
|
-
const
|
|
1354
|
-
if (!
|
|
1462
|
+
}, Le = (f) => {
|
|
1463
|
+
l.searchForm.enableCellCopy && ((f.ctrlKey || f.metaKey) && f.key === "c" ? y.selectedCells.length > 0 && (f.preventDefault(), f.stopPropagation(), wt()) : f.key === "Escape" && Ie());
|
|
1464
|
+
}, Ne = () => {
|
|
1465
|
+
y.isSelecting = !1;
|
|
1466
|
+
}, We = (f) => {
|
|
1467
|
+
const c = m.value;
|
|
1468
|
+
if (!c || !c.$el)
|
|
1355
1469
|
return;
|
|
1356
|
-
|
|
1357
|
-
},
|
|
1358
|
-
g[
|
|
1359
|
-
},
|
|
1360
|
-
g[
|
|
1470
|
+
c.$el.contains(f.target) || Ie();
|
|
1471
|
+
}, xt = (f) => {
|
|
1472
|
+
g[b] = f, F();
|
|
1473
|
+
}, Ct = (f) => {
|
|
1474
|
+
g[p] = f, g[b] = 1, F();
|
|
1361
1475
|
};
|
|
1362
|
-
function
|
|
1363
|
-
const
|
|
1364
|
-
|
|
1476
|
+
function Ze() {
|
|
1477
|
+
const f = m.value.getCheckboxRecords();
|
|
1478
|
+
l.searchForm.selections = f;
|
|
1365
1479
|
}
|
|
1366
|
-
const
|
|
1367
|
-
const
|
|
1368
|
-
if (
|
|
1369
|
-
|
|
1370
|
-
const
|
|
1371
|
-
|
|
1480
|
+
const Ge = (f) => {
|
|
1481
|
+
const c = m.value;
|
|
1482
|
+
if (c) {
|
|
1483
|
+
c.toggleCheckboxRow(f);
|
|
1484
|
+
const $ = m.value.getCheckboxRecords();
|
|
1485
|
+
l.searchForm.selections = $;
|
|
1372
1486
|
}
|
|
1373
1487
|
};
|
|
1374
|
-
return e({ tableRef:
|
|
1375
|
-
var
|
|
1376
|
-
const
|
|
1377
|
-
return L(),
|
|
1378
|
-
class:
|
|
1488
|
+
return e({ tableRef: m, getList: F, getPrm: x, clearSort: O, calculateTableHeight: k }), (f, c) => {
|
|
1489
|
+
var V;
|
|
1490
|
+
const $ = z("el-button"), T = z("el-checkbox"), U = z("el-text"), W = z("vxe-column"), M = z("VxeTable"), le = z("el-pagination");
|
|
1491
|
+
return L(), se("div", {
|
|
1492
|
+
class: Ve({ box: t.searchForm.showShadow })
|
|
1379
1493
|
}, [
|
|
1380
|
-
t.searchForm.showSearch ? (L(), B(
|
|
1494
|
+
t.searchForm.showSearch ? (L(), B(vn, {
|
|
1381
1495
|
key: 0,
|
|
1382
1496
|
form: t.searchForm,
|
|
1383
|
-
onReset:
|
|
1384
|
-
onConfirm:
|
|
1385
|
-
onVisibleChange:
|
|
1497
|
+
onReset: d,
|
|
1498
|
+
onConfirm: c[1] || (c[1] = (I) => F()),
|
|
1499
|
+
onVisibleChange: H(k)
|
|
1386
1500
|
}, {
|
|
1387
|
-
btn:
|
|
1388
|
-
|
|
1389
|
-
X(
|
|
1390
|
-
|
|
1501
|
+
btn: D(() => [
|
|
1502
|
+
c[3] || (c[3] = ae("span", { class: "mgr10" }, null, -1)),
|
|
1503
|
+
X(f.$slots, "search-bar-btn", {}, void 0, !0),
|
|
1504
|
+
q($, {
|
|
1391
1505
|
class: "mgl10",
|
|
1392
1506
|
round: "",
|
|
1393
|
-
onClick:
|
|
1507
|
+
onClick: c[0] || (c[0] = (I) => m.value.openCustom())
|
|
1394
1508
|
}, {
|
|
1395
|
-
default:
|
|
1396
|
-
|
|
1509
|
+
default: D(() => [
|
|
1510
|
+
q(yt, { name: "Tools" })
|
|
1397
1511
|
]),
|
|
1398
1512
|
_: 1
|
|
1399
1513
|
})
|
|
1400
1514
|
]),
|
|
1401
1515
|
_: 3
|
|
1402
1516
|
}, 8, ["form", "onVisibleChange"])) : ce("", !0),
|
|
1403
|
-
X(
|
|
1517
|
+
X(f.$slots, "table-header-left", {}, void 0, !0),
|
|
1404
1518
|
ae("div", {
|
|
1405
1519
|
ref_key: "tableContentRef",
|
|
1406
|
-
ref:
|
|
1520
|
+
ref: u
|
|
1407
1521
|
}, [
|
|
1408
|
-
|
|
1409
|
-
id:
|
|
1522
|
+
q(M, he({
|
|
1523
|
+
id: v.value,
|
|
1410
1524
|
ref_key: "tableRef",
|
|
1411
|
-
ref:
|
|
1412
|
-
loading: t.loading ||
|
|
1413
|
-
data: t.api ?
|
|
1525
|
+
ref: m,
|
|
1526
|
+
loading: t.loading || s.value,
|
|
1527
|
+
data: t.api ? i.value : t.data,
|
|
1414
1528
|
border: ""
|
|
1415
1529
|
}, ue.value, {
|
|
1416
|
-
height:
|
|
1417
|
-
onCheckboxChange:
|
|
1418
|
-
onCheckboxAll:
|
|
1419
|
-
onSortChange: (
|
|
1530
|
+
height: S.value,
|
|
1531
|
+
onCheckboxChange: Ze,
|
|
1532
|
+
onCheckboxAll: Ze,
|
|
1533
|
+
onSortChange: (V = ue.value["sort-config"]) == null ? void 0 : V.sortChange
|
|
1420
1534
|
}), {
|
|
1421
|
-
default:
|
|
1422
|
-
t.searchForm.showCheckBox == null || t.searchForm.showCheckBox ? (L(), B(
|
|
1535
|
+
default: D(() => [
|
|
1536
|
+
t.searchForm.showCheckBox == null || t.searchForm.showCheckBox ? (L(), B(W, {
|
|
1423
1537
|
key: 0,
|
|
1424
1538
|
type: "checkbox",
|
|
1425
|
-
width:
|
|
1426
|
-
title:
|
|
1539
|
+
width: H(a) == "zh_cn" ? 80 : 150,
|
|
1540
|
+
title: f.$t("xu-hao"),
|
|
1427
1541
|
fixed: "left"
|
|
1428
1542
|
}, {
|
|
1429
|
-
checkbox:
|
|
1430
|
-
ae("div",
|
|
1431
|
-
Z ? (L(), B(
|
|
1543
|
+
checkbox: D(({ rowIndex: I, row: K, checked: Z, disabled: P, indeterminate: G }) => [
|
|
1544
|
+
ae("div", wn, [
|
|
1545
|
+
Z ? (L(), B(T, {
|
|
1432
1546
|
key: 0,
|
|
1433
1547
|
checked: !0,
|
|
1434
1548
|
disabled: P,
|
|
1435
1549
|
size: "default",
|
|
1436
|
-
onClick:
|
|
1437
|
-
}, null, 8, ["disabled", "onClick"])) : (L(), B(
|
|
1550
|
+
onClick: Me((N) => !P && Ge(K), ["stop"])
|
|
1551
|
+
}, null, 8, ["disabled", "onClick"])) : (L(), B(T, {
|
|
1438
1552
|
key: 1,
|
|
1439
1553
|
disabled: P,
|
|
1440
1554
|
checked: !1,
|
|
1441
1555
|
size: "default",
|
|
1442
|
-
onClick:
|
|
1556
|
+
onClick: Me((N) => !P && Ge(K), ["stop"])
|
|
1443
1557
|
}, null, 8, ["disabled", "onClick"])),
|
|
1444
|
-
|
|
1558
|
+
q(U, {
|
|
1445
1559
|
type: "info",
|
|
1446
1560
|
class: "mgl5"
|
|
1447
1561
|
}, {
|
|
1448
|
-
default:
|
|
1449
|
-
Q(J(
|
|
1562
|
+
default: D(() => [
|
|
1563
|
+
Q(J(I + 1), 1)
|
|
1450
1564
|
]),
|
|
1451
1565
|
_: 2
|
|
1452
1566
|
}, 1024)
|
|
@@ -1454,28 +1568,28 @@ const yn = { class: "center" }, vn = {
|
|
|
1454
1568
|
]),
|
|
1455
1569
|
_: 1
|
|
1456
1570
|
}, 8, ["width", "title"])) : ce("", !0),
|
|
1457
|
-
X(
|
|
1571
|
+
X(f.$slots, "default", {}, void 0, !0)
|
|
1458
1572
|
]),
|
|
1459
1573
|
_: 3
|
|
1460
1574
|
}, 16, ["id", "loading", "data", "height", "onSortChange"])
|
|
1461
1575
|
], 512),
|
|
1462
1576
|
t.searchForm.showPage ? (L(), B(le, {
|
|
1463
1577
|
key: 1,
|
|
1464
|
-
"current-page": g[
|
|
1465
|
-
"onUpdate:currentPage":
|
|
1578
|
+
"current-page": g[H(b)],
|
|
1579
|
+
"onUpdate:currentPage": c[2] || (c[2] = (I) => g[H(b)] = I),
|
|
1466
1580
|
class: "myPagination mgt10",
|
|
1467
1581
|
background: "",
|
|
1468
1582
|
layout: "total, sizes, prev, pager, next",
|
|
1469
1583
|
total: g.total,
|
|
1470
|
-
"page-size": g[
|
|
1471
|
-
"page-sizes": t.searchForm.pageSizes ||
|
|
1472
|
-
onCurrentChange:
|
|
1473
|
-
onSizeChange:
|
|
1584
|
+
"page-size": g[H(p)],
|
|
1585
|
+
"page-sizes": t.searchForm.pageSizes || H(o).pageSizes,
|
|
1586
|
+
onCurrentChange: xt,
|
|
1587
|
+
onSizeChange: Ct
|
|
1474
1588
|
}, null, 8, ["current-page", "total", "page-size", "page-sizes"])) : ce("", !0)
|
|
1475
1589
|
], 2);
|
|
1476
1590
|
};
|
|
1477
1591
|
}
|
|
1478
|
-
},
|
|
1592
|
+
}, Qn = /* @__PURE__ */ _e(xn, [["__scopeId", "data-v-d93cad32"]]), eo = {
|
|
1479
1593
|
__name: "index",
|
|
1480
1594
|
props: {
|
|
1481
1595
|
sheetsConfig: {
|
|
@@ -1490,40 +1604,40 @@ const yn = { class: "center" }, vn = {
|
|
|
1490
1604
|
setup(t) {
|
|
1491
1605
|
const e = t;
|
|
1492
1606
|
function n() {
|
|
1493
|
-
|
|
1607
|
+
nn(e.fileName, e.sheetsConfig);
|
|
1494
1608
|
}
|
|
1495
|
-
return (
|
|
1496
|
-
const o =
|
|
1609
|
+
return (a, r) => {
|
|
1610
|
+
const o = z("el-link");
|
|
1497
1611
|
return L(), B(o, he({
|
|
1498
1612
|
type: "primary",
|
|
1499
1613
|
underline: "never"
|
|
1500
|
-
},
|
|
1501
|
-
default:
|
|
1502
|
-
Q(J(
|
|
1614
|
+
}, a.$attrs, { onClick: n }), {
|
|
1615
|
+
default: D(() => [
|
|
1616
|
+
Q(J(a.$t("xia-zai-dao-ru-mo-ban")), 1)
|
|
1503
1617
|
]),
|
|
1504
1618
|
_: 1
|
|
1505
1619
|
}, 16);
|
|
1506
1620
|
};
|
|
1507
1621
|
}
|
|
1508
|
-
},
|
|
1622
|
+
}, Cn = {
|
|
1509
1623
|
mounted(t, e) {
|
|
1510
|
-
e.value &&
|
|
1624
|
+
e.value && tt(t);
|
|
1511
1625
|
},
|
|
1512
1626
|
updated(t, e) {
|
|
1513
|
-
e.value ?
|
|
1627
|
+
e.value ? tt(t) : nt(t);
|
|
1514
1628
|
},
|
|
1515
1629
|
beforeUnmount(t) {
|
|
1516
|
-
|
|
1630
|
+
nt(t);
|
|
1517
1631
|
}
|
|
1518
1632
|
};
|
|
1519
|
-
async function
|
|
1520
|
-
await
|
|
1633
|
+
async function tt(t) {
|
|
1634
|
+
await p();
|
|
1521
1635
|
const e = t.querySelector(".el-dialog");
|
|
1522
1636
|
if (!e)
|
|
1523
1637
|
return;
|
|
1524
|
-
const n = t.querySelector(".el-dialog__header"),
|
|
1525
|
-
|
|
1526
|
-
let
|
|
1638
|
+
const n = t.querySelector(".el-dialog__header"), a = t.querySelector(".el-overlay");
|
|
1639
|
+
a.style.cssText += "overflow: hidden;", n.style.cursor = "move";
|
|
1640
|
+
let r = !1, o = {
|
|
1527
1641
|
// 数据源,不变部分为:window信息、dialog信息、mouse初始值信息,可变部分为:拖拽坐标位移
|
|
1528
1642
|
window: {
|
|
1529
1643
|
// window信息
|
|
@@ -1549,50 +1663,50 @@ async function Qe(t) {
|
|
|
1549
1663
|
y: 0
|
|
1550
1664
|
}
|
|
1551
1665
|
};
|
|
1552
|
-
n.addEventListener("mousedown",
|
|
1553
|
-
function
|
|
1554
|
-
o.mouse.x - o.drag.x >= o.dialog.x && (o.drag.x = o.mouse.x - o.dialog.x), o.drag.x - o.mouse.x >= o.window.width - (o.dialog.x + o.dialog.width) && (o.drag.x = o.mouse.x + o.window.width - o.dialog.x - o.dialog.width), o.mouse.y - o.drag.y >= o.dialog.y && (o.drag.y = o.mouse.y - o.dialog.y), o.drag.y - o.mouse.y >= o.window.height - (o.dialog.y + o.dialog.height) && (o.drag.y = o.mouse.y + o.window.height - o.dialog.y - o.dialog.height),
|
|
1666
|
+
n.addEventListener("mousedown", i), document.addEventListener("mousemove", v), document.addEventListener("mouseup", w), window.addEventListener("resize", b);
|
|
1667
|
+
function l() {
|
|
1668
|
+
o.mouse.x - o.drag.x >= o.dialog.x && (o.drag.x = o.mouse.x - o.dialog.x), o.drag.x - o.mouse.x >= o.window.width - (o.dialog.x + o.dialog.width) && (o.drag.x = o.mouse.x + o.window.width - o.dialog.x - o.dialog.width), o.mouse.y - o.drag.y >= o.dialog.y && (o.drag.y = o.mouse.y - o.dialog.y), o.drag.y - o.mouse.y >= o.window.height - (o.dialog.y + o.dialog.height) && (o.drag.y = o.mouse.y + o.window.height - o.dialog.y - o.dialog.height), s();
|
|
1555
1669
|
}
|
|
1556
|
-
function
|
|
1557
|
-
let g = o.drag.y - o.mouse.y + o.dialog.y,
|
|
1558
|
-
e.style.cssText += `position: absolute; top: calc(${g}px - ${o.dialog.marginTop}); left: ${
|
|
1670
|
+
function s() {
|
|
1671
|
+
let g = o.drag.y - o.mouse.y + o.dialog.y, m = o.drag.x - o.mouse.x + o.dialog.x;
|
|
1672
|
+
e.style.cssText += `position: absolute; top: calc(${g}px - ${o.dialog.marginTop}); left: ${m}px;`;
|
|
1559
1673
|
}
|
|
1560
|
-
function
|
|
1674
|
+
function i(g) {
|
|
1561
1675
|
g.button === 0 && (o.window = {
|
|
1562
1676
|
width: document.body.clientWidth,
|
|
1563
1677
|
height: document.body.clientHeight
|
|
1564
1678
|
}, o.dialog = e.getBoundingClientRect(), o.dialog.marginTop = window.getComputedStyle(e).marginTop, o.mouse = {
|
|
1565
1679
|
x: g.clientX,
|
|
1566
1680
|
y: g.clientY
|
|
1567
|
-
},
|
|
1681
|
+
}, r = !0);
|
|
1568
1682
|
}
|
|
1569
|
-
function
|
|
1570
|
-
|
|
1683
|
+
function v(g) {
|
|
1684
|
+
r && (o.drag = {
|
|
1571
1685
|
x: g.clientX,
|
|
1572
1686
|
y: g.clientY
|
|
1573
|
-
},
|
|
1574
|
-
}
|
|
1575
|
-
function C(g) {
|
|
1576
|
-
l.style.userSelect = "auto", s = !1;
|
|
1687
|
+
}, a.style.userSelect = "none", l());
|
|
1577
1688
|
}
|
|
1578
1689
|
function w(g) {
|
|
1690
|
+
a.style.userSelect = "auto", r = !1;
|
|
1579
1691
|
}
|
|
1580
|
-
function
|
|
1581
|
-
|
|
1692
|
+
function b(g) {
|
|
1693
|
+
}
|
|
1694
|
+
function p() {
|
|
1695
|
+
return new Promise((g, m) => {
|
|
1582
1696
|
setTimeout(() => {
|
|
1583
1697
|
g();
|
|
1584
1698
|
}, 500);
|
|
1585
1699
|
});
|
|
1586
1700
|
}
|
|
1587
|
-
t.__mouseDown__ =
|
|
1701
|
+
t.__mouseDown__ = i, t.__mouseUp__ = w, t.__mouseMove__ = v, t.__sizeChange__ = b;
|
|
1588
1702
|
}
|
|
1589
|
-
function
|
|
1703
|
+
function nt(t) {
|
|
1590
1704
|
document.removeEventListener("mousedown", t.__mouseDown__), document.removeEventListener("mousemove", t.__mouseMove__), document.removeEventListener("mouseup", t.__mouseUp__), window.removeEventListener("resize", t.__sizeChange__);
|
|
1591
1705
|
}
|
|
1592
|
-
const
|
|
1706
|
+
const kn = {
|
|
1593
1707
|
key: 0,
|
|
1594
1708
|
class: "drawer-btn"
|
|
1595
|
-
},
|
|
1709
|
+
}, _n = { key: 1 }, to = {
|
|
1596
1710
|
__name: "index",
|
|
1597
1711
|
props: {
|
|
1598
1712
|
layer: {
|
|
@@ -1612,48 +1726,48 @@ const wn = {
|
|
|
1612
1726
|
},
|
|
1613
1727
|
emits: ["confirm"],
|
|
1614
1728
|
setup(t, { emit: e }) {
|
|
1615
|
-
const n = t,
|
|
1616
|
-
|
|
1729
|
+
const n = t, a = e, { t: r } = me(), o = Re(() => {
|
|
1730
|
+
a("confirm");
|
|
1617
1731
|
}, 300);
|
|
1618
|
-
async function
|
|
1619
|
-
n.layer.type == "drawer" ? n.layer.onClose ? n.layer.onClose() : await
|
|
1620
|
-
confirmButtonText:
|
|
1621
|
-
cancelButtonText:
|
|
1732
|
+
async function l() {
|
|
1733
|
+
n.layer.type == "drawer" ? n.layer.onClose ? n.layer.onClose() : await Et.confirm(r("que-ding-guan-bi-ma"), {
|
|
1734
|
+
confirmButtonText: r("que-ding"),
|
|
1735
|
+
cancelButtonText: r("qu-xiao"),
|
|
1622
1736
|
type: "warning"
|
|
1623
1737
|
}).catch(() => {
|
|
1624
1738
|
}) == "confirm" && (n.layer.show = !1) : n.layer.show = !1;
|
|
1625
1739
|
}
|
|
1626
|
-
return (
|
|
1627
|
-
const
|
|
1628
|
-
return t.layer.type ? (L(), B(
|
|
1740
|
+
return (s, i) => {
|
|
1741
|
+
const v = z("el-button"), w = z("el-drawer"), b = z("el-dialog");
|
|
1742
|
+
return t.layer.type ? (L(), B(w, {
|
|
1629
1743
|
key: 0,
|
|
1630
1744
|
modelValue: t.layer.show,
|
|
1631
|
-
"onUpdate:modelValue":
|
|
1745
|
+
"onUpdate:modelValue": i[0] || (i[0] = (p) => t.layer.show = p),
|
|
1632
1746
|
size: t.layer.width || "100%",
|
|
1633
1747
|
title: t.layer.title,
|
|
1634
1748
|
direction: "rtl",
|
|
1635
1749
|
"append-to-body": "",
|
|
1636
|
-
"before-close":
|
|
1750
|
+
"before-close": l,
|
|
1637
1751
|
class: "drawer-content"
|
|
1638
1752
|
}, {
|
|
1639
|
-
default:
|
|
1640
|
-
X(
|
|
1641
|
-
|
|
1642
|
-
t.layer.showButton ? (L(),
|
|
1643
|
-
X(
|
|
1644
|
-
|
|
1645
|
-
default:
|
|
1646
|
-
Q(J(
|
|
1753
|
+
default: D(() => [
|
|
1754
|
+
X(s.$slots, "default"),
|
|
1755
|
+
i[2] || (i[2] = ae("p", { class: "mgt50" }, null, -1)),
|
|
1756
|
+
t.layer.showButton ? (L(), se("div", kn, [
|
|
1757
|
+
X(s.$slots, "btn", {}, () => [
|
|
1758
|
+
q(v, { onClick: l }, {
|
|
1759
|
+
default: D(() => [
|
|
1760
|
+
Q(J(s.$t("qu-xiao")), 1)
|
|
1647
1761
|
]),
|
|
1648
1762
|
_: 1
|
|
1649
1763
|
}),
|
|
1650
|
-
|
|
1764
|
+
q(v, {
|
|
1651
1765
|
type: "primary",
|
|
1652
1766
|
loading: t.loading,
|
|
1653
|
-
onClick:
|
|
1767
|
+
onClick: H(o)
|
|
1654
1768
|
}, {
|
|
1655
|
-
default:
|
|
1656
|
-
Q(J(
|
|
1769
|
+
default: D(() => [
|
|
1770
|
+
Q(J(s.$t("ti-jiao")), 1)
|
|
1657
1771
|
]),
|
|
1658
1772
|
_: 1
|
|
1659
1773
|
}, 8, ["loading", "onClick"])
|
|
@@ -1661,36 +1775,36 @@ const wn = {
|
|
|
1661
1775
|
])) : ce("", !0)
|
|
1662
1776
|
]),
|
|
1663
1777
|
_: 3
|
|
1664
|
-
}, 8, ["modelValue", "size", "title"])) :
|
|
1665
|
-
|
|
1778
|
+
}, 8, ["modelValue", "size", "title"])) : Vt((L(), se("div", _n, [
|
|
1779
|
+
q(b, {
|
|
1666
1780
|
"close-on-click-modal": !1,
|
|
1667
1781
|
modelValue: t.layer.show,
|
|
1668
|
-
"onUpdate:modelValue":
|
|
1782
|
+
"onUpdate:modelValue": i[1] || (i[1] = (p) => t.layer.show = p),
|
|
1669
1783
|
title: t.layer.title,
|
|
1670
1784
|
width: t.layer.width || 500,
|
|
1671
1785
|
center: ""
|
|
1672
|
-
},
|
|
1673
|
-
default:
|
|
1674
|
-
X(
|
|
1786
|
+
}, at({
|
|
1787
|
+
default: D(() => [
|
|
1788
|
+
X(s.$slots, "default")
|
|
1675
1789
|
]),
|
|
1676
1790
|
_: 2
|
|
1677
1791
|
}, [
|
|
1678
1792
|
t.layer.showButton ? {
|
|
1679
1793
|
name: "footer",
|
|
1680
|
-
fn:
|
|
1681
|
-
X(
|
|
1682
|
-
|
|
1683
|
-
default:
|
|
1684
|
-
Q(J(
|
|
1794
|
+
fn: D(() => [
|
|
1795
|
+
X(s.$slots, "btn", {}, () => [
|
|
1796
|
+
q(v, { onClick: l }, {
|
|
1797
|
+
default: D(() => [
|
|
1798
|
+
Q(J(s.$t("qu-xiao")), 1)
|
|
1685
1799
|
]),
|
|
1686
1800
|
_: 1
|
|
1687
1801
|
}),
|
|
1688
|
-
|
|
1802
|
+
q(v, {
|
|
1689
1803
|
type: "primary",
|
|
1690
|
-
onClick:
|
|
1804
|
+
onClick: H(o)
|
|
1691
1805
|
}, {
|
|
1692
|
-
default:
|
|
1693
|
-
Q(J(
|
|
1806
|
+
default: D(() => [
|
|
1807
|
+
Q(J(s.$t("ti-jiao")), 1)
|
|
1694
1808
|
]),
|
|
1695
1809
|
_: 1
|
|
1696
1810
|
}, 8, ["onClick"])
|
|
@@ -1700,30 +1814,30 @@ const wn = {
|
|
|
1700
1814
|
} : void 0
|
|
1701
1815
|
]), 1032, ["modelValue", "title", "width"])
|
|
1702
1816
|
])), [
|
|
1703
|
-
[
|
|
1817
|
+
[H(Cn), t.layer.show]
|
|
1704
1818
|
]);
|
|
1705
1819
|
};
|
|
1706
1820
|
}
|
|
1707
1821
|
};
|
|
1708
|
-
function
|
|
1709
|
-
const n =
|
|
1822
|
+
function no(t, e = {}) {
|
|
1823
|
+
const n = ve(), a = {
|
|
1710
1824
|
inForm: !0,
|
|
1711
1825
|
required: !0,
|
|
1712
1826
|
...e
|
|
1713
|
-
},
|
|
1827
|
+
}, r = {
|
|
1714
1828
|
phone: /^1(3[0-9]|4[01456879]|5[0-35-9]|6[2567]|7[0-8]|8[0-9]|9[0-35-9])\d{8}$/,
|
|
1715
1829
|
password: /(?=.*\d)(?=.*[a-zA-Z])(?=.*[^a-zA-Z0-9]).{8,12}/,
|
|
1716
1830
|
email: /^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/
|
|
1717
|
-
}[t], { inForm: o, value:
|
|
1718
|
-
return o ? function(
|
|
1719
|
-
if (
|
|
1720
|
-
|
|
1831
|
+
}[t], { inForm: o, value: l, required: s, msg: i = n("validate.invalidInput") } = a;
|
|
1832
|
+
return o ? function(v, w, b) {
|
|
1833
|
+
if (s) {
|
|
1834
|
+
r.test(w) ? b() : b(new Error(i));
|
|
1721
1835
|
return;
|
|
1722
1836
|
}
|
|
1723
|
-
|
|
1724
|
-
} :
|
|
1837
|
+
w && !r.test(w) ? b(new Error(i)) : b();
|
|
1838
|
+
} : r.test(l);
|
|
1725
1839
|
}
|
|
1726
|
-
class
|
|
1840
|
+
class oo {
|
|
1727
1841
|
constructor(e = {}) {
|
|
1728
1842
|
this.config = {
|
|
1729
1843
|
clientCode: e.clientCode || "one-portal",
|
|
@@ -1819,10 +1933,10 @@ class Qn {
|
|
|
1819
1933
|
});
|
|
1820
1934
|
if (!n.ok)
|
|
1821
1935
|
throw new Error(`HTTP ${n.status}: ${n.statusText}`);
|
|
1822
|
-
const
|
|
1823
|
-
if (
|
|
1824
|
-
return this.token =
|
|
1825
|
-
throw new Error(
|
|
1936
|
+
const a = await n.json();
|
|
1937
|
+
if (a.success && a.data)
|
|
1938
|
+
return this.token = a.data.token, this.user = a.data.user, this.saveToStorage(), this.clearTicketFromUrl(), this.log("ST票据验证成功,用户登录成功:", this.user), this.config.loginCallback && this.config.loginCallback(this.user, this.token), !0;
|
|
1939
|
+
throw new Error(a.message || "ST票据验证失败");
|
|
1826
1940
|
} catch (n) {
|
|
1827
1941
|
return this.log("ST票据验证失败:", n), this.handleError(n), !1;
|
|
1828
1942
|
}
|
|
@@ -1861,19 +1975,19 @@ class Qn {
|
|
|
1861
1975
|
* 发送带认证的HTTP请求
|
|
1862
1976
|
*/
|
|
1863
1977
|
async request(e, n = {}) {
|
|
1864
|
-
const
|
|
1978
|
+
const a = {
|
|
1865
1979
|
headers: {
|
|
1866
1980
|
"Content-Type": "application/json",
|
|
1867
1981
|
...n.headers
|
|
1868
1982
|
},
|
|
1869
1983
|
...n
|
|
1870
1984
|
};
|
|
1871
|
-
|
|
1985
|
+
a.headers.appId = this.config.clientCode, this.token && (a.headers.Authorization = `Bearer ${this.token}`);
|
|
1872
1986
|
try {
|
|
1873
|
-
const
|
|
1874
|
-
return
|
|
1875
|
-
} catch (
|
|
1876
|
-
throw this.log("请求失败:",
|
|
1987
|
+
const r = await fetch(e, a);
|
|
1988
|
+
return r.status === 401 ? (this.log("Token已过期,需要重新登录"), this.logout(), null) : r;
|
|
1989
|
+
} catch (r) {
|
|
1990
|
+
throw this.log("请求失败:", r), r;
|
|
1877
1991
|
}
|
|
1878
1992
|
}
|
|
1879
1993
|
/**
|
|
@@ -1929,126 +2043,126 @@ class Qn {
|
|
|
1929
2043
|
return this.config[e];
|
|
1930
2044
|
}
|
|
1931
2045
|
}
|
|
1932
|
-
function
|
|
1933
|
-
const
|
|
2046
|
+
function lo(t, e = {}) {
|
|
2047
|
+
const a = Object.assign({
|
|
1934
2048
|
manual: !1,
|
|
1935
2049
|
// 手动执行
|
|
1936
2050
|
log: !1,
|
|
1937
2051
|
params: null,
|
|
1938
2052
|
format: null
|
|
1939
|
-
}, e), { manual:
|
|
1940
|
-
const g =
|
|
1941
|
-
|
|
1942
|
-
const { code:
|
|
1943
|
-
if (
|
|
1944
|
-
const { records:
|
|
1945
|
-
|
|
2053
|
+
}, e), { manual: r, log: o, params: l = {}, cb: s, format: i } = a, v = R([]), w = R(!1), b = (p) => {
|
|
2054
|
+
const g = p || l;
|
|
2055
|
+
w.value = !0, t(g).then((m) => {
|
|
2056
|
+
const { code: u, data: h, msg: k } = m;
|
|
2057
|
+
if (s) {
|
|
2058
|
+
const { records: _, rows: C } = h || {}, S = _ || C ? _ || C : h;
|
|
2059
|
+
v.value = De(S, i), s(m);
|
|
1946
2060
|
}
|
|
1947
|
-
if (
|
|
1948
|
-
if (
|
|
1949
|
-
const { records:
|
|
1950
|
-
g && g.total != null && (
|
|
2061
|
+
if (h) {
|
|
2062
|
+
if (h.records != null || h.rows != null) {
|
|
2063
|
+
const { records: _, rows: C, total: S = 0 } = h || {};
|
|
2064
|
+
g && g.total != null && (l.total = parseInt(S)), v.value = De(_ || C || [], i);
|
|
1951
2065
|
} else
|
|
1952
|
-
|
|
1953
|
-
o && console.log("useRequest-res",
|
|
2066
|
+
v.value = De(h, i);
|
|
2067
|
+
o && console.log("useRequest-res", v.value);
|
|
1954
2068
|
}
|
|
1955
|
-
}).catch((
|
|
1956
|
-
|
|
2069
|
+
}).catch((m) => {
|
|
2070
|
+
s && (console.log("useRequestErr", m), s({ code: 500 }));
|
|
1957
2071
|
}).finally(() => {
|
|
1958
|
-
|
|
2072
|
+
w.value = !1;
|
|
1959
2073
|
});
|
|
1960
2074
|
};
|
|
1961
|
-
return
|
|
2075
|
+
return r || b(), [w, v, b];
|
|
1962
2076
|
}
|
|
1963
|
-
function
|
|
1964
|
-
const e = R(t), n = R(""),
|
|
1965
|
-
return
|
|
1966
|
-
const o =
|
|
1967
|
-
n.value = o[0],
|
|
1968
|
-
}), [e, n,
|
|
2077
|
+
function ao(t) {
|
|
2078
|
+
const e = R(t), n = R(""), a = R("");
|
|
2079
|
+
return Pe(e, (r) => {
|
|
2080
|
+
const o = r || ["", ""];
|
|
2081
|
+
n.value = o[0], a.value = o[1];
|
|
2082
|
+
}), [e, n, a];
|
|
1969
2083
|
}
|
|
1970
|
-
function
|
|
2084
|
+
function ro(t) {
|
|
1971
2085
|
return Object.prototype.toString.call(t).slice(8, -1).toLowerCase();
|
|
1972
2086
|
}
|
|
1973
|
-
function
|
|
2087
|
+
function De(t, e) {
|
|
1974
2088
|
if (!e)
|
|
1975
2089
|
return t;
|
|
1976
2090
|
if (t instanceof Array)
|
|
1977
|
-
return t.map((
|
|
1978
|
-
let
|
|
1979
|
-
return e.forEach((o) =>
|
|
2091
|
+
return t.map((a) => {
|
|
2092
|
+
let r = {};
|
|
2093
|
+
return e.forEach((o) => r[o] = a[o]), r;
|
|
1980
2094
|
});
|
|
1981
2095
|
let n = {};
|
|
1982
|
-
return e.forEach((
|
|
2096
|
+
return e.forEach((a) => n[a] = t[a]), n;
|
|
1983
2097
|
}
|
|
1984
|
-
function
|
|
1985
|
-
const { locale: n } = me(),
|
|
1986
|
-
return
|
|
2098
|
+
function so(t, e = []) {
|
|
2099
|
+
const { locale: n } = me(), a = R(t());
|
|
2100
|
+
return Pe(
|
|
1987
2101
|
[n, ...e],
|
|
1988
2102
|
() => {
|
|
1989
|
-
|
|
2103
|
+
a.value = t();
|
|
1990
2104
|
},
|
|
1991
2105
|
{ immediate: !0 }
|
|
1992
|
-
),
|
|
2106
|
+
), a;
|
|
1993
2107
|
}
|
|
1994
|
-
function
|
|
2108
|
+
function io(t, e = "zh_cn", n = "en_us") {
|
|
1995
2109
|
if (!t)
|
|
1996
2110
|
return "-";
|
|
1997
|
-
const
|
|
1998
|
-
return t[
|
|
2111
|
+
const a = { en_us: n, zh_cn: e }, o = Ye().global.locale.value;
|
|
2112
|
+
return t[a[o]] || t[e] || "-";
|
|
1999
2113
|
}
|
|
2000
|
-
function
|
|
2001
|
-
let n =
|
|
2002
|
-
return typeof t == "string" && t.length > 0 && (n =
|
|
2114
|
+
function co(t, e) {
|
|
2115
|
+
let n = Pt;
|
|
2116
|
+
return typeof t == "string" && t.length > 0 && (n = Be(t).mapState), bt(e, n);
|
|
2003
2117
|
}
|
|
2004
|
-
function
|
|
2005
|
-
let n =
|
|
2006
|
-
return typeof t == "string" && t.length > 0 && (n =
|
|
2118
|
+
function uo(t, e) {
|
|
2119
|
+
let n = Rt;
|
|
2120
|
+
return typeof t == "string" && t.length > 0 && (n = Be(t).mapGetters), bt(e, n);
|
|
2007
2121
|
}
|
|
2008
|
-
function
|
|
2009
|
-
let n =
|
|
2010
|
-
return typeof t == "string" && t.length > 0 && (n =
|
|
2122
|
+
function fo(t, e) {
|
|
2123
|
+
let n = Bt;
|
|
2124
|
+
return typeof t == "string" && t.length > 0 && (n = Be(t).mapActions), $n(e, n);
|
|
2011
2125
|
}
|
|
2012
|
-
function
|
|
2013
|
-
const n =
|
|
2014
|
-
return Object.keys(
|
|
2015
|
-
const
|
|
2016
|
-
|
|
2017
|
-
}),
|
|
2126
|
+
function bt(t, e) {
|
|
2127
|
+
const n = ut(), a = e(t), r = {};
|
|
2128
|
+
return Object.keys(a).forEach((o) => {
|
|
2129
|
+
const l = a[o].bind({ $store: n });
|
|
2130
|
+
r[o] = re(l);
|
|
2131
|
+
}), r;
|
|
2018
2132
|
}
|
|
2019
|
-
function
|
|
2020
|
-
const n =
|
|
2021
|
-
return Object.keys(
|
|
2022
|
-
|
|
2023
|
-
}),
|
|
2133
|
+
function $n(t, e) {
|
|
2134
|
+
const n = ut(), a = e(t), r = {};
|
|
2135
|
+
return Object.keys(a).forEach((o) => {
|
|
2136
|
+
r[o] = a[o].bind({ $store: n });
|
|
2137
|
+
}), r;
|
|
2024
2138
|
}
|
|
2025
|
-
function
|
|
2026
|
-
return typeof t == "function" || Object.prototype.toString.call(t) === "[object Object]" && !
|
|
2139
|
+
function ze(t) {
|
|
2140
|
+
return typeof t == "function" || Object.prototype.toString.call(t) === "[object Object]" && !qt(t);
|
|
2027
2141
|
}
|
|
2028
|
-
function
|
|
2029
|
-
|
|
2142
|
+
function ho() {
|
|
2143
|
+
xe.renderer.add("Enum", {
|
|
2030
2144
|
// 默认显示模板
|
|
2031
2145
|
renderTableDefault(t, e) {
|
|
2032
2146
|
let n;
|
|
2033
2147
|
if ([null, void 0].includes(e.row[e.column.field]))
|
|
2034
2148
|
return "-";
|
|
2035
|
-
const
|
|
2149
|
+
const a = e.row[e.column.field];
|
|
2036
2150
|
if (t.type == "tag") {
|
|
2037
|
-
let
|
|
2038
|
-
return
|
|
2039
|
-
type: t.enum.getTag(
|
|
2040
|
-
},
|
|
2041
|
-
default: () => [
|
|
2151
|
+
let r;
|
|
2152
|
+
return q(z("el-text"), {
|
|
2153
|
+
type: t.enum.getTag(a)
|
|
2154
|
+
}, ze(r = t.enum.getName(a)) ? r : {
|
|
2155
|
+
default: () => [r]
|
|
2042
2156
|
});
|
|
2043
2157
|
}
|
|
2044
|
-
return
|
|
2158
|
+
return q(z("el-text"), null, ze(n = t.enum.getName(a)) ? n : {
|
|
2045
2159
|
default: () => [n]
|
|
2046
2160
|
});
|
|
2047
2161
|
}
|
|
2048
|
-
}),
|
|
2162
|
+
}), xe.renderer.add("InputNumber", {
|
|
2049
2163
|
// 默认显示模板
|
|
2050
2164
|
renderTableDefault(t, e) {
|
|
2051
|
-
return
|
|
2165
|
+
return q(It, he({
|
|
2052
2166
|
modelValue: e.row[e.column.field],
|
|
2053
2167
|
"onUpdate:modelValue": (n) => e.row[e.column.field] = n
|
|
2054
2168
|
}, t.props, {
|
|
@@ -2056,42 +2170,42 @@ function io() {
|
|
|
2056
2170
|
"value-on-clear": 0
|
|
2057
2171
|
}), null);
|
|
2058
2172
|
}
|
|
2059
|
-
}),
|
|
2173
|
+
}), xe.renderer.add("TrueFalse", {
|
|
2060
2174
|
// 默认显示模板
|
|
2061
2175
|
renderTableDefault(t, e) {
|
|
2062
2176
|
const {
|
|
2063
2177
|
locale: n
|
|
2064
2178
|
} = me();
|
|
2065
|
-
let
|
|
2066
|
-
return
|
|
2179
|
+
let a = n.value == "zh_cn";
|
|
2180
|
+
return q(Lt, {
|
|
2067
2181
|
type: e.row[e.column.field] ? "success" : "danger"
|
|
2068
2182
|
}, {
|
|
2069
|
-
default: () => [e.row[e.column.field] ?
|
|
2183
|
+
default: () => [e.row[e.column.field] ? a ? "是" : "YES" : a ? "否" : "NO"]
|
|
2070
2184
|
});
|
|
2071
2185
|
}
|
|
2072
|
-
}),
|
|
2186
|
+
}), xe.renderer.add("I18n", {
|
|
2073
2187
|
// 默认显示模板
|
|
2074
2188
|
renderTableDefault(t, e) {
|
|
2075
2189
|
const {
|
|
2076
2190
|
locale: n
|
|
2077
2191
|
} = me();
|
|
2078
|
-
let
|
|
2079
|
-
return e.row[
|
|
2192
|
+
let a = n.value == "zh_cn" ? e.column.field : t.fieldEn;
|
|
2193
|
+
return e.row[a] || e.row[e.column.field];
|
|
2080
2194
|
}
|
|
2081
|
-
}),
|
|
2195
|
+
}), xe.renderer.add("Link", {
|
|
2082
2196
|
// 默认显示模板
|
|
2083
2197
|
renderTableDefault(t, e) {
|
|
2084
|
-
var
|
|
2198
|
+
var s;
|
|
2085
2199
|
let n = e.column.field;
|
|
2086
|
-
const
|
|
2087
|
-
multiple:
|
|
2200
|
+
const a = Ut(), {
|
|
2201
|
+
multiple: r,
|
|
2088
2202
|
to: o
|
|
2089
2203
|
} = t;
|
|
2090
|
-
if (!
|
|
2091
|
-
return
|
|
2204
|
+
if (!r)
|
|
2205
|
+
return q(Je, {
|
|
2092
2206
|
underline: "never",
|
|
2093
2207
|
type: "primary",
|
|
2094
|
-
onclick: () =>
|
|
2208
|
+
onclick: () => a.push({
|
|
2095
2209
|
path: o,
|
|
2096
2210
|
query: {
|
|
2097
2211
|
[n]: e.row[n]
|
|
@@ -2100,64 +2214,64 @@ function io() {
|
|
|
2100
2214
|
}, {
|
|
2101
2215
|
default: () => [e.row[n]]
|
|
2102
2216
|
});
|
|
2103
|
-
const
|
|
2104
|
-
return
|
|
2217
|
+
const l = ((s = e.row[n]) == null ? void 0 : s.split(",")) || [];
|
|
2218
|
+
return l.map((i, v) => q("span", null, [q(Je, {
|
|
2105
2219
|
underline: "never",
|
|
2106
2220
|
type: "primary",
|
|
2107
|
-
onclick: () =>
|
|
2221
|
+
onclick: () => a.push({
|
|
2108
2222
|
path: o,
|
|
2109
2223
|
query: {
|
|
2110
|
-
[n]:
|
|
2224
|
+
[n]: i
|
|
2111
2225
|
}
|
|
2112
2226
|
})
|
|
2113
|
-
},
|
|
2114
|
-
default: () => [
|
|
2115
|
-
}),
|
|
2227
|
+
}, ze(i) ? i : {
|
|
2228
|
+
default: () => [i]
|
|
2229
|
+
}), v < l.length - 1 ? "," : ""]));
|
|
2116
2230
|
}
|
|
2117
2231
|
});
|
|
2118
2232
|
}
|
|
2119
2233
|
export {
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2162
|
-
|
|
2234
|
+
sn as CmpDictionary,
|
|
2235
|
+
yt as CmpIcon,
|
|
2236
|
+
Zn as ConfrimButton,
|
|
2237
|
+
eo as DownExcelTemp,
|
|
2238
|
+
Gn as ImportButton,
|
|
2239
|
+
Vn as LayOutForm,
|
|
2240
|
+
to as Layer,
|
|
2241
|
+
Qn as ListPage,
|
|
2242
|
+
oo as OnePortalCasSDK,
|
|
2243
|
+
vn as SearchBar,
|
|
2244
|
+
et as StatusMap,
|
|
2245
|
+
Un as _toRaw,
|
|
2246
|
+
ro as _typeOf,
|
|
2247
|
+
Rn as arrToStatusMap,
|
|
2248
|
+
Pn as arrayToTree,
|
|
2249
|
+
Kn as checkFileSize,
|
|
2250
|
+
no as creatValidator,
|
|
2251
|
+
Nn as createImportFields,
|
|
2252
|
+
Hn as createListPageId,
|
|
2253
|
+
Ae as en_us,
|
|
2254
|
+
An as exportExcel,
|
|
2255
|
+
Ye as getI18n,
|
|
2256
|
+
ve as getI18nT,
|
|
2257
|
+
bn as getListPageConfig,
|
|
2258
|
+
io as getLocaleValue,
|
|
2259
|
+
Wn as getValueBykey,
|
|
2260
|
+
qn as importExcel,
|
|
2261
|
+
Wt as messages,
|
|
2262
|
+
ho as registerVxeRenderers,
|
|
2263
|
+
Xn as resetListPageConfig,
|
|
2264
|
+
Jn as setListPageConfig,
|
|
2265
|
+
Zt as setupI18n,
|
|
2266
|
+
jn as sleep,
|
|
2267
|
+
pt as stringToArray,
|
|
2268
|
+
Bn as stripHtmlTags,
|
|
2269
|
+
Yn as unicode2Str,
|
|
2270
|
+
fo as useActions,
|
|
2271
|
+
ao as useDatePicker,
|
|
2272
|
+
uo as useGetters,
|
|
2273
|
+
so as useI18nReState,
|
|
2274
|
+
lo as useRequest,
|
|
2275
|
+
co as useState,
|
|
2276
|
+
qe as zh_cn
|
|
2163
2277
|
};
|