joy-admin-components 0.1.41 → 0.1.44
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/README.md +1 -10
- package/dist/joy-admin-components.es.js +475 -493
- package/dist/joy-admin-components.umd.js +2 -2
- package/dist/style.css +1 -1
- package/package.json +19 -8
- package/src/utils/index.d.ts +0 -17
|
@@ -1,105 +1,104 @@
|
|
|
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
|
|
9
|
-
import {
|
|
10
|
-
import { VxeUI as me } from "vxe-pc-ui";
|
|
1
|
+
import { ElForm as dt, ElRow as ft, ElCol as ht, ElInputNumber as mt, ElText as gt, ElLink as je } from "element-plus";
|
|
2
|
+
import { defineComponent as Ye, ref as q, onMounted as He, h as ke, mergeModels as qe, useAttrs as pt, useModel as vt, computed as ce, resolveComponent as O, openBlock as L, createBlock as U, mergeProps as me, unref as K, withCtx as R, renderSlot as ae, createVNode as G, createTextVNode as ee, toDisplayString as te, createCommentVNode as se, createElementBlock as le, Fragment as Se, renderList as Ne, withModifiers as Ie, resolveDynamicComponent as Ke, createElementVNode as re, withKeys as bt, normalizeStyle as yt, normalizeClass as Ee, reactive as pe, nextTick as _e, onUpdated as Ct, onUnmounted as xt, watch as Ze } from "vue";
|
|
3
|
+
import { saveAs as wt } from "file-saver";
|
|
4
|
+
import Ge from "exceljs";
|
|
5
|
+
import ve from "dayjs";
|
|
6
|
+
import { createI18n as kt, useI18n as ue } from "vue-i18n";
|
|
7
|
+
import { debounce as We, cloneDeep as Je, isArray as Pe } from "lodash";
|
|
8
|
+
import { createNamespacedHelpers as Oe, useStore as Qe, mapState as _t, mapGetters as $t, mapActions as St } from "vuex";
|
|
9
|
+
import { VxeUI as he } from "vxe-pc-ui";
|
|
11
10
|
import { useRouter as It } from "vue-router";
|
|
12
|
-
const
|
|
11
|
+
const gn = Ye({
|
|
13
12
|
name: "LayOutForm",
|
|
14
13
|
setup(n, { slots: e, attrs: t, emit: l }) {
|
|
15
|
-
const o = q(null), r = () => e.default ? e.default().filter((
|
|
16
|
-
(
|
|
14
|
+
const o = q(null), r = () => e.default ? e.default().filter((d) => d.type !== Symbol.for("v-cmt")).map((d) => d.type === Symbol.for("v-fgt") ? d.children : d).flat().map(
|
|
15
|
+
(d) => {
|
|
17
16
|
var i;
|
|
18
17
|
return ke(
|
|
19
|
-
|
|
20
|
-
{ span: ((i =
|
|
18
|
+
ht,
|
|
19
|
+
{ span: ((i = d.props) == null ? void 0 : i.span) || 24 },
|
|
21
20
|
{
|
|
22
|
-
default: () =>
|
|
21
|
+
default: () => d
|
|
23
22
|
}
|
|
24
23
|
);
|
|
25
24
|
}
|
|
26
25
|
) : null;
|
|
27
|
-
|
|
26
|
+
He(() => {
|
|
28
27
|
l("ref", o.value);
|
|
29
28
|
});
|
|
30
29
|
function a() {
|
|
31
30
|
return ke(
|
|
32
|
-
|
|
31
|
+
dt,
|
|
33
32
|
{ ...t, ref: o },
|
|
34
|
-
() => ke(
|
|
33
|
+
() => ke(ft, { gutter: t.gutter ?? 20 }, { default: () => r() })
|
|
35
34
|
);
|
|
36
35
|
}
|
|
37
36
|
return a;
|
|
38
37
|
}
|
|
39
38
|
});
|
|
40
|
-
var
|
|
41
|
-
function
|
|
39
|
+
var Xe = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
40
|
+
function et(n) {
|
|
42
41
|
return n && n.__esModule && Object.prototype.hasOwnProperty.call(n, "default") ? n.default : n;
|
|
43
42
|
}
|
|
44
|
-
var
|
|
43
|
+
var tt = { exports: {} };
|
|
45
44
|
(function(n, e) {
|
|
46
45
|
(function(t, l) {
|
|
47
46
|
n.exports = l();
|
|
48
|
-
})(
|
|
47
|
+
})(Xe, function() {
|
|
49
48
|
var t = "minute", l = /[+-]\d\d(?::?\d\d)?/g, o = /([+-]|\d\d)/g;
|
|
50
|
-
return function(r, a,
|
|
49
|
+
return function(r, a, d) {
|
|
51
50
|
var i = a.prototype;
|
|
52
|
-
|
|
53
|
-
var f = { date:
|
|
51
|
+
d.utc = function(u) {
|
|
52
|
+
var f = { date: u, utc: !0, args: arguments };
|
|
54
53
|
return new a(f);
|
|
55
|
-
}, i.utc = function(
|
|
56
|
-
var f =
|
|
57
|
-
return
|
|
54
|
+
}, i.utc = function(u) {
|
|
55
|
+
var f = d(this.toDate(), { locale: this.$L, utc: !0 });
|
|
56
|
+
return u ? f.add(this.utcOffset(), t) : f;
|
|
58
57
|
}, i.local = function() {
|
|
59
|
-
return
|
|
58
|
+
return d(this.toDate(), { locale: this.$L, utc: !1 });
|
|
60
59
|
};
|
|
61
60
|
var v = i.parse;
|
|
62
|
-
i.parse = function(
|
|
63
|
-
|
|
61
|
+
i.parse = function(u) {
|
|
62
|
+
u.utc && (this.$u = !0), this.$utils().u(u.$offset) || (this.$offset = u.$offset), v.call(this, u);
|
|
64
63
|
};
|
|
65
|
-
var
|
|
64
|
+
var g = i.init;
|
|
66
65
|
i.init = function() {
|
|
67
66
|
if (this.$u) {
|
|
68
|
-
var
|
|
69
|
-
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();
|
|
70
69
|
} else
|
|
71
|
-
|
|
70
|
+
g.call(this);
|
|
72
71
|
};
|
|
73
72
|
var k = i.utcOffset;
|
|
74
|
-
i.utcOffset = function(
|
|
73
|
+
i.utcOffset = function(u, f) {
|
|
75
74
|
var $ = this.$utils().u;
|
|
76
|
-
if ($(
|
|
75
|
+
if ($(u))
|
|
77
76
|
return this.$u ? 0 : $(this.$offset) ? k.call(this) : this.$offset;
|
|
78
|
-
if (typeof
|
|
77
|
+
if (typeof u == "string" && (u = function(T) {
|
|
79
78
|
T === void 0 && (T = "");
|
|
80
79
|
var Y = T.match(l);
|
|
81
80
|
if (!Y)
|
|
82
81
|
return null;
|
|
83
|
-
var _ = ("" + Y[0]).match(o) || ["-", 0, 0], y = _[0],
|
|
84
|
-
return
|
|
85
|
-
}(
|
|
82
|
+
var _ = ("" + Y[0]).match(o) || ["-", 0, 0], y = _[0], p = 60 * +_[1] + +_[2];
|
|
83
|
+
return p === 0 ? 0 : y === "+" ? p : -p;
|
|
84
|
+
}(u), u === null))
|
|
86
85
|
return this;
|
|
87
|
-
var h = Math.abs(
|
|
86
|
+
var h = Math.abs(u) <= 16 ? 60 * u : u;
|
|
88
87
|
if (h === 0)
|
|
89
88
|
return this.utc(f);
|
|
90
89
|
var m = this.clone();
|
|
91
90
|
if (f)
|
|
92
91
|
return m.$offset = h, m.$u = !1, m;
|
|
93
|
-
var
|
|
94
|
-
return (m = this.local().add(h +
|
|
92
|
+
var I = this.$u ? this.toDate().getTimezoneOffset() : -1 * this.utcOffset();
|
|
93
|
+
return (m = this.local().add(h + I, t)).$offset = h, m.$x.$localOffset = I, m;
|
|
95
94
|
};
|
|
96
95
|
var x = i.format;
|
|
97
|
-
i.format = function(
|
|
98
|
-
var f =
|
|
96
|
+
i.format = function(u) {
|
|
97
|
+
var f = u || (this.$u ? "YYYY-MM-DDTHH:mm:ss[Z]" : "");
|
|
99
98
|
return x.call(this, f);
|
|
100
99
|
}, i.valueOf = function() {
|
|
101
|
-
var
|
|
102
|
-
return this.$d.valueOf() - 6e4 *
|
|
100
|
+
var u = this.$utils().u(this.$offset) ? 0 : this.$offset + (this.$x.$localOffset || this.$d.getTimezoneOffset());
|
|
101
|
+
return this.$d.valueOf() - 6e4 * u;
|
|
103
102
|
}, i.isUTC = function() {
|
|
104
103
|
return !!this.$u;
|
|
105
104
|
}, i.toISOString = function() {
|
|
@@ -108,88 +107,88 @@ var ot = { exports: {} };
|
|
|
108
107
|
return this.toDate().toUTCString();
|
|
109
108
|
};
|
|
110
109
|
var w = i.toDate;
|
|
111
|
-
i.toDate = function(
|
|
112
|
-
return
|
|
110
|
+
i.toDate = function(u) {
|
|
111
|
+
return u === "s" && this.$offset ? d(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate() : w.call(this);
|
|
113
112
|
};
|
|
114
113
|
var b = i.diff;
|
|
115
|
-
i.diff = function(
|
|
116
|
-
if (
|
|
117
|
-
return b.call(this,
|
|
118
|
-
var h = this.local(), m = u
|
|
114
|
+
i.diff = function(u, f, $) {
|
|
115
|
+
if (u && this.$u === u.$u)
|
|
116
|
+
return b.call(this, u, f, $);
|
|
117
|
+
var h = this.local(), m = d(u).local();
|
|
119
118
|
return b.call(h, m, f, $);
|
|
120
119
|
};
|
|
121
120
|
};
|
|
122
121
|
});
|
|
123
|
-
})(
|
|
124
|
-
var
|
|
125
|
-
const
|
|
126
|
-
var
|
|
122
|
+
})(tt);
|
|
123
|
+
var Et = tt.exports;
|
|
124
|
+
const Lt = /* @__PURE__ */ et(Et);
|
|
125
|
+
var nt = { exports: {} };
|
|
127
126
|
(function(n, e) {
|
|
128
127
|
(function(t, l) {
|
|
129
128
|
n.exports = l();
|
|
130
|
-
})(
|
|
129
|
+
})(Xe, function() {
|
|
131
130
|
var t = { year: 0, month: 1, day: 2, hour: 3, minute: 4, second: 5 }, l = {};
|
|
132
131
|
return function(o, r, a) {
|
|
133
|
-
var
|
|
132
|
+
var d, i = function(x, w, b) {
|
|
134
133
|
b === void 0 && (b = {});
|
|
135
|
-
var
|
|
134
|
+
var u = new Date(x), f = function($, h) {
|
|
136
135
|
h === void 0 && (h = {});
|
|
137
|
-
var m = h.timeZoneName || "short",
|
|
138
|
-
return T || (T = new Intl.DateTimeFormat("en-US", { hour12: !1, timeZone: $, year: "numeric", month: "2-digit", day: "2-digit", hour: "2-digit", minute: "2-digit", second: "2-digit", timeZoneName: m }), l[
|
|
136
|
+
var m = h.timeZoneName || "short", I = $ + "|" + m, T = l[I];
|
|
137
|
+
return T || (T = new Intl.DateTimeFormat("en-US", { hour12: !1, timeZone: $, year: "numeric", month: "2-digit", day: "2-digit", hour: "2-digit", minute: "2-digit", second: "2-digit", timeZoneName: m }), l[I] = T), T;
|
|
139
138
|
}(w, b);
|
|
140
|
-
return f.formatToParts(
|
|
139
|
+
return f.formatToParts(u);
|
|
141
140
|
}, v = function(x, w) {
|
|
142
|
-
for (var b = i(x, w),
|
|
143
|
-
var $ = b[f], h = $.type, m = $.value,
|
|
144
|
-
|
|
141
|
+
for (var b = i(x, w), u = [], f = 0; f < b.length; f += 1) {
|
|
142
|
+
var $ = b[f], h = $.type, m = $.value, I = t[h];
|
|
143
|
+
I >= 0 && (u[I] = parseInt(m, 10));
|
|
145
144
|
}
|
|
146
|
-
var T =
|
|
145
|
+
var T = u[3], Y = T === 24 ? 0 : T, _ = u[0] + "-" + u[1] + "-" + u[2] + " " + Y + ":" + u[4] + ":" + u[5] + ":000", y = +x;
|
|
147
146
|
return (a.utc(_).valueOf() - (y -= y % 1e3)) / 6e4;
|
|
148
|
-
},
|
|
149
|
-
|
|
150
|
-
x === void 0 && (x =
|
|
151
|
-
var b,
|
|
147
|
+
}, g = r.prototype;
|
|
148
|
+
g.tz = function(x, w) {
|
|
149
|
+
x === void 0 && (x = d);
|
|
150
|
+
var b, u = this.utcOffset(), f = this.toDate(), $ = f.toLocaleString("en-US", { timeZone: x }), h = Math.round((f - new Date($)) / 1e3 / 60), m = 15 * -Math.round(f.getTimezoneOffset() / 15) - h;
|
|
152
151
|
if (!Number(m))
|
|
153
152
|
b = this.utcOffset(0, w);
|
|
154
153
|
else if (b = a($, { locale: this.$L }).$set("millisecond", this.$ms).utcOffset(m, !0), w) {
|
|
155
|
-
var
|
|
156
|
-
b = b.add(
|
|
154
|
+
var I = b.utcOffset();
|
|
155
|
+
b = b.add(u - I, "minute");
|
|
157
156
|
}
|
|
158
157
|
return b.$x.$timezone = x, b;
|
|
159
|
-
},
|
|
160
|
-
var w = this.$x.$timezone || a.tz.guess(), b = i(this.valueOf(), w, { timeZoneName: x }).find(function(
|
|
161
|
-
return
|
|
158
|
+
}, g.offsetName = function(x) {
|
|
159
|
+
var w = this.$x.$timezone || a.tz.guess(), b = i(this.valueOf(), w, { timeZoneName: x }).find(function(u) {
|
|
160
|
+
return u.type.toLowerCase() === "timezonename";
|
|
162
161
|
});
|
|
163
162
|
return b && b.value;
|
|
164
163
|
};
|
|
165
|
-
var k =
|
|
166
|
-
|
|
164
|
+
var k = g.startOf;
|
|
165
|
+
g.startOf = function(x, w) {
|
|
167
166
|
if (!this.$x || !this.$x.$timezone)
|
|
168
167
|
return k.call(this, x, w);
|
|
169
168
|
var b = a(this.format("YYYY-MM-DD HH:mm:ss:SSS"), { locale: this.$L });
|
|
170
169
|
return k.call(b, x, w).tz(this.$x.$timezone, !0);
|
|
171
170
|
}, a.tz = function(x, w, b) {
|
|
172
|
-
var
|
|
171
|
+
var u = b && w, f = b || w || d, $ = v(+a(), f);
|
|
173
172
|
if (typeof x != "string")
|
|
174
173
|
return a(x).tz(f);
|
|
175
174
|
var h = function(Y, _, y) {
|
|
176
|
-
var
|
|
175
|
+
var p = Y - 60 * _ * 1e3, P = v(p, y);
|
|
177
176
|
if (_ === P)
|
|
178
|
-
return [
|
|
179
|
-
var z = v(
|
|
180
|
-
return P === z ? [
|
|
181
|
-
}(a.utc(x,
|
|
177
|
+
return [p, _];
|
|
178
|
+
var z = v(p -= 60 * (P - _) * 1e3, y);
|
|
179
|
+
return P === z ? [p, P] : [Y - 60 * Math.min(P, z) * 1e3, Math.max(P, z)];
|
|
180
|
+
}(a.utc(x, u).valueOf(), $, f), m = h[0], I = h[1], T = a(m).utcOffset(I);
|
|
182
181
|
return T.$x.$timezone = f, T;
|
|
183
182
|
}, a.tz.guess = function() {
|
|
184
183
|
return Intl.DateTimeFormat().resolvedOptions().timeZone;
|
|
185
184
|
}, a.tz.setDefault = function(x) {
|
|
186
|
-
|
|
185
|
+
d = x;
|
|
187
186
|
};
|
|
188
187
|
};
|
|
189
188
|
});
|
|
190
|
-
})(
|
|
191
|
-
var
|
|
192
|
-
const
|
|
189
|
+
})(nt);
|
|
190
|
+
var Tt = nt.exports;
|
|
191
|
+
const Ft = /* @__PURE__ */ et(Tt), Le = {
|
|
193
192
|
// 组件通用文本
|
|
194
193
|
"dao-ru": "导入",
|
|
195
194
|
"quan-xuan": "全选",
|
|
@@ -249,44 +248,44 @@ const Ot = /* @__PURE__ */ nt(Ft), Le = {
|
|
|
249
248
|
tools: {
|
|
250
249
|
keysLengthError: "Keys length must be greater than 2, default first two are label and value"
|
|
251
250
|
}
|
|
252
|
-
},
|
|
251
|
+
}, Ot = {
|
|
253
252
|
zh_cn: Le,
|
|
254
253
|
en: Te
|
|
255
254
|
};
|
|
256
|
-
let
|
|
257
|
-
function
|
|
255
|
+
let ie = null;
|
|
256
|
+
function Dt(n = null) {
|
|
258
257
|
if (n) {
|
|
259
258
|
const { global: e } = n;
|
|
260
|
-
return e.messages.value.zh_cn ? e.mergeLocaleMessage("zh_cn", Le) : e.setLocaleMessage("zh_cn", Le), e.messages.value.en ? e.mergeLocaleMessage("en", Te) : e.setLocaleMessage("en", Te),
|
|
259
|
+
return e.messages.value.zh_cn ? e.mergeLocaleMessage("zh_cn", Le) : e.setLocaleMessage("zh_cn", Le), e.messages.value.en ? e.mergeLocaleMessage("en", Te) : e.setLocaleMessage("en", Te), ie = n, n;
|
|
261
260
|
}
|
|
262
|
-
return
|
|
261
|
+
return ie || (ie = kt({
|
|
263
262
|
legacy: !1,
|
|
264
263
|
locale: "zh_cn",
|
|
265
264
|
fallbackLocale: "zh_cn",
|
|
266
|
-
messages:
|
|
267
|
-
})),
|
|
265
|
+
messages: Ot
|
|
266
|
+
})), ie;
|
|
268
267
|
}
|
|
269
|
-
function
|
|
270
|
-
return
|
|
268
|
+
function ot() {
|
|
269
|
+
return ie || Dt();
|
|
271
270
|
}
|
|
272
271
|
function De() {
|
|
273
|
-
return
|
|
272
|
+
return ot().global.t;
|
|
274
273
|
}
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
async function
|
|
274
|
+
ve.extend(Lt);
|
|
275
|
+
ve.extend(Ft);
|
|
276
|
+
async function pn(n, e) {
|
|
278
277
|
const { fields: t, range: l = 1 } = e;
|
|
279
278
|
if (!t) {
|
|
280
279
|
const a = De();
|
|
281
280
|
throw new Error(a("excel.fieldsMappingRequired"));
|
|
282
281
|
}
|
|
283
|
-
let o = new
|
|
282
|
+
let o = new Ge.Workbook();
|
|
284
283
|
await o.xlsx.load(n);
|
|
285
284
|
const r = {};
|
|
286
|
-
return o.eachSheet(function(a,
|
|
285
|
+
return o.eachSheet(function(a, d) {
|
|
287
286
|
const i = [];
|
|
288
|
-
a.eachRow(function(v,
|
|
289
|
-
if (
|
|
287
|
+
a.eachRow(function(v, g) {
|
|
288
|
+
if (g > l) {
|
|
290
289
|
let k = {}, x = !0;
|
|
291
290
|
Object.keys(t).forEach((w) => {
|
|
292
291
|
const b = v.getCell(t[w]).value;
|
|
@@ -296,54 +295,54 @@ async function bn(n, e) {
|
|
|
296
295
|
}), r[a._name] = i;
|
|
297
296
|
}), o = null, r;
|
|
298
297
|
}
|
|
299
|
-
const
|
|
298
|
+
const zt = {
|
|
300
299
|
columnWidth: 30
|
|
301
300
|
};
|
|
302
301
|
async function Mt(n, e, t = [], l = {}) {
|
|
303
302
|
if (!n || !e)
|
|
304
303
|
return;
|
|
305
|
-
const { columnStyle: o } = l, { columnWidth: r } =
|
|
304
|
+
const { columnStyle: o } = l, { columnWidth: r } = zt;
|
|
306
305
|
e.forEach((i) => {
|
|
307
306
|
i.width = i.width ? i.width : r;
|
|
308
307
|
});
|
|
309
|
-
const { workbook: a, worksheet:
|
|
310
|
-
|
|
308
|
+
const { workbook: a, worksheet: d } = Rt();
|
|
309
|
+
d.columns = e, d.addRows(t), o && await At(a, d, o);
|
|
311
310
|
try {
|
|
312
311
|
const i = await a.xlsx.writeBuffer(), v = new File([i], n, {
|
|
313
312
|
type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
|
|
314
313
|
});
|
|
315
|
-
|
|
314
|
+
wt(v);
|
|
316
315
|
} catch (i) {
|
|
317
316
|
console.log(i);
|
|
318
317
|
}
|
|
319
318
|
}
|
|
320
319
|
function Rt() {
|
|
321
|
-
const n = new
|
|
320
|
+
const n = new Ge.Workbook();
|
|
322
321
|
n.creator = "distributor System", n.lastModifiedBy = "distributor System", n.created = /* @__PURE__ */ new Date(), n.modified = /* @__PURE__ */ new Date(), n.lastPrinted = /* @__PURE__ */ new Date();
|
|
323
322
|
const e = n.addWorksheet("Sheet1");
|
|
324
323
|
return { workbook: n, worksheet: e };
|
|
325
324
|
}
|
|
326
|
-
async function
|
|
325
|
+
async function At(n, e, t) {
|
|
327
326
|
const l = Object.keys(t);
|
|
328
327
|
for (const o of l) {
|
|
329
328
|
const r = t[o], { type: a } = r;
|
|
330
329
|
switch (a) {
|
|
331
330
|
case "IMG":
|
|
332
|
-
await
|
|
331
|
+
await Vt(n, e, o);
|
|
333
332
|
break;
|
|
334
333
|
}
|
|
335
334
|
}
|
|
336
335
|
}
|
|
337
|
-
async function
|
|
336
|
+
async function Vt(n, e, t, l) {
|
|
338
337
|
const o = e.getColumn(t), r = o.values;
|
|
339
|
-
e.getColumn(t).width = 20, e.eachRow((a,
|
|
340
|
-
|
|
338
|
+
e.getColumn(t).width = 20, e.eachRow((a, d) => {
|
|
339
|
+
d > 1 && (a.height = 40);
|
|
341
340
|
});
|
|
342
|
-
for (let a = 0,
|
|
341
|
+
for (let a = 0, d = r.length; a < d; a++) {
|
|
343
342
|
if (a < 2)
|
|
344
343
|
continue;
|
|
345
344
|
let i = r[a];
|
|
346
|
-
i && (e.getCell(o.letter + a).value = "", await
|
|
345
|
+
i && (e.getCell(o.letter + a).value = "", await Ut(n, e, i, {
|
|
347
346
|
width: 100,
|
|
348
347
|
height: 50,
|
|
349
348
|
col: o._number - 1,
|
|
@@ -351,20 +350,20 @@ async function Ut(n, e, t, l) {
|
|
|
351
350
|
}));
|
|
352
351
|
}
|
|
353
352
|
}
|
|
354
|
-
async function
|
|
355
|
-
const { col: o, row: r, width: a, height:
|
|
353
|
+
async function Ut(n, e, t, l) {
|
|
354
|
+
const { col: o, row: r, width: a, height: d } = l, { success: i, base64: v } = await jt(t, 0.3);
|
|
356
355
|
if (i) {
|
|
357
|
-
const
|
|
356
|
+
const g = n.addImage({
|
|
358
357
|
base64: v,
|
|
359
358
|
extension: "jpeg"
|
|
360
359
|
});
|
|
361
|
-
e.addImage(
|
|
360
|
+
e.addImage(g, {
|
|
362
361
|
tl: { col: o, row: r },
|
|
363
|
-
ext: { width: a, height:
|
|
362
|
+
ext: { width: a, height: d }
|
|
364
363
|
});
|
|
365
364
|
}
|
|
366
365
|
}
|
|
367
|
-
function
|
|
366
|
+
function jt(n, e = 1) {
|
|
368
367
|
const t = new Image();
|
|
369
368
|
return t.setAttribute("crossOrigin", "anonymous"), t.crossOrigin = "anonymous", t.src = n, new Promise((l, o) => {
|
|
370
369
|
t.onload = () => {
|
|
@@ -379,7 +378,7 @@ function qt(n, e = 1) {
|
|
|
379
378
|
};
|
|
380
379
|
});
|
|
381
380
|
}
|
|
382
|
-
function
|
|
381
|
+
function qt(n) {
|
|
383
382
|
if (n < 26)
|
|
384
383
|
return String.fromCharCode(65 + n);
|
|
385
384
|
{
|
|
@@ -387,17 +386,17 @@ function Pt(n) {
|
|
|
387
386
|
return e + t;
|
|
388
387
|
}
|
|
389
388
|
}
|
|
390
|
-
function
|
|
389
|
+
function vn(n) {
|
|
391
390
|
return new Promise((e) => {
|
|
392
391
|
setTimeout(() => {
|
|
393
392
|
e();
|
|
394
393
|
}, n);
|
|
395
394
|
});
|
|
396
395
|
}
|
|
397
|
-
function
|
|
396
|
+
function bn(n) {
|
|
398
397
|
return JSON.parse(JSON.stringify(n));
|
|
399
398
|
}
|
|
400
|
-
function
|
|
399
|
+
function yn(n) {
|
|
401
400
|
let e = [], t = {}, l = (o, r) => Object.prototype.hasOwnProperty.call(o, r);
|
|
402
401
|
for (const o of n) {
|
|
403
402
|
t[o.id] = {
|
|
@@ -412,10 +411,10 @@ function xn(n) {
|
|
|
412
411
|
}
|
|
413
412
|
return e;
|
|
414
413
|
}
|
|
415
|
-
function
|
|
414
|
+
function lt(n, e = " ") {
|
|
416
415
|
return n ? n.split(e).filter((t) => t.trim()) : [];
|
|
417
416
|
}
|
|
418
|
-
class
|
|
417
|
+
class Be {
|
|
419
418
|
constructor(e, t = ["label", "value", "labelEn"]) {
|
|
420
419
|
this.list = e, this.map = new Map(
|
|
421
420
|
e.map((l) => {
|
|
@@ -453,42 +452,42 @@ class Ye {
|
|
|
453
452
|
return this.map.has(e);
|
|
454
453
|
}
|
|
455
454
|
}
|
|
456
|
-
function
|
|
455
|
+
function Cn(n, e = [], t = "i18nName") {
|
|
457
456
|
if (n.length == 0)
|
|
458
|
-
return new
|
|
457
|
+
return new Be([]);
|
|
459
458
|
if (e.length < 2) {
|
|
460
459
|
const o = De();
|
|
461
460
|
throw new Error(o("tools.keysLengthError"));
|
|
462
461
|
}
|
|
463
462
|
let l = n.map((o) => {
|
|
464
463
|
let r = {};
|
|
465
|
-
return t && (r.labelEn = o[t]), e.forEach((a,
|
|
466
|
-
|
|
464
|
+
return t && (r.labelEn = o[t]), e.forEach((a, d) => {
|
|
465
|
+
d === 0 ? r.label = o[a] : d === 1 ? r.value = o[a] : r[a] = o[a];
|
|
467
466
|
}), r;
|
|
468
467
|
});
|
|
469
|
-
return new
|
|
468
|
+
return new Be(l);
|
|
470
469
|
}
|
|
471
|
-
function
|
|
470
|
+
function xn(n) {
|
|
472
471
|
return n ? n.replace(/<[^>]+>/g, "") : "";
|
|
473
472
|
}
|
|
474
|
-
function
|
|
473
|
+
function wn(n) {
|
|
475
474
|
return n ? (n.includes("\\\\u") && (n = n.replace(/\\/g, "")), n.replace(/\\u[\dA-F]{4}/gi, (e) => String.fromCharCode(parseInt(e.replace(/\\u/g, ""), 16)))) : "";
|
|
476
475
|
}
|
|
477
|
-
function
|
|
476
|
+
function kn(n, e = 10) {
|
|
478
477
|
let t = 1048576 * e;
|
|
479
478
|
return !(n.size > t);
|
|
480
479
|
}
|
|
481
|
-
function
|
|
480
|
+
function _n(n) {
|
|
482
481
|
return Array.from(10).fill(0).map((t, l) => n + "_" + l);
|
|
483
482
|
}
|
|
484
|
-
function
|
|
483
|
+
function $n(n) {
|
|
485
484
|
let e = {};
|
|
486
485
|
return n.map((t, l) => {
|
|
487
|
-
let { key: o, option: r, type: a } = t,
|
|
488
|
-
r ? e[o] = `${
|
|
486
|
+
let { key: o, option: r, type: a } = t, d = qt(l);
|
|
487
|
+
r ? e[o] = `${d}---option` : a === "image" ? e[o] = `${d}---image` : e[o] = d;
|
|
489
488
|
}), e;
|
|
490
489
|
}
|
|
491
|
-
function
|
|
490
|
+
function Sn(n, e) {
|
|
492
491
|
return e.split(".").reduce((t, l) => t && t[l], n);
|
|
493
492
|
}
|
|
494
493
|
const ge = (n, e) => {
|
|
@@ -496,7 +495,7 @@ const ge = (n, e) => {
|
|
|
496
495
|
for (const [l, o] of e)
|
|
497
496
|
t[l] = o;
|
|
498
497
|
return t;
|
|
499
|
-
},
|
|
498
|
+
}, Pt = {
|
|
500
499
|
__name: "index",
|
|
501
500
|
props: /* @__PURE__ */ qe({
|
|
502
501
|
api: {
|
|
@@ -536,30 +535,30 @@ const ge = (n, e) => {
|
|
|
536
535
|
}),
|
|
537
536
|
emits: /* @__PURE__ */ qe(["success", "change"], ["update:modelValue"]),
|
|
538
537
|
setup(n, { emit: e }) {
|
|
539
|
-
const t = n, l =
|
|
538
|
+
const t = n, l = pt(), { t: o, locale: r } = ue(), a = vt(n, "modelValue"), d = q(""), i = ce(() => {
|
|
540
539
|
if (l.remote !== void 0)
|
|
541
540
|
return t.data;
|
|
542
|
-
const h =
|
|
541
|
+
const h = lt(d.value), { data: m, labelValue: I } = t, T = m || k.value;
|
|
543
542
|
if (h.length == 0)
|
|
544
543
|
return T;
|
|
545
|
-
const { label: Y, labelEn: _ } =
|
|
544
|
+
const { label: Y, labelEn: _ } = I;
|
|
546
545
|
let y = r.value == "en_us" ? _ || "i18nName" : Y;
|
|
547
546
|
return h.length == 1 ? T.filter(
|
|
548
547
|
(P) => P[y].toLowerCase().includes(h[0].toLowerCase())
|
|
549
548
|
) : T.filter((P) => {
|
|
550
549
|
let z = !1;
|
|
551
|
-
return z = h.some((
|
|
550
|
+
return z = h.some((de) => P[y].toLowerCase() == de.toLowerCase()), z;
|
|
552
551
|
});
|
|
553
|
-
}), v =
|
|
552
|
+
}), v = ce({
|
|
554
553
|
get() {
|
|
555
554
|
return l.multiple == null || a.value == null ? !1 : a.value.length == i.value.length;
|
|
556
555
|
},
|
|
557
556
|
set(h) {
|
|
558
557
|
return h;
|
|
559
558
|
}
|
|
560
|
-
}),
|
|
559
|
+
}), g = e, k = q([]), x = async () => {
|
|
561
560
|
const { data: h } = await t.api();
|
|
562
|
-
k.value = [...h],
|
|
561
|
+
k.value = [...h], g("success", k);
|
|
563
562
|
};
|
|
564
563
|
t.api && x();
|
|
565
564
|
const w = t.labelValue.label.split("-"), b = (h) => {
|
|
@@ -570,50 +569,50 @@ const ge = (n, e) => {
|
|
|
570
569
|
return m = m || h[t.labelValue.label], m;
|
|
571
570
|
} else {
|
|
572
571
|
let m = [];
|
|
573
|
-
return w.forEach((
|
|
574
|
-
m.push(h[
|
|
572
|
+
return w.forEach((I) => {
|
|
573
|
+
m.push(h[I]);
|
|
575
574
|
}), m.join("-");
|
|
576
575
|
}
|
|
577
576
|
};
|
|
578
|
-
function
|
|
579
|
-
a.value = h ? i.value.map((m) => m[t.labelValue.value]) : [],
|
|
577
|
+
function u(h) {
|
|
578
|
+
a.value = h ? i.value.map((m) => m[t.labelValue.value]) : [], g("change", a.value);
|
|
580
579
|
}
|
|
581
580
|
function f(h) {
|
|
582
|
-
t.optionClick(h),
|
|
581
|
+
t.optionClick(h), g("change", l["value-key"] ? h : h[t.labelValue.value]);
|
|
583
582
|
}
|
|
584
583
|
function $(h) {
|
|
585
584
|
return a.value.length >= t.maxLimit && !a.value.includes(h[t.labelValue.value]);
|
|
586
585
|
}
|
|
587
586
|
return (h, m) => {
|
|
588
|
-
const
|
|
589
|
-
return L(), U(Y,
|
|
587
|
+
const I = O("el-checkbox"), T = O("el-option"), Y = O("el-select");
|
|
588
|
+
return L(), U(Y, me({
|
|
590
589
|
modelValue: a.value,
|
|
591
590
|
"onUpdate:modelValue": m[1] || (m[1] = (_) => a.value = _),
|
|
592
591
|
filterable: "",
|
|
593
592
|
"collapse-tags": "",
|
|
594
593
|
"collapse-tags-tooltip": "",
|
|
595
|
-
"filter-method": K(l).remote != null ? void 0 : (_) =>
|
|
594
|
+
"filter-method": K(l).remote != null ? void 0 : (_) => d.value = _,
|
|
596
595
|
clearable: ""
|
|
597
596
|
}, K(l), { onClear: n.optionClick }), {
|
|
598
|
-
default:
|
|
599
|
-
K(l).multiple != null && n.showCheckAll && n.maxLimit == null ?
|
|
600
|
-
G(
|
|
597
|
+
default: R(() => [
|
|
598
|
+
K(l).multiple != null && n.showCheckAll && n.maxLimit == null ? ae(h.$slots, "header", { key: 0 }, () => [
|
|
599
|
+
G(I, {
|
|
601
600
|
class: "mgl20",
|
|
602
601
|
modelValue: v.value,
|
|
603
602
|
"onUpdate:modelValue": m[0] || (m[0] = (_) => v.value = _),
|
|
604
|
-
onChange:
|
|
603
|
+
onChange: u
|
|
605
604
|
}, {
|
|
606
|
-
default:
|
|
607
|
-
te(
|
|
605
|
+
default: R(() => [
|
|
606
|
+
ee(te(h.$t("quan-xuan")), 1)
|
|
608
607
|
]),
|
|
609
608
|
_: 1
|
|
610
609
|
}, 8, ["modelValue"])
|
|
611
|
-
], !0) :
|
|
612
|
-
(L(!0),
|
|
610
|
+
], !0) : se("", !0),
|
|
611
|
+
(L(!0), le(Se, null, Ne(i.value, (_, y) => (L(), U(T, {
|
|
613
612
|
key: y,
|
|
614
613
|
label: b(_),
|
|
615
614
|
disabled: K(l).multiple != null && n.maxLimit > 0 ? $(_) : !1,
|
|
616
|
-
onClick:
|
|
615
|
+
onClick: Ie((p) => f(_), ["stop"]),
|
|
617
616
|
value: K(l)["value-key"] ? _ : _[n.labelValue.value]
|
|
618
617
|
}, null, 8, ["label", "disabled", "onClick", "value"]))), 128))
|
|
619
618
|
]),
|
|
@@ -621,8 +620,8 @@ const ge = (n, e) => {
|
|
|
621
620
|
}, 16, ["modelValue", "filter-method", "onClear"]);
|
|
622
621
|
};
|
|
623
622
|
}
|
|
624
|
-
},
|
|
625
|
-
const
|
|
623
|
+
}, Bt = /* @__PURE__ */ ge(Pt, [["__scopeId", "data-v-34eb8641"]]);
|
|
624
|
+
const Yt = Ye({
|
|
626
625
|
props: {
|
|
627
626
|
name: {
|
|
628
627
|
tyepe: String,
|
|
@@ -630,38 +629,38 @@ const Ht = He({
|
|
|
630
629
|
}
|
|
631
630
|
}
|
|
632
631
|
});
|
|
633
|
-
function
|
|
632
|
+
function Ht(n, e, t, l, o, r) {
|
|
634
633
|
const a = O("el-icon");
|
|
635
634
|
return L(), U(a, { class: "cmp-icon" }, {
|
|
636
|
-
default:
|
|
637
|
-
(L(), U(
|
|
635
|
+
default: R(() => [
|
|
636
|
+
(L(), U(Ke(n.name)))
|
|
638
637
|
]),
|
|
639
638
|
_: 1
|
|
640
639
|
});
|
|
641
640
|
}
|
|
642
|
-
const
|
|
641
|
+
const rt = /* @__PURE__ */ ge(Yt, [["render", Ht], ["__scopeId", "data-v-733f9daa"]]), In = {
|
|
643
642
|
__name: "index",
|
|
644
643
|
emits: ["ok", "no"],
|
|
645
644
|
setup(n, { emit: e }) {
|
|
646
|
-
const t = e, l =
|
|
645
|
+
const t = e, l = We(() => {
|
|
647
646
|
t("ok");
|
|
648
647
|
}, 500);
|
|
649
648
|
function o() {
|
|
650
649
|
t("no");
|
|
651
650
|
}
|
|
652
651
|
return (r, a) => {
|
|
653
|
-
const
|
|
654
|
-
return L(), U(i,
|
|
652
|
+
const d = O("el-link"), i = O("el-popconfirm");
|
|
653
|
+
return L(), U(i, me(r.$attrs, {
|
|
655
654
|
onConfirm: K(l),
|
|
656
655
|
onCancel: o
|
|
657
656
|
}), {
|
|
658
|
-
reference:
|
|
659
|
-
G(
|
|
657
|
+
reference: R(() => [
|
|
658
|
+
G(d, {
|
|
660
659
|
underline: "never",
|
|
661
660
|
type: r.$attrs.type
|
|
662
661
|
}, {
|
|
663
|
-
default:
|
|
664
|
-
|
|
662
|
+
default: R(() => [
|
|
663
|
+
ae(r.$slots, "default")
|
|
665
664
|
]),
|
|
666
665
|
_: 3
|
|
667
666
|
}, 8, ["type"])
|
|
@@ -671,7 +670,7 @@ const st = /* @__PURE__ */ ge(Ht, [["render", Nt], ["__scopeId", "data-v-733f9da
|
|
|
671
670
|
};
|
|
672
671
|
}
|
|
673
672
|
};
|
|
674
|
-
const
|
|
673
|
+
const Nt = ["accept"], Kt = {
|
|
675
674
|
__name: "index",
|
|
676
675
|
props: {
|
|
677
676
|
accept: {
|
|
@@ -691,49 +690,49 @@ const Kt = ["accept"], Zt = {
|
|
|
691
690
|
t("fileChange", a), l.value.value = null;
|
|
692
691
|
}
|
|
693
692
|
return (r, a) => {
|
|
694
|
-
const
|
|
695
|
-
return L(),
|
|
696
|
-
G(
|
|
693
|
+
const d = O("el-button");
|
|
694
|
+
return L(), le("span", null, [
|
|
695
|
+
G(d, {
|
|
697
696
|
loading: n.loading,
|
|
698
697
|
class: "mgr10",
|
|
699
698
|
onClick: a[0] || (a[0] = (i) => l.value.click())
|
|
700
699
|
}, {
|
|
701
|
-
default:
|
|
702
|
-
te(
|
|
700
|
+
default: R(() => [
|
|
701
|
+
ee(te(r.$t("dao-ru")), 1)
|
|
703
702
|
]),
|
|
704
703
|
_: 1
|
|
705
704
|
}, 8, ["loading"]),
|
|
706
|
-
|
|
705
|
+
re("input", {
|
|
707
706
|
onChange: o,
|
|
708
707
|
ref_key: "input",
|
|
709
708
|
ref: l,
|
|
710
709
|
accept: n.accept,
|
|
711
710
|
style: { position: "absolute", width: "0px", height: "0px", opacity: "0" },
|
|
712
711
|
type: "file"
|
|
713
|
-
}, null, 40,
|
|
712
|
+
}, null, 40, Nt)
|
|
714
713
|
]);
|
|
715
714
|
};
|
|
716
715
|
}
|
|
717
|
-
},
|
|
716
|
+
}, En = /* @__PURE__ */ ge(Kt, [["__scopeId", "data-v-5f1449ad"]]);
|
|
718
717
|
function Fe(n) {
|
|
719
718
|
let e = {};
|
|
720
719
|
return n.forEach((t) => {
|
|
721
|
-
const { key: l, type: o, option: r = {}, value: a, dateType:
|
|
720
|
+
const { key: l, type: o, option: r = {}, value: a, dateType: d } = t;
|
|
722
721
|
if (l)
|
|
723
722
|
if (o == "input" && (r != null && r.multiple))
|
|
724
|
-
e[l] =
|
|
723
|
+
e[l] = lt(a);
|
|
725
724
|
else if (o == "date")
|
|
726
|
-
if (
|
|
725
|
+
if (d.includes("range")) {
|
|
727
726
|
const [i, v] = l;
|
|
728
|
-
let [
|
|
729
|
-
|
|
727
|
+
let [g, k] = a || [];
|
|
728
|
+
g && d == "daterange" && (g = ve(g).format("YYYY-MM-DD 00:00:00"), k = ve(k).format("YYYY-MM-DD 23:59:59")), e[i] = g, e[v] = k;
|
|
730
729
|
} else
|
|
731
730
|
e[l] = a;
|
|
732
731
|
else
|
|
733
732
|
e[l] = a;
|
|
734
733
|
}), e;
|
|
735
734
|
}
|
|
736
|
-
const
|
|
735
|
+
const Zt = { key: 0 }, Gt = { class: "btns" }, Wt = { class: "left" }, Jt = { class: "right" }, Qt = {
|
|
737
736
|
__name: "index",
|
|
738
737
|
props: {
|
|
739
738
|
form: {
|
|
@@ -743,11 +742,11 @@ const Gt = { key: 0 }, Jt = { class: "btns" }, Wt = { class: "left" }, Qt = { cl
|
|
|
743
742
|
},
|
|
744
743
|
emits: ["confirm", "reset", "visibleChange"],
|
|
745
744
|
setup(n, { expose: e, emit: t }) {
|
|
746
|
-
const l = n, o = t, r = q(!0), a = q(null), { t:
|
|
745
|
+
const l = n, o = t, r = q(!0), a = q(null), { t: d } = ue(), i = ce(() => r.value ? d("guan-bi") : d("zhan-kai"));
|
|
747
746
|
function v() {
|
|
748
747
|
o("confirm");
|
|
749
748
|
}
|
|
750
|
-
function
|
|
749
|
+
function g(f) {
|
|
751
750
|
f.option.onClear && f.option.onClear(), o("confirm");
|
|
752
751
|
}
|
|
753
752
|
function k() {
|
|
@@ -759,58 +758,58 @@ const Gt = { key: 0 }, Jt = { class: "btns" }, Wt = { class: "left" }, Qt = { cl
|
|
|
759
758
|
function w() {
|
|
760
759
|
return Fe(l.form.items);
|
|
761
760
|
}
|
|
762
|
-
const b =
|
|
763
|
-
function
|
|
761
|
+
const b = Je(l.form.items);
|
|
762
|
+
function u() {
|
|
764
763
|
l.form.items.forEach((f) => {
|
|
765
764
|
const $ = b.find((h) => h.key == f.key);
|
|
766
765
|
$ && (f.value = $.value);
|
|
767
766
|
});
|
|
768
767
|
}
|
|
769
|
-
return e({ getPrm: w, reset:
|
|
770
|
-
const h = O("el-input"), m = O("el-date-picker"),
|
|
771
|
-
return L(),
|
|
768
|
+
return e({ getPrm: w, reset: u }), (f, $) => {
|
|
769
|
+
const h = O("el-input"), m = O("el-date-picker"), I = O("el-form-item"), T = O("el-form"), Y = O("el-link"), _ = O("el-button");
|
|
770
|
+
return L(), le("div", {
|
|
772
771
|
class: "searchBar-container mgt10 mgb10",
|
|
773
|
-
onKeydown:
|
|
772
|
+
onKeydown: bt(v, ["enter"])
|
|
774
773
|
}, [
|
|
775
|
-
|
|
774
|
+
re("div", {
|
|
776
775
|
class: "searchBar",
|
|
777
|
-
style:
|
|
776
|
+
style: yt({ height: r.value ? "auto" : "42px" })
|
|
778
777
|
}, [
|
|
779
778
|
G(T, {
|
|
780
779
|
inline: "",
|
|
781
780
|
model: n.form.data
|
|
782
781
|
}, {
|
|
783
|
-
default:
|
|
784
|
-
(L(!0),
|
|
782
|
+
default: R(() => [
|
|
783
|
+
(L(!0), le(Se, null, Ne(n.form.items.filter((y) => !y.hidden), (y) => (L(), le(Se, {
|
|
785
784
|
key: y.key
|
|
786
785
|
}, [
|
|
787
|
-
y.type == "br" ? (L(),
|
|
786
|
+
y.type == "br" ? (L(), le("br", Zt)) : (L(), U(I, {
|
|
788
787
|
key: 1,
|
|
789
788
|
label: y.name
|
|
790
789
|
}, {
|
|
791
|
-
default:
|
|
792
|
-
var
|
|
790
|
+
default: R(() => {
|
|
791
|
+
var p, P;
|
|
793
792
|
return [
|
|
794
793
|
y.type === "input" ? (L(), U(h, {
|
|
795
794
|
key: 0,
|
|
796
795
|
modelValue: y.value,
|
|
797
796
|
"onUpdate:modelValue": (z) => y.value = z,
|
|
798
|
-
class:
|
|
797
|
+
class: Ee(((p = y.option) == null ? void 0 : p.class) || "w150"),
|
|
799
798
|
placeholder: f.$t("qing-shu-ru"),
|
|
800
799
|
clearable: ""
|
|
801
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "class", "placeholder"])) : y.type === "custom" ? (L(), U(
|
|
802
|
-
y.type === "select" ? (L(), U(
|
|
800
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "class", "placeholder"])) : y.type === "custom" ? (L(), U(Ke(y.render), { key: 1 })) : se("", !0),
|
|
801
|
+
y.type === "select" ? (L(), U(Bt, me({
|
|
803
802
|
key: 2,
|
|
804
803
|
class: ((P = y.option) == null ? void 0 : P.class) || "w150",
|
|
805
804
|
modelValue: y.value,
|
|
806
805
|
"onUpdate:modelValue": (z) => y.value = z
|
|
807
806
|
}, { ref_for: !0 }, y.option, {
|
|
808
807
|
onChange: v,
|
|
809
|
-
onClear: (z) =>
|
|
810
|
-
}), null, 16, ["class", "modelValue", "onUpdate:modelValue", "onClear"])) :
|
|
808
|
+
onClear: (z) => g(y)
|
|
809
|
+
}), null, 16, ["class", "modelValue", "onUpdate:modelValue", "onClear"])) : se("", !0),
|
|
811
810
|
y.type === "date" ? (L(), U(m, {
|
|
812
811
|
key: 3,
|
|
813
|
-
class:
|
|
812
|
+
class: Ee({ datetimerange: "w300", daterange: "w200" }[y.dateType] || "w100"),
|
|
814
813
|
modelValue: y.value,
|
|
815
814
|
"onUpdate:modelValue": (z) => y.value = z,
|
|
816
815
|
"value-format": { datetimerange: "YYYY-MM-DD HH:mm:ss", daterange: "YYYY-MM-DD" }[y.dateType] || "YYYY-MM-DD",
|
|
@@ -820,7 +819,7 @@ const Gt = { key: 0 }, Jt = { class: "btns" }, Wt = { class: "left" }, Qt = { cl
|
|
|
820
819
|
placeholder: f.$t("qing-xuan-ze"),
|
|
821
820
|
"start-placeholder": f.$t("kai-shi-shi-jian"),
|
|
822
821
|
"end-placeholder": f.$t("jie-shu-shi-jian")
|
|
823
|
-
}, null, 8, ["class", "modelValue", "onUpdate:modelValue", "value-format", "type", "onFocus", "onChange", "placeholder", "start-placeholder", "end-placeholder"])) :
|
|
822
|
+
}, null, 8, ["class", "modelValue", "onUpdate:modelValue", "value-format", "type", "onFocus", "onChange", "placeholder", "start-placeholder", "end-placeholder"])) : se("", !0)
|
|
824
823
|
];
|
|
825
824
|
}),
|
|
826
825
|
_: 2
|
|
@@ -830,11 +829,11 @@ const Gt = { key: 0 }, Jt = { class: "btns" }, Wt = { class: "left" }, Qt = { cl
|
|
|
830
829
|
_: 1
|
|
831
830
|
}, 8, ["model"])
|
|
832
831
|
], 4),
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
832
|
+
re("div", Gt, [
|
|
833
|
+
re("div", Wt, [
|
|
834
|
+
ae(f.$slots, "table-header-left", {}, void 0, !0)
|
|
836
835
|
]),
|
|
837
|
-
|
|
836
|
+
re("div", Jt, [
|
|
838
837
|
G(Y, {
|
|
839
838
|
underline: "never",
|
|
840
839
|
class: "mgr10",
|
|
@@ -842,11 +841,11 @@ const Gt = { key: 0 }, Jt = { class: "btns" }, Wt = { class: "left" }, Qt = { cl
|
|
|
842
841
|
o("visibleChange", !r.value), r.value = !r.value;
|
|
843
842
|
})
|
|
844
843
|
}, {
|
|
845
|
-
default:
|
|
846
|
-
G(
|
|
844
|
+
default: R(() => [
|
|
845
|
+
G(rt, {
|
|
847
846
|
name: r.value ? "ArrowUp" : "ArrowDown"
|
|
848
847
|
}, null, 8, ["name"]),
|
|
849
|
-
|
|
848
|
+
ee(" " + te(i.value), 1)
|
|
850
849
|
]),
|
|
851
850
|
_: 1
|
|
852
851
|
}),
|
|
@@ -854,8 +853,8 @@ const Gt = { key: 0 }, Jt = { class: "btns" }, Wt = { class: "left" }, Qt = { cl
|
|
|
854
853
|
type: "primary",
|
|
855
854
|
onClick: v
|
|
856
855
|
}, {
|
|
857
|
-
default:
|
|
858
|
-
te(
|
|
856
|
+
default: R(() => [
|
|
857
|
+
ee(te(f.$t("shai-xuan")), 1)
|
|
859
858
|
]),
|
|
860
859
|
_: 1
|
|
861
860
|
}),
|
|
@@ -863,19 +862,19 @@ const Gt = { key: 0 }, Jt = { class: "btns" }, Wt = { class: "left" }, Qt = { cl
|
|
|
863
862
|
type: "primary",
|
|
864
863
|
onClick: k
|
|
865
864
|
}, {
|
|
866
|
-
default:
|
|
867
|
-
te(
|
|
865
|
+
default: R(() => [
|
|
866
|
+
ee(te(f.$t("chong-zhi")), 1)
|
|
868
867
|
]),
|
|
869
868
|
_: 1
|
|
870
869
|
}),
|
|
871
|
-
|
|
870
|
+
ae(f.$slots, "btn", {}, void 0, !0)
|
|
872
871
|
])
|
|
873
872
|
])
|
|
874
873
|
], 32);
|
|
875
874
|
};
|
|
876
875
|
}
|
|
877
|
-
},
|
|
878
|
-
const
|
|
876
|
+
}, Xt = /* @__PURE__ */ ge(Qt, [["__scopeId", "data-v-32ac9990"]]);
|
|
877
|
+
const en = { class: "center" }, tn = {
|
|
879
878
|
__name: "index",
|
|
880
879
|
props: {
|
|
881
880
|
// 表格id 本地存储列设置时使用
|
|
@@ -917,57 +916,61 @@ const tn = { class: "center" }, nn = {
|
|
|
917
916
|
}
|
|
918
917
|
},
|
|
919
918
|
setup(n, { expose: e }) {
|
|
920
|
-
const { t, locale: l } =
|
|
921
|
-
o.searchForm.selections = [], o.searchForm.enableCellCopy == null && (o.searchForm.enableCellCopy = !0);
|
|
922
|
-
const
|
|
919
|
+
const { t, locale: l } = ue(), o = n, r = q(!1), a = q([]);
|
|
920
|
+
o.searchForm.selections = [], console.log("单元格复制功能默认启用,若不需要请在searchForm中设置enableCellCopy为false123", o.searchForm.enableCellCopy), o.searchForm.enableCellCopy == null && (o.searchForm.enableCellCopy = !0);
|
|
921
|
+
const d = Je(o.searchForm.items), i = o.searchForm.pageNoKey || "pageNo", v = pe({
|
|
923
922
|
[i]: 1,
|
|
924
923
|
pageSize: 10,
|
|
925
924
|
total: 0
|
|
926
|
-
}),
|
|
925
|
+
}), g = q(null), k = q(null), x = q(450), w = We(() => {
|
|
927
926
|
_e(() => {
|
|
928
927
|
if (!k.value)
|
|
929
928
|
return;
|
|
930
|
-
const s = k.value.getBoundingClientRect(), C = window.innerHeight,
|
|
929
|
+
const s = k.value.getBoundingClientRect(), C = window.innerHeight, E = s.top, A = 100, Z = C - E - A, V = 200;
|
|
931
930
|
x.value = Math.max(Z, V);
|
|
932
931
|
});
|
|
933
932
|
}, 100), b = () => {
|
|
934
933
|
w();
|
|
935
|
-
},
|
|
934
|
+
}, u = () => {
|
|
936
935
|
if (!o.searchForm.enableCellCopy)
|
|
937
936
|
return !1;
|
|
938
|
-
const c =
|
|
937
|
+
const c = g.value;
|
|
939
938
|
if (!c || !c.$el)
|
|
940
939
|
return !1;
|
|
941
940
|
const s = c.$el;
|
|
942
|
-
return s.classList.add("cell-copy-enabled"), s.setAttribute("tabindex", "-1"), s.removeEventListener("mousedown", z), s.removeEventListener("mousemove",
|
|
941
|
+
return s.classList.add("cell-copy-enabled"), s.setAttribute("tabindex", "-1"), s.removeEventListener("mousedown", z), s.removeEventListener("mousemove", de), s.removeEventListener("mouseup", be), s.removeEventListener("keydown", Ce), s.addEventListener("mousedown", z), s.addEventListener("mousemove", de), s.addEventListener("mouseup", be), s.addEventListener("keydown", Ce), !0;
|
|
943
942
|
};
|
|
944
|
-
|
|
945
|
-
w(), window.addEventListener("resize", b), o.searchForm.enableCellCopy && (document.addEventListener("mouseup",
|
|
946
|
-
|
|
943
|
+
He(() => {
|
|
944
|
+
w(), window.addEventListener("resize", b), o.searchForm.enableCellCopy && (document.addEventListener("mouseup", Re), document.addEventListener("mousedown", Ae), setTimeout(() => {
|
|
945
|
+
u();
|
|
947
946
|
}, 500));
|
|
948
|
-
}),
|
|
947
|
+
}), Ct(() => {
|
|
948
|
+
o.searchForm.enableCellCopy && setTimeout(() => {
|
|
949
|
+
u();
|
|
950
|
+
}, 500);
|
|
951
|
+
}), xt(() => {
|
|
949
952
|
if (window.removeEventListener("resize", b), o.searchForm.enableCellCopy) {
|
|
950
|
-
document.removeEventListener("mouseup",
|
|
951
|
-
const c =
|
|
953
|
+
document.removeEventListener("mouseup", Re), document.removeEventListener("mousedown", Ae);
|
|
954
|
+
const c = g.value;
|
|
952
955
|
if (c && c.$el) {
|
|
953
956
|
const s = c.$el;
|
|
954
|
-
s.removeEventListener("mousedown", z), s.removeEventListener("mousemove",
|
|
957
|
+
s.removeEventListener("mousedown", z), s.removeEventListener("mousemove", de), s.removeEventListener("mouseup", be), s.removeEventListener("keydown", Ce);
|
|
955
958
|
}
|
|
956
959
|
}
|
|
957
960
|
});
|
|
958
|
-
const f =
|
|
961
|
+
const f = ce(() => xe.value.height || x.value);
|
|
959
962
|
let $;
|
|
960
963
|
async function h(c) {
|
|
961
964
|
const { dataFormat: s } = o.tableConfig;
|
|
962
965
|
c.pageNo != 1 && (c.nextSearchAfter = $), r.value = !0;
|
|
963
|
-
const { code: C, data:
|
|
966
|
+
const { code: C, data: E = {} } = await o.api(c).finally(() => {
|
|
964
967
|
r.value = !1, o.searchForm.selections = [];
|
|
965
968
|
});
|
|
966
969
|
if (C == 200) {
|
|
967
|
-
let
|
|
968
|
-
a.value = s ? s(
|
|
970
|
+
let A = E.rows || E.records || [];
|
|
971
|
+
a.value = s ? s(A) : A, v.total = E.totalRows || E.total || 0, $ = E.nextSearchAfter, o.searchForm.enableCellCopy && _e(() => {
|
|
969
972
|
setTimeout(() => {
|
|
970
|
-
|
|
973
|
+
u();
|
|
971
974
|
}, 100);
|
|
972
975
|
});
|
|
973
976
|
}
|
|
@@ -976,10 +979,10 @@ const tn = { class: "center" }, nn = {
|
|
|
976
979
|
const { searchData: s = () => ({}) } = o.tableConfig, C = s();
|
|
977
980
|
h({ ...v, ...Fe(o.searchForm.items), ...c, ...C });
|
|
978
981
|
}
|
|
979
|
-
function
|
|
982
|
+
function I() {
|
|
980
983
|
const { reset: c } = o.tableConfig;
|
|
981
984
|
c && c(), o.searchForm.items.forEach((s) => {
|
|
982
|
-
const C =
|
|
985
|
+
const C = d.find((E) => Pe(s.key) && Pe(E.key) ? s.key.join(",") == E.key.join(",") : E.key == s.key);
|
|
983
986
|
C && (s.value = C.value);
|
|
984
987
|
}), m();
|
|
985
988
|
}
|
|
@@ -988,16 +991,16 @@ const tn = { class: "center" }, nn = {
|
|
|
988
991
|
return { ...v, ...Fe(o.searchForm.items) };
|
|
989
992
|
}
|
|
990
993
|
const Y = () => {
|
|
991
|
-
const c =
|
|
994
|
+
const c = g.value;
|
|
992
995
|
c && c.clearSort();
|
|
993
|
-
}, _ =
|
|
996
|
+
}, _ = pe({
|
|
994
997
|
storage: !0
|
|
995
|
-
}), y =
|
|
998
|
+
}), y = pe({
|
|
996
999
|
width: "auto",
|
|
997
1000
|
drag: !0,
|
|
998
1001
|
resizable: !0,
|
|
999
1002
|
maxFixedSize: 0
|
|
1000
|
-
}),
|
|
1003
|
+
}), p = pe({
|
|
1001
1004
|
isSelecting: !1,
|
|
1002
1005
|
// 是否正在选择
|
|
1003
1006
|
startCell: null,
|
|
@@ -1013,58 +1016,58 @@ const tn = { class: "center" }, nn = {
|
|
|
1013
1016
|
const C = s.closest(".vxe-body--row");
|
|
1014
1017
|
if (!C)
|
|
1015
1018
|
return null;
|
|
1016
|
-
const
|
|
1017
|
-
if (!
|
|
1019
|
+
const E = g.value;
|
|
1020
|
+
if (!E)
|
|
1018
1021
|
return null;
|
|
1019
|
-
let
|
|
1022
|
+
let A = -1;
|
|
1020
1023
|
const Z = C.getAttribute("data-rowid");
|
|
1021
1024
|
if (Z != null)
|
|
1022
|
-
|
|
1025
|
+
A = parseInt(Z, 10);
|
|
1023
1026
|
else {
|
|
1024
1027
|
const F = C.parentElement;
|
|
1025
|
-
|
|
1028
|
+
A = Array.from(F.querySelectorAll(".vxe-body--row")).indexOf(C);
|
|
1026
1029
|
}
|
|
1027
|
-
if (
|
|
1030
|
+
if (A < 0)
|
|
1028
1031
|
return null;
|
|
1029
1032
|
let V = -1;
|
|
1030
1033
|
const X = s.getAttribute("data-colid");
|
|
1031
|
-
if (X && (V =
|
|
1032
|
-
const S = Array.from(C.querySelectorAll(".vxe-body--column")).indexOf(s), j = !!s.closest(".vxe-table--fixed-left-wrapper"), H = !!s.closest(".vxe-table--fixed-right-wrapper"),
|
|
1034
|
+
if (X && (V = E.getColumns().findIndex((S) => S.id === X)), V < 0) {
|
|
1035
|
+
const S = Array.from(C.querySelectorAll(".vxe-body--column")).indexOf(s), j = !!s.closest(".vxe-table--fixed-left-wrapper"), H = !!s.closest(".vxe-table--fixed-right-wrapper"), M = E.getColumns();
|
|
1033
1036
|
if (j) {
|
|
1034
|
-
const N =
|
|
1035
|
-
S < N.length && (V =
|
|
1037
|
+
const N = M.filter((B) => B.fixed === "left");
|
|
1038
|
+
S < N.length && (V = M.indexOf(N[S]));
|
|
1036
1039
|
} else if (H) {
|
|
1037
|
-
const N =
|
|
1038
|
-
S < N.length && (V =
|
|
1040
|
+
const N = M.filter((B) => B.fixed === "right");
|
|
1041
|
+
S < N.length && (V = M.indexOf(N[S]));
|
|
1039
1042
|
} else {
|
|
1040
1043
|
const N = o.searchForm.showCheckBox ? 1 : 0;
|
|
1041
|
-
V =
|
|
1044
|
+
V = M.filter((W) => W.fixed === "left").length + S - N;
|
|
1042
1045
|
}
|
|
1043
1046
|
}
|
|
1044
|
-
return V < 0 ? null : { rowIndex:
|
|
1047
|
+
return V < 0 ? null : { rowIndex: A, colIndex: V, cell: s };
|
|
1045
1048
|
}, z = (c) => {
|
|
1046
1049
|
const s = P(c.target);
|
|
1047
1050
|
if (!s) {
|
|
1048
1051
|
ye();
|
|
1049
1052
|
return;
|
|
1050
1053
|
}
|
|
1051
|
-
|
|
1054
|
+
p.isSelecting = !0, p.startCell = {
|
|
1052
1055
|
rowIndex: s.rowIndex,
|
|
1053
1056
|
colIndex: s.colIndex
|
|
1054
|
-
},
|
|
1055
|
-
},
|
|
1056
|
-
if (!
|
|
1057
|
+
}, p.endCell = { ...p.startCell }, ze(), Me();
|
|
1058
|
+
}, de = (c) => {
|
|
1059
|
+
if (!p.isSelecting)
|
|
1057
1060
|
return;
|
|
1058
1061
|
const s = P(c.target);
|
|
1059
|
-
s && (
|
|
1062
|
+
s && (p.endCell = {
|
|
1060
1063
|
rowIndex: s.rowIndex,
|
|
1061
1064
|
colIndex: s.colIndex
|
|
1062
|
-
}, ze(),
|
|
1065
|
+
}, ze(), Me());
|
|
1063
1066
|
}, be = () => {
|
|
1064
|
-
|
|
1067
|
+
p.isSelecting = !1;
|
|
1065
1068
|
}, ye = () => {
|
|
1066
|
-
|
|
1067
|
-
const c =
|
|
1069
|
+
p.selectedCells = [], p.startCell = null, p.endCell = null;
|
|
1070
|
+
const c = g.value;
|
|
1068
1071
|
if (!c)
|
|
1069
1072
|
return;
|
|
1070
1073
|
c.$el.querySelectorAll(
|
|
@@ -1079,21 +1082,21 @@ const tn = { class: "center" }, nn = {
|
|
|
1079
1082
|
);
|
|
1080
1083
|
});
|
|
1081
1084
|
}, ze = () => {
|
|
1082
|
-
if (!
|
|
1083
|
-
|
|
1085
|
+
if (!p.startCell || !p.endCell) {
|
|
1086
|
+
p.selectedCells = [];
|
|
1084
1087
|
return;
|
|
1085
1088
|
}
|
|
1086
|
-
const c =
|
|
1087
|
-
|
|
1088
|
-
for (let F =
|
|
1089
|
+
const c = p.startCell.rowIndex, s = p.endCell.rowIndex, C = p.startCell.colIndex, E = p.endCell.colIndex, A = Math.min(c, s), Z = Math.max(c, s), V = Math.min(C, E), X = Math.max(C, E);
|
|
1090
|
+
p.selectedCells = [];
|
|
1091
|
+
for (let F = A; F <= Z; F++)
|
|
1089
1092
|
for (let S = V; S <= X; S++)
|
|
1090
|
-
|
|
1093
|
+
p.selectedCells.push({
|
|
1091
1094
|
rowIndex: F,
|
|
1092
1095
|
colIndex: S
|
|
1093
1096
|
});
|
|
1094
|
-
},
|
|
1097
|
+
}, Me = () => {
|
|
1095
1098
|
_e(() => {
|
|
1096
|
-
const c =
|
|
1099
|
+
const c = g.value;
|
|
1097
1100
|
if (!c)
|
|
1098
1101
|
return;
|
|
1099
1102
|
const s = c.$el;
|
|
@@ -1107,33 +1110,33 @@ const tn = { class: "center" }, nn = {
|
|
|
1107
1110
|
"cell-border-bottom",
|
|
1108
1111
|
"cell-border-left"
|
|
1109
1112
|
);
|
|
1110
|
-
}),
|
|
1113
|
+
}), p.selectedCells.length === 0)
|
|
1111
1114
|
return;
|
|
1112
|
-
const C = c.getColumns(),
|
|
1115
|
+
const C = c.getColumns(), E = p.selectedCells.map((j) => j.rowIndex), A = p.selectedCells.map((j) => j.colIndex), Z = Math.min(...E), V = Math.max(...E), X = Math.min(...A), F = Math.max(...A), S = [
|
|
1113
1116
|
s.querySelector(".vxe-table--body-wrapper tbody"),
|
|
1114
1117
|
s.querySelector(".vxe-table--fixed-left-wrapper tbody"),
|
|
1115
1118
|
s.querySelector(".vxe-table--fixed-right-wrapper tbody")
|
|
1116
1119
|
].filter(Boolean);
|
|
1117
|
-
|
|
1118
|
-
const
|
|
1119
|
-
if (!
|
|
1120
|
+
p.selectedCells.forEach(({ rowIndex: j, colIndex: H }) => {
|
|
1121
|
+
const M = C[H];
|
|
1122
|
+
if (!M)
|
|
1120
1123
|
return;
|
|
1121
|
-
const N =
|
|
1122
|
-
for (const
|
|
1123
|
-
const
|
|
1124
|
-
if (!
|
|
1124
|
+
const N = M.fixed === "left", B = M.fixed === "right";
|
|
1125
|
+
for (const W of S) {
|
|
1126
|
+
const fe = W.querySelectorAll(".vxe-body--row")[j];
|
|
1127
|
+
if (!fe)
|
|
1125
1128
|
continue;
|
|
1126
|
-
const
|
|
1129
|
+
const ne = Array.from(fe.querySelectorAll(".vxe-body--column"));
|
|
1127
1130
|
let D = null;
|
|
1128
|
-
if (N &&
|
|
1129
|
-
const
|
|
1130
|
-
D =
|
|
1131
|
-
} else if (B &&
|
|
1132
|
-
const
|
|
1133
|
-
D =
|
|
1134
|
-
} else if (!N && !B &&
|
|
1135
|
-
const
|
|
1136
|
-
D =
|
|
1131
|
+
if (N && W.closest(".vxe-table--fixed-left-wrapper")) {
|
|
1132
|
+
const J = C.filter((Q) => Q.fixed === "left").indexOf(M);
|
|
1133
|
+
D = ne[J];
|
|
1134
|
+
} else if (B && W.closest(".vxe-table--fixed-right-wrapper")) {
|
|
1135
|
+
const J = C.filter((Q) => Q.fixed === "right").indexOf(M);
|
|
1136
|
+
D = ne[J];
|
|
1137
|
+
} else if (!N && !B && W.closest(".vxe-table--body-wrapper")) {
|
|
1138
|
+
const oe = o.searchForm.showCheckBox ? 1 : 0, J = C.filter((we) => we.fixed === "left").length, Q = H - J;
|
|
1139
|
+
D = ne[Q + oe];
|
|
1137
1140
|
}
|
|
1138
1141
|
if (D && !D.classList.contains("col--checkbox") && !D.classList.contains("col--seq")) {
|
|
1139
1142
|
D.classList.add("cell-selected"), j === Z && D.classList.add("cell-border-top"), j === V && D.classList.add("cell-border-bottom"), H === X && D.classList.add("cell-border-left"), H === F && D.classList.add("cell-border-right");
|
|
@@ -1142,46 +1145,46 @@ const tn = { class: "center" }, nn = {
|
|
|
1142
1145
|
}
|
|
1143
1146
|
});
|
|
1144
1147
|
});
|
|
1145
|
-
},
|
|
1146
|
-
if (
|
|
1148
|
+
}, st = async () => {
|
|
1149
|
+
if (p.selectedCells.length === 0)
|
|
1147
1150
|
return;
|
|
1148
|
-
const c =
|
|
1151
|
+
const c = g.value;
|
|
1149
1152
|
if (!c)
|
|
1150
1153
|
return;
|
|
1151
|
-
const s = c.$el, C = c.getColumns(),
|
|
1154
|
+
const s = c.$el, C = c.getColumns(), E = [...new Set(p.selectedCells.map((F) => F.rowIndex))].sort(
|
|
1152
1155
|
(F, S) => F - S
|
|
1153
|
-
),
|
|
1156
|
+
), A = [...new Set(p.selectedCells.map((F) => F.colIndex))].sort(
|
|
1154
1157
|
(F, S) => F - S
|
|
1155
1158
|
), Z = [
|
|
1156
1159
|
s.querySelector(".vxe-table--body-wrapper tbody"),
|
|
1157
1160
|
s.querySelector(".vxe-table--fixed-left-wrapper tbody"),
|
|
1158
1161
|
s.querySelector(".vxe-table--fixed-right-wrapper tbody")
|
|
1159
1162
|
].filter(Boolean), V = [];
|
|
1160
|
-
|
|
1163
|
+
E.forEach((F) => {
|
|
1161
1164
|
const S = [];
|
|
1162
|
-
|
|
1165
|
+
A.forEach((j) => {
|
|
1163
1166
|
const H = C[j];
|
|
1164
1167
|
if (!H) {
|
|
1165
1168
|
S.push("");
|
|
1166
1169
|
return;
|
|
1167
1170
|
}
|
|
1168
|
-
const
|
|
1171
|
+
const M = H.fixed === "left", N = H.fixed === "right";
|
|
1169
1172
|
let B = "";
|
|
1170
|
-
for (const
|
|
1171
|
-
const
|
|
1172
|
-
if (!
|
|
1173
|
+
for (const W of Z) {
|
|
1174
|
+
const fe = W.querySelectorAll(".vxe-body--row")[F];
|
|
1175
|
+
if (!fe)
|
|
1173
1176
|
continue;
|
|
1174
|
-
const
|
|
1177
|
+
const ne = Array.from(fe.querySelectorAll(".vxe-body--column"));
|
|
1175
1178
|
let D = null;
|
|
1176
|
-
if (
|
|
1177
|
-
const
|
|
1178
|
-
D =
|
|
1179
|
-
} else if (N &&
|
|
1180
|
-
const
|
|
1181
|
-
D =
|
|
1182
|
-
} else if (!
|
|
1183
|
-
const
|
|
1184
|
-
D =
|
|
1179
|
+
if (M && W.closest(".vxe-table--fixed-left-wrapper")) {
|
|
1180
|
+
const J = C.filter((Q) => Q.fixed === "left").indexOf(H);
|
|
1181
|
+
D = ne[J];
|
|
1182
|
+
} else if (N && W.closest(".vxe-table--fixed-right-wrapper")) {
|
|
1183
|
+
const J = C.filter((Q) => Q.fixed === "right").indexOf(H);
|
|
1184
|
+
D = ne[J];
|
|
1185
|
+
} else if (!M && !N && W.closest(".vxe-table--body-wrapper")) {
|
|
1186
|
+
const oe = o.searchForm.showCheckBox ? 1 : 0, J = C.filter((we) => we.fixed === "left").length, Q = j - J;
|
|
1187
|
+
D = ne[Q + oe];
|
|
1185
1188
|
}
|
|
1186
1189
|
if (D && !D.classList.contains("col--checkbox") && !D.classList.contains("col--seq")) {
|
|
1187
1190
|
B = D.innerText || D.textContent || "", B = B.trim(), B = B.replace(/\n/g, " ").replace(/\s+/g, " ");
|
|
@@ -1199,15 +1202,15 @@ const tn = { class: "center" }, nn = {
|
|
|
1199
1202
|
console.error("复制失败:", F);
|
|
1200
1203
|
}
|
|
1201
1204
|
}, Ce = (c) => {
|
|
1202
|
-
o.searchForm.enableCellCopy && ((c.ctrlKey || c.metaKey) && c.key === "c" ?
|
|
1203
|
-
},
|
|
1204
|
-
|
|
1205
|
-
},
|
|
1206
|
-
const s =
|
|
1205
|
+
o.searchForm.enableCellCopy && ((c.ctrlKey || c.metaKey) && c.key === "c" ? p.selectedCells.length > 0 && (c.preventDefault(), c.stopPropagation(), st()) : c.key === "Escape" && ye());
|
|
1206
|
+
}, Re = () => {
|
|
1207
|
+
p.isSelecting = !1;
|
|
1208
|
+
}, Ae = (c) => {
|
|
1209
|
+
const s = g.value;
|
|
1207
1210
|
if (!s || !s.$el)
|
|
1208
1211
|
return;
|
|
1209
1212
|
s.$el.contains(c.target) || ye();
|
|
1210
|
-
}, xe =
|
|
1213
|
+
}, xe = ce(() => {
|
|
1211
1214
|
const { customConfig: c, columnConfig: s, ...C } = o.tableConfig;
|
|
1212
1215
|
return {
|
|
1213
1216
|
headerAlign: "left",
|
|
@@ -1223,59 +1226,59 @@ const tn = { class: "center" }, nn = {
|
|
|
1223
1226
|
"virtual-y-config": { enabled: !0, gt: 100 },
|
|
1224
1227
|
...C
|
|
1225
1228
|
};
|
|
1226
|
-
}),
|
|
1229
|
+
}), it = (c) => {
|
|
1227
1230
|
v.pageNo = c, m();
|
|
1228
|
-
},
|
|
1231
|
+
}, ct = (c) => {
|
|
1229
1232
|
v.pageSize = c, v[i] = 1, m();
|
|
1230
1233
|
};
|
|
1231
1234
|
function Ve() {
|
|
1232
|
-
const c =
|
|
1235
|
+
const c = g.value.getCheckboxRecords();
|
|
1233
1236
|
o.searchForm.selections = c;
|
|
1234
1237
|
}
|
|
1235
1238
|
const Ue = (c) => {
|
|
1236
|
-
const s =
|
|
1239
|
+
const s = g.value;
|
|
1237
1240
|
if (s) {
|
|
1238
1241
|
s.toggleCheckboxRow(c);
|
|
1239
|
-
const C =
|
|
1242
|
+
const C = g.value.getCheckboxRecords();
|
|
1240
1243
|
o.searchForm.selections = C;
|
|
1241
1244
|
}
|
|
1242
1245
|
};
|
|
1243
|
-
return e({ tableRef:
|
|
1246
|
+
return e({ tableRef: g, getList: m, getPrm: T, clearSort: Y, calculateTableHeight: w }), (c, s) => {
|
|
1244
1247
|
var F;
|
|
1245
|
-
const C = O("el-button"),
|
|
1246
|
-
return L(),
|
|
1247
|
-
class:
|
|
1248
|
+
const C = O("el-button"), E = O("el-checkbox"), A = O("el-text"), Z = O("vxe-column"), V = O("VxeTable"), X = O("el-pagination");
|
|
1249
|
+
return L(), le("div", {
|
|
1250
|
+
class: Ee({ box: n.searchForm.showShadow })
|
|
1248
1251
|
}, [
|
|
1249
|
-
n.searchForm.showSearch ? (L(), U(
|
|
1252
|
+
n.searchForm.showSearch ? (L(), U(Xt, {
|
|
1250
1253
|
key: 0,
|
|
1251
1254
|
form: n.searchForm,
|
|
1252
|
-
onReset:
|
|
1255
|
+
onReset: I,
|
|
1253
1256
|
onConfirm: s[1] || (s[1] = (S) => m()),
|
|
1254
1257
|
onVisibleChange: K(w)
|
|
1255
1258
|
}, {
|
|
1256
|
-
btn:
|
|
1257
|
-
|
|
1259
|
+
btn: R(() => [
|
|
1260
|
+
ae(c.$slots, "search-bar-btn", {}, void 0, !0),
|
|
1258
1261
|
G(C, {
|
|
1259
1262
|
round: "",
|
|
1260
|
-
onClick: s[0] || (s[0] = (S) =>
|
|
1263
|
+
onClick: s[0] || (s[0] = (S) => g.value.openCustom())
|
|
1261
1264
|
}, {
|
|
1262
|
-
default:
|
|
1263
|
-
G(
|
|
1265
|
+
default: R(() => [
|
|
1266
|
+
G(rt, { name: "Tools" })
|
|
1264
1267
|
]),
|
|
1265
1268
|
_: 1
|
|
1266
1269
|
})
|
|
1267
1270
|
]),
|
|
1268
1271
|
_: 3
|
|
1269
|
-
}, 8, ["form", "onVisibleChange"])) :
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
+
}, 8, ["form", "onVisibleChange"])) : se("", !0),
|
|
1273
|
+
ae(c.$slots, "table-header-left", {}, void 0, !0),
|
|
1274
|
+
re("div", {
|
|
1272
1275
|
ref_key: "tableContentRef",
|
|
1273
1276
|
ref: k
|
|
1274
1277
|
}, [
|
|
1275
|
-
G(V,
|
|
1278
|
+
G(V, me({
|
|
1276
1279
|
id: n.id,
|
|
1277
1280
|
ref_key: "tableRef",
|
|
1278
|
-
ref:
|
|
1281
|
+
ref: g,
|
|
1279
1282
|
loading: n.loading || r.value,
|
|
1280
1283
|
data: n.api ? a.value : n.data,
|
|
1281
1284
|
border: ""
|
|
@@ -1285,7 +1288,7 @@ const tn = { class: "center" }, nn = {
|
|
|
1285
1288
|
onCheckboxAll: Ve,
|
|
1286
1289
|
onSortChange: (F = xe.value["sort-config"]) == null ? void 0 : F.sortChange
|
|
1287
1290
|
}), {
|
|
1288
|
-
default:
|
|
1291
|
+
default: R(() => [
|
|
1289
1292
|
n.searchForm.showCheckBox == null || n.searchForm.showCheckBox ? (L(), U(Z, {
|
|
1290
1293
|
key: 0,
|
|
1291
1294
|
type: "checkbox",
|
|
@@ -1293,35 +1296,35 @@ const tn = { class: "center" }, nn = {
|
|
|
1293
1296
|
title: c.$t("xu-hao"),
|
|
1294
1297
|
fixed: "left"
|
|
1295
1298
|
}, {
|
|
1296
|
-
checkbox:
|
|
1297
|
-
|
|
1298
|
-
H ? (L(), U(
|
|
1299
|
+
checkbox: R(({ rowIndex: S, row: j, checked: H, disabled: M, indeterminate: N }) => [
|
|
1300
|
+
re("div", en, [
|
|
1301
|
+
H ? (L(), U(E, {
|
|
1299
1302
|
key: 0,
|
|
1300
1303
|
checked: !0,
|
|
1301
|
-
disabled:
|
|
1304
|
+
disabled: M,
|
|
1302
1305
|
size: "default",
|
|
1303
|
-
onClick:
|
|
1304
|
-
}, null, 8, ["disabled", "onClick"])) : (L(), U(
|
|
1306
|
+
onClick: Ie((B) => !M && Ue(j), ["stop"])
|
|
1307
|
+
}, null, 8, ["disabled", "onClick"])) : (L(), U(E, {
|
|
1305
1308
|
key: 1,
|
|
1306
|
-
disabled:
|
|
1309
|
+
disabled: M,
|
|
1307
1310
|
checked: !1,
|
|
1308
1311
|
size: "default",
|
|
1309
|
-
onClick:
|
|
1312
|
+
onClick: Ie((B) => !M && Ue(j), ["stop"])
|
|
1310
1313
|
}, null, 8, ["disabled", "onClick"])),
|
|
1311
|
-
G(
|
|
1314
|
+
G(A, {
|
|
1312
1315
|
type: "info",
|
|
1313
1316
|
class: "mgl5"
|
|
1314
1317
|
}, {
|
|
1315
|
-
default:
|
|
1316
|
-
te(
|
|
1318
|
+
default: R(() => [
|
|
1319
|
+
ee(te(S + 1), 1)
|
|
1317
1320
|
]),
|
|
1318
1321
|
_: 2
|
|
1319
1322
|
}, 1024)
|
|
1320
1323
|
])
|
|
1321
1324
|
]),
|
|
1322
1325
|
_: 1
|
|
1323
|
-
}, 8, ["width", "title"])) :
|
|
1324
|
-
|
|
1326
|
+
}, 8, ["width", "title"])) : se("", !0),
|
|
1327
|
+
ae(c.$slots, "default", {}, void 0, !0)
|
|
1325
1328
|
]),
|
|
1326
1329
|
_: 3
|
|
1327
1330
|
}, 16, ["id", "loading", "data", "height", "onSortChange"])
|
|
@@ -1336,13 +1339,13 @@ const tn = { class: "center" }, nn = {
|
|
|
1336
1339
|
total: v.total,
|
|
1337
1340
|
"page-size": v.pageSize,
|
|
1338
1341
|
"page-sizes": [10, 50, 100, 500],
|
|
1339
|
-
onCurrentChange:
|
|
1340
|
-
onSizeChange:
|
|
1341
|
-
}, null, 8, ["current-page", "total", "page-size"])) :
|
|
1342
|
+
onCurrentChange: it,
|
|
1343
|
+
onSizeChange: ct
|
|
1344
|
+
}, null, 8, ["current-page", "total", "page-size"])) : se("", !0)
|
|
1342
1345
|
], 2);
|
|
1343
1346
|
};
|
|
1344
1347
|
}
|
|
1345
|
-
},
|
|
1348
|
+
}, Ln = /* @__PURE__ */ ge(tn, [["__scopeId", "data-v-8b6ee274"]]), Tn = {
|
|
1346
1349
|
__name: "index",
|
|
1347
1350
|
props: {
|
|
1348
1351
|
sheetsConfig: {
|
|
@@ -1361,19 +1364,19 @@ const tn = { class: "center" }, nn = {
|
|
|
1361
1364
|
}
|
|
1362
1365
|
return (l, o) => {
|
|
1363
1366
|
const r = O("el-link");
|
|
1364
|
-
return L(), U(r,
|
|
1367
|
+
return L(), U(r, me({
|
|
1365
1368
|
type: "primary",
|
|
1366
1369
|
underline: "never"
|
|
1367
1370
|
}, l.$attrs, { onClick: t }), {
|
|
1368
|
-
default:
|
|
1369
|
-
te(
|
|
1371
|
+
default: R(() => [
|
|
1372
|
+
ee(te(l.$t("xia-zai-dao-ru-mo-ban")), 1)
|
|
1370
1373
|
]),
|
|
1371
1374
|
_: 1
|
|
1372
1375
|
}, 16);
|
|
1373
1376
|
};
|
|
1374
1377
|
}
|
|
1375
1378
|
};
|
|
1376
|
-
function
|
|
1379
|
+
function Fn(n, e = {}) {
|
|
1377
1380
|
const t = De(), l = {
|
|
1378
1381
|
inForm: !0,
|
|
1379
1382
|
required: !0,
|
|
@@ -1382,36 +1385,16 @@ function Dn(n, e = {}) {
|
|
|
1382
1385
|
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}$/,
|
|
1383
1386
|
password: /(?=.*\d)(?=.*[a-zA-Z])(?=.*[^a-zA-Z0-9]).{8,12}/,
|
|
1384
1387
|
email: /^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/
|
|
1385
|
-
}[n], { inForm: r, value: a, required:
|
|
1386
|
-
return r ? function(v,
|
|
1387
|
-
if (
|
|
1388
|
-
o.test(
|
|
1388
|
+
}[n], { inForm: r, value: a, required: d, msg: i = t("validate.invalidInput") } = l;
|
|
1389
|
+
return r ? function(v, g, k) {
|
|
1390
|
+
if (d) {
|
|
1391
|
+
o.test(g) ? k() : k(new Error(i));
|
|
1389
1392
|
return;
|
|
1390
1393
|
}
|
|
1391
|
-
|
|
1394
|
+
g && !o.test(g) ? k(new Error(i)) : k();
|
|
1392
1395
|
} : o.test(a);
|
|
1393
1396
|
}
|
|
1394
|
-
|
|
1395
|
-
//加密
|
|
1396
|
-
encrypt(n, e) {
|
|
1397
|
-
e = e || "1CFEC667A1E6D42DC12565AAAA460494";
|
|
1398
|
-
var t = ee.enc.Utf8.parse(e), l = ee.enc.Utf8.parse(n), o = ee.AES.encrypt(l, t, {
|
|
1399
|
-
mode: ee.mode.ECB,
|
|
1400
|
-
padding: ee.pad.Pkcs7
|
|
1401
|
-
});
|
|
1402
|
-
return o.toString();
|
|
1403
|
-
},
|
|
1404
|
-
//解密
|
|
1405
|
-
decrypt(n, e) {
|
|
1406
|
-
e = e || "1CFEC667A1E6D42DC12565AAAA460494";
|
|
1407
|
-
var t = ee.enc.Utf8.parse(e), l = ee.AES.decrypt(n, t, {
|
|
1408
|
-
mode: ee.mode.ECB,
|
|
1409
|
-
padding: ee.pad.Pkcs7
|
|
1410
|
-
});
|
|
1411
|
-
return ee.enc.Utf8.stringify(l).toString();
|
|
1412
|
-
}
|
|
1413
|
-
};
|
|
1414
|
-
class An {
|
|
1397
|
+
class On {
|
|
1415
1398
|
constructor(e = {}) {
|
|
1416
1399
|
this.config = {
|
|
1417
1400
|
clientCode: e.clientCode || "one-portal",
|
|
@@ -1617,45 +1600,45 @@ class An {
|
|
|
1617
1600
|
return this.config[e];
|
|
1618
1601
|
}
|
|
1619
1602
|
}
|
|
1620
|
-
function
|
|
1603
|
+
function Dn(n, e = {}) {
|
|
1621
1604
|
const l = Object.assign({
|
|
1622
1605
|
manual: !1,
|
|
1623
1606
|
// 手动执行
|
|
1624
1607
|
log: !1,
|
|
1625
1608
|
params: null,
|
|
1626
1609
|
format: null
|
|
1627
|
-
}, e), { manual: o, log: r, params: a = {}, cb:
|
|
1610
|
+
}, e), { manual: o, log: r, params: a = {}, cb: d, format: i } = l, v = q([]), g = q(!1), k = (x) => {
|
|
1628
1611
|
const w = x || a;
|
|
1629
|
-
|
|
1630
|
-
const { code:
|
|
1631
|
-
if (
|
|
1632
|
-
const { records: h, rows: m } = f || {},
|
|
1633
|
-
v.value = $e(
|
|
1612
|
+
g.value = !0, n(w).then((b) => {
|
|
1613
|
+
const { code: u, data: f, msg: $ } = b;
|
|
1614
|
+
if (d) {
|
|
1615
|
+
const { records: h, rows: m } = f || {}, I = h || m ? h || m : f;
|
|
1616
|
+
v.value = $e(I, i), d(b);
|
|
1634
1617
|
}
|
|
1635
1618
|
if (f) {
|
|
1636
1619
|
if (f.records != null || f.rows != null) {
|
|
1637
|
-
const { records: h, rows: m, total:
|
|
1638
|
-
w && w.total != null && (a.total = parseInt(
|
|
1620
|
+
const { records: h, rows: m, total: I = 0 } = f || {};
|
|
1621
|
+
w && w.total != null && (a.total = parseInt(I)), v.value = $e(h || m || [], i);
|
|
1639
1622
|
} else
|
|
1640
1623
|
v.value = $e(f, i);
|
|
1641
1624
|
r && console.log("useRequest-res", v.value);
|
|
1642
1625
|
}
|
|
1643
1626
|
}).catch((b) => {
|
|
1644
|
-
|
|
1627
|
+
d && (console.log("useRequestErr", b), d({ code: 500 }));
|
|
1645
1628
|
}).finally(() => {
|
|
1646
|
-
|
|
1629
|
+
g.value = !1;
|
|
1647
1630
|
});
|
|
1648
1631
|
};
|
|
1649
|
-
return o || k(), [
|
|
1632
|
+
return o || k(), [g, v, k];
|
|
1650
1633
|
}
|
|
1651
|
-
function
|
|
1634
|
+
function zn(n) {
|
|
1652
1635
|
const e = q(n), t = q(""), l = q("");
|
|
1653
|
-
return
|
|
1636
|
+
return Ze(e, (o) => {
|
|
1654
1637
|
const r = o || ["", ""];
|
|
1655
1638
|
t.value = r[0], l.value = r[1];
|
|
1656
1639
|
}), [e, t, l];
|
|
1657
1640
|
}
|
|
1658
|
-
function
|
|
1641
|
+
function Mn(n) {
|
|
1659
1642
|
return Object.prototype.toString.call(n).slice(8, -1).toLowerCase();
|
|
1660
1643
|
}
|
|
1661
1644
|
function $e(n, e) {
|
|
@@ -1669,9 +1652,9 @@ function $e(n, e) {
|
|
|
1669
1652
|
let t = {};
|
|
1670
1653
|
return e.forEach((l) => t[l] = n[l]), t;
|
|
1671
1654
|
}
|
|
1672
|
-
function
|
|
1673
|
-
const { locale: t } =
|
|
1674
|
-
return
|
|
1655
|
+
function Rn(n, e = []) {
|
|
1656
|
+
const { locale: t } = ue(), l = q(n());
|
|
1657
|
+
return Ze(
|
|
1675
1658
|
[t, ...e],
|
|
1676
1659
|
() => {
|
|
1677
1660
|
l.value = n();
|
|
@@ -1679,38 +1662,38 @@ function Un(n, e = []) {
|
|
|
1679
1662
|
{ immediate: !0 }
|
|
1680
1663
|
), l;
|
|
1681
1664
|
}
|
|
1682
|
-
function
|
|
1665
|
+
function An(n, e = "zh_cn", t = "en_us") {
|
|
1683
1666
|
if (!n)
|
|
1684
1667
|
return "-";
|
|
1685
|
-
const l = { en_us: t, zh_cn: e }, r =
|
|
1668
|
+
const l = { en_us: t, zh_cn: e }, r = ot().global.locale.value;
|
|
1686
1669
|
return n[l[r]] || n[e] || "-";
|
|
1687
1670
|
}
|
|
1688
|
-
function
|
|
1671
|
+
function Vn(n, e) {
|
|
1672
|
+
let t = _t;
|
|
1673
|
+
return typeof n == "string" && n.length > 0 && (t = Oe(n).mapState), at(e, t);
|
|
1674
|
+
}
|
|
1675
|
+
function Un(n, e) {
|
|
1689
1676
|
let t = $t;
|
|
1690
|
-
return typeof n == "string" && n.length > 0 && (t = Oe(n).
|
|
1677
|
+
return typeof n == "string" && n.length > 0 && (t = Oe(n).mapGetters), at(e, t);
|
|
1691
1678
|
}
|
|
1692
|
-
function
|
|
1679
|
+
function jn(n, e) {
|
|
1693
1680
|
let t = St;
|
|
1694
|
-
return typeof n == "string" && n.length > 0 && (t = Oe(n).
|
|
1695
|
-
}
|
|
1696
|
-
function Bn(n, e) {
|
|
1697
|
-
let t = Et;
|
|
1698
|
-
return typeof n == "string" && n.length > 0 && (t = Oe(n).mapActions), on(e, t);
|
|
1681
|
+
return typeof n == "string" && n.length > 0 && (t = Oe(n).mapActions), nn(e, t);
|
|
1699
1682
|
}
|
|
1700
|
-
function
|
|
1701
|
-
const t =
|
|
1683
|
+
function at(n, e) {
|
|
1684
|
+
const t = Qe(), l = e(n), o = {};
|
|
1702
1685
|
return Object.keys(l).forEach((r) => {
|
|
1703
1686
|
const a = l[r].bind({ $store: t });
|
|
1704
|
-
o[r] =
|
|
1687
|
+
o[r] = ce(a);
|
|
1705
1688
|
}), o;
|
|
1706
1689
|
}
|
|
1707
|
-
function
|
|
1708
|
-
const t =
|
|
1690
|
+
function nn(n, e) {
|
|
1691
|
+
const t = Qe(), l = e(n), o = {};
|
|
1709
1692
|
return Object.keys(l).forEach((r) => {
|
|
1710
1693
|
o[r] = l[r].bind({ $store: t });
|
|
1711
1694
|
}), o;
|
|
1712
1695
|
}
|
|
1713
|
-
const
|
|
1696
|
+
const on = {
|
|
1714
1697
|
__name: "EnumRender",
|
|
1715
1698
|
props: {
|
|
1716
1699
|
renderOpts: {
|
|
@@ -1728,57 +1711,57 @@ const ln = {
|
|
|
1728
1711
|
return (l, o) => {
|
|
1729
1712
|
const r = O("el-text");
|
|
1730
1713
|
return n.renderOpts.text ? (L(), U(r, { key: 0 }, {
|
|
1731
|
-
default:
|
|
1732
|
-
te(
|
|
1714
|
+
default: R(() => [
|
|
1715
|
+
ee(te(n.renderOpts.enum.getName(K(t))), 1)
|
|
1733
1716
|
]),
|
|
1734
1717
|
_: 1
|
|
1735
1718
|
})) : (L(), U(r, {
|
|
1736
1719
|
key: 1,
|
|
1737
1720
|
type: n.renderOpts.enum.getTag(K(t))
|
|
1738
1721
|
}, {
|
|
1739
|
-
default:
|
|
1740
|
-
te(
|
|
1722
|
+
default: R(() => [
|
|
1723
|
+
ee(te(n.renderOpts.enum.getName(K(t))), 1)
|
|
1741
1724
|
]),
|
|
1742
1725
|
_: 1
|
|
1743
1726
|
}, 8, ["type"]));
|
|
1744
1727
|
};
|
|
1745
1728
|
}
|
|
1746
1729
|
};
|
|
1747
|
-
function
|
|
1748
|
-
|
|
1730
|
+
function qn() {
|
|
1731
|
+
he.renderer.add("Enum", {
|
|
1749
1732
|
// 默认显示模板
|
|
1750
1733
|
renderTableDefault(n, e) {
|
|
1751
|
-
return [null, void 0].includes(e.row[e.column.field]) ? "-" : /* @__PURE__ */ React.createElement(
|
|
1734
|
+
return [null, void 0].includes(e.row[e.column.field]) ? "-" : /* @__PURE__ */ React.createElement(on, { renderOpts: n, params: e });
|
|
1752
1735
|
}
|
|
1753
|
-
}),
|
|
1736
|
+
}), he.renderer.add("InputNumber", {
|
|
1754
1737
|
// 默认显示模板
|
|
1755
1738
|
renderTableDefault(n, e) {
|
|
1756
|
-
return /* @__PURE__ */ React.createElement(
|
|
1739
|
+
return /* @__PURE__ */ React.createElement(mt, { "v-model": e.row[e.column.field], ...n.props, "step-strictly": !0, "value-on-clear": 0 });
|
|
1757
1740
|
}
|
|
1758
|
-
}),
|
|
1741
|
+
}), he.renderer.add("TrueFalse", {
|
|
1759
1742
|
// 默认显示模板
|
|
1760
1743
|
renderTableDefault(n, e) {
|
|
1761
|
-
const { locale: t } =
|
|
1744
|
+
const { locale: t } = ue();
|
|
1762
1745
|
let l = t.value == "zh_cn";
|
|
1763
1746
|
return /* @__PURE__ */ React.createElement(
|
|
1764
|
-
|
|
1747
|
+
gt,
|
|
1765
1748
|
{
|
|
1766
1749
|
type: e.row[e.column.field] ? "success" : "danger"
|
|
1767
1750
|
},
|
|
1768
1751
|
e.row[e.column.field] ? l ? "是" : "YES" : l ? "否" : "NO"
|
|
1769
1752
|
);
|
|
1770
1753
|
}
|
|
1771
|
-
}),
|
|
1754
|
+
}), he.renderer.add("I18n", {
|
|
1772
1755
|
// 默认显示模板
|
|
1773
1756
|
renderTableDefault(n, e) {
|
|
1774
|
-
const { locale: t } =
|
|
1757
|
+
const { locale: t } = ue();
|
|
1775
1758
|
let l = t.value == "zh_cn" ? e.column.field : n.fieldEn;
|
|
1776
1759
|
return e.row[l] || e.row[e.column.field];
|
|
1777
1760
|
}
|
|
1778
|
-
}),
|
|
1761
|
+
}), he.renderer.add("Link", {
|
|
1779
1762
|
// 默认显示模板
|
|
1780
1763
|
renderTableDefault(n, e) {
|
|
1781
|
-
var
|
|
1764
|
+
var d;
|
|
1782
1765
|
let t = e.column.field;
|
|
1783
1766
|
const l = It(), { multiple: o, to: r } = n;
|
|
1784
1767
|
if (!o)
|
|
@@ -1791,7 +1774,7 @@ function Yn() {
|
|
|
1791
1774
|
},
|
|
1792
1775
|
e.row[t]
|
|
1793
1776
|
);
|
|
1794
|
-
const a = ((
|
|
1777
|
+
const a = ((d = e.row[t]) == null ? void 0 : d.split(",")) || [];
|
|
1795
1778
|
return a.map((i, v) => /* @__PURE__ */ React.createElement("span", null, /* @__PURE__ */ React.createElement(
|
|
1796
1779
|
je,
|
|
1797
1780
|
{
|
|
@@ -1805,44 +1788,43 @@ function Yn() {
|
|
|
1805
1788
|
});
|
|
1806
1789
|
}
|
|
1807
1790
|
export {
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
zn as crypto,
|
|
1791
|
+
Bt as CmpDictionary,
|
|
1792
|
+
rt as CmpIcon,
|
|
1793
|
+
In as ConfrimButton,
|
|
1794
|
+
Tn as DownExcelTemp,
|
|
1795
|
+
En as ImportButton,
|
|
1796
|
+
gn as LayOutForm,
|
|
1797
|
+
Ln as ListPage,
|
|
1798
|
+
On as OnePortalCasSDK,
|
|
1799
|
+
Xt as SearchBar,
|
|
1800
|
+
Be as StatusMap,
|
|
1801
|
+
bn as _toRaw,
|
|
1802
|
+
Mn as _typeOf,
|
|
1803
|
+
Cn as arrToStatusMap,
|
|
1804
|
+
yn as arrayToTree,
|
|
1805
|
+
kn as checkFileSize,
|
|
1806
|
+
Fn as creatValidator,
|
|
1807
|
+
$n as createImportFields,
|
|
1808
|
+
_n as createListPageId,
|
|
1827
1809
|
Te as en,
|
|
1828
1810
|
Mt as exportExcel,
|
|
1829
|
-
|
|
1811
|
+
ot as getI18n,
|
|
1830
1812
|
De as getI18nT,
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1813
|
+
An as getLocaleValue,
|
|
1814
|
+
Sn as getValueBykey,
|
|
1815
|
+
pn as importExcel,
|
|
1816
|
+
Ot as messages,
|
|
1817
|
+
qn as registerVxeRenderers,
|
|
1818
|
+
Dt as setupI18n,
|
|
1819
|
+
vn as sleep,
|
|
1820
|
+
lt as stringToArray,
|
|
1821
|
+
xn as stripHtmlTags,
|
|
1822
|
+
wn as unicode2Str,
|
|
1823
|
+
jn as useActions,
|
|
1824
|
+
zn as useDatePicker,
|
|
1825
|
+
Un as useGetters,
|
|
1826
|
+
Rn as useI18nReState,
|
|
1827
|
+
Dn as useRequest,
|
|
1828
|
+
Vn as useState,
|
|
1847
1829
|
Le as zhCn
|
|
1848
1830
|
};
|