vue-2024-ui 0.0.81 → 0.0.82
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/index.es.js +614 -589
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import _t, { ElForm as We, ElButtonGroup as Ge, ElButton as _e, ElPopover as Ke, ElMessage as Te, ElMessageBox as vt, ElDialog as kt, ElDrawer as Ct } from "element-plus";
|
|
2
|
-
import { mergeModels as Be, useModel as Ie, ref as ye, nextTick as yt, onMounted as Ne, resolveComponent as L, openBlock as n, createElementBlock as
|
|
2
|
+
import { mergeModels as Be, useModel as Ie, ref as ye, nextTick as yt, onMounted as Ne, resolveComponent as L, openBlock as n, createElementBlock as x, unref as o, createBlock as q, mergeProps as S, withCtx as y, renderSlot as p, Fragment as P, renderList as Y, createTextVNode as we, toDisplayString as Ee, createSlots as fe, createVNode as Z, createCommentVNode as $e, normalizeProps as Qe, createElementVNode as J, useSlots as ht, inject as at, useAttrs as nt, onUnmounted as Dt, computed as Ye, normalizeStyle as Oe, withModifiers as ct, guardReactiveProps as ft, resolveDynamicComponent as Ae, Transition as Vt, withDirectives as Mt, vShow as Tt, h as qe, onBeforeUnmount as Ft, normalizeClass as gt, watchEffect as St, watch as qt, createApp as xt } from "vue";
|
|
3
3
|
import { FullScreen as Ot, Remove as At } from "@element-plus/icons-vue";
|
|
4
4
|
import bt from "sortablejs";
|
|
5
5
|
import { Dexie as Bt } from "dexie";
|
|
@@ -189,55 +189,55 @@ var $t = { exports: {} };
|
|
|
189
189
|
(function(t, e) {
|
|
190
190
|
f.exports = e();
|
|
191
191
|
})(Yt, function() {
|
|
192
|
-
var t = 1e3, e = 6e4, a = 36e5, d = "millisecond", U = "second", T = "minute",
|
|
193
|
-
var $ = ["th", "st", "nd", "rd"], g =
|
|
194
|
-
return "[" +
|
|
195
|
-
} },
|
|
196
|
-
var _ = String(
|
|
197
|
-
return !_ || _.length >= $ ?
|
|
198
|
-
},
|
|
199
|
-
var $ = -
|
|
200
|
-
return ($ <= 0 ? "+" : "-") +
|
|
201
|
-
}, m: function
|
|
202
|
-
if ($.date() < g.date()) return -
|
|
203
|
-
var _ = 12 * (g.year() - $.year()) + (g.month() - $.month()), s = $.clone().add(_, z), i = g - s < 0,
|
|
204
|
-
return +(-(_ + (g - s) / (i ? s -
|
|
205
|
-
}, a: function(
|
|
206
|
-
return
|
|
207
|
-
}, p: function(
|
|
208
|
-
return { M: z, y: R, w: D, d: E, D:
|
|
209
|
-
}, u: function(
|
|
210
|
-
return
|
|
211
|
-
} },
|
|
212
|
-
pe[
|
|
213
|
-
var m = "$isDayjsObject",
|
|
214
|
-
return
|
|
215
|
-
}, C = function
|
|
192
|
+
var t = 1e3, e = 6e4, a = 36e5, d = "millisecond", U = "second", T = "minute", F = "hour", E = "day", D = "week", z = "month", te = "quarter", R = "year", V = "date", b = "Invalid Date", w = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, ae = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, K = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(B) {
|
|
193
|
+
var $ = ["th", "st", "nd", "rd"], g = B % 100;
|
|
194
|
+
return "[" + B + ($[(g - 20) % 10] || $[g] || $[0]) + "]";
|
|
195
|
+
} }, ue = function(B, $, g) {
|
|
196
|
+
var _ = String(B);
|
|
197
|
+
return !_ || _.length >= $ ? B : "" + Array($ + 1 - _.length).join(g) + B;
|
|
198
|
+
}, de = { s: ue, z: function(B) {
|
|
199
|
+
var $ = -B.utcOffset(), g = Math.abs($), _ = Math.floor(g / 60), s = g % 60;
|
|
200
|
+
return ($ <= 0 ? "+" : "-") + ue(_, 2, "0") + ":" + ue(s, 2, "0");
|
|
201
|
+
}, m: function B($, g) {
|
|
202
|
+
if ($.date() < g.date()) return -B(g, $);
|
|
203
|
+
var _ = 12 * (g.year() - $.year()) + (g.month() - $.month()), s = $.clone().add(_, z), i = g - s < 0, A = $.clone().add(_ + (i ? -1 : 1), z);
|
|
204
|
+
return +(-(_ + (g - s) / (i ? s - A : A - s)) || 0);
|
|
205
|
+
}, a: function(B) {
|
|
206
|
+
return B < 0 ? Math.ceil(B) || 0 : Math.floor(B);
|
|
207
|
+
}, p: function(B) {
|
|
208
|
+
return { M: z, y: R, w: D, d: E, D: V, h: F, m: T, s: U, ms: d, Q: te }[B] || String(B || "").toLowerCase().replace(/s$/, "");
|
|
209
|
+
}, u: function(B) {
|
|
210
|
+
return B === void 0;
|
|
211
|
+
} }, me = "en", pe = {};
|
|
212
|
+
pe[me] = K;
|
|
213
|
+
var m = "$isDayjsObject", M = function(B) {
|
|
214
|
+
return B instanceof ee || !(!B || !B[m]);
|
|
215
|
+
}, C = function B($, g, _) {
|
|
216
216
|
var s;
|
|
217
|
-
if (!$) return
|
|
217
|
+
if (!$) return me;
|
|
218
218
|
if (typeof $ == "string") {
|
|
219
219
|
var i = $.toLowerCase();
|
|
220
220
|
pe[i] && (s = i), g && (pe[i] = g, s = i);
|
|
221
|
-
var
|
|
222
|
-
if (!s &&
|
|
221
|
+
var A = $.split("-");
|
|
222
|
+
if (!s && A.length > 1) return B(A[0]);
|
|
223
223
|
} else {
|
|
224
224
|
var H = $.name;
|
|
225
225
|
pe[H] = $, s = H;
|
|
226
226
|
}
|
|
227
|
-
return !_ && s && (
|
|
228
|
-
}, h = function(
|
|
229
|
-
if (
|
|
227
|
+
return !_ && s && (me = s), s || !_ && me;
|
|
228
|
+
}, h = function(B, $) {
|
|
229
|
+
if (M(B)) return B.clone();
|
|
230
230
|
var g = typeof $ == "object" ? $ : {};
|
|
231
|
-
return g.date =
|
|
232
|
-
}, I =
|
|
233
|
-
I.l = C, I.i =
|
|
234
|
-
return h(
|
|
231
|
+
return g.date = B, g.args = arguments, new ee(g);
|
|
232
|
+
}, I = de;
|
|
233
|
+
I.l = C, I.i = M, I.w = function(B, $) {
|
|
234
|
+
return h(B, { locale: $.$L, utc: $.$u, x: $.$x, $offset: $.$offset });
|
|
235
235
|
};
|
|
236
236
|
var ee = function() {
|
|
237
|
-
function
|
|
237
|
+
function B(g) {
|
|
238
238
|
this.$L = C(g.locale, null, !0), this.parse(g), this.$x = this.$x || g.x || {}, this[m] = !0;
|
|
239
239
|
}
|
|
240
|
-
var $ =
|
|
240
|
+
var $ = B.prototype;
|
|
241
241
|
return $.parse = function(g) {
|
|
242
242
|
this.$d = function(_) {
|
|
243
243
|
var s = _.date, i = _.utc;
|
|
@@ -245,10 +245,10 @@ var $t = { exports: {} };
|
|
|
245
245
|
if (I.u(s)) return /* @__PURE__ */ new Date();
|
|
246
246
|
if (s instanceof Date) return new Date(s);
|
|
247
247
|
if (typeof s == "string" && !/Z$/i.test(s)) {
|
|
248
|
-
var
|
|
249
|
-
if (
|
|
250
|
-
var H =
|
|
251
|
-
return i ? new Date(Date.UTC(
|
|
248
|
+
var A = s.match(w);
|
|
249
|
+
if (A) {
|
|
250
|
+
var H = A[2] - 1 || 0, X = (A[7] || "0").substring(0, 3);
|
|
251
|
+
return i ? new Date(Date.UTC(A[1], H, A[3] || 1, A[4] || 0, A[5] || 0, A[6] || 0, X)) : new Date(A[1], H, A[3] || 1, A[4] || 0, A[5] || 0, A[6] || 0, X);
|
|
252
252
|
}
|
|
253
253
|
}
|
|
254
254
|
return new Date(s);
|
|
@@ -274,24 +274,24 @@ var $t = { exports: {} };
|
|
|
274
274
|
}, $.valueOf = function() {
|
|
275
275
|
return this.$d.getTime();
|
|
276
276
|
}, $.startOf = function(g, _) {
|
|
277
|
-
var s = this, i = !!I.u(_) || _,
|
|
277
|
+
var s = this, i = !!I.u(_) || _, A = I.p(g), H = function(De, u) {
|
|
278
278
|
var N = I.w(s.$u ? Date.UTC(s.$y, u, De) : new Date(s.$y, u, De), s);
|
|
279
279
|
return i ? N : N.endOf(E);
|
|
280
280
|
}, X = function(De, u) {
|
|
281
281
|
return I.w(s.toDate()[De].apply(s.toDate("s"), (i ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(u)), s);
|
|
282
|
-
},
|
|
283
|
-
switch (
|
|
282
|
+
}, se = this.$W, ce = this.$M, he = this.$D, ve = "set" + (this.$u ? "UTC" : "");
|
|
283
|
+
switch (A) {
|
|
284
284
|
case R:
|
|
285
285
|
return i ? H(1, 0) : H(31, 11);
|
|
286
286
|
case z:
|
|
287
|
-
return i ? H(1,
|
|
287
|
+
return i ? H(1, ce) : H(0, ce + 1);
|
|
288
288
|
case D:
|
|
289
|
-
var Ce = this.$locale().weekStart || 0, Fe = (
|
|
290
|
-
return H(i ? he - Fe : he + (6 - Fe),
|
|
289
|
+
var Ce = this.$locale().weekStart || 0, Fe = (se < Ce ? se + 7 : se) - Ce;
|
|
290
|
+
return H(i ? he - Fe : he + (6 - Fe), ce);
|
|
291
291
|
case E:
|
|
292
|
-
case
|
|
292
|
+
case V:
|
|
293
293
|
return X(ve + "Hours", 0);
|
|
294
|
-
case
|
|
294
|
+
case F:
|
|
295
295
|
return X(ve + "Minutes", 1);
|
|
296
296
|
case T:
|
|
297
297
|
return X(ve + "Seconds", 2);
|
|
@@ -303,10 +303,10 @@ var $t = { exports: {} };
|
|
|
303
303
|
}, $.endOf = function(g) {
|
|
304
304
|
return this.startOf(g, !1);
|
|
305
305
|
}, $.$set = function(g, _) {
|
|
306
|
-
var s, i = I.p(g),
|
|
306
|
+
var s, i = I.p(g), A = "set" + (this.$u ? "UTC" : ""), H = (s = {}, s[E] = A + "Date", s[V] = A + "Date", s[z] = A + "Month", s[R] = A + "FullYear", s[F] = A + "Hours", s[T] = A + "Minutes", s[U] = A + "Seconds", s[d] = A + "Milliseconds", s)[i], X = i === E ? this.$D + (_ - this.$W) : _;
|
|
307
307
|
if (i === z || i === R) {
|
|
308
|
-
var
|
|
309
|
-
|
|
308
|
+
var se = this.clone().set(V, 1);
|
|
309
|
+
se.$d[H](X), se.init(), this.$d = se.set(V, Math.min(this.$D, se.daysInMonth())).$d;
|
|
310
310
|
} else H && this.$d[H](X);
|
|
311
311
|
return this.init(), this;
|
|
312
312
|
}, $.set = function(g, _) {
|
|
@@ -316,44 +316,44 @@ var $t = { exports: {} };
|
|
|
316
316
|
}, $.add = function(g, _) {
|
|
317
317
|
var s, i = this;
|
|
318
318
|
g = Number(g);
|
|
319
|
-
var
|
|
319
|
+
var A = I.p(_), H = function(ce) {
|
|
320
320
|
var he = h(i);
|
|
321
|
-
return I.w(he.date(he.date() + Math.round(
|
|
321
|
+
return I.w(he.date(he.date() + Math.round(ce * g)), i);
|
|
322
322
|
};
|
|
323
|
-
if (
|
|
324
|
-
if (
|
|
325
|
-
if (
|
|
326
|
-
if (
|
|
327
|
-
var X = (s = {}, s[T] = e, s[
|
|
328
|
-
return I.w(
|
|
323
|
+
if (A === z) return this.set(z, this.$M + g);
|
|
324
|
+
if (A === R) return this.set(R, this.$y + g);
|
|
325
|
+
if (A === E) return H(1);
|
|
326
|
+
if (A === D) return H(7);
|
|
327
|
+
var X = (s = {}, s[T] = e, s[F] = a, s[U] = t, s)[A] || 1, se = this.$d.getTime() + g * X;
|
|
328
|
+
return I.w(se, this);
|
|
329
329
|
}, $.subtract = function(g, _) {
|
|
330
330
|
return this.add(-1 * g, _);
|
|
331
331
|
}, $.format = function(g) {
|
|
332
332
|
var _ = this, s = this.$locale();
|
|
333
333
|
if (!this.isValid()) return s.invalidDate || b;
|
|
334
|
-
var i = g || "YYYY-MM-DDTHH:mm:ssZ",
|
|
335
|
-
return u && (u[N] || u(_, i)) ||
|
|
334
|
+
var i = g || "YYYY-MM-DDTHH:mm:ssZ", A = I.z(this), H = this.$H, X = this.$m, se = this.$M, ce = s.weekdays, he = s.months, ve = s.meridiem, Ce = function(u, N, ie, Ve) {
|
|
335
|
+
return u && (u[N] || u(_, i)) || ie[N].slice(0, Ve);
|
|
336
336
|
}, Fe = function(u) {
|
|
337
337
|
return I.s(H % 12 || 12, u, "0");
|
|
338
|
-
}, De = ve || function(u, N,
|
|
339
|
-
var
|
|
340
|
-
return
|
|
338
|
+
}, De = ve || function(u, N, ie) {
|
|
339
|
+
var Ve = u < 12 ? "AM" : "PM";
|
|
340
|
+
return ie ? Ve.toLowerCase() : Ve;
|
|
341
341
|
};
|
|
342
|
-
return i.replace(
|
|
343
|
-
return N || function(
|
|
344
|
-
switch (
|
|
342
|
+
return i.replace(ae, function(u, N) {
|
|
343
|
+
return N || function(ie) {
|
|
344
|
+
switch (ie) {
|
|
345
345
|
case "YY":
|
|
346
346
|
return String(_.$y).slice(-2);
|
|
347
347
|
case "YYYY":
|
|
348
348
|
return I.s(_.$y, 4, "0");
|
|
349
349
|
case "M":
|
|
350
|
-
return
|
|
350
|
+
return se + 1;
|
|
351
351
|
case "MM":
|
|
352
|
-
return I.s(
|
|
352
|
+
return I.s(se + 1, 2, "0");
|
|
353
353
|
case "MMM":
|
|
354
|
-
return Ce(s.monthsShort,
|
|
354
|
+
return Ce(s.monthsShort, se, he, 3);
|
|
355
355
|
case "MMMM":
|
|
356
|
-
return Ce(he,
|
|
356
|
+
return Ce(he, se);
|
|
357
357
|
case "D":
|
|
358
358
|
return _.$D;
|
|
359
359
|
case "DD":
|
|
@@ -361,11 +361,11 @@ var $t = { exports: {} };
|
|
|
361
361
|
case "d":
|
|
362
362
|
return String(_.$W);
|
|
363
363
|
case "dd":
|
|
364
|
-
return Ce(s.weekdaysMin, _.$W,
|
|
364
|
+
return Ce(s.weekdaysMin, _.$W, ce, 2);
|
|
365
365
|
case "ddd":
|
|
366
|
-
return Ce(s.weekdaysShort, _.$W,
|
|
366
|
+
return Ce(s.weekdaysShort, _.$W, ce, 3);
|
|
367
367
|
case "dddd":
|
|
368
|
-
return
|
|
368
|
+
return ce[_.$W];
|
|
369
369
|
case "H":
|
|
370
370
|
return String(H);
|
|
371
371
|
case "HH":
|
|
@@ -389,16 +389,16 @@ var $t = { exports: {} };
|
|
|
389
389
|
case "SSS":
|
|
390
390
|
return I.s(_.$ms, 3, "0");
|
|
391
391
|
case "Z":
|
|
392
|
-
return
|
|
392
|
+
return A;
|
|
393
393
|
}
|
|
394
394
|
return null;
|
|
395
|
-
}(u) ||
|
|
395
|
+
}(u) || A.replace(":", "");
|
|
396
396
|
});
|
|
397
397
|
}, $.utcOffset = function() {
|
|
398
398
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
399
399
|
}, $.diff = function(g, _, s) {
|
|
400
|
-
var i,
|
|
401
|
-
return I.m(
|
|
400
|
+
var i, A = this, H = I.p(_), X = h(g), se = (X.utcOffset() - this.utcOffset()) * e, ce = this - X, he = function() {
|
|
401
|
+
return I.m(A, X);
|
|
402
402
|
};
|
|
403
403
|
switch (H) {
|
|
404
404
|
case R:
|
|
@@ -411,22 +411,22 @@ var $t = { exports: {} };
|
|
|
411
411
|
i = he() / 3;
|
|
412
412
|
break;
|
|
413
413
|
case D:
|
|
414
|
-
i = (
|
|
414
|
+
i = (ce - se) / 6048e5;
|
|
415
415
|
break;
|
|
416
416
|
case E:
|
|
417
|
-
i = (
|
|
417
|
+
i = (ce - se) / 864e5;
|
|
418
418
|
break;
|
|
419
|
-
case
|
|
420
|
-
i =
|
|
419
|
+
case F:
|
|
420
|
+
i = ce / a;
|
|
421
421
|
break;
|
|
422
422
|
case T:
|
|
423
|
-
i =
|
|
423
|
+
i = ce / e;
|
|
424
424
|
break;
|
|
425
425
|
case U:
|
|
426
|
-
i =
|
|
426
|
+
i = ce / t;
|
|
427
427
|
break;
|
|
428
428
|
default:
|
|
429
|
-
i =
|
|
429
|
+
i = ce;
|
|
430
430
|
}
|
|
431
431
|
return s ? i : I.a(i);
|
|
432
432
|
}, $.daysInMonth = function() {
|
|
@@ -447,17 +447,17 @@ var $t = { exports: {} };
|
|
|
447
447
|
return this.$d.toISOString();
|
|
448
448
|
}, $.toString = function() {
|
|
449
449
|
return this.$d.toUTCString();
|
|
450
|
-
},
|
|
451
|
-
}(),
|
|
452
|
-
return h.prototype =
|
|
453
|
-
|
|
454
|
-
return this.$g($,
|
|
450
|
+
}, B;
|
|
451
|
+
}(), ne = ee.prototype;
|
|
452
|
+
return h.prototype = ne, [["$ms", d], ["$s", U], ["$m", T], ["$H", F], ["$W", E], ["$M", z], ["$y", R], ["$D", V]].forEach(function(B) {
|
|
453
|
+
ne[B[1]] = function($) {
|
|
454
|
+
return this.$g($, B[0], B[1]);
|
|
455
455
|
};
|
|
456
|
-
}), h.extend = function(
|
|
457
|
-
return
|
|
458
|
-
}, h.locale = C, h.isDayjs =
|
|
459
|
-
return h(1e3 *
|
|
460
|
-
}, h.en = pe[
|
|
456
|
+
}), h.extend = function(B, $) {
|
|
457
|
+
return B.$i || (B($, ee, h), B.$i = !0), h;
|
|
458
|
+
}, h.locale = C, h.isDayjs = M, h.unix = function(B) {
|
|
459
|
+
return h(1e3 * B);
|
|
460
|
+
}, h.en = pe[me], h.Ls = pe, h.p = {}, h;
|
|
461
461
|
});
|
|
462
462
|
})($t);
|
|
463
463
|
var jt = $t.exports;
|
|
@@ -475,7 +475,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
475
475
|
}),
|
|
476
476
|
emits: ["update:modelValue"],
|
|
477
477
|
setup(f) {
|
|
478
|
-
const c = Ie(f, "modelValue"), t = f, e = t.item || {}, a = t.ctrlKey, d = t.ctrlType, U = t.model, T = ye([]),
|
|
478
|
+
const c = Ie(f, "modelValue"), t = f, e = t.item || {}, a = t.ctrlKey, d = t.ctrlType, U = t.model, T = ye([]), F = ye([]), E = () => Object.keys(ht()).filter((b) => b.startsWith(`${t.t}-${a}-`)).map((b) => b.replace(`${t.t}-${a}-`, "")), D = (b) => [
|
|
479
479
|
"year",
|
|
480
480
|
"years",
|
|
481
481
|
"month",
|
|
@@ -509,53 +509,53 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
509
509
|
}), R = ye((b) => {
|
|
510
510
|
e["remote-method"](b, (w) => {
|
|
511
511
|
yt(() => {
|
|
512
|
-
|
|
512
|
+
F.value = w;
|
|
513
513
|
});
|
|
514
514
|
});
|
|
515
|
-
}),
|
|
515
|
+
}), V = async (b = "options") => {
|
|
516
516
|
try {
|
|
517
517
|
const w = await (e == null ? void 0 : e.getDicts(t.formInfo));
|
|
518
518
|
if (typeof w == "string")
|
|
519
|
-
|
|
519
|
+
F.value = [{ label: w, value: c.value }];
|
|
520
520
|
else {
|
|
521
|
-
const
|
|
521
|
+
const ae = w == null ? void 0 : w.map((K, ue) => ({
|
|
522
522
|
...K,
|
|
523
|
-
value: K.value ?? K.label ??
|
|
523
|
+
value: K.value ?? K.label ?? ue,
|
|
524
524
|
label: K.label || "未知选项"
|
|
525
525
|
}));
|
|
526
|
-
|
|
526
|
+
F.value = ae || [];
|
|
527
527
|
}
|
|
528
528
|
} catch (w) {
|
|
529
529
|
throw console.error("获取选项失败:", w), w;
|
|
530
530
|
}
|
|
531
531
|
};
|
|
532
532
|
return Ne(async () => {
|
|
533
|
-
var
|
|
534
|
-
e && e["remote-method"] && (te.value["remote-method"] = R), (K = (
|
|
535
|
-
const b = (
|
|
536
|
-
typeof e.getDicts == "function" &&
|
|
537
|
-
console.error(`Failed to load ${
|
|
533
|
+
var ae, K;
|
|
534
|
+
e && e["remote-method"] && (te.value["remote-method"] = R), (K = (ae = U[a]) == null ? void 0 : ae.options) != null && K.length && (F.value = U[a].options);
|
|
535
|
+
const b = (ue, de = "options", me = U[a]) => {
|
|
536
|
+
typeof e.getDicts == "function" && V(de).catch((pe) => {
|
|
537
|
+
console.error(`Failed to load ${de} for ${ue}:`, pe);
|
|
538
538
|
});
|
|
539
539
|
};
|
|
540
540
|
["radio", "radio-button", "checkbox-group", "checkbox-group-button", "select", "cascader"].includes(d) && b(d), d === be.TREESELECT && await (async () => {
|
|
541
541
|
try {
|
|
542
|
-
typeof e.getDicts == "function" ? T.value = await e.getDicts(t.formInfo) : T.value =
|
|
543
|
-
} catch (
|
|
544
|
-
console.error("Failed to load data for tree-select:",
|
|
542
|
+
typeof e.getDicts == "function" ? T.value = await e.getDicts(t.formInfo) : T.value = F.value;
|
|
543
|
+
} catch (de) {
|
|
544
|
+
console.error("Failed to load data for tree-select:", de);
|
|
545
545
|
}
|
|
546
546
|
})();
|
|
547
547
|
}), (b, w) => {
|
|
548
548
|
var Ce, Fe, De;
|
|
549
|
-
const
|
|
550
|
-
return n(),
|
|
551
|
-
o(d) == o(be).RADIO ? (n(),
|
|
549
|
+
const ae = L("el-radio"), K = L("el-radio-group"), ue = L("el-radio-button"), de = L("el-checkbox"), me = L("el-checkbox-group"), pe = L("el-checkbox-button"), m = L("g-select-option"), M = L("el-option"), C = L("el-select"), h = L("el-tree-select"), I = L("el-time-picker"), ee = L("el-time-select"), ne = L("el-date-picker"), B = L("el-color-picker"), $ = L("el-rate"), g = L("el-slider"), _ = L("el-switch"), s = L("el-transfer"), i = L("el-cascader"), A = L("el-button"), H = L("el-upload"), X = L("el-autocomplete"), se = L("el-input-number"), ce = L("el-input"), he = L("el-link"), ve = L("el-tag");
|
|
550
|
+
return n(), x("div", Lt, [
|
|
551
|
+
o(d) == o(be).RADIO ? (n(), q(K, S({
|
|
552
552
|
key: 0,
|
|
553
553
|
modelValue: c.value,
|
|
554
554
|
"onUpdate:modelValue": w[0] || (w[0] = (u) => c.value = u)
|
|
555
555
|
}, o(e)), {
|
|
556
556
|
default: y(() => [
|
|
557
557
|
p(b.$slots, `${t.t}-${o(a)}`, { data: o(e) }, () => [
|
|
558
|
-
(n(!0),
|
|
558
|
+
(n(!0), x(P, null, Y(F.value, (u) => (n(), q(ae, S({ ref_for: !0 }, u), {
|
|
559
559
|
default: y(() => [
|
|
560
560
|
p(b.$slots, `${t.t}-${o(a)}-options`, { option: u })
|
|
561
561
|
]),
|
|
@@ -564,14 +564,14 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
564
564
|
])
|
|
565
565
|
]),
|
|
566
566
|
_: 3
|
|
567
|
-
}, 16, ["modelValue"])) : o(d) == o(be).RADIOBUTTON ? (n(),
|
|
567
|
+
}, 16, ["modelValue"])) : o(d) == o(be).RADIOBUTTON ? (n(), q(K, S({
|
|
568
568
|
key: 1,
|
|
569
569
|
modelValue: c.value,
|
|
570
570
|
"onUpdate:modelValue": w[1] || (w[1] = (u) => c.value = u)
|
|
571
571
|
}, o(e)), {
|
|
572
572
|
default: y(() => [
|
|
573
573
|
p(b.$slots, `${t.t}-${o(a)}`, { data: o(e) }, () => [
|
|
574
|
-
(n(!0),
|
|
574
|
+
(n(!0), x(P, null, Y(F.value, (u) => (n(), q(ue, S({ ref_for: !0 }, u), {
|
|
575
575
|
default: y(() => [
|
|
576
576
|
p(b.$slots, `${t.t}-${o(a)}-options`, { option: u })
|
|
577
577
|
]),
|
|
@@ -580,7 +580,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
580
580
|
])
|
|
581
581
|
]),
|
|
582
582
|
_: 3
|
|
583
|
-
}, 16, ["modelValue"])) : o(d) == o(be).CHECKBOX ? (n(),
|
|
583
|
+
}, 16, ["modelValue"])) : o(d) == o(be).CHECKBOX ? (n(), q(de, S({
|
|
584
584
|
key: 2,
|
|
585
585
|
modelValue: c.value,
|
|
586
586
|
"onUpdate:modelValue": w[2] || (w[2] = (u) => c.value = u)
|
|
@@ -591,14 +591,14 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
591
591
|
])
|
|
592
592
|
]),
|
|
593
593
|
_: 3
|
|
594
|
-
}, 16, ["modelValue"])) : o(d) == o(be).CHECKBOXGROUP ? (n(),
|
|
594
|
+
}, 16, ["modelValue"])) : o(d) == o(be).CHECKBOXGROUP ? (n(), q(me, S({
|
|
595
595
|
key: 3,
|
|
596
596
|
modelValue: c.value,
|
|
597
597
|
"onUpdate:modelValue": w[3] || (w[3] = (u) => c.value = u)
|
|
598
598
|
}, o(e)), {
|
|
599
599
|
default: y(() => [
|
|
600
600
|
p(b.$slots, `${t.t}-${o(a)}`, { data: o(e) }, () => [
|
|
601
|
-
(n(!0),
|
|
601
|
+
(n(!0), x(P, null, Y(F.value, (u) => (n(), q(de, S({ ref_for: !0 }, u), {
|
|
602
602
|
default: y(() => [
|
|
603
603
|
p(b.$slots, `${t.t}-${o(a)}-options`, { option: u }, () => [
|
|
604
604
|
we(Ee(u.label), 1)
|
|
@@ -609,14 +609,14 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
609
609
|
])
|
|
610
610
|
]),
|
|
611
611
|
_: 3
|
|
612
|
-
}, 16, ["modelValue"])) : o(d) == o(be).CHECKBOXGROUPBUTTON ? (n(),
|
|
612
|
+
}, 16, ["modelValue"])) : o(d) == o(be).CHECKBOXGROUPBUTTON ? (n(), q(me, S({
|
|
613
613
|
key: 4,
|
|
614
614
|
modelValue: c.value,
|
|
615
615
|
"onUpdate:modelValue": w[4] || (w[4] = (u) => c.value = u)
|
|
616
616
|
}, o(e)), {
|
|
617
617
|
default: y(() => [
|
|
618
618
|
p(b.$slots, `${t.t}-${o(a)}`, { data: o(e) }, () => [
|
|
619
|
-
(n(!0),
|
|
619
|
+
(n(!0), x(P, null, Y(F.value, (u) => (n(), q(pe, S({ ref_for: !0 }, u), {
|
|
620
620
|
default: y(() => [
|
|
621
621
|
p(b.$slots, `${t.t}-${o(a)}-options`, { option: u })
|
|
622
622
|
]),
|
|
@@ -625,18 +625,18 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
625
625
|
])
|
|
626
626
|
]),
|
|
627
627
|
_: 3
|
|
628
|
-
}, 16, ["modelValue"])) : o(d) === o(be).SELECT ? (n(),
|
|
628
|
+
}, 16, ["modelValue"])) : o(d) === o(be).SELECT ? (n(), q(C, S({
|
|
629
629
|
key: 5,
|
|
630
630
|
modelValue: c.value,
|
|
631
631
|
"onUpdate:modelValue": w[5] || (w[5] = (u) => c.value = u),
|
|
632
632
|
placeholder: o(U)[o(a)].label
|
|
633
|
-
}, te.value),
|
|
633
|
+
}, te.value), fe({
|
|
634
634
|
default: y(() => [
|
|
635
|
-
p(b.$slots, `${t.t}-${o(a)}`, { options:
|
|
636
|
-
(n(!0),
|
|
635
|
+
p(b.$slots, `${t.t}-${o(a)}`, { options: F.value }, () => [
|
|
636
|
+
(n(!0), x(P, null, Y(F.value, (u) => (n(), x(P, {
|
|
637
637
|
key: u.value
|
|
638
638
|
}, [
|
|
639
|
-
Z(
|
|
639
|
+
Z(M, S({ ref_for: !0 }, o(ke)(u, (N) => N != "children"), {
|
|
640
640
|
onClick: (N) => te.value.change && te.value.change(u)
|
|
641
641
|
}), {
|
|
642
642
|
default: y(() => {
|
|
@@ -646,14 +646,14 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
646
646
|
key: 0,
|
|
647
647
|
option: u
|
|
648
648
|
}, () => {
|
|
649
|
-
var
|
|
649
|
+
var ie;
|
|
650
650
|
return [
|
|
651
651
|
Z(m, {
|
|
652
|
-
columns: (
|
|
652
|
+
columns: (ie = o(e)) == null ? void 0 : ie.columns,
|
|
653
653
|
data: u,
|
|
654
654
|
t: t.t
|
|
655
|
-
},
|
|
656
|
-
Y(b.$slots, (
|
|
655
|
+
}, fe({ _: 2 }, [
|
|
656
|
+
Y(b.$slots, (Ve, l) => ({
|
|
657
657
|
name: l,
|
|
658
658
|
fn: y((r) => [
|
|
659
659
|
p(b.$slots, l, {
|
|
@@ -669,27 +669,27 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
669
669
|
}),
|
|
670
670
|
_: 2
|
|
671
671
|
}, 1040, ["onClick"]),
|
|
672
|
-
u.children && u.children.length ? (n(!0),
|
|
672
|
+
u.children && u.children.length ? (n(!0), x(P, { key: 0 }, Y(u.children, (N) => (n(), q(M, S({
|
|
673
673
|
style: { "margin-left": "20px" },
|
|
674
674
|
key: N.value,
|
|
675
675
|
ref_for: !0
|
|
676
|
-
}, o(ke)(N, (
|
|
677
|
-
onClick: (
|
|
676
|
+
}, o(ke)(N, (ie) => ie != "children"), {
|
|
677
|
+
onClick: (ie) => te.value.change && te.value.change(N)
|
|
678
678
|
}), {
|
|
679
679
|
default: y(() => {
|
|
680
|
-
var
|
|
680
|
+
var ie;
|
|
681
681
|
return [
|
|
682
|
-
(
|
|
682
|
+
(ie = o(e)) != null && ie.columns ? p(b.$slots, `${t.t}-${o(a)}-options`, {
|
|
683
683
|
key: 0,
|
|
684
684
|
option: N
|
|
685
685
|
}, () => {
|
|
686
|
-
var
|
|
686
|
+
var Ve;
|
|
687
687
|
return [
|
|
688
688
|
Z(m, {
|
|
689
|
-
columns: (
|
|
689
|
+
columns: (Ve = o(e)) == null ? void 0 : Ve.columns,
|
|
690
690
|
data: N,
|
|
691
691
|
t: t.t
|
|
692
|
-
},
|
|
692
|
+
}, fe({ _: 2 }, [
|
|
693
693
|
Y(b.$slots, (l, r) => ({
|
|
694
694
|
name: r,
|
|
695
695
|
fn: y((v) => [
|
|
@@ -720,11 +720,11 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
720
720
|
columns: (u = o(e)) == null ? void 0 : u.columns,
|
|
721
721
|
title: !0,
|
|
722
722
|
t: t.t
|
|
723
|
-
},
|
|
724
|
-
Y(b.$slots, (N,
|
|
725
|
-
name:
|
|
726
|
-
fn: y((
|
|
727
|
-
p(b.$slots,
|
|
723
|
+
}, fe({ _: 2 }, [
|
|
724
|
+
Y(b.$slots, (N, ie) => ({
|
|
725
|
+
name: ie,
|
|
726
|
+
fn: y((Ve) => [
|
|
727
|
+
p(b.$slots, ie, { data: Ve })
|
|
728
728
|
])
|
|
729
729
|
}))
|
|
730
730
|
]), 1032, ["columns", "t"])
|
|
@@ -738,26 +738,26 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
738
738
|
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: N })
|
|
739
739
|
])
|
|
740
740
|
}))
|
|
741
|
-
]), 1040, ["modelValue", "placeholder"])) : o(d) == o(be).TREESELECT ? (n(),
|
|
741
|
+
]), 1040, ["modelValue", "placeholder"])) : o(d) == o(be).TREESELECT ? (n(), q(h, S({
|
|
742
742
|
key: 6,
|
|
743
743
|
modelValue: c.value,
|
|
744
744
|
"onUpdate:modelValue": w[6] || (w[6] = (u) => c.value = u),
|
|
745
745
|
placeholder: o(U)[o(a)].label
|
|
746
|
-
}, o(e), { data: T.value }),
|
|
746
|
+
}, o(e), { data: T.value }), fe({ _: 2 }, [
|
|
747
747
|
Y(E(), (u) => ({
|
|
748
748
|
name: u,
|
|
749
749
|
fn: y((N) => [
|
|
750
750
|
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: N })
|
|
751
751
|
])
|
|
752
752
|
}))
|
|
753
|
-
]), 1040, ["modelValue", "placeholder", "data"])) : o(d) == o(be).TIME ? (n(),
|
|
753
|
+
]), 1040, ["modelValue", "placeholder", "data"])) : o(d) == o(be).TIME ? (n(), q(I, S({
|
|
754
754
|
key: 7,
|
|
755
755
|
modelValue: c.value,
|
|
756
756
|
"onUpdate:modelValue": w[7] || (w[7] = (u) => c.value = u),
|
|
757
757
|
"arrow-control": ""
|
|
758
758
|
}, o(e), {
|
|
759
759
|
placeholder: o(U)[o(a)].label
|
|
760
|
-
}), null, 16, ["modelValue", "placeholder"])) : o(d) == o(be).TIMESELECT ? (n(),
|
|
760
|
+
}), null, 16, ["modelValue", "placeholder"])) : o(d) == o(be).TIMESELECT ? (n(), q(ee, S({
|
|
761
761
|
key: 8,
|
|
762
762
|
modelValue: c.value,
|
|
763
763
|
"onUpdate:modelValue": w[8] || (w[8] = (u) => c.value = u),
|
|
@@ -765,68 +765,68 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
765
765
|
step: "00:15",
|
|
766
766
|
end: "23:30",
|
|
767
767
|
placeholder: o(U)[o(a)].label
|
|
768
|
-
}, o(e)), null, 16, ["modelValue", "placeholder"])) : D(o(d)) ? (n(),
|
|
768
|
+
}, o(e)), null, 16, ["modelValue", "placeholder"])) : D(o(d)) ? (n(), q(ne, S({
|
|
769
769
|
key: 9,
|
|
770
770
|
modelValue: c.value,
|
|
771
771
|
"onUpdate:modelValue": w[9] || (w[9] = (u) => c.value = u),
|
|
772
|
-
type:
|
|
772
|
+
type: o(d),
|
|
773
773
|
placeholder: o(U)[o(a)].label,
|
|
774
774
|
"value-format": z(o(d))
|
|
775
|
-
}, o(e)),
|
|
775
|
+
}, o(e)), fe({ _: 2 }, [
|
|
776
776
|
Y(E(), (u) => ({
|
|
777
777
|
name: u,
|
|
778
778
|
fn: y((N) => [
|
|
779
779
|
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: N })
|
|
780
780
|
])
|
|
781
781
|
}))
|
|
782
|
-
]), 1040, ["modelValue", "placeholder", "value-format"])) : o(d) == o(be).COLOR ? (n(),
|
|
782
|
+
]), 1040, ["modelValue", "type", "placeholder", "value-format"])) : o(d) == o(be).COLOR ? (n(), q(B, S({
|
|
783
783
|
key: 10,
|
|
784
784
|
modelValue: c.value,
|
|
785
785
|
"onUpdate:modelValue": w[10] || (w[10] = (u) => c.value = u)
|
|
786
|
-
}, o(e)), null, 16, ["modelValue"])) : o(d) == o(be).RATE ? (n(),
|
|
786
|
+
}, o(e)), null, 16, ["modelValue"])) : o(d) == o(be).RATE ? (n(), q($, S({
|
|
787
787
|
key: 11,
|
|
788
788
|
modelValue: c.value,
|
|
789
789
|
"onUpdate:modelValue": w[11] || (w[11] = (u) => c.value = u)
|
|
790
|
-
}, o(e)), null, 16, ["modelValue"])) : o(d) == o(be).SLIDER ? (n(),
|
|
790
|
+
}, o(e)), null, 16, ["modelValue"])) : o(d) == o(be).SLIDER ? (n(), q(g, S({
|
|
791
791
|
key: 12,
|
|
792
792
|
modelValue: c.value,
|
|
793
793
|
"onUpdate:modelValue": w[12] || (w[12] = (u) => c.value = u)
|
|
794
|
-
}, o(e)), null, 16, ["modelValue"])) : o(d) == o(be).SWITCH ? (n(),
|
|
794
|
+
}, o(e)), null, 16, ["modelValue"])) : o(d) == o(be).SWITCH ? (n(), q(_, S({
|
|
795
795
|
key: 13,
|
|
796
796
|
modelValue: c.value,
|
|
797
797
|
"onUpdate:modelValue": w[13] || (w[13] = (u) => c.value = u)
|
|
798
|
-
}, o(e)),
|
|
798
|
+
}, o(e)), fe({ _: 2 }, [
|
|
799
799
|
Y(E(), (u) => ({
|
|
800
800
|
name: u,
|
|
801
801
|
fn: y((N) => [
|
|
802
802
|
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: N })
|
|
803
803
|
])
|
|
804
804
|
}))
|
|
805
|
-
]), 1040, ["modelValue"])) : o(d) == o(be).TRANSFER ? (n(),
|
|
805
|
+
]), 1040, ["modelValue"])) : o(d) == o(be).TRANSFER ? (n(), q(s, S({
|
|
806
806
|
key: 14,
|
|
807
807
|
modelValue: c.value,
|
|
808
808
|
"onUpdate:modelValue": w[14] || (w[14] = (u) => c.value = u)
|
|
809
|
-
}, o(e)),
|
|
809
|
+
}, o(e)), fe({ _: 2 }, [
|
|
810
810
|
Y(E(), (u) => ({
|
|
811
811
|
name: u,
|
|
812
812
|
fn: y((N) => [
|
|
813
813
|
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: N })
|
|
814
814
|
])
|
|
815
815
|
}))
|
|
816
|
-
]), 1040, ["modelValue"])) : o(d) == o(be).CASCADER ? (n(),
|
|
816
|
+
]), 1040, ["modelValue"])) : o(d) == o(be).CASCADER ? (n(), q(i, S({
|
|
817
817
|
key: 15,
|
|
818
818
|
modelValue: c.value,
|
|
819
819
|
"onUpdate:modelValue": w[15] || (w[15] = (u) => c.value = u)
|
|
820
|
-
}, o(e), { options:
|
|
820
|
+
}, o(e), { options: F.value }), fe({ _: 2 }, [
|
|
821
821
|
Y(E(), (u) => ({
|
|
822
822
|
name: u,
|
|
823
823
|
fn: y((N) => [
|
|
824
824
|
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: N })
|
|
825
825
|
])
|
|
826
826
|
}))
|
|
827
|
-
]), 1040, ["modelValue", "options"])) : o(d) == o(be).IMAGE ? (n(),
|
|
827
|
+
]), 1040, ["modelValue", "options"])) : o(d) == o(be).IMAGE ? (n(), q(H, Qe(S({ key: 16 }, o(e))), fe({
|
|
828
828
|
default: y(() => [
|
|
829
|
-
Z(
|
|
829
|
+
Z(A, { type: "primary" }, {
|
|
830
830
|
default: y(() => w[21] || (w[21] = [
|
|
831
831
|
we("点击上传")
|
|
832
832
|
])),
|
|
@@ -837,45 +837,45 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
837
837
|
}, [
|
|
838
838
|
Y(E(), (u, N) => ({
|
|
839
839
|
name: u,
|
|
840
|
-
fn: y((
|
|
841
|
-
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data:
|
|
840
|
+
fn: y((ie) => [
|
|
841
|
+
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: ie })
|
|
842
842
|
])
|
|
843
843
|
}))
|
|
844
|
-
]), 1040)) : o(d) == o(be).AUTOCOMPLETE ? (n(),
|
|
844
|
+
]), 1040)) : o(d) == o(be).AUTOCOMPLETE ? (n(), q(X, S({
|
|
845
845
|
key: 17,
|
|
846
846
|
modelValue: c.value,
|
|
847
847
|
"onUpdate:modelValue": w[16] || (w[16] = (u) => c.value = u)
|
|
848
848
|
}, o(e), {
|
|
849
849
|
placeholder: o(U)[o(a)].label
|
|
850
|
-
}),
|
|
850
|
+
}), fe({ _: 2 }, [
|
|
851
851
|
Y(E(), (u, N) => ({
|
|
852
852
|
name: u,
|
|
853
|
-
fn: y((
|
|
854
|
-
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data:
|
|
853
|
+
fn: y((ie) => [
|
|
854
|
+
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: ie })
|
|
855
855
|
])
|
|
856
856
|
}))
|
|
857
|
-
]), 1040, ["modelValue", "placeholder"])) : o(d) == o(be).INPUTNUMBER ? (n(),
|
|
857
|
+
]), 1040, ["modelValue", "placeholder"])) : o(d) == o(be).INPUTNUMBER ? (n(), q(se, S({
|
|
858
858
|
key: 18,
|
|
859
859
|
modelValue: c.value,
|
|
860
860
|
"onUpdate:modelValue": w[17] || (w[17] = (u) => c.value = u),
|
|
861
861
|
min: 0,
|
|
862
862
|
max: 1e8,
|
|
863
863
|
placeholder: o(U)[o(a)].label
|
|
864
|
-
}, o(e)),
|
|
864
|
+
}, o(e)), fe({ _: 2 }, [
|
|
865
865
|
Y(E(), (u, N) => ({
|
|
866
866
|
name: u,
|
|
867
|
-
fn: y((
|
|
868
|
-
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data:
|
|
867
|
+
fn: y((ie) => [
|
|
868
|
+
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: ie })
|
|
869
869
|
])
|
|
870
870
|
}))
|
|
871
|
-
]), 1040, ["modelValue", "placeholder"])) : o(d) == o(be).MONEY ? (n(),
|
|
872
|
-
Z(
|
|
871
|
+
]), 1040, ["modelValue", "placeholder"])) : o(d) == o(be).MONEY ? (n(), x("div", Rt, [
|
|
872
|
+
Z(ce, S({
|
|
873
873
|
modelValue: c.value,
|
|
874
874
|
"onUpdate:modelValue": w[18] || (w[18] = (u) => c.value = u),
|
|
875
875
|
placeholder: o(U)[o(a)].label,
|
|
876
876
|
type: o(be).NUMBER,
|
|
877
877
|
maxlength: ((Fe = o(e)) == null ? void 0 : Fe.max) || 25
|
|
878
|
-
}, { ...o(e), type: o(d) }),
|
|
878
|
+
}, { ...o(e), type: o(d) }), fe({
|
|
879
879
|
suffix: y(() => [
|
|
880
880
|
J("div", {
|
|
881
881
|
title: o(rt)(c.value),
|
|
@@ -886,49 +886,49 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
886
886
|
}, [
|
|
887
887
|
Y(E(), (u, N) => ({
|
|
888
888
|
name: u,
|
|
889
|
-
fn: y((
|
|
890
|
-
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data:
|
|
889
|
+
fn: y((ie) => [
|
|
890
|
+
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: ie })
|
|
891
891
|
])
|
|
892
892
|
}))
|
|
893
893
|
]), 1040, ["modelValue", "placeholder", "type", "maxlength"])
|
|
894
|
-
])) : (o(d) === "primary" || o(d) === "success" || o(d) === "warning" || o(d) == "danger" || o(d) === "info" || o(d) == "default") && o(e).isLink === !0 ? (n(),
|
|
895
|
-
Z(he,
|
|
894
|
+
])) : (o(d) === "primary" || o(d) === "success" || o(d) === "warning" || o(d) == "danger" || o(d) === "info" || o(d) == "default") && o(e).isLink === !0 ? (n(), x("div", Nt, [
|
|
895
|
+
Z(he, S(o(e), {
|
|
896
896
|
innerHTML: o(e).innerHtml || c.value
|
|
897
897
|
}), null, 16, ["innerHTML"])
|
|
898
|
-
])) : (o(d) === "primary" || o(d) === "success" || o(d) === "warning" || o(d) == "danger" || o(d) === "info") && o(e).isTag === !0 ? (n(),
|
|
899
|
-
Array.isArray(o(e).innerHtml) && o(e).innerHtml.length > 1 ? (n(!0),
|
|
900
|
-
typeof u == "object" ? (n(),
|
|
898
|
+
])) : (o(d) === "primary" || o(d) === "success" || o(d) === "warning" || o(d) == "danger" || o(d) === "info") && o(e).isTag === !0 ? (n(), x("div", Pt, [
|
|
899
|
+
Array.isArray(o(e).innerHtml) && o(e).innerHtml.length > 1 ? (n(!0), x(P, { key: 0 }, Y(o(e).innerHtml, (u, N) => (n(), x(P, { key: N }, [
|
|
900
|
+
typeof u == "object" ? (n(), q(ve, S({
|
|
901
901
|
key: 0,
|
|
902
902
|
ref_for: !0
|
|
903
903
|
}, u, {
|
|
904
904
|
innerHTML: u == null ? void 0 : u.value,
|
|
905
905
|
style: { "margin-right": "3px" }
|
|
906
|
-
}), null, 16, ["innerHTML"])) : (n(),
|
|
906
|
+
}), null, 16, ["innerHTML"])) : (n(), q(ve, S({
|
|
907
907
|
key: 1,
|
|
908
908
|
ref_for: !0
|
|
909
909
|
}, o(e), {
|
|
910
910
|
innerHTML: u,
|
|
911
911
|
style: { "margin-right": "3px" }
|
|
912
912
|
}), null, 16, ["innerHTML"]))
|
|
913
|
-
], 64))), 128)) : (n(),
|
|
913
|
+
], 64))), 128)) : (n(), q(ve, S({ key: 1 }, o(e), {
|
|
914
914
|
innerHTML: o(e).innerHtml || c.value
|
|
915
915
|
}), null, 16, ["innerHTML"]))
|
|
916
|
-
])) : o(d) == "div" ? (n(),
|
|
916
|
+
])) : o(d) == "div" ? (n(), x("div", S({ key: 22 }, o(e), {
|
|
917
917
|
innerHTML: o(e).innerHtml || c.value
|
|
918
|
-
}), null, 16, zt)) : o(d) == "span" ? (n(),
|
|
918
|
+
}), null, 16, zt)) : o(d) == "span" ? (n(), x("span", S({ key: 23 }, o(e), {
|
|
919
919
|
innerHTML: o(e).innerHtml || c.value
|
|
920
|
-
}), null, 16, Wt)) : (n(),
|
|
920
|
+
}), null, 16, Wt)) : (n(), q(ce, S({
|
|
921
921
|
key: 24,
|
|
922
922
|
modelValue: c.value,
|
|
923
923
|
"onUpdate:modelValue": w[19] || (w[19] = (u) => c.value = u),
|
|
924
924
|
placeholder: o(U)[o(a)].label,
|
|
925
925
|
maxlength: ((De = o(e)) == null ? void 0 : De.max) || 25,
|
|
926
926
|
clearable: !0
|
|
927
|
-
}, { ...o(e), type: o(d) }),
|
|
927
|
+
}, { ...o(e), type: o(d) }), fe({ _: 2 }, [
|
|
928
928
|
Y(E(), (u, N) => ({
|
|
929
929
|
name: u,
|
|
930
|
-
fn: y((
|
|
931
|
-
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data:
|
|
930
|
+
fn: y((ie) => [
|
|
931
|
+
p(b.$slots, `${t.t}-${o(a)}-${u}`, { data: ie })
|
|
932
932
|
])
|
|
933
933
|
}))
|
|
934
934
|
]), 1040, ["modelValue", "placeholder", "maxlength"]))
|
|
@@ -946,7 +946,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
946
946
|
},
|
|
947
947
|
emits: /* @__PURE__ */ Be(["submit", "reset"], ["update:modelValue"]),
|
|
948
948
|
setup(f, { emit: c }) {
|
|
949
|
-
var
|
|
949
|
+
var ue, de, me, pe;
|
|
950
950
|
const t = Ie(f, "modelValue"), e = c, a = ye(null), d = at("options"), U = {
|
|
951
951
|
inline: !0,
|
|
952
952
|
type: "hidden",
|
|
@@ -957,7 +957,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
957
957
|
style: {
|
|
958
958
|
display: "flex",
|
|
959
959
|
flexWrap: "wrap",
|
|
960
|
-
...(
|
|
960
|
+
...(ue = nt()) == null ? void 0 : ue.style
|
|
961
961
|
},
|
|
962
962
|
// 表单底部属性
|
|
963
963
|
footer: {
|
|
@@ -987,8 +987,8 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
987
987
|
click: () => {
|
|
988
988
|
if (!a.value) return;
|
|
989
989
|
let m = !0;
|
|
990
|
-
e("reset", (
|
|
991
|
-
m =
|
|
990
|
+
e("reset", (M) => {
|
|
991
|
+
m = M;
|
|
992
992
|
}), m && a.value.resetFields();
|
|
993
993
|
}
|
|
994
994
|
},
|
|
@@ -998,17 +998,17 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
998
998
|
editable: !1
|
|
999
999
|
}
|
|
1000
1000
|
};
|
|
1001
|
-
t.value.form =
|
|
1001
|
+
t.value.form = Me(
|
|
1002
1002
|
U,
|
|
1003
1003
|
d == null ? void 0 : d.form,
|
|
1004
|
-
(
|
|
1004
|
+
(de = t.value) == null ? void 0 : de.form
|
|
1005
1005
|
);
|
|
1006
|
-
const T = async (m,
|
|
1006
|
+
const T = async (m, M) => {
|
|
1007
1007
|
let C = 5;
|
|
1008
1008
|
for (; C > 0; ) {
|
|
1009
1009
|
if (await yt(), a.value) {
|
|
1010
1010
|
a.value.validate((h, I) => {
|
|
1011
|
-
h ? e("submit", m,
|
|
1011
|
+
h ? e("submit", m, M) : console.log("表单验证不通过!", I);
|
|
1012
1012
|
});
|
|
1013
1013
|
return;
|
|
1014
1014
|
}
|
|
@@ -1017,31 +1017,31 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1017
1017
|
console.error("表单实例获取失败,请检查组件状态");
|
|
1018
1018
|
};
|
|
1019
1019
|
t.value.form.submit.click = T;
|
|
1020
|
-
const
|
|
1020
|
+
const F = {
|
|
1021
1021
|
type: "hidden",
|
|
1022
1022
|
labelPosition: "right",
|
|
1023
1023
|
style: {
|
|
1024
1024
|
width: "100%"
|
|
1025
1025
|
}
|
|
1026
1026
|
};
|
|
1027
|
-
t.value.formItems =
|
|
1028
|
-
|
|
1027
|
+
t.value.formItems = Me(
|
|
1028
|
+
F,
|
|
1029
1029
|
d == null ? void 0 : d.formItems,
|
|
1030
|
-
(
|
|
1030
|
+
(me = t == null ? void 0 : t.value) == null ? void 0 : me.formItems
|
|
1031
1031
|
);
|
|
1032
1032
|
const E = {
|
|
1033
1033
|
span: 12,
|
|
1034
1034
|
offset: 0
|
|
1035
1035
|
};
|
|
1036
|
-
t.value.form.cols =
|
|
1036
|
+
t.value.form.cols = Me(
|
|
1037
1037
|
E,
|
|
1038
1038
|
(pe = d == null ? void 0 : d.form) == null ? void 0 : pe.cols,
|
|
1039
1039
|
t.value.form.cols
|
|
1040
1040
|
);
|
|
1041
1041
|
const D = (m) => {
|
|
1042
|
-
let
|
|
1042
|
+
let M = [];
|
|
1043
1043
|
if (m.rules)
|
|
1044
|
-
|
|
1044
|
+
M = m.rules;
|
|
1045
1045
|
else {
|
|
1046
1046
|
const h = { ...{
|
|
1047
1047
|
required: void 0,
|
|
@@ -1052,39 +1052,39 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1052
1052
|
pattern: void 0,
|
|
1053
1053
|
validate: void 0
|
|
1054
1054
|
}, ...m };
|
|
1055
|
-
h.required &&
|
|
1056
|
-
validator: (I, ee,
|
|
1057
|
-
ee && m.type == "number" && (ee < h.min || ee > h.max) ?
|
|
1055
|
+
h.required && M.push({ required: !0, message: `${h.label}不能为空!`, trigger: "blur" }), h.max && h.min && M.push({
|
|
1056
|
+
validator: (I, ee, ne) => {
|
|
1057
|
+
ee && m.type == "number" && (ee < h.min || ee > h.max) ? ne(new Error(`${h.label} 必须在 ${h.min} 和 ${h.max} 之间!`)) : ee && m.type !== "number" && (ee.toString().length < h.min || ee.toString().length > h.max) ? ne(new Error(`字符长度必须在 ${h.min} 和 ${h.max} 之间!`)) : ne();
|
|
1058
1058
|
}
|
|
1059
|
-
}), h.max && !h.min && m.type == "number" &&
|
|
1060
|
-
validator: (I, ee,
|
|
1061
|
-
ee && ee > h.max ?
|
|
1059
|
+
}), h.max && !h.min && m.type == "number" && M.push({
|
|
1060
|
+
validator: (I, ee, ne) => {
|
|
1061
|
+
ee && ee > h.max ? ne(new Error(`${h.label}不能大于${h.max}!`)) : ne();
|
|
1062
1062
|
}
|
|
1063
|
-
}), h.min && !h.max && m.type == "number" &&
|
|
1064
|
-
validator: (I, ee,
|
|
1065
|
-
ee && ee < h.min ?
|
|
1063
|
+
}), h.min && !h.max && m.type == "number" && M.push({
|
|
1064
|
+
validator: (I, ee, ne) => {
|
|
1065
|
+
ee && ee < h.min ? ne(new Error(`${h.label}不能小于${h.min}!`)) : ne();
|
|
1066
1066
|
}
|
|
1067
|
-
}), h.type == "email" &&
|
|
1068
|
-
validator: (I, ee,
|
|
1067
|
+
}), h.type == "email" && M.push({ type: "email", message: "不是一个正确的邮箱地址!" }), h.type == "url" && M.push({ type: "url", message: "不是一个合正确的URL!" }), h.pattern && M.push({ pattern: h == null ? void 0 : h.pattern, message: (h == null ? void 0 : h.message) || "格式不正确!" }), h.validate && M.push({
|
|
1068
|
+
validator: (I, ee, ne) => h.validate(I, ee, ne)
|
|
1069
1069
|
});
|
|
1070
1070
|
}
|
|
1071
|
-
return
|
|
1072
|
-
}, z = (m,
|
|
1073
|
-
var I, ee,
|
|
1074
|
-
const C =
|
|
1071
|
+
return M;
|
|
1072
|
+
}, z = (m, M = !1) => {
|
|
1073
|
+
var I, ee, ne, B, $;
|
|
1074
|
+
const C = M ? m : m == null ? void 0 : m.item, h = typeof (C == null ? void 0 : C.editor) == "function" ? C.editor(b.value, (I = t.value.form) == null ? void 0 : I.modalState) : (C == null ? void 0 : C.editor) || {};
|
|
1075
1075
|
if (((ee = t.value.form) == null ? void 0 : ee.modalState) === "edit") {
|
|
1076
|
-
const g = typeof (C == null ? void 0 : C.editor) == "object" ? (
|
|
1076
|
+
const g = typeof (C == null ? void 0 : C.editor) == "object" ? (ne = C.editor) == null ? void 0 : ne.ep : typeof (C == null ? void 0 : C.editor) == "function" ? h == null ? void 0 : h.ep : {};
|
|
1077
1077
|
return { ...h, ...g };
|
|
1078
1078
|
}
|
|
1079
|
-
if (((
|
|
1079
|
+
if (((B = t.value.form) == null ? void 0 : B.modalState) === "add") {
|
|
1080
1080
|
const g = typeof (C == null ? void 0 : C.editor) == "object" ? ($ = C.editor) == null ? void 0 : $.ap : typeof (C == null ? void 0 : C.editor) == "function" ? h == null ? void 0 : h.ap : {};
|
|
1081
1081
|
return { ...h, ...g };
|
|
1082
1082
|
}
|
|
1083
1083
|
return h;
|
|
1084
1084
|
}, te = (m) => {
|
|
1085
|
-
var C, h, I, ee,
|
|
1086
|
-
const
|
|
1087
|
-
return ((h = t.value.form) == null ? void 0 : h.modalState) === "edit" ? ((I =
|
|
1085
|
+
var C, h, I, ee, ne;
|
|
1086
|
+
const M = typeof m.editor == "function" ? m.editor(b.value, (C = t.value.form) == null ? void 0 : C.modalState) : m.editor;
|
|
1087
|
+
return ((h = t.value.form) == null ? void 0 : h.modalState) === "edit" ? ((I = M == null ? void 0 : M.ep) == null ? void 0 : I.type) ?? (M == null ? void 0 : M.type) ?? m.type : ((ee = t.value.form) == null ? void 0 : ee.modalState) === "add" ? ((ne = M == null ? void 0 : M.ap) == null ? void 0 : ne.type) ?? (M == null ? void 0 : M.type) ?? m.type : (M == null ? void 0 : M.type) ?? m.type;
|
|
1088
1088
|
};
|
|
1089
1089
|
Ne(() => {
|
|
1090
1090
|
R();
|
|
@@ -1092,26 +1092,26 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1092
1092
|
a.value = null;
|
|
1093
1093
|
});
|
|
1094
1094
|
const R = () => {
|
|
1095
|
-
for (const [m,
|
|
1096
|
-
t.value[m].formItem = { ...t.value[m].formItem, ...
|
|
1097
|
-
},
|
|
1095
|
+
for (const [m, M] of Object.entries(V.value))
|
|
1096
|
+
t.value[m].formItem = { ...t.value[m].formItem, ...M.formItem }, t.value[m].formItem.style = { ...t.value[m].formItem.style, ...M.formItem.style };
|
|
1097
|
+
}, V = Ye(() => Object.fromEntries(Object.entries(t.value).filter((m) => m[1].type != "hidden").filter((m) => !["table", "tableColumns", "query", "queryItems"].includes(m[0])).filter((m) => m[1].editor !== !1).filter((m) => m[1].type !== "control").filter((m) => {
|
|
1098
1098
|
var C, h, I;
|
|
1099
|
-
const
|
|
1100
|
-
return t.value.form.modalState === "edit" ? ((h =
|
|
1099
|
+
const M = typeof m[1].editor == "function" ? m[1].editor(b.value, (C = t.value.form) == null ? void 0 : C.modalState) : m[1].editor;
|
|
1100
|
+
return t.value.form.modalState === "edit" ? ((h = M == null ? void 0 : M.ep) == null ? void 0 : h.editor) !== !1 : t.value.form.modalState === "add" ? ((I = M == null ? void 0 : M.ap) == null ? void 0 : I.editor) !== !1 : !0;
|
|
1101
1101
|
}).map((m) => [m[0], m[1]]))), b = Ye(() => Object.fromEntries(Object.entries(t.value).filter((m) => m[1].type != "hidden").filter((m) => m[1].type != "control").map((m) => [m[0], m[1].value]))), w = Ye(() => {
|
|
1102
1102
|
const m = /* @__PURE__ */ new Map();
|
|
1103
|
-
return Object.entries(
|
|
1103
|
+
return Object.entries(V.value).forEach(([M, C]) => {
|
|
1104
1104
|
if (C.groupName) {
|
|
1105
1105
|
const h = C.groupName;
|
|
1106
1106
|
m.has(h) || m.set(h, {
|
|
1107
1107
|
groupName: h,
|
|
1108
1108
|
items: []
|
|
1109
|
-
}), m.get(h).items.push({ key:
|
|
1109
|
+
}), m.get(h).items.push({ key: M, item: C });
|
|
1110
1110
|
}
|
|
1111
|
-
}), m.forEach((
|
|
1112
|
-
|
|
1111
|
+
}), m.forEach((M) => {
|
|
1112
|
+
M.tabPane = Me(...M.items.map(({ item: C }) => C.tabPane || {}));
|
|
1113
1113
|
}), Array.from(m.values());
|
|
1114
|
-
}),
|
|
1114
|
+
}), ae = [
|
|
1115
1115
|
{
|
|
1116
1116
|
name: "f-submit",
|
|
1117
1117
|
label: t.value.form.submit.label,
|
|
@@ -1134,10 +1134,10 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1134
1134
|
originalOrder: 1
|
|
1135
1135
|
// 添加原始顺序标识
|
|
1136
1136
|
}
|
|
1137
|
-
], K = Ye(() =>
|
|
1138
|
-
return (m,
|
|
1139
|
-
const C = L("el-form-item"), h = L("el-col"), I = L("el-tab-pane"), ee = L("el-tabs"),
|
|
1140
|
-
return n(),
|
|
1137
|
+
], K = Ye(() => ae.filter((m) => !m.hidden).sort((m, M) => m.sort - M.sort || m.originalOrder - M.originalOrder));
|
|
1138
|
+
return (m, M) => {
|
|
1139
|
+
const C = L("el-form-item"), h = L("el-col"), I = L("el-tab-pane"), ee = L("el-tabs"), ne = L("el-button"), B = L("el-form");
|
|
1140
|
+
return n(), q(B, S({
|
|
1141
1141
|
ref_key: "gform",
|
|
1142
1142
|
ref: a,
|
|
1143
1143
|
model: t.value,
|
|
@@ -1147,14 +1147,14 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1147
1147
|
w.value.length > 0 ? p(m.$slots, "default", { key: 0 }, () => {
|
|
1148
1148
|
var $, g, _;
|
|
1149
1149
|
return [
|
|
1150
|
-
Z(ee,
|
|
1150
|
+
Z(ee, S({
|
|
1151
1151
|
class: "demo-tabs",
|
|
1152
1152
|
modelValue: w.value[0].groupName,
|
|
1153
|
-
"onUpdate:modelValue":
|
|
1153
|
+
"onUpdate:modelValue": M[0] || (M[0] = (s) => w.value[0].groupName = s),
|
|
1154
1154
|
style: { width: "100%" }
|
|
1155
1155
|
}, t.value.form.tabs), {
|
|
1156
1156
|
default: y(() => [
|
|
1157
|
-
(n(!0),
|
|
1157
|
+
(n(!0), x(P, null, Y(w.value, (s) => (n(), q(I, S({
|
|
1158
1158
|
key: s.groupName,
|
|
1159
1159
|
label: s.groupName,
|
|
1160
1160
|
name: s.groupName,
|
|
@@ -1162,14 +1162,14 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1162
1162
|
ref_for: !0
|
|
1163
1163
|
}, s.tabPane), {
|
|
1164
1164
|
default: y(() => [
|
|
1165
|
-
(n(!0),
|
|
1165
|
+
(n(!0), x(P, null, Y(s.items, (i, A) => (n(), q(h, S({ ref_for: !0 }, { ...t.value.form.cols, ...i == null ? void 0 : i.item.col }, {
|
|
1166
1166
|
key: i.key,
|
|
1167
1167
|
style: { width: "100%" }
|
|
1168
1168
|
}), {
|
|
1169
1169
|
default: y(() => {
|
|
1170
1170
|
var H, X;
|
|
1171
1171
|
return [
|
|
1172
|
-
Z(C,
|
|
1172
|
+
Z(C, S({
|
|
1173
1173
|
label: i == null ? void 0 : i.item.label,
|
|
1174
1174
|
prop: `${i.key}.value`,
|
|
1175
1175
|
rules: D(i == null ? void 0 : i.item),
|
|
@@ -1181,9 +1181,9 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1181
1181
|
formInfo: b.value,
|
|
1182
1182
|
model: t.value
|
|
1183
1183
|
}, () => [
|
|
1184
|
-
(n(),
|
|
1184
|
+
(n(), q(Xe, {
|
|
1185
1185
|
modelValue: t.value[i.key].value,
|
|
1186
|
-
"onUpdate:modelValue": (
|
|
1186
|
+
"onUpdate:modelValue": (se) => t.value[i.key].value = se,
|
|
1187
1187
|
item: z(i),
|
|
1188
1188
|
ctrlKey: i.key,
|
|
1189
1189
|
ctrlType: te(i == null ? void 0 : i.item),
|
|
@@ -1192,11 +1192,11 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1192
1192
|
class: "g-ctrl-container",
|
|
1193
1193
|
t: "f",
|
|
1194
1194
|
formInfo: b.value
|
|
1195
|
-
},
|
|
1196
|
-
Y(m.$slots, (
|
|
1197
|
-
name:
|
|
1195
|
+
}, fe({ _: 2 }, [
|
|
1196
|
+
Y(m.$slots, (se, ce) => ({
|
|
1197
|
+
name: ce,
|
|
1198
1198
|
fn: y((he) => [
|
|
1199
|
-
p(m.$slots,
|
|
1199
|
+
p(m.$slots, ce, {
|
|
1200
1200
|
data: he,
|
|
1201
1201
|
item: i.item,
|
|
1202
1202
|
model: t.value
|
|
@@ -1223,10 +1223,10 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1223
1223
|
style: Oe(t.value.form.footer.style)
|
|
1224
1224
|
}, [
|
|
1225
1225
|
p(m.$slots, "f-footer-left"),
|
|
1226
|
-
(n(!0),
|
|
1226
|
+
(n(!0), x(P, null, Y(K.value, (s) => (n(), x(P, null, [
|
|
1227
1227
|
p(m.$slots, s.name + "-left"),
|
|
1228
1228
|
p(m.$slots, s.name, {}, () => [
|
|
1229
|
-
Z(
|
|
1229
|
+
Z(ne, S({ ref_for: !0 }, s.info, {
|
|
1230
1230
|
onClick: ct((i) => s.click(b.value, t.value), ["stop"])
|
|
1231
1231
|
}), {
|
|
1232
1232
|
default: y(() => [
|
|
@@ -1244,19 +1244,19 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1244
1244
|
}) : p(m.$slots, "default", { key: 1 }, () => {
|
|
1245
1245
|
var $, g, _;
|
|
1246
1246
|
return [
|
|
1247
|
-
(n(!0),
|
|
1247
|
+
(n(!0), x(P, null, Y(V.value, (s, i) => (n(), q(h, S({ ref_for: !0 }, { ...t.value.form.cols, ...s.col }, {
|
|
1248
1248
|
key: i,
|
|
1249
1249
|
style: { width: "100%" }
|
|
1250
1250
|
}), {
|
|
1251
1251
|
default: y(() => {
|
|
1252
|
-
var
|
|
1252
|
+
var A;
|
|
1253
1253
|
return [
|
|
1254
|
-
Z(C,
|
|
1254
|
+
Z(C, S({
|
|
1255
1255
|
label: s.label,
|
|
1256
1256
|
prop: `${i}.value`,
|
|
1257
1257
|
rules: D(s),
|
|
1258
1258
|
ref_for: !0
|
|
1259
|
-
}, { ...(
|
|
1259
|
+
}, { ...(A = t.value) == null ? void 0 : A.formItems, ...s == null ? void 0 : s.formItem }, { style: { width: "100%" } }), {
|
|
1260
1260
|
label: y((H) => [
|
|
1261
1261
|
p(m.$slots, `f-${i}-label`, {
|
|
1262
1262
|
data: H,
|
|
@@ -1272,7 +1272,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1272
1272
|
formInfo: b.value,
|
|
1273
1273
|
model: t.value
|
|
1274
1274
|
}, () => [
|
|
1275
|
-
(n(),
|
|
1275
|
+
(n(), q(Xe, {
|
|
1276
1276
|
modelValue: t.value[i].value,
|
|
1277
1277
|
"onUpdate:modelValue": (H) => t.value[i].value = H,
|
|
1278
1278
|
item: z(s, !0),
|
|
@@ -1283,12 +1283,12 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1283
1283
|
class: "g-ctrl-container",
|
|
1284
1284
|
t: "f",
|
|
1285
1285
|
formInfo: b.value
|
|
1286
|
-
},
|
|
1286
|
+
}, fe({ _: 2 }, [
|
|
1287
1287
|
Y(m.$slots, (H, X) => ({
|
|
1288
1288
|
name: X,
|
|
1289
|
-
fn: y((
|
|
1289
|
+
fn: y((se) => [
|
|
1290
1290
|
p(m.$slots, X, {
|
|
1291
|
-
data:
|
|
1291
|
+
data: se,
|
|
1292
1292
|
item: s,
|
|
1293
1293
|
model: t.value
|
|
1294
1294
|
})
|
|
@@ -1308,10 +1308,10 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1308
1308
|
style: Oe(t.value.form.footer.style)
|
|
1309
1309
|
}, [
|
|
1310
1310
|
p(m.$slots, "f-footer-left"),
|
|
1311
|
-
(n(!0),
|
|
1311
|
+
(n(!0), x(P, null, Y(K.value, (s) => (n(), x(P, null, [
|
|
1312
1312
|
p(m.$slots, s.name + "-left"),
|
|
1313
1313
|
p(m.$slots, s.name, {}, () => [
|
|
1314
|
-
Z(
|
|
1314
|
+
Z(ne, S({ ref_for: !0 }, s.info, {
|
|
1315
1315
|
onClick: ct((i) => s.click(b.value, t.value), ["stop"])
|
|
1316
1316
|
}), {
|
|
1317
1317
|
default: y(() => [
|
|
@@ -1342,19 +1342,19 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1342
1342
|
}),
|
|
1343
1343
|
emits: ["update:modelValue", "update:info"],
|
|
1344
1344
|
setup(f) {
|
|
1345
|
-
const c = Ie(f, "modelValue"), t = f, e = Ie(f, "info"), a = (T) => Ye(() => Object.fromEntries(Object.entries(c.value).filter((
|
|
1346
|
-
const
|
|
1347
|
-
return (
|
|
1345
|
+
const c = Ie(f, "modelValue"), t = f, e = Ie(f, "info"), a = (T) => Ye(() => Object.fromEntries(Object.entries(c.value).filter((F) => typeof F[1].search == "function" ? F[1].search && F[1].search(e.value).more === T : F[1].search && F[1].search.more === T).map((F) => [F[0], F[1]]))).value, d = (T) => typeof T.search == "function" ? T.search(e.value) : T.search || {}, U = (T) => {
|
|
1346
|
+
const F = d(T);
|
|
1347
|
+
return (F == null ? void 0 : F.type) || T.type;
|
|
1348
1348
|
};
|
|
1349
|
-
return (T,
|
|
1349
|
+
return (T, F) => {
|
|
1350
1350
|
const E = L("el-form-item");
|
|
1351
|
-
return n(!0),
|
|
1351
|
+
return n(!0), x(P, null, Y(a(t.more), (D, z) => p(T.$slots, `q-${z}`, {
|
|
1352
1352
|
key: z,
|
|
1353
1353
|
item: D,
|
|
1354
1354
|
queryModel: e.value,
|
|
1355
1355
|
model: c.value
|
|
1356
1356
|
}, () => [
|
|
1357
|
-
Z(E,
|
|
1357
|
+
Z(E, S({
|
|
1358
1358
|
label: D.label,
|
|
1359
1359
|
ref_for: !0
|
|
1360
1360
|
}, { ...c.value.queryItems, ...d(D) }), {
|
|
@@ -1374,7 +1374,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1374
1374
|
model: c.value,
|
|
1375
1375
|
t: "q",
|
|
1376
1376
|
formInfo: e.value
|
|
1377
|
-
},
|
|
1377
|
+
}, fe({ _: 2 }, [
|
|
1378
1378
|
Y(Object.keys(T.$slots), (te) => ({
|
|
1379
1379
|
name: te,
|
|
1380
1380
|
fn: y((R) => [
|
|
@@ -1409,8 +1409,8 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1409
1409
|
emits: /* @__PURE__ */ Be(["query", "reset"], ["update:modelValue"]),
|
|
1410
1410
|
setup(f, { emit: c }) {
|
|
1411
1411
|
const t = Ie(f, "modelValue"), e = c, a = at("options"), d = ye(!1);
|
|
1412
|
-
let U = Object.fromEntries(Object.entries(t.value).filter((
|
|
1413
|
-
const T = ye(U),
|
|
1412
|
+
let U = Object.fromEntries(Object.entries(t.value).filter((V) => V[1].search).map(([V, b]) => [V, b.value]));
|
|
1413
|
+
const T = ye(U), F = {
|
|
1414
1414
|
hidden: !1,
|
|
1415
1415
|
type: "hidden",
|
|
1416
1416
|
labelWidth: 100,
|
|
@@ -1458,7 +1458,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1458
1458
|
}
|
|
1459
1459
|
}
|
|
1460
1460
|
};
|
|
1461
|
-
t.value.query =
|
|
1461
|
+
t.value.query = Me(F, a == null ? void 0 : a.query, t.value.query);
|
|
1462
1462
|
const E = {
|
|
1463
1463
|
2: {
|
|
1464
1464
|
title: "更多查询",
|
|
@@ -1476,7 +1476,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1476
1476
|
trigger: "click"
|
|
1477
1477
|
}
|
|
1478
1478
|
};
|
|
1479
|
-
t.value.query.more.dialog =
|
|
1479
|
+
t.value.query.more.dialog = Me(
|
|
1480
1480
|
E[t.value.query.more.mode] || {},
|
|
1481
1481
|
t.value.query.more.dialog
|
|
1482
1482
|
);
|
|
@@ -1487,25 +1487,25 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1487
1487
|
width: "280px"
|
|
1488
1488
|
}
|
|
1489
1489
|
};
|
|
1490
|
-
t.value.queryItems =
|
|
1491
|
-
const z = (
|
|
1492
|
-
const w = Object.keys(
|
|
1490
|
+
t.value.queryItems = Me(D, a == null ? void 0 : a.queryItems, t.value.queryItems);
|
|
1491
|
+
const z = (V, b) => {
|
|
1492
|
+
const w = Object.keys(V.slots).filter((ae) => ae !== "default").reduce((ae, K) => (ae[K] = (ue) => V.slots[K]({
|
|
1493
1493
|
model: t.value
|
|
1494
1494
|
// 传递当前模型数据
|
|
1495
|
-
}),
|
|
1495
|
+
}), ae), {});
|
|
1496
1496
|
return qe(mt, {
|
|
1497
1497
|
modelValue: t.value,
|
|
1498
|
-
"onUpdate:modelValue": (
|
|
1498
|
+
"onUpdate:modelValue": (ae) => t.value = ae,
|
|
1499
1499
|
info: T.value,
|
|
1500
|
-
"onUpdate:info": (
|
|
1500
|
+
"onUpdate:info": (ae) => T.value = ae,
|
|
1501
1501
|
more: b
|
|
1502
1502
|
}, w);
|
|
1503
1503
|
}, te = ht(), R = () => {
|
|
1504
|
-
var w,
|
|
1505
|
-
const
|
|
1504
|
+
var w, ae, K, ue, de, me, pe, m, M;
|
|
1505
|
+
const V = [
|
|
1506
1506
|
{
|
|
1507
1507
|
key: "query",
|
|
1508
|
-
hidden: (K = (
|
|
1508
|
+
hidden: (K = (ae = (w = t.value) == null ? void 0 : w.query) == null ? void 0 : ae.query) == null ? void 0 : K.hidden,
|
|
1509
1509
|
component: _e,
|
|
1510
1510
|
props: {
|
|
1511
1511
|
...t.value.query.query,
|
|
@@ -1516,7 +1516,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1516
1516
|
},
|
|
1517
1517
|
{
|
|
1518
1518
|
key: "reset",
|
|
1519
|
-
hidden: (
|
|
1519
|
+
hidden: (me = (de = (ue = t.value) == null ? void 0 : ue.query) == null ? void 0 : de.reset) == null ? void 0 : me.hidden,
|
|
1520
1520
|
component: _e,
|
|
1521
1521
|
props: {
|
|
1522
1522
|
...t.value.query.reset,
|
|
@@ -1527,7 +1527,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1527
1527
|
},
|
|
1528
1528
|
{
|
|
1529
1529
|
key: "more",
|
|
1530
|
-
hidden: (
|
|
1530
|
+
hidden: (M = (m = (pe = t.value) == null ? void 0 : pe.query) == null ? void 0 : m.more) == null ? void 0 : M.hidden,
|
|
1531
1531
|
component: t.value.query.more.mode === 3 ? Ke : _e,
|
|
1532
1532
|
props: t.value.query.more.mode === 3 ? { ...t.value.query.more.dialog } : {
|
|
1533
1533
|
...t.value.query.more,
|
|
@@ -1541,51 +1541,51 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1541
1541
|
}, () => z({ slots: te }, !0)) : null
|
|
1542
1542
|
}
|
|
1543
1543
|
];
|
|
1544
|
-
return
|
|
1544
|
+
return V.sort((C, h) => C.sort - h.sort), V.filter((C) => !C.hidden).map((C) => C.key === "more" && C.component === Ke ? qe(Ke, C.props, {
|
|
1545
1545
|
reference: () => qe(_e, t.value.query.more, () => C.label),
|
|
1546
1546
|
default: C.content
|
|
1547
1547
|
}) : (C.props.slot = "query-" + C.key, C.label ? qe(C.component, C.props, () => C.label) : qe(C.component, C.props)));
|
|
1548
1548
|
};
|
|
1549
|
-
return (
|
|
1550
|
-
var K,
|
|
1551
|
-
const w = L("el-form-item"),
|
|
1552
|
-
return n(),
|
|
1549
|
+
return (V, b) => {
|
|
1550
|
+
var K, ue, de, me, pe, m, M, C, h, I, ee, ne, B, $, g, _, s;
|
|
1551
|
+
const w = L("el-form-item"), ae = L("el-drawer");
|
|
1552
|
+
return n(), x(P, null, [
|
|
1553
1553
|
J("div", {
|
|
1554
1554
|
class: "g-query-container",
|
|
1555
|
-
style: Oe((
|
|
1555
|
+
style: Oe((ue = (K = t.value.query) == null ? void 0 : K.container) == null ? void 0 : ue.style)
|
|
1556
1556
|
}, [
|
|
1557
1557
|
Z(o(We), Qe(ft(o(ke)(t.value.query, (i) => !["query", "more", "reset", "btns"].includes(i)))), {
|
|
1558
1558
|
default: y(() => {
|
|
1559
|
-
var i,
|
|
1559
|
+
var i, A;
|
|
1560
1560
|
return [
|
|
1561
|
-
(n(),
|
|
1562
|
-
((
|
|
1561
|
+
(n(), q(Ae(z({ slots: V.$slots }, void 0)))),
|
|
1562
|
+
((A = (i = t.value.query) == null ? void 0 : i.container) == null ? void 0 : A.inline) === !0 ? (n(), q(w, { key: 0 }, {
|
|
1563
1563
|
default: y(() => {
|
|
1564
|
-
var H, X,
|
|
1564
|
+
var H, X, se, ce, he;
|
|
1565
1565
|
return [
|
|
1566
1566
|
J("div", {
|
|
1567
1567
|
style: Oe((X = (H = t.value.query) == null ? void 0 : H.btns) == null ? void 0 : X.style)
|
|
1568
1568
|
}, [
|
|
1569
|
-
t.value.query.group ? (n(),
|
|
1569
|
+
t.value.query.group ? (n(), q(o(Ge), { key: 0 }, {
|
|
1570
1570
|
default: y(() => [
|
|
1571
|
-
(n(!0),
|
|
1572
|
-
(n(),
|
|
1571
|
+
(n(!0), x(P, null, Y(R(), (ve) => p(V.$slots, ve.props.slot, {}, () => [
|
|
1572
|
+
(n(), q(Ae(ve)))
|
|
1573
1573
|
], !0)), 256)),
|
|
1574
|
-
p(
|
|
1574
|
+
p(V.$slots, "q-btns", {}, void 0, !0)
|
|
1575
1575
|
]),
|
|
1576
1576
|
_: 3
|
|
1577
|
-
})) : (n(),
|
|
1578
|
-
(he = (
|
|
1577
|
+
})) : (n(), x(P, { key: 1 }, [
|
|
1578
|
+
(he = (ce = (se = t.value) == null ? void 0 : se.query) == null ? void 0 : ce.btns) != null && he.group ? (n(), q(o(Ge), { key: 0 }, {
|
|
1579
1579
|
default: y(() => [
|
|
1580
|
-
(n(!0),
|
|
1581
|
-
(n(),
|
|
1580
|
+
(n(!0), x(P, null, Y(R(), (ve) => p(V.$slots, ve.props.slot, {}, () => [
|
|
1581
|
+
(n(), q(Ae(ve)))
|
|
1582
1582
|
], !0)), 256))
|
|
1583
1583
|
]),
|
|
1584
1584
|
_: 3
|
|
1585
|
-
})) : (n(!0),
|
|
1586
|
-
(n(),
|
|
1585
|
+
})) : (n(!0), x(P, { key: 1 }, Y(R(), (ve) => p(V.$slots, ve.props.slot, {}, () => [
|
|
1586
|
+
(n(), q(Ae(ve)))
|
|
1587
1587
|
], !0)), 256)),
|
|
1588
|
-
p(
|
|
1588
|
+
p(V.$slots, "q-btns", {}, void 0, !0)
|
|
1589
1589
|
], 64))
|
|
1590
1590
|
], 4)
|
|
1591
1591
|
];
|
|
@@ -1596,42 +1596,42 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1596
1596
|
}),
|
|
1597
1597
|
_: 3
|
|
1598
1598
|
}, 16),
|
|
1599
|
-
((pe = (
|
|
1599
|
+
((pe = (me = (de = t.value) == null ? void 0 : de.query) == null ? void 0 : me.container) == null ? void 0 : pe.inline) === !1 ? (n(), x("div", {
|
|
1600
1600
|
key: 0,
|
|
1601
|
-
style: Oe((
|
|
1601
|
+
style: Oe((M = (m = t.value.query) == null ? void 0 : m.btns) == null ? void 0 : M.style)
|
|
1602
1602
|
}, [
|
|
1603
|
-
t.value.query.group ? (n(),
|
|
1603
|
+
t.value.query.group ? (n(), q(o(Ge), { key: 0 }, {
|
|
1604
1604
|
default: y(() => [
|
|
1605
|
-
(n(!0),
|
|
1606
|
-
(n(),
|
|
1605
|
+
(n(!0), x(P, null, Y(R(), (i) => p(V.$slots, i.props.slot, {}, () => [
|
|
1606
|
+
(n(), q(Ae(i)))
|
|
1607
1607
|
], !0)), 256)),
|
|
1608
|
-
p(
|
|
1608
|
+
p(V.$slots, "q-btns", {}, void 0, !0)
|
|
1609
1609
|
]),
|
|
1610
1610
|
_: 3
|
|
1611
|
-
})) : (n(),
|
|
1612
|
-
(h = (C = t.value.query) == null ? void 0 : C.btns) != null && h.group ? (n(),
|
|
1611
|
+
})) : (n(), x(P, { key: 1 }, [
|
|
1612
|
+
(h = (C = t.value.query) == null ? void 0 : C.btns) != null && h.group ? (n(), q(o(Ge), { key: 0 }, {
|
|
1613
1613
|
default: y(() => [
|
|
1614
|
-
(n(!0),
|
|
1615
|
-
(n(),
|
|
1614
|
+
(n(!0), x(P, null, Y(R(), (i) => p(V.$slots, i.props.slot, {}, () => [
|
|
1615
|
+
(n(), q(Ae(i)))
|
|
1616
1616
|
], !0)), 256))
|
|
1617
1617
|
]),
|
|
1618
1618
|
_: 3
|
|
1619
|
-
})) : (n(!0),
|
|
1620
|
-
(n(),
|
|
1619
|
+
})) : (n(!0), x(P, { key: 1 }, Y(R(), (i) => p(V.$slots, i.props.slot, {}, () => [
|
|
1620
|
+
(n(), q(Ae(i)))
|
|
1621
1621
|
], !0)), 256)),
|
|
1622
|
-
p(
|
|
1622
|
+
p(V.$slots, "q-btns", {}, void 0, !0)
|
|
1623
1623
|
], 64))
|
|
1624
1624
|
], 4)) : $e("", !0)
|
|
1625
1625
|
], 4),
|
|
1626
|
-
d.value && !((
|
|
1626
|
+
d.value && !((ne = (ee = (I = t.value) == null ? void 0 : I.query) == null ? void 0 : ee.more) != null && ne.hidden) && t.value.query.more.mode == 2 ? (n(), q(ae, S({
|
|
1627
1627
|
key: 0,
|
|
1628
1628
|
modelValue: d.value,
|
|
1629
1629
|
"onUpdate:modelValue": b[4] || (b[4] = (i) => d.value = i),
|
|
1630
1630
|
title: "更多查询",
|
|
1631
1631
|
"show-close": !1
|
|
1632
|
-
}, t.value.query.more.dialog),
|
|
1632
|
+
}, t.value.query.more.dialog), fe({
|
|
1633
1633
|
default: y(() => [
|
|
1634
|
-
Z(o(We),
|
|
1634
|
+
Z(o(We), S(o(ke)(t.value.query, (i) => !["query", "more", "reset"].includes(i)), { style: { width: "98%" } }), {
|
|
1635
1635
|
default: y(() => [
|
|
1636
1636
|
Z(mt, {
|
|
1637
1637
|
modelValue: t.value,
|
|
@@ -1639,11 +1639,11 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1639
1639
|
info: T.value,
|
|
1640
1640
|
"onUpdate:info": b[1] || (b[1] = (i) => T.value = i),
|
|
1641
1641
|
more: !0
|
|
1642
|
-
},
|
|
1643
|
-
Y(
|
|
1644
|
-
name:
|
|
1642
|
+
}, fe({ _: 2 }, [
|
|
1643
|
+
Y(V.$slots, (i, A, H) => ({
|
|
1644
|
+
name: A,
|
|
1645
1645
|
fn: y((X) => [
|
|
1646
|
-
p(
|
|
1646
|
+
p(V.$slots, A, { model: t.value }, void 0, !0)
|
|
1647
1647
|
])
|
|
1648
1648
|
}))
|
|
1649
1649
|
]), 1032, ["modelValue", "info"])
|
|
@@ -1653,11 +1653,11 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1653
1653
|
]),
|
|
1654
1654
|
_: 2
|
|
1655
1655
|
}, [
|
|
1656
|
-
(s = (_ = (g = ($ = (
|
|
1656
|
+
(s = (_ = (g = ($ = (B = t.value) == null ? void 0 : B.query) == null ? void 0 : $.more) == null ? void 0 : g.dialog) == null ? void 0 : _.footer) != null && s.hidden ? void 0 : {
|
|
1657
1657
|
name: "footer",
|
|
1658
1658
|
fn: y(() => [
|
|
1659
1659
|
J("div", Qe(ft(t.value.query.more.dialog.footer)), [
|
|
1660
|
-
Z(o(_e),
|
|
1660
|
+
Z(o(_e), S(t.value.query.query, {
|
|
1661
1661
|
onClick: b[2] || (b[2] = (i) => t.value.query.query.click())
|
|
1662
1662
|
}), {
|
|
1663
1663
|
default: y(() => [
|
|
@@ -1665,7 +1665,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1665
1665
|
]),
|
|
1666
1666
|
_: 1
|
|
1667
1667
|
}, 16),
|
|
1668
|
-
Z(o(_e),
|
|
1668
|
+
Z(o(_e), S(t.value.query.reset, {
|
|
1669
1669
|
onClick: b[3] || (b[3] = (i) => t.value.query.reset.click())
|
|
1670
1670
|
}), {
|
|
1671
1671
|
default: y(() => [
|
|
@@ -1678,19 +1678,19 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1678
1678
|
key: "0"
|
|
1679
1679
|
}
|
|
1680
1680
|
]), 1040, ["modelValue"])) : $e("", !0),
|
|
1681
|
-
Z(
|
|
1681
|
+
Z(Vt, {
|
|
1682
1682
|
duration: 300,
|
|
1683
1683
|
name: "nested",
|
|
1684
1684
|
style: { padding: "10px" }
|
|
1685
1685
|
}, {
|
|
1686
1686
|
default: y(() => {
|
|
1687
|
-
var i,
|
|
1687
|
+
var i, A, H;
|
|
1688
1688
|
return [
|
|
1689
|
-
d.value && !((H = (
|
|
1689
|
+
d.value && !((H = (A = (i = t.value) == null ? void 0 : i.query) == null ? void 0 : A.more) != null && H.hidden) && t.value.query.more.mode == 1 ? (n(), x("div", Gt, [
|
|
1690
1690
|
J("div", Qt, [
|
|
1691
|
-
t.value.query.more.mode == 1 ?
|
|
1691
|
+
t.value.query.more.mode == 1 ? Mt((n(), q(o(We), Qe(S({ key: 0 }, o(ke)(t.value.query, (X) => !["query", "more", "reset"].includes(X)))), {
|
|
1692
1692
|
default: y(() => [
|
|
1693
|
-
(n(),
|
|
1693
|
+
(n(), q(Ae(z({ slots: V.$slots }, !0))))
|
|
1694
1694
|
]),
|
|
1695
1695
|
_: 1
|
|
1696
1696
|
}, 16)), [
|
|
@@ -1717,41 +1717,41 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1717
1717
|
emits: ["excel"],
|
|
1718
1718
|
setup(f, { emit: c }) {
|
|
1719
1719
|
const t = f, e = c, a = ye(t.items), d = () => {
|
|
1720
|
-
a.value.forEach((
|
|
1721
|
-
|
|
1720
|
+
a.value.forEach((F) => {
|
|
1721
|
+
F.value = !0;
|
|
1722
1722
|
});
|
|
1723
1723
|
}, U = () => {
|
|
1724
|
-
a.value.forEach((
|
|
1725
|
-
|
|
1724
|
+
a.value.forEach((F) => {
|
|
1725
|
+
F.value = !1;
|
|
1726
1726
|
});
|
|
1727
1727
|
}, T = () => {
|
|
1728
|
-
e("excel", a.value, (
|
|
1729
|
-
if (!
|
|
1728
|
+
e("excel", a.value, (F, E = "excel.xls") => {
|
|
1729
|
+
if (!F) {
|
|
1730
1730
|
console.error("下载链接无效");
|
|
1731
1731
|
return;
|
|
1732
1732
|
}
|
|
1733
1733
|
try {
|
|
1734
1734
|
const D = document.createElement("a");
|
|
1735
|
-
D.href =
|
|
1735
|
+
D.href = F, D.download = E, D.style.display = "none", document.body.appendChild(D), D.click(), document.body.removeChild(D);
|
|
1736
1736
|
} catch (D) {
|
|
1737
1737
|
console.error("下载文件时出现错误:", D);
|
|
1738
1738
|
}
|
|
1739
1739
|
});
|
|
1740
1740
|
};
|
|
1741
1741
|
return Ne(() => {
|
|
1742
|
-
const
|
|
1742
|
+
const F = new bt(document.getElementById("excelSortEl"), {
|
|
1743
1743
|
animation: 150,
|
|
1744
1744
|
onEnd: () => {
|
|
1745
|
-
let D =
|
|
1745
|
+
let D = F.toArray();
|
|
1746
1746
|
console.log(D);
|
|
1747
1747
|
}
|
|
1748
|
-
}), E =
|
|
1748
|
+
}), E = F;
|
|
1749
1749
|
Ft(() => {
|
|
1750
1750
|
E && E.destroy();
|
|
1751
1751
|
});
|
|
1752
|
-
}), (
|
|
1752
|
+
}), (F, E) => {
|
|
1753
1753
|
const D = L("el-divider"), z = L("el-alert"), te = L("el-checkbox"), R = L("el-button");
|
|
1754
|
-
return n(),
|
|
1754
|
+
return n(), x("div", Zt, [
|
|
1755
1755
|
J("div", Kt, [
|
|
1756
1756
|
J("div", el, [
|
|
1757
1757
|
J("a", {
|
|
@@ -1773,18 +1773,18 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1773
1773
|
}),
|
|
1774
1774
|
E[0] || (E[0] = J("div", { style: { margin: "1px 0" } }, null, -1)),
|
|
1775
1775
|
J("div", tl, [
|
|
1776
|
-
(n(!0),
|
|
1776
|
+
(n(!0), x(P, null, Y(a.value, (V) => (n(), q(te, {
|
|
1777
1777
|
class: "check-box-hover",
|
|
1778
1778
|
style: { width: "120px !important", height: "30px !important", border: "1px solid #dfe6ec", margin: "5px !important", "border-radius": "3px !important", "padding-left": "5px !important", display: "flex !important", "align-items": "center !important" },
|
|
1779
|
-
"data-id":
|
|
1780
|
-
modelValue:
|
|
1781
|
-
"onUpdate:modelValue": (b) =>
|
|
1782
|
-
key:
|
|
1783
|
-
title:
|
|
1779
|
+
"data-id": V.key,
|
|
1780
|
+
modelValue: V.value,
|
|
1781
|
+
"onUpdate:modelValue": (b) => V.value = b,
|
|
1782
|
+
key: V.key,
|
|
1783
|
+
title: V.label
|
|
1784
1784
|
}, {
|
|
1785
1785
|
default: y(() => [
|
|
1786
1786
|
J("span", {
|
|
1787
|
-
textContent: Ee(
|
|
1787
|
+
textContent: Ee(V.label),
|
|
1788
1788
|
style: { display: "block", "text-overflow": "ellipsis", width: "95px", overflow: "hidden" }
|
|
1789
1789
|
}, null, 8, ll)
|
|
1790
1790
|
]),
|
|
@@ -1796,7 +1796,7 @@ const et = /* @__PURE__ */ Ut(jt), Lt = {
|
|
|
1796
1796
|
Z(R, {
|
|
1797
1797
|
type: "primary",
|
|
1798
1798
|
onClick: T,
|
|
1799
|
-
disabled: a.value.filter((
|
|
1799
|
+
disabled: a.value.filter((V) => V.value).length < 1
|
|
1800
1800
|
}, {
|
|
1801
1801
|
default: y(() => [
|
|
1802
1802
|
we(Ee(t.commitText), 1)
|
|
@@ -1879,9 +1879,9 @@ const dl = {
|
|
|
1879
1879
|
onEnd: () => {
|
|
1880
1880
|
D.toArray().forEach(async (te, R) => {
|
|
1881
1881
|
e.value[te].sort = R;
|
|
1882
|
-
let
|
|
1882
|
+
let V = e.value[te].width || "auto";
|
|
1883
1883
|
try {
|
|
1884
|
-
const b = await He(e.value.table.user, c.name, te, { sort: R, width:
|
|
1884
|
+
const b = await He(e.value.table.user, c.name, te, { sort: R, width: V });
|
|
1885
1885
|
console.log(b);
|
|
1886
1886
|
} catch (b) {
|
|
1887
1887
|
console.error("列排序和宽度保存信息时出错:", b), Te({
|
|
@@ -1928,7 +1928,7 @@ const dl = {
|
|
|
1928
1928
|
message: "清除列保存信息失败!"
|
|
1929
1929
|
});
|
|
1930
1930
|
}
|
|
1931
|
-
},
|
|
1931
|
+
}, F = () => {
|
|
1932
1932
|
vt.confirm("确定要复位吗?", "提示", {
|
|
1933
1933
|
confirmButtonText: "确定",
|
|
1934
1934
|
cancelButtonText: "取消",
|
|
@@ -1955,13 +1955,13 @@ const dl = {
|
|
|
1955
1955
|
})).sort((E, D) => E.sort - D.sort), d();
|
|
1956
1956
|
}), (E, D) => {
|
|
1957
1957
|
const z = L("el-divider"), te = L("el-alert"), R = L("el-checkbox");
|
|
1958
|
-
return n(),
|
|
1958
|
+
return n(), x("div", null, [
|
|
1959
1959
|
J("div", dl, [
|
|
1960
1960
|
J("a", { onClick: U }, "全选"),
|
|
1961
1961
|
Z(z, { direction: "vertical" }),
|
|
1962
1962
|
J("a", { onClick: T }, "全不选"),
|
|
1963
1963
|
Z(z, { direction: "vertical" }),
|
|
1964
|
-
J("a", { onClick:
|
|
1964
|
+
J("a", { onClick: F }, "复位")
|
|
1965
1965
|
]),
|
|
1966
1966
|
Z(te, {
|
|
1967
1967
|
title: "拖动表格列标题可以改变表格列显示顺序 !",
|
|
@@ -1972,21 +1972,21 @@ const dl = {
|
|
|
1972
1972
|
}),
|
|
1973
1973
|
J("div", null, [
|
|
1974
1974
|
J("div", cl, [
|
|
1975
|
-
(n(!0),
|
|
1976
|
-
modelValue:
|
|
1977
|
-
"onUpdate:modelValue": (b) =>
|
|
1978
|
-
"data-id":
|
|
1979
|
-
class: gt(["check-box-hover",
|
|
1980
|
-
onChange: (b) => a(b,
|
|
1975
|
+
(n(!0), x(P, null, Y(t.value, (V) => (n(), q(R, {
|
|
1976
|
+
modelValue: V.showCol,
|
|
1977
|
+
"onUpdate:modelValue": (b) => V.showCol = b,
|
|
1978
|
+
"data-id": V.value,
|
|
1979
|
+
class: gt(["check-box-hover", V.value == "control" ? "filtered" : ""]),
|
|
1980
|
+
onChange: (b) => a(b, V.value),
|
|
1981
1981
|
style: { width: "125px !important", height: "30px !important", border: "1px solid #dfe6ec", margin: "5px !important", "border-radius": "2px !important", "padding-left": "5px !important", display: "flex !important", "align-items": "center !important" },
|
|
1982
|
-
value:
|
|
1983
|
-
title:
|
|
1984
|
-
disabled:
|
|
1985
|
-
key:
|
|
1982
|
+
value: V.value,
|
|
1983
|
+
title: V.label,
|
|
1984
|
+
disabled: V.alwaysShow,
|
|
1985
|
+
key: V.value
|
|
1986
1986
|
}, {
|
|
1987
1987
|
default: y(() => [
|
|
1988
1988
|
J("span", {
|
|
1989
|
-
textContent: Ee(
|
|
1989
|
+
textContent: Ee(V.label),
|
|
1990
1990
|
style: { display: "block", "text-overflow": "ellipsis", width: "95px", overflow: "hidden" }
|
|
1991
1991
|
}, null, 8, fl)
|
|
1992
1992
|
]),
|
|
@@ -2003,7 +2003,7 @@ const dl = {
|
|
|
2003
2003
|
}, hl = { class: "table-container" }, gl = ["src"], bl = ["innerHTML"], $l = { key: 0 }, El = { style: { display: "flex", "margin-top": "-2px" } }, wl = { style: { display: "flex", flex: "1" } }, _l = {
|
|
2004
2004
|
style: { display: "flex", "justify-content": "center", width: "100%", height: "100%" },
|
|
2005
2005
|
id: "table-form"
|
|
2006
|
-
}, kl = { key: 1 }, Cl = { style: { display: "flex" } }, Dl = { style: { display: "flex", flex: "1" } },
|
|
2006
|
+
}, kl = { key: 1 }, Cl = { style: { display: "flex" } }, Dl = { style: { display: "flex", flex: "1" } }, Vl = /* @__PURE__ */ Object.assign({
|
|
2007
2007
|
name: "g-table",
|
|
2008
2008
|
inheritAttrs: !1
|
|
2009
2009
|
}, {
|
|
@@ -2017,10 +2017,10 @@ const dl = {
|
|
|
2017
2017
|
}),
|
|
2018
2018
|
emits: /* @__PURE__ */ Be(["load", "open", "delete", "submit", "reset", "download", "row-save"], ["update:modelValue"]),
|
|
2019
2019
|
setup(f, { emit: c }) {
|
|
2020
|
-
var Ce, Fe, De, u, N,
|
|
2020
|
+
var Ce, Fe, De, u, N, ie, Ve;
|
|
2021
2021
|
const t = c, e = Ie(f, "modelValue"), a = at("options"), d = ye({}), U = Object.entries(e.value).filter(([l, r]) => (r == null ? void 0 : r.search) !== void 0).map(([l, r]) => [l, r.value]);
|
|
2022
2022
|
d.value = Object.fromEntries(U);
|
|
2023
|
-
const T = ye(!1),
|
|
2023
|
+
const T = ye(!1), F = ["type", "index", "label", "column-key", "prop", "width", "min-width", "fixed", "render-header", "sortable", "sort-method", "sort-by", "sort-orders", "resizable", "formatter", "show-overflow-tooltip", "align", "header-align", "class-name", "label-class-name", "selectable", "reserve-selection", "filters", "filter-placement", "filter-class-name", "filter-multiple", "filter-method", "filtered-value"], E = ye([]), D = f, z = nt(), te = ye({}), R = ye([]), V = {
|
|
2024
2024
|
autoWatch: !1,
|
|
2025
2025
|
data: [],
|
|
2026
2026
|
border: !0,
|
|
@@ -2031,25 +2031,25 @@ const dl = {
|
|
|
2031
2031
|
load: () => {
|
|
2032
2032
|
let { currentPage: l, pageSize: r } = e.value.table.page;
|
|
2033
2033
|
try {
|
|
2034
|
-
t("load", { currentPage: l, pageSize: r, ...d.value }, (v,
|
|
2035
|
-
var
|
|
2034
|
+
t("load", { currentPage: l, pageSize: r, ...d.value }, (v, O, { fields: G = [], sums: Q = {} } = {}) => {
|
|
2035
|
+
var le, Se;
|
|
2036
2036
|
if (!Array.isArray(v)) {
|
|
2037
2037
|
console.error("从 load 事件回调中接收到的数据不是数组格式。"), Te.error("数据加载失败,请检查数据格式。");
|
|
2038
2038
|
return;
|
|
2039
2039
|
}
|
|
2040
|
-
if (typeof
|
|
2040
|
+
if (typeof O != "number") {
|
|
2041
2041
|
console.error("从 load 事件回调中接收到的 total 不是数字格式。"), Te.error("数据加载失败,请检查数据格式。");
|
|
2042
2042
|
return;
|
|
2043
2043
|
}
|
|
2044
|
-
e.value.table.data = v, ((Se = (
|
|
2044
|
+
e.value.table.data = v, ((Se = (le = e.value.control) == null ? void 0 : le.add) == null ? void 0 : Se.inline) === !0 && e.value.table.data.unshift(de), e.value.table.page.total = O, R.value = G, te.value = Q, ce();
|
|
2045
2045
|
});
|
|
2046
2046
|
} catch (v) {
|
|
2047
2047
|
console.error("触发 load 事件时出现错误:", v), Te.error("数据加载时出现错误,请稍后重试。");
|
|
2048
2048
|
}
|
|
2049
2049
|
},
|
|
2050
2050
|
onHeaderDragend: (l, r, v) => {
|
|
2051
|
-
var
|
|
2052
|
-
He((
|
|
2051
|
+
var O;
|
|
2052
|
+
He((O = e.value.table) == null ? void 0 : O.user, D.name, v.property, { width: l });
|
|
2053
2053
|
},
|
|
2054
2054
|
onRowDblclick: (l, r, v) => {
|
|
2055
2055
|
e.value.table.dblclickType == "edit" ? C(l, r, v, e) : e.value.table.dblclickType == "view" && I(l, r, v, e);
|
|
@@ -2077,11 +2077,11 @@ const dl = {
|
|
|
2077
2077
|
},
|
|
2078
2078
|
dblclickType: "edit",
|
|
2079
2079
|
"summary-method": ({ columns: l, data: r }, v) => v,
|
|
2080
|
-
onSortChange: ({ column: l, prop: r, order: v },
|
|
2080
|
+
onSortChange: ({ column: l, prop: r, order: v }, O) => {
|
|
2081
2081
|
}
|
|
2082
2082
|
};
|
|
2083
|
-
e.value.table =
|
|
2084
|
-
|
|
2083
|
+
e.value.table = Me(
|
|
2084
|
+
V,
|
|
2085
2085
|
a == null ? void 0 : a.table,
|
|
2086
2086
|
e.value.table,
|
|
2087
2087
|
z
|
|
@@ -2093,14 +2093,13 @@ const dl = {
|
|
|
2093
2093
|
width: 250,
|
|
2094
2094
|
fixed: "right",
|
|
2095
2095
|
style: { ...(Fe = (Ce = e.value) == null ? void 0 : Ce.control) == null ? void 0 : Fe.style },
|
|
2096
|
-
validate: (l) => !0,
|
|
2096
|
+
validate: async (l) => await !0,
|
|
2097
2097
|
add: {
|
|
2098
2098
|
label: "新增",
|
|
2099
2099
|
text: !1,
|
|
2100
2100
|
type: "primary",
|
|
2101
2101
|
mode: "dialog",
|
|
2102
2102
|
inline: !1,
|
|
2103
|
-
adding: !1,
|
|
2104
2103
|
auth: () => !0
|
|
2105
2104
|
},
|
|
2106
2105
|
view: {
|
|
@@ -2116,8 +2115,8 @@ const dl = {
|
|
|
2116
2115
|
type: "primary",
|
|
2117
2116
|
mode: "dialog",
|
|
2118
2117
|
auth: (l, r, v) => {
|
|
2119
|
-
var
|
|
2120
|
-
return ((Q = (G = (
|
|
2118
|
+
var O, G, Q;
|
|
2119
|
+
return ((Q = (G = (O = e.value) == null ? void 0 : O.control) == null ? void 0 : G.add) == null ? void 0 : Q.inline) === !1;
|
|
2121
2120
|
}
|
|
2122
2121
|
},
|
|
2123
2122
|
delete: {
|
|
@@ -2125,8 +2124,8 @@ const dl = {
|
|
|
2125
2124
|
label: "删除",
|
|
2126
2125
|
type: "danger",
|
|
2127
2126
|
auth: (l, r, v) => {
|
|
2128
|
-
var
|
|
2129
|
-
return !(((Q = (G = (
|
|
2127
|
+
var O, G, Q;
|
|
2128
|
+
return !(((Q = (G = (O = e.value) == null ? void 0 : O.control) == null ? void 0 : G.add) == null ? void 0 : Q.inline) === !0 && v === 0);
|
|
2130
2129
|
},
|
|
2131
2130
|
dialog: {
|
|
2132
2131
|
message: "此操作将永久删除该文件, 是否继续?",
|
|
@@ -2161,7 +2160,7 @@ const dl = {
|
|
|
2161
2160
|
}
|
|
2162
2161
|
}
|
|
2163
2162
|
};
|
|
2164
|
-
e.value.control =
|
|
2163
|
+
e.value.control = Me(
|
|
2165
2164
|
b,
|
|
2166
2165
|
a == null ? void 0 : a.control,
|
|
2167
2166
|
(De = e.value) == null ? void 0 : De.control
|
|
@@ -2170,21 +2169,21 @@ const dl = {
|
|
|
2170
2169
|
type: "hidden",
|
|
2171
2170
|
minWidth: 120,
|
|
2172
2171
|
align: "center",
|
|
2173
|
-
formatter: (l, r, v,
|
|
2172
|
+
formatter: (l, r, v, O) => v
|
|
2174
2173
|
};
|
|
2175
|
-
e.value.tableColumns =
|
|
2174
|
+
e.value.tableColumns = Me(
|
|
2176
2175
|
w,
|
|
2177
2176
|
a == null ? void 0 : a.tableColumns,
|
|
2178
2177
|
(u = e.value) == null ? void 0 : u.tableColumns
|
|
2179
2178
|
);
|
|
2180
|
-
const
|
|
2179
|
+
const ae = {
|
|
2181
2180
|
type: "hidden",
|
|
2182
2181
|
disabled: void 0,
|
|
2183
2182
|
footer: { hidden: !1 },
|
|
2184
2183
|
modalState: void 0
|
|
2185
2184
|
};
|
|
2186
|
-
e.value.form =
|
|
2187
|
-
|
|
2185
|
+
e.value.form = Me(
|
|
2186
|
+
ae,
|
|
2188
2187
|
a == null ? void 0 : a.form,
|
|
2189
2188
|
(N = e.value) == null ? void 0 : N.form
|
|
2190
2189
|
);
|
|
@@ -2195,12 +2194,12 @@ const dl = {
|
|
|
2195
2194
|
width: "100%"
|
|
2196
2195
|
}
|
|
2197
2196
|
};
|
|
2198
|
-
e.value.formItems =
|
|
2197
|
+
e.value.formItems = Me(
|
|
2199
2198
|
K,
|
|
2200
2199
|
a == null ? void 0 : a.formItems,
|
|
2201
|
-
(
|
|
2200
|
+
(ie = e == null ? void 0 : e.value) == null ? void 0 : ie.formItems
|
|
2202
2201
|
);
|
|
2203
|
-
const
|
|
2202
|
+
const ue = {
|
|
2204
2203
|
title: "编辑",
|
|
2205
2204
|
mode: "drawer",
|
|
2206
2205
|
type: "hidden",
|
|
@@ -2208,12 +2207,12 @@ const dl = {
|
|
|
2208
2207
|
size: 700,
|
|
2209
2208
|
fullScreen: !1
|
|
2210
2209
|
};
|
|
2211
|
-
e.value.dialog =
|
|
2212
|
-
|
|
2210
|
+
e.value.dialog = Me(
|
|
2211
|
+
ue,
|
|
2213
2212
|
a == null ? void 0 : a.dialog,
|
|
2214
|
-
(
|
|
2213
|
+
(Ve = e.value) == null ? void 0 : Ve.dialog
|
|
2215
2214
|
);
|
|
2216
|
-
const
|
|
2215
|
+
const de = Object.fromEntries(Object.entries(ke(e.value, (l, r) => r.type != "control" && r.editor !== !1 && r.type != "hidden")).map(([l, r]) => [l, r.value])), me = (l, r) => {
|
|
2217
2216
|
let v = r;
|
|
2218
2217
|
if (l.decimals && !isNaN(parseFloat(r)) && (typeof l.decimals == "number" ? v = parseFloat(v).toFixed(l.decimals) : typeof l.decimals == "object" && l.decimals.num && (l.decimals.pad ? v = parseFloat(v).toFixed(l.decimals.num) : v = parseFloat(parseFloat(v).toFixed(l.decimals.num)).toString())), ["date", "datetime", "time", "time-select"].includes(l.type) && et(r).isValid()) {
|
|
2219
2218
|
const G = {
|
|
@@ -2228,52 +2227,78 @@ const dl = {
|
|
|
2228
2227
|
d.value = l.value;
|
|
2229
2228
|
}, m = (l) => {
|
|
2230
2229
|
d.value = l, e.value.table.load();
|
|
2231
|
-
},
|
|
2230
|
+
}, M = async (l) => {
|
|
2232
2231
|
var r, v;
|
|
2233
|
-
e.value.form.modalState = "add"
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2232
|
+
e.value.form.modalState = "add";
|
|
2233
|
+
try {
|
|
2234
|
+
if (!await ((r = e.value.control) == null ? void 0 : r.validate("add", { m: l }))) return;
|
|
2235
|
+
} catch (O) {
|
|
2236
|
+
console.error("验证失败:", O);
|
|
2237
|
+
return;
|
|
2238
|
+
}
|
|
2239
|
+
(v = e.value.control.add) != null && v.click ? e.value.control.add.click(l) : e.value.control.add.inline === !0 ? (console.log(de), e.value.table.data.unshift(de), t("open", "row-add", { initFormData: de })) : (e.value.form.disabled = !1, e.value.dialog.mode = e.value.control.add.mode, e.value.dialog.title = e.value.control.add.label, Object.keys(de).forEach((O) => {
|
|
2240
|
+
e.value[O] && (e.value[O].value = de[O]);
|
|
2241
|
+
}), T.value = !0, t("open", "add", { m: l }));
|
|
2242
|
+
}, C = async (l, r, v, O) => {
|
|
2237
2243
|
var G, Q;
|
|
2238
|
-
e.value.form.modalState = "edit"
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2244
|
+
e.value.form.modalState = "edit";
|
|
2245
|
+
try {
|
|
2246
|
+
if (!await ((G = e.value.control) == null ? void 0 : G.validate("edit", { row: l, column: r, $index: v, m: O }))) return;
|
|
2247
|
+
} catch (le) {
|
|
2248
|
+
console.error("验证失败:", le);
|
|
2249
|
+
return;
|
|
2250
|
+
}
|
|
2251
|
+
(Q = e.value.control.edit) != null && Q.click ? e.value.control.edit.click(l, r, v, O) : (e.value.form.disabled = !1, e.value.dialog.mode = e.value.control.edit.mode, e.value.dialog.title = e.value.control.edit.label, Object.keys(l).forEach((le) => {
|
|
2252
|
+
e.value[le] && (e.value[le].value = l[le]);
|
|
2253
|
+
}), T.value = !0, t("open", "edit", { m: O, row: l, column: r, $index: v }));
|
|
2254
|
+
}, h = async (l, r, v, O) => {
|
|
2242
2255
|
var G, Q;
|
|
2243
|
-
|
|
2244
|
-
if ((
|
|
2245
|
-
|
|
2246
|
-
|
|
2247
|
-
|
|
2248
|
-
|
|
2249
|
-
|
|
2250
|
-
|
|
2251
|
-
|
|
2252
|
-
|
|
2256
|
+
try {
|
|
2257
|
+
if (!await ((G = e.value.control) == null ? void 0 : G.validate("delete", { row: l, column: r, $index: v, m: O }))) return;
|
|
2258
|
+
} catch (le) {
|
|
2259
|
+
console.error("验证失败:", le);
|
|
2260
|
+
return;
|
|
2261
|
+
}
|
|
2262
|
+
if ((Q = e.value.control.delete) != null && Q.click)
|
|
2263
|
+
e.value.control.delete.click(l, r, v, O);
|
|
2264
|
+
else {
|
|
2265
|
+
let { message: le, title: Se, options: Pe } = e.value.control.delete.dialog;
|
|
2266
|
+
vt.confirm(le, Se, Pe).then(() => {
|
|
2267
|
+
t("delete", { row: l, column: r, $index: v }, (ze) => {
|
|
2268
|
+
ze && (e.value.table.data.splice(v, 1), e.value.table.page.total--);
|
|
2253
2269
|
});
|
|
2254
|
-
}
|
|
2255
|
-
|
|
2270
|
+
}).catch(() => {
|
|
2271
|
+
});
|
|
2272
|
+
}
|
|
2273
|
+
}, I = async (l, r, v, O) => {
|
|
2256
2274
|
var G, Q;
|
|
2257
|
-
e.value.form.modalState = void 0
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2275
|
+
e.value.form.modalState = void 0;
|
|
2276
|
+
try {
|
|
2277
|
+
if (!await ((G = e.value.control) == null ? void 0 : G.validate("view", { row: l, column: r, $index: v, m: O }))) return;
|
|
2278
|
+
} catch (le) {
|
|
2279
|
+
console.error("验证失败:", le);
|
|
2280
|
+
return;
|
|
2281
|
+
}
|
|
2282
|
+
(Q = e.value.control.view) != null && Q.click ? e.value.control.view.click(l, r, v, O) : (e.value.form.disabled = !0, e.value.dialog.mode = e.value.control.view.mode, e.value.dialog.title = e.value.control.view.label, Object.keys(l).forEach((le) => {
|
|
2283
|
+
e.value[le] && (e.value[le].value = l[le]);
|
|
2284
|
+
}), T.value = !0, t("open", "view", { m: O, row: l, column: r, $index: v }));
|
|
2285
|
+
}, ee = (l, r, v, O) => {
|
|
2261
2286
|
var G;
|
|
2262
|
-
(G = e.value.control.save) != null && G.click ? e.value.control.save.click(l, r, v,
|
|
2287
|
+
(G = e.value.control.save) != null && G.click ? e.value.control.save.click(l, r, v, O) : t("row-save", { row: l, column: r, $index: v, data: e.value.table.data }, (Q) => {
|
|
2263
2288
|
Q && e.value.table.load();
|
|
2264
2289
|
});
|
|
2265
|
-
},
|
|
2290
|
+
}, ne = (l, r) => {
|
|
2266
2291
|
t("submit", e.value.form.modalState, l, r, (v) => {
|
|
2267
2292
|
v && (T.value = !1, r.table.load());
|
|
2268
2293
|
});
|
|
2269
|
-
},
|
|
2294
|
+
}, B = (l) => {
|
|
2270
2295
|
t("reset", l);
|
|
2271
2296
|
}, $ = (l, r) => {
|
|
2272
2297
|
var v;
|
|
2273
2298
|
if ((v = l.control.download) != null && v.click)
|
|
2274
2299
|
l.control.download.click(l, r);
|
|
2275
2300
|
else {
|
|
2276
|
-
let
|
|
2301
|
+
let O = ot({
|
|
2277
2302
|
title: l.control.download.label,
|
|
2278
2303
|
size: 480,
|
|
2279
2304
|
width: 600,
|
|
@@ -2282,7 +2307,7 @@ const dl = {
|
|
|
2282
2307
|
items: r,
|
|
2283
2308
|
commitText: l.control.download.excelLabel,
|
|
2284
2309
|
onExcel: (G, Q) => {
|
|
2285
|
-
t("download", G, Q),
|
|
2310
|
+
t("download", G, Q), O();
|
|
2286
2311
|
}
|
|
2287
2312
|
})
|
|
2288
2313
|
}
|
|
@@ -2302,7 +2327,7 @@ const dl = {
|
|
|
2302
2327
|
}
|
|
2303
2328
|
}, l.control.setting.mode);
|
|
2304
2329
|
}, _ = e.value.control, s = [
|
|
2305
|
-
{ type: "add", func:
|
|
2330
|
+
{ type: "add", func: M },
|
|
2306
2331
|
{ type: "download", func: $ },
|
|
2307
2332
|
{ type: "setting", func: g },
|
|
2308
2333
|
{ type: "view", func: I },
|
|
@@ -2310,61 +2335,61 @@ const dl = {
|
|
|
2310
2335
|
{ type: "delete", func: h },
|
|
2311
2336
|
{ type: "save", func: ee }
|
|
2312
2337
|
], i = (l) => s.filter((r) => l.includes(r.type)).map(({ type: r, func: v }) => {
|
|
2313
|
-
var
|
|
2338
|
+
var O, G, Q;
|
|
2314
2339
|
return {
|
|
2315
2340
|
name: `control-${r}`,
|
|
2316
2341
|
attr: _ == null ? void 0 : _[r],
|
|
2317
2342
|
func: v,
|
|
2318
|
-
label: (
|
|
2343
|
+
label: (O = _ == null ? void 0 : _[r]) == null ? void 0 : O.label,
|
|
2319
2344
|
sort: ((G = _ == null ? void 0 : _[r]) == null ? void 0 : G.sort) || 0,
|
|
2320
2345
|
groupName: ((Q = _ == null ? void 0 : _[r]) == null ? void 0 : Q.groupName) || "default"
|
|
2321
2346
|
};
|
|
2322
|
-
}).sort((r, v) => r.sort - v.sort),
|
|
2323
|
-
const
|
|
2324
|
-
return r[
|
|
2347
|
+
}).sort((r, v) => r.sort - v.sort), A = (l) => i(l).reduce((r, v) => {
|
|
2348
|
+
const O = v.groupName || "default";
|
|
2349
|
+
return r[O] || (r[O] = []), r[O].push(v), r;
|
|
2325
2350
|
}, {}), H = Ye(() => Object.fromEntries(
|
|
2326
2351
|
Object.entries(e.value).filter(([l, r]) => r.type !== "hidden").filter(([l, r]) => r.visible !== !1).filter(([l, r]) => r.showCol !== !1).map(([l, r]) => (r.sort = typeof r.sort == "number" ? r.sort : 0, [l, r])).sort((l, r) => l[1].sort - r[1].sort)
|
|
2327
|
-
)), X = ye({}),
|
|
2328
|
-
const v = (
|
|
2329
|
-
for (const Q of
|
|
2352
|
+
)), X = ye({}), se = (l, r) => {
|
|
2353
|
+
const v = (O, G) => {
|
|
2354
|
+
for (const Q of O) {
|
|
2330
2355
|
if (Q.value == G) return Q.label;
|
|
2331
2356
|
if (Q.children) {
|
|
2332
|
-
const
|
|
2333
|
-
if (
|
|
2357
|
+
const le = v(Q.children, G);
|
|
2358
|
+
if (le) return le;
|
|
2334
2359
|
}
|
|
2335
2360
|
}
|
|
2336
2361
|
return null;
|
|
2337
2362
|
};
|
|
2338
2363
|
if (l.getDicts) {
|
|
2339
|
-
const
|
|
2340
|
-
return X.value[
|
|
2341
|
-
X.value[
|
|
2364
|
+
const O = r.toString();
|
|
2365
|
+
return X.value[O] ? (l.options = X.value[O], l.formatter || (l.formatter = (G, Q, le, Se) => l.options && v(l.options, le) || le), Promise.resolve()) : l.getDicts(e.value.table.data).then((G) => {
|
|
2366
|
+
X.value[O] = G, l.options = G, l.formatter || (l.formatter = (Q, le, Se, Pe) => l.options && v(l.options, Se) || Se);
|
|
2342
2367
|
});
|
|
2343
2368
|
}
|
|
2344
2369
|
return Promise.resolve();
|
|
2345
|
-
},
|
|
2370
|
+
}, ce = () => {
|
|
2346
2371
|
const l = [];
|
|
2347
2372
|
Object.keys(e.value).forEach((r) => {
|
|
2348
2373
|
if (e.value[r].getDicts) {
|
|
2349
|
-
const v =
|
|
2350
|
-
e.value.table.data.forEach((
|
|
2374
|
+
const v = se(e.value[r], r).then(() => {
|
|
2375
|
+
e.value.table.data.forEach((O) => {
|
|
2351
2376
|
var G;
|
|
2352
2377
|
if (e.value[r].getDicts && ((G = e.value[r]) == null ? void 0 : G.forceString) !== !1) {
|
|
2353
|
-
const Q =
|
|
2354
|
-
|
|
2378
|
+
const Q = O[r];
|
|
2379
|
+
O[r] = Q != null ? Q.toString() : Q;
|
|
2355
2380
|
}
|
|
2356
2381
|
});
|
|
2357
|
-
}).catch((
|
|
2358
|
-
console.error(`加载字典${r}出错:`,
|
|
2382
|
+
}).catch((O) => {
|
|
2383
|
+
console.error(`加载字典${r}出错:`, O);
|
|
2359
2384
|
});
|
|
2360
2385
|
l.push(v);
|
|
2361
2386
|
}
|
|
2362
2387
|
}), Promise.all(l).catch((r) => {
|
|
2363
2388
|
console.error("字典加载过程中发生错误:", r);
|
|
2364
2389
|
});
|
|
2365
|
-
}, he = (l, r, v,
|
|
2390
|
+
}, he = (l, r, v, O) => {
|
|
2366
2391
|
var G, Q;
|
|
2367
|
-
return l.table ? (G = l.table(r, v,
|
|
2392
|
+
return l.table ? (G = l.table(r, v, O)) != null && G.auth ? (Q = l.table(r, v, O)) == null ? void 0 : Q.auth(r, v, O) : !0 : !1;
|
|
2368
2393
|
}, ve = (l, r) => l.name === "control-save" && r === 0 && e.value.control.add.inline === !0 ? l.attr.addLabel : l.label;
|
|
2369
2394
|
return St(() => {
|
|
2370
2395
|
e.value.table.autoWatch && e.value.table.load();
|
|
@@ -2401,24 +2426,24 @@ const dl = {
|
|
|
2401
2426
|
e.value.table.autoWatch || e.value.table.load();
|
|
2402
2427
|
}), (l, r) => {
|
|
2403
2428
|
var ze, ut, st, it, dt;
|
|
2404
|
-
const v = L("el-button-group"),
|
|
2405
|
-
return n(),
|
|
2429
|
+
const v = L("el-button-group"), O = L("el-table-column"), G = L("el-table"), Q = L("el-pagination"), le = L("el-icon"), Se = L("el-dialog"), Pe = L("el-drawer");
|
|
2430
|
+
return n(), x(P, null, [
|
|
2406
2431
|
J("div", vl, [
|
|
2407
|
-
((ut = (ze = e.value) == null ? void 0 : ze.query) == null ? void 0 : ut.hidden) != !0 ? (n(),
|
|
2432
|
+
((ut = (ze = e.value) == null ? void 0 : ze.query) == null ? void 0 : ut.hidden) != !0 ? (n(), x("div", yl, [
|
|
2408
2433
|
p(l.$slots, "query", {}, () => [
|
|
2409
2434
|
Z(Jt, {
|
|
2410
2435
|
modelValue: e.value,
|
|
2411
2436
|
"onUpdate:modelValue": r[0] || (r[0] = (j) => e.value = j),
|
|
2412
2437
|
onQuery: m,
|
|
2413
2438
|
onReset: pe
|
|
2414
|
-
},
|
|
2439
|
+
}, fe({
|
|
2415
2440
|
"q-btns": y(() => [
|
|
2416
2441
|
p(l.$slots, "q-btns", {}, () => [
|
|
2417
|
-
(n(!0),
|
|
2418
|
-
|
|
2442
|
+
(n(!0), x(P, null, Y(A(["add", "download", "setting"]), (j, oe) => (n(), x(P, null, [
|
|
2443
|
+
oe == "default" ? (n(!0), x(P, { key: 0 }, Y(j, (k) => (n(), x(P, null, [
|
|
2419
2444
|
p(l.$slots, k.name + "-left", {}, void 0, !0),
|
|
2420
2445
|
(k.name === "control-add" ? k.attr.auth() && k.attr.inline === !1 : k.attr.auth()) ? p(l.$slots, k.name, { key: 0 }, () => [
|
|
2421
|
-
k.label ? (n(),
|
|
2446
|
+
k.label ? (n(), q(o(_e), S({
|
|
2422
2447
|
key: 0,
|
|
2423
2448
|
ref_for: !0
|
|
2424
2449
|
}, k.attr, {
|
|
@@ -2428,7 +2453,7 @@ const dl = {
|
|
|
2428
2453
|
we(Ee(k.label), 1)
|
|
2429
2454
|
]),
|
|
2430
2455
|
_: 2
|
|
2431
|
-
}, 1040, ["onClick"])) : (n(),
|
|
2456
|
+
}, 1040, ["onClick"])) : (n(), q(o(_e), S({
|
|
2432
2457
|
key: 1,
|
|
2433
2458
|
ref_for: !0
|
|
2434
2459
|
}, k.attr, {
|
|
@@ -2436,12 +2461,12 @@ const dl = {
|
|
|
2436
2461
|
}), null, 16, ["onClick"]))
|
|
2437
2462
|
], !0) : $e("", !0),
|
|
2438
2463
|
p(l.$slots, k.name + "-right", {}, void 0, !0)
|
|
2439
|
-
], 64))), 256)) : (n(),
|
|
2464
|
+
], 64))), 256)) : (n(), q(v, { key: 1 }, {
|
|
2440
2465
|
default: y(() => [
|
|
2441
|
-
(n(!0),
|
|
2466
|
+
(n(!0), x(P, null, Y(j, (k) => (n(), x(P, null, [
|
|
2442
2467
|
p(l.$slots, k.name + "-left", {}, void 0, !0),
|
|
2443
2468
|
(k.name === "control-add" ? k.attr.auth() && k.attr.inline === !1 : k.attr.auth()) ? p(l.$slots, k.name, { key: 0 }, () => [
|
|
2444
|
-
k.label ? (n(),
|
|
2469
|
+
k.label ? (n(), q(o(_e), S({
|
|
2445
2470
|
key: 0,
|
|
2446
2471
|
ref_for: !0
|
|
2447
2472
|
}, k.attr, {
|
|
@@ -2451,7 +2476,7 @@ const dl = {
|
|
|
2451
2476
|
we(Ee(k.label), 1)
|
|
2452
2477
|
]),
|
|
2453
2478
|
_: 2
|
|
2454
|
-
}, 1040, ["onClick"])) : (n(),
|
|
2479
|
+
}, 1040, ["onClick"])) : (n(), q(o(_e), S({
|
|
2455
2480
|
key: 1,
|
|
2456
2481
|
ref_for: !0
|
|
2457
2482
|
}, k.attr, {
|
|
@@ -2468,21 +2493,21 @@ const dl = {
|
|
|
2468
2493
|
]),
|
|
2469
2494
|
_: 2
|
|
2470
2495
|
}, [
|
|
2471
|
-
Y(l.$slots, (j,
|
|
2472
|
-
name:
|
|
2496
|
+
Y(l.$slots, (j, oe, k) => ({
|
|
2497
|
+
name: oe,
|
|
2473
2498
|
fn: y((W) => [
|
|
2474
|
-
p(l.$slots,
|
|
2499
|
+
p(l.$slots, oe, { model: e.value }, void 0, !0)
|
|
2475
2500
|
])
|
|
2476
2501
|
}))
|
|
2477
2502
|
]), 1032, ["modelValue"])
|
|
2478
2503
|
], !0)
|
|
2479
2504
|
])) : $e("", !0),
|
|
2480
2505
|
J("div", hl, [
|
|
2481
|
-
Z(G,
|
|
2506
|
+
Z(G, S({ ...l.$attrs, ...o(ke)(e.value.table, (j) => !["dblclickType", "page"].includes(j)) }, {
|
|
2482
2507
|
"summary-method": (j) => e.value.table["summary-method"](j, { fields: R.value, sums: te.value }),
|
|
2483
2508
|
onSortChange: r[1] || (r[1] = (j) => {
|
|
2484
|
-
var
|
|
2485
|
-
e.value.table.onSortChange(j, d.value), ((
|
|
2509
|
+
var oe, k;
|
|
2510
|
+
e.value.table.onSortChange(j, d.value), ((oe = j == null ? void 0 : j.column) == null ? void 0 : oe.sortable) === "custom" && ((k = e.value.table) == null || k.load());
|
|
2486
2511
|
})
|
|
2487
2512
|
}), {
|
|
2488
2513
|
append: y(() => [
|
|
@@ -2493,38 +2518,38 @@ const dl = {
|
|
|
2493
2518
|
]),
|
|
2494
2519
|
default: y(() => [
|
|
2495
2520
|
p(l.$slots, "default", {}, () => [
|
|
2496
|
-
(n(!0),
|
|
2497
|
-
prop:
|
|
2498
|
-
key:
|
|
2521
|
+
(n(!0), x(P, null, Y(H.value, (j, oe) => (n(), q(O, S({
|
|
2522
|
+
prop: oe,
|
|
2523
|
+
key: oe,
|
|
2499
2524
|
ref_for: !0
|
|
2500
|
-
}, { ...e.value.tableColumns, ...o(ke)(j, (k) =>
|
|
2525
|
+
}, { ...e.value.tableColumns, ...o(ke)(j, (k) => F.includes(k)) }, { "header-align": "center" }), fe({
|
|
2501
2526
|
header: y(({ column: k, $index: W }) => [
|
|
2502
|
-
|
|
2527
|
+
oe == "control" ? p(l.$slots, `${oe}-header`, {
|
|
2503
2528
|
key: 0,
|
|
2504
2529
|
column: k,
|
|
2505
2530
|
$index: W
|
|
2506
2531
|
}, () => [
|
|
2507
2532
|
r[10] || (r[10] = J("span", null, "操作", -1))
|
|
2508
|
-
], !0) : p(l.$slots, `${
|
|
2533
|
+
], !0) : p(l.$slots, `${oe}-header`, {
|
|
2509
2534
|
key: 1,
|
|
2510
2535
|
column: k,
|
|
2511
2536
|
$index: W
|
|
2512
2537
|
}, void 0, !0)
|
|
2513
2538
|
]),
|
|
2514
2539
|
"filter-icon": y((k) => [
|
|
2515
|
-
p(l.$slots, `${
|
|
2540
|
+
p(l.$slots, `${oe}-filter-icon`, { data: k }, void 0, !0)
|
|
2516
2541
|
]),
|
|
2517
2542
|
_: 2
|
|
2518
2543
|
}, [
|
|
2519
2544
|
j.type === "image" ? {
|
|
2520
2545
|
name: "default",
|
|
2521
|
-
fn: y(({ row: k, column: W, $index:
|
|
2522
|
-
p(l.$slots, `${
|
|
2546
|
+
fn: y(({ row: k, column: W, $index: re }) => [
|
|
2547
|
+
p(l.$slots, `${oe}`, {
|
|
2523
2548
|
row: k,
|
|
2524
2549
|
column: W,
|
|
2525
|
-
$index:
|
|
2550
|
+
$index: re
|
|
2526
2551
|
}, () => [
|
|
2527
|
-
J("img",
|
|
2552
|
+
J("img", S({
|
|
2528
2553
|
style: { width: "80px", height: "80px", "object-fit": "cover", "border-radius": "3px" },
|
|
2529
2554
|
src: j.value,
|
|
2530
2555
|
ref_for: !0
|
|
@@ -2534,17 +2559,17 @@ const dl = {
|
|
|
2534
2559
|
key: "0"
|
|
2535
2560
|
} : j.type === "expand" ? {
|
|
2536
2561
|
name: "default",
|
|
2537
|
-
fn: y(({ row: k, column: W, $index:
|
|
2538
|
-
p(l.$slots, `${
|
|
2562
|
+
fn: y(({ row: k, column: W, $index: re }) => [
|
|
2563
|
+
p(l.$slots, `${oe}`, {
|
|
2539
2564
|
row: k,
|
|
2540
2565
|
column: W,
|
|
2541
|
-
$index:
|
|
2566
|
+
$index: re
|
|
2542
2567
|
}, void 0, !0)
|
|
2543
2568
|
]),
|
|
2544
2569
|
key: "1"
|
|
2545
2570
|
} : j.type == "control" ? {
|
|
2546
2571
|
name: "default",
|
|
2547
|
-
fn: y(({ row: k, column: W, $index:
|
|
2572
|
+
fn: y(({ row: k, column: W, $index: re }) => {
|
|
2548
2573
|
var je, Le;
|
|
2549
2574
|
return [
|
|
2550
2575
|
J("div", {
|
|
@@ -2555,78 +2580,78 @@ const dl = {
|
|
|
2555
2580
|
p(l.$slots, "control-left", {
|
|
2556
2581
|
row: k,
|
|
2557
2582
|
column: W,
|
|
2558
|
-
$index:
|
|
2583
|
+
$index: re
|
|
2559
2584
|
}, void 0, !0),
|
|
2560
|
-
(n(!0),
|
|
2561
|
-
Je == "default" ? (n(!0),
|
|
2585
|
+
(n(!0), x(P, null, Y(A(["view", "edit", "delete", "save"]), (Re, Je) => (n(), x(P, null, [
|
|
2586
|
+
Je == "default" ? (n(!0), x(P, { key: 0 }, Y(Re, (ge) => (n(), x(P, null, [
|
|
2562
2587
|
p(l.$slots, ge.name + "-left", {
|
|
2563
2588
|
row: k,
|
|
2564
2589
|
column: W,
|
|
2565
|
-
$index:
|
|
2590
|
+
$index: re
|
|
2566
2591
|
}, void 0, !0),
|
|
2567
|
-
ge.attr.auth(k, W,
|
|
2592
|
+
ge.attr.auth(k, W, re) ? p(l.$slots, ge.name, {
|
|
2568
2593
|
key: 0,
|
|
2569
2594
|
row: k,
|
|
2570
2595
|
column: W,
|
|
2571
|
-
$index:
|
|
2596
|
+
$index: re
|
|
2572
2597
|
}, () => [
|
|
2573
|
-
ge.label ? (n(),
|
|
2598
|
+
ge.label ? (n(), q(o(_e), S({
|
|
2574
2599
|
key: 0,
|
|
2575
2600
|
ref_for: !0
|
|
2576
2601
|
}, ge.attr, {
|
|
2577
|
-
onClick: (Ze) => ge.func(k, W,
|
|
2602
|
+
onClick: (Ze) => ge.func(k, W, re, e.value)
|
|
2578
2603
|
}), {
|
|
2579
2604
|
default: y(() => [
|
|
2580
|
-
we(Ee(ve(ge,
|
|
2605
|
+
we(Ee(ve(ge, re)), 1)
|
|
2581
2606
|
]),
|
|
2582
2607
|
_: 2
|
|
2583
|
-
}, 1040, ["onClick"])) : (n(),
|
|
2608
|
+
}, 1040, ["onClick"])) : (n(), q(o(_e), S({
|
|
2584
2609
|
key: 1,
|
|
2585
2610
|
ref_for: !0
|
|
2586
2611
|
}, ge.attr, {
|
|
2587
|
-
onClick: (Ze) => ge.func(k, W,
|
|
2612
|
+
onClick: (Ze) => ge.func(k, W, re, e.value)
|
|
2588
2613
|
}), null, 16, ["onClick"]))
|
|
2589
2614
|
], !0) : $e("", !0),
|
|
2590
2615
|
p(l.$slots, ge.name + "-right", {
|
|
2591
2616
|
row: k,
|
|
2592
2617
|
column: W,
|
|
2593
|
-
$index:
|
|
2618
|
+
$index: re
|
|
2594
2619
|
}, void 0, !0)
|
|
2595
|
-
], 64))), 256)) : (n(),
|
|
2620
|
+
], 64))), 256)) : (n(), q(v, { key: 1 }, {
|
|
2596
2621
|
default: y(() => [
|
|
2597
|
-
(n(!0),
|
|
2622
|
+
(n(!0), x(P, null, Y(Re, (ge) => (n(), x(P, null, [
|
|
2598
2623
|
p(l.$slots, ge.name + "-left", {
|
|
2599
2624
|
row: k,
|
|
2600
2625
|
column: W,
|
|
2601
|
-
$index:
|
|
2626
|
+
$index: re
|
|
2602
2627
|
}, void 0, !0),
|
|
2603
|
-
ge.attr.auth(k, W,
|
|
2628
|
+
ge.attr.auth(k, W, re) ? p(l.$slots, ge.name, {
|
|
2604
2629
|
key: 0,
|
|
2605
2630
|
row: k,
|
|
2606
2631
|
column: W,
|
|
2607
|
-
$index:
|
|
2632
|
+
$index: re
|
|
2608
2633
|
}, () => [
|
|
2609
|
-
ge.label ? (n(),
|
|
2634
|
+
ge.label ? (n(), q(o(_e), S({
|
|
2610
2635
|
key: 0,
|
|
2611
2636
|
ref_for: !0
|
|
2612
2637
|
}, ge.attr, {
|
|
2613
|
-
onClick: (Ze) => ge.func(k, W,
|
|
2638
|
+
onClick: (Ze) => ge.func(k, W, re, e.value)
|
|
2614
2639
|
}), {
|
|
2615
2640
|
default: y(() => [
|
|
2616
|
-
we(Ee(ve(ge,
|
|
2641
|
+
we(Ee(ve(ge, re)), 1)
|
|
2617
2642
|
]),
|
|
2618
2643
|
_: 2
|
|
2619
|
-
}, 1040, ["onClick"])) : (n(),
|
|
2644
|
+
}, 1040, ["onClick"])) : (n(), q(o(_e), S({
|
|
2620
2645
|
key: 1,
|
|
2621
2646
|
ref_for: !0
|
|
2622
2647
|
}, ge.attr, {
|
|
2623
|
-
onClick: (Ze) => ge.func(k, W,
|
|
2648
|
+
onClick: (Ze) => ge.func(k, W, re, e.value)
|
|
2624
2649
|
}), null, 16, ["onClick"]))
|
|
2625
2650
|
], !0) : $e("", !0),
|
|
2626
2651
|
p(l.$slots, ge.name + "-right", {
|
|
2627
2652
|
row: k,
|
|
2628
2653
|
column: W,
|
|
2629
|
-
$index:
|
|
2654
|
+
$index: re
|
|
2630
2655
|
}, void 0, !0)
|
|
2631
2656
|
], 64))), 256))
|
|
2632
2657
|
]),
|
|
@@ -2636,7 +2661,7 @@ const dl = {
|
|
|
2636
2661
|
p(l.$slots, "control-right", {
|
|
2637
2662
|
row: k,
|
|
2638
2663
|
column: W,
|
|
2639
|
-
$index:
|
|
2664
|
+
$index: re
|
|
2640
2665
|
}, void 0, !0)
|
|
2641
2666
|
], !0)
|
|
2642
2667
|
], 6)
|
|
@@ -2645,27 +2670,27 @@ const dl = {
|
|
|
2645
2670
|
key: "2"
|
|
2646
2671
|
} : j.type != "selection" && j.type != "index" ? {
|
|
2647
2672
|
name: "default",
|
|
2648
|
-
fn: y(({ row: k, column: W, $index:
|
|
2649
|
-
he(j, k, W,
|
|
2673
|
+
fn: y(({ row: k, column: W, $index: re }) => [
|
|
2674
|
+
he(j, k, W, re) && re != -1 ? p(l.$slots, `${oe}`, {
|
|
2650
2675
|
key: 0,
|
|
2651
2676
|
row: k,
|
|
2652
2677
|
column: W,
|
|
2653
|
-
$index:
|
|
2678
|
+
$index: re
|
|
2654
2679
|
}, () => {
|
|
2655
2680
|
var je;
|
|
2656
2681
|
return [
|
|
2657
|
-
(n(),
|
|
2658
|
-
modelValue: k[
|
|
2659
|
-
"onUpdate:modelValue": (Le) => k[
|
|
2660
|
-
item: j == null ? void 0 : j.table(k, W,
|
|
2661
|
-
ctrlKey:
|
|
2662
|
-
key:
|
|
2663
|
-
ctrlType: (je = j.table(k, W,
|
|
2682
|
+
(n(), q(Xe, {
|
|
2683
|
+
modelValue: k[oe],
|
|
2684
|
+
"onUpdate:modelValue": (Le) => k[oe] = Le,
|
|
2685
|
+
item: j == null ? void 0 : j.table(k, W, re),
|
|
2686
|
+
ctrlKey: oe,
|
|
2687
|
+
key: oe + "-" + re,
|
|
2688
|
+
ctrlType: (je = j.table(k, W, re)) != null && je.type ? j.table(k, W, re).type : j.type,
|
|
2664
2689
|
model: e.value,
|
|
2665
2690
|
class: "g-ctrl-container",
|
|
2666
2691
|
t: "t",
|
|
2667
2692
|
formInfo: k
|
|
2668
|
-
},
|
|
2693
|
+
}, fe({ _: 2 }, [
|
|
2669
2694
|
Y(l.$slots, (Le, Re) => ({
|
|
2670
2695
|
name: Re,
|
|
2671
2696
|
fn: y((Je) => [
|
|
@@ -2678,14 +2703,14 @@ const dl = {
|
|
|
2678
2703
|
}))
|
|
2679
2704
|
]), 1032, ["modelValue", "onUpdate:modelValue", "item", "ctrlKey", "ctrlType", "model", "formInfo"]))
|
|
2680
2705
|
];
|
|
2681
|
-
}, !0) : p(l.$slots, `${
|
|
2706
|
+
}, !0) : p(l.$slots, `${oe}`, {
|
|
2682
2707
|
key: 1,
|
|
2683
2708
|
row: k,
|
|
2684
2709
|
column: W,
|
|
2685
|
-
$index:
|
|
2710
|
+
$index: re
|
|
2686
2711
|
}, () => [
|
|
2687
2712
|
J("div", {
|
|
2688
|
-
innerHTML:
|
|
2713
|
+
innerHTML: me(j, W.formatter(k, W, k[oe], re))
|
|
2689
2714
|
}, null, 8, bl)
|
|
2690
2715
|
], !0)
|
|
2691
2716
|
]),
|
|
@@ -2697,7 +2722,7 @@ const dl = {
|
|
|
2697
2722
|
_: 3
|
|
2698
2723
|
}, 16, ["summary-method"]),
|
|
2699
2724
|
(dt = (it = (st = e.value) == null ? void 0 : st.table) == null ? void 0 : it.page) != null && dt.hidden ? $e("", !0) : p(l.$slots, "page", { key: 0 }, () => [
|
|
2700
|
-
Z(Q,
|
|
2725
|
+
Z(Q, S({
|
|
2701
2726
|
"page-size": e.value.table.page.pageSize,
|
|
2702
2727
|
"onUpdate:pageSize": r[2] || (r[2] = (j) => e.value.table.page.pageSize = j),
|
|
2703
2728
|
"current-page": e.value.table.page.currentPage,
|
|
@@ -2711,8 +2736,8 @@ const dl = {
|
|
|
2711
2736
|
], !0)
|
|
2712
2737
|
])
|
|
2713
2738
|
]),
|
|
2714
|
-
e.value.dialog.mode == "dialog" && T.value ? (n(),
|
|
2715
|
-
Z(Se,
|
|
2739
|
+
e.value.dialog.mode == "dialog" && T.value ? (n(), x("div", $l, [
|
|
2740
|
+
Z(Se, S({
|
|
2716
2741
|
modelValue: T.value,
|
|
2717
2742
|
"onUpdate:modelValue": r[7] || (r[7] = (j) => T.value = j),
|
|
2718
2743
|
fullscreen: e.value.dialog.fullScreen
|
|
@@ -2720,7 +2745,7 @@ const dl = {
|
|
|
2720
2745
|
width: o(wt)(e.value.dialog.width) + 35
|
|
2721
2746
|
}), {
|
|
2722
2747
|
header: y(() => {
|
|
2723
|
-
var j,
|
|
2748
|
+
var j, oe, k, W;
|
|
2724
2749
|
return [
|
|
2725
2750
|
J("div", El, [
|
|
2726
2751
|
J("div", wl, [
|
|
@@ -2728,28 +2753,28 @@ const dl = {
|
|
|
2728
2753
|
J("div", null, Ee(e.value.dialog.title), 1)
|
|
2729
2754
|
], !0)
|
|
2730
2755
|
]),
|
|
2731
|
-
((
|
|
2756
|
+
((oe = (j = e.value) == null ? void 0 : j.dialog) == null ? void 0 : oe.fullScreen) === !1 ? (n(), x("div", {
|
|
2732
2757
|
key: 0,
|
|
2733
|
-
onClick: r[4] || (r[4] = (
|
|
2758
|
+
onClick: r[4] || (r[4] = (re) => {
|
|
2734
2759
|
e.value.dialog.fullScreen = !0;
|
|
2735
2760
|
}),
|
|
2736
2761
|
class: "max"
|
|
2737
2762
|
}, [
|
|
2738
|
-
Z(
|
|
2763
|
+
Z(le, null, {
|
|
2739
2764
|
default: y(() => [
|
|
2740
2765
|
Z(o(Ot))
|
|
2741
2766
|
]),
|
|
2742
2767
|
_: 1
|
|
2743
2768
|
})
|
|
2744
2769
|
])) : $e("", !0),
|
|
2745
|
-
((W = (k = e.value) == null ? void 0 : k.dialog) == null ? void 0 : W.fullScreen) === !0 ? (n(),
|
|
2770
|
+
((W = (k = e.value) == null ? void 0 : k.dialog) == null ? void 0 : W.fullScreen) === !0 ? (n(), x("div", {
|
|
2746
2771
|
key: 1,
|
|
2747
|
-
onClick: r[5] || (r[5] = (
|
|
2772
|
+
onClick: r[5] || (r[5] = (re) => {
|
|
2748
2773
|
e.value.dialog.fullScreen = !1;
|
|
2749
2774
|
}),
|
|
2750
2775
|
class: "max"
|
|
2751
2776
|
}, [
|
|
2752
|
-
Z(
|
|
2777
|
+
Z(le, null, {
|
|
2753
2778
|
default: y(() => [
|
|
2754
2779
|
Z(o(At))
|
|
2755
2780
|
]),
|
|
@@ -2765,13 +2790,13 @@ const dl = {
|
|
|
2765
2790
|
Z(tt, {
|
|
2766
2791
|
modelValue: e.value,
|
|
2767
2792
|
"onUpdate:modelValue": r[6] || (r[6] = (j) => e.value = j),
|
|
2768
|
-
onSubmit:
|
|
2769
|
-
onReset:
|
|
2770
|
-
},
|
|
2771
|
-
Y(l.$slots, (j,
|
|
2772
|
-
name:
|
|
2793
|
+
onSubmit: ne,
|
|
2794
|
+
onReset: B
|
|
2795
|
+
}, fe({ _: 2 }, [
|
|
2796
|
+
Y(l.$slots, (j, oe, k) => ({
|
|
2797
|
+
name: oe,
|
|
2773
2798
|
fn: y((W) => [
|
|
2774
|
-
p(l.$slots,
|
|
2799
|
+
p(l.$slots, oe, { model: W }, void 0, !0)
|
|
2775
2800
|
])
|
|
2776
2801
|
}))
|
|
2777
2802
|
]), 1032, ["modelValue"])
|
|
@@ -2781,8 +2806,8 @@ const dl = {
|
|
|
2781
2806
|
_: 3
|
|
2782
2807
|
}, 16, ["modelValue", "fullscreen", "width"])
|
|
2783
2808
|
])) : $e("", !0),
|
|
2784
|
-
e.value.dialog.mode == "drawer" && T.value ? (n(),
|
|
2785
|
-
Z(Pe,
|
|
2809
|
+
e.value.dialog.mode == "drawer" && T.value ? (n(), x("div", kl, [
|
|
2810
|
+
Z(Pe, S({
|
|
2786
2811
|
modelValue: T.value,
|
|
2787
2812
|
"onUpdate:modelValue": r[9] || (r[9] = (j) => T.value = j)
|
|
2788
2813
|
}, o(ke)(e.value.dialog, (j) => !["width"].includes(j))), {
|
|
@@ -2800,13 +2825,13 @@ const dl = {
|
|
|
2800
2825
|
Z(tt, {
|
|
2801
2826
|
modelValue: e.value,
|
|
2802
2827
|
"onUpdate:modelValue": r[8] || (r[8] = (j) => e.value = j),
|
|
2803
|
-
onSubmit:
|
|
2804
|
-
onReset:
|
|
2805
|
-
},
|
|
2806
|
-
Y(l.$slots, (j,
|
|
2807
|
-
name:
|
|
2828
|
+
onSubmit: ne,
|
|
2829
|
+
onReset: B
|
|
2830
|
+
}, fe({ _: 2 }, [
|
|
2831
|
+
Y(l.$slots, (j, oe, k) => ({
|
|
2832
|
+
name: oe,
|
|
2808
2833
|
fn: y((W) => [
|
|
2809
|
-
p(l.$slots,
|
|
2834
|
+
p(l.$slots, oe, { model: W }, void 0, !0)
|
|
2810
2835
|
])
|
|
2811
2836
|
}))
|
|
2812
2837
|
]), 1032, ["modelValue"])
|
|
@@ -2818,7 +2843,7 @@ const dl = {
|
|
|
2818
2843
|
], 64);
|
|
2819
2844
|
};
|
|
2820
2845
|
}
|
|
2821
|
-
}),
|
|
2846
|
+
}), Ml = /* @__PURE__ */ Ue(Vl, [["__scopeId", "data-v-66a3cf08"]]), Tl = { class: "g-tree-table" }, Fl = { class: "g-tree-container" }, Sl = { class: "g-tree-table-container" }, ql = /* @__PURE__ */ Object.assign({
|
|
2822
2847
|
name: "g-tree-table",
|
|
2823
2848
|
inheritAttrs: !1
|
|
2824
2849
|
}, {
|
|
@@ -2829,70 +2854,70 @@ const dl = {
|
|
|
2829
2854
|
},
|
|
2830
2855
|
emits: /* @__PURE__ */ Be(["load"], ["update:modelValue"]),
|
|
2831
2856
|
setup(f, { emit: c }) {
|
|
2832
|
-
const t = c, e = Ie(f, "modelValue"), a = nt(), d = ye((a == null ? void 0 : a.width) || "180px"), U = ye((a == null ? void 0 : a.search) === void 0 ? !0 : a == null ? void 0 : a.search), T = ye({}),
|
|
2833
|
-
var w,
|
|
2857
|
+
const t = c, e = Ie(f, "modelValue"), a = nt(), d = ye((a == null ? void 0 : a.width) || "180px"), U = ye((a == null ? void 0 : a.search) === void 0 ? !0 : a == null ? void 0 : a.search), T = ye({}), F = ye(""), E = ye(null), D = (R, V) => {
|
|
2858
|
+
var w, ae;
|
|
2834
2859
|
if (!R) return !0;
|
|
2835
|
-
const b = ((
|
|
2836
|
-
return
|
|
2837
|
-
}, z = (R,
|
|
2838
|
-
t("load", T.value, R,
|
|
2860
|
+
const b = ((ae = (w = a.tree) == null ? void 0 : w.props) == null ? void 0 : ae.label) || "label";
|
|
2861
|
+
return V[b].includes(R);
|
|
2862
|
+
}, z = (R, V) => {
|
|
2863
|
+
t("load", T.value, R, V);
|
|
2839
2864
|
}, te = (R) => {
|
|
2840
2865
|
T.value = R, e.value.table.load();
|
|
2841
2866
|
};
|
|
2842
|
-
return qt(
|
|
2867
|
+
return qt(F, (R) => {
|
|
2843
2868
|
E.value.filter(R);
|
|
2844
|
-
}), (R,
|
|
2845
|
-
const b = L("el-input"), w = L("el-tree"),
|
|
2846
|
-
return n(),
|
|
2869
|
+
}), (R, V) => {
|
|
2870
|
+
const b = L("el-input"), w = L("el-tree"), ae = L("g-table");
|
|
2871
|
+
return n(), x("div", Tl, [
|
|
2847
2872
|
J("div", {
|
|
2848
2873
|
class: "g-tree-left",
|
|
2849
2874
|
style: Oe({ width: d.value })
|
|
2850
2875
|
}, [
|
|
2851
|
-
U.value ? (n(),
|
|
2876
|
+
U.value ? (n(), q(b, {
|
|
2852
2877
|
key: 0,
|
|
2853
|
-
modelValue:
|
|
2854
|
-
"onUpdate:modelValue":
|
|
2878
|
+
modelValue: F.value,
|
|
2879
|
+
"onUpdate:modelValue": V[0] || (V[0] = (K) => F.value = K),
|
|
2855
2880
|
style: { width: "100%", padding: "0 10px", "box-sizing": "border-box" },
|
|
2856
2881
|
placeholder: "输入节点查询",
|
|
2857
2882
|
clearable: ""
|
|
2858
2883
|
}, null, 8, ["modelValue"])) : $e("", !0),
|
|
2859
2884
|
J("div", Fl, [
|
|
2860
|
-
Z(w,
|
|
2885
|
+
Z(w, S({
|
|
2861
2886
|
style: { width: d.value },
|
|
2862
2887
|
"filter-node-method": D,
|
|
2863
2888
|
"expand-on-click-node": !1,
|
|
2864
2889
|
ref_key: "treeRef",
|
|
2865
2890
|
ref: E,
|
|
2866
2891
|
onNodeClick: te
|
|
2867
|
-
}, R.$attrs.tree),
|
|
2868
|
-
default: y(({ node: K, data:
|
|
2892
|
+
}, R.$attrs.tree), fe({
|
|
2893
|
+
default: y(({ node: K, data: ue }) => [
|
|
2869
2894
|
p(R.$slots, "tree", {
|
|
2870
2895
|
node: K,
|
|
2871
|
-
data:
|
|
2896
|
+
data: ue
|
|
2872
2897
|
}, () => [
|
|
2873
2898
|
J("span", null, Ee(K.label), 1)
|
|
2874
2899
|
], !0)
|
|
2875
2900
|
]),
|
|
2876
2901
|
_: 2
|
|
2877
2902
|
}, [
|
|
2878
|
-
Y(R.$slots, (K,
|
|
2879
|
-
name:
|
|
2880
|
-
fn: y((
|
|
2881
|
-
p(R.$slots,
|
|
2903
|
+
Y(R.$slots, (K, ue, de) => ({
|
|
2904
|
+
name: ue,
|
|
2905
|
+
fn: y((me) => [
|
|
2906
|
+
p(R.$slots, ue, { data: me }, void 0, !0)
|
|
2882
2907
|
])
|
|
2883
2908
|
}))
|
|
2884
2909
|
]), 1040, ["style"])
|
|
2885
2910
|
])
|
|
2886
2911
|
], 4),
|
|
2887
2912
|
J("div", Sl, [
|
|
2888
|
-
Z(
|
|
2913
|
+
Z(ae, S({
|
|
2889
2914
|
modelValue: e.value,
|
|
2890
|
-
"onUpdate:modelValue":
|
|
2891
|
-
}, R.$attrs, { onLoad: z }),
|
|
2892
|
-
Y(R.$slots, (K,
|
|
2893
|
-
name:
|
|
2894
|
-
fn: y((
|
|
2895
|
-
p(R.$slots,
|
|
2915
|
+
"onUpdate:modelValue": V[1] || (V[1] = (K) => e.value = K)
|
|
2916
|
+
}, R.$attrs, { onLoad: z }), fe({ _: 2 }, [
|
|
2917
|
+
Y(R.$slots, (K, ue, de) => ({
|
|
2918
|
+
name: ue,
|
|
2919
|
+
fn: y((me) => [
|
|
2920
|
+
p(R.$slots, ue, { data: me }, void 0, !0)
|
|
2896
2921
|
])
|
|
2897
2922
|
}))
|
|
2898
2923
|
]), 1040, ["modelValue"])
|
|
@@ -2928,8 +2953,8 @@ const dl = {
|
|
|
2928
2953
|
},
|
|
2929
2954
|
setup(f) {
|
|
2930
2955
|
const c = f;
|
|
2931
|
-
return (t, e) => c.title ? (n(),
|
|
2932
|
-
(n(!0),
|
|
2956
|
+
return (t, e) => c.title ? (n(), x("div", Ol, [
|
|
2957
|
+
(n(!0), x(P, null, Y(c.columns, (a) => (n(), x("span", {
|
|
2933
2958
|
style: Oe({ width: (a == null ? void 0 : a.width) || pt, ...a == null ? void 0 : a.titleStyle, textAlign: (a == null ? void 0 : a.align) || "center" }),
|
|
2934
2959
|
key: a.key
|
|
2935
2960
|
}, [
|
|
@@ -2937,8 +2962,8 @@ const dl = {
|
|
|
2937
2962
|
we(Ee(a.label), 1)
|
|
2938
2963
|
], !0)
|
|
2939
2964
|
], 4))), 128))
|
|
2940
|
-
])) : (n(),
|
|
2941
|
-
(n(!0),
|
|
2965
|
+
])) : (n(), x("div", Al, [
|
|
2966
|
+
(n(!0), x(P, null, Y(c.columns, (a) => (n(), x("span", {
|
|
2942
2967
|
style: Oe({ width: (a == null ? void 0 : a.width) || pt, textAlign: (a == null ? void 0 : a.align) || "center", ...a == null ? void 0 : a.style }),
|
|
2943
2968
|
key: a.key,
|
|
2944
2969
|
title: f.data[a.key]
|
|
@@ -2949,7 +2974,7 @@ const dl = {
|
|
|
2949
2974
|
], 12, Bl))), 128))
|
|
2950
2975
|
]));
|
|
2951
2976
|
}
|
|
2952
|
-
}), Yl = /* @__PURE__ */ Ue(Il, [["__scopeId", "data-v-ba0fcda6"]]), Ul = Object.freeze({}), Et = [
|
|
2977
|
+
}), Yl = /* @__PURE__ */ Ue(Il, [["__scopeId", "data-v-ba0fcda6"]]), Ul = Object.freeze({}), Et = [Ml, tt, xl, Yl];
|
|
2953
2978
|
let lt = {};
|
|
2954
2979
|
const Gl = {
|
|
2955
2980
|
install: (f, c = {}) => {
|
|
@@ -2973,7 +2998,7 @@ const Gl = {
|
|
|
2973
2998
|
U.unmount(), t.remove();
|
|
2974
2999
|
}, 300);
|
|
2975
3000
|
}, () => {
|
|
2976
|
-
var T,
|
|
3001
|
+
var T, F, E;
|
|
2977
3002
|
return qe(a, {
|
|
2978
3003
|
modelValue: d.value,
|
|
2979
3004
|
"onUpdate:modelValue": (D) => d.value = D,
|
|
@@ -2982,7 +3007,7 @@ const Gl = {
|
|
|
2982
3007
|
destroyOnClose: !0
|
|
2983
3008
|
}, {
|
|
2984
3009
|
default: (T = f.slots) == null ? void 0 : T.default,
|
|
2985
|
-
header: (
|
|
3010
|
+
header: (F = f.slots) == null ? void 0 : F.header,
|
|
2986
3011
|
footer: (E = f.slots) == null ? void 0 : E.footer
|
|
2987
3012
|
});
|
|
2988
3013
|
};
|
|
@@ -3014,11 +3039,11 @@ function wt(f, c = window.innerWidth) {
|
|
|
3014
3039
|
throw new Error("Invalid calc expression");
|
|
3015
3040
|
};
|
|
3016
3041
|
const a = f.slice(5, -1).trim();
|
|
3017
|
-
return d(a.replace(/([0-9.]+)([a-z%]+)/g, (T,
|
|
3042
|
+
return d(a.replace(/([0-9.]+)([a-z%]+)/g, (T, F, E) => wt(F + E, c)));
|
|
3018
3043
|
}
|
|
3019
3044
|
throw new Error("Unsupported unit in value: " + f);
|
|
3020
3045
|
}
|
|
3021
|
-
const
|
|
3046
|
+
const Me = (...f) => {
|
|
3022
3047
|
const c = {}, t = (e, a) => (Object.keys(a).forEach((d) => {
|
|
3023
3048
|
e[d] = typeof a[d] == "object" && !Array.isArray(a[d]) ? t(e[d] || {}, a[d]) : a[d];
|
|
3024
3049
|
}), e);
|
|
@@ -3055,8 +3080,8 @@ function rt(f) {
|
|
|
3055
3080
|
d = d || "整", f = Math.floor(f);
|
|
3056
3081
|
for (let U = 0; U < e[0].length && f > 0; U++) {
|
|
3057
3082
|
let T = "";
|
|
3058
|
-
for (let
|
|
3059
|
-
T = t[f % 10] + e[1][
|
|
3083
|
+
for (let F = 0; F < e[1].length && f > 0; F++)
|
|
3084
|
+
T = t[f % 10] + e[1][F] + T, f = Math.floor(f / 10);
|
|
3060
3085
|
d = T.replace(/(零.)*零$/, "").replace(/^$/, "零") + e[0][U] + d;
|
|
3061
3086
|
}
|
|
3062
3087
|
return a + d.replace(/(零.)*零元/, "元").replace(/(零.)+/g, "零").replace(/^整$/, "零元整");
|
|
@@ -3103,7 +3128,7 @@ export {
|
|
|
3103
3128
|
ke as filterObject,
|
|
3104
3129
|
Ll as findTreeLabelByValue,
|
|
3105
3130
|
Rl as formatAmount,
|
|
3106
|
-
|
|
3131
|
+
Me as mergeObjects,
|
|
3107
3132
|
rt as moneyToChinese,
|
|
3108
3133
|
ot as openModal
|
|
3109
3134
|
};
|