vue-2024-ui 0.0.78 → 0.0.80
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 +1480 -1455
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { mergeModels as
|
|
1
|
+
import _t, { ElForm as ze, ElButtonGroup as Ge, ElButton as _e, ElPopover as Ke, ElMessage as Fe, ElMessageBox as vt, ElDialog as kt, ElDrawer as Ct } from "element-plus";
|
|
2
|
+
import { mergeModels as Be, useModel as Ie, ref as ve, nextTick as ht, onMounted as Ne, resolveComponent as R, openBlock as n, createElementBlock as q, unref as o, createBlock as O, mergeProps as S, withCtx as h, renderSlot as p, Fragment as G, renderList as j, createTextVNode as we, toDisplayString as Ee, createSlots as ce, createVNode as X, createCommentVNode as be, normalizeProps as Qe, createElementVNode as Z, useSlots as yt, inject as rt, useAttrs as nt, onUnmounted as Dt, computed as Ye, normalizeStyle as Ae, withModifiers as ct, guardReactiveProps as ft, resolveDynamicComponent as xe, Transition as Vt, withDirectives as Mt, vShow as Ft, h as qe, onBeforeUnmount as Tt, normalizeClass as gt, watchEffect as St, watch as qt, createApp as Ot } from "vue";
|
|
3
3
|
import { FullScreen as At, Remove as xt } from "@element-plus/icons-vue";
|
|
4
4
|
import bt from "sortablejs";
|
|
5
5
|
import { Dexie as Bt } from "dexie";
|
|
@@ -180,401 +180,428 @@ var It = {
|
|
|
180
180
|
indicator: "幻灯片切换至索引 {index}"
|
|
181
181
|
}
|
|
182
182
|
}
|
|
183
|
-
},
|
|
184
|
-
function
|
|
183
|
+
}, Yt = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
184
|
+
function Ut(f) {
|
|
185
185
|
return f && f.__esModule && Object.prototype.hasOwnProperty.call(f, "default") ? f.default : f;
|
|
186
186
|
}
|
|
187
187
|
var $t = { exports: {} };
|
|
188
188
|
(function(f, c) {
|
|
189
189
|
(function(t, e) {
|
|
190
190
|
f.exports = e();
|
|
191
|
-
})(
|
|
192
|
-
var t = 1e3, e = 6e4,
|
|
193
|
-
var
|
|
194
|
-
return "[" +
|
|
195
|
-
} },
|
|
196
|
-
var _ = String(
|
|
197
|
-
return !_ || _.length >=
|
|
198
|
-
},
|
|
199
|
-
var
|
|
200
|
-
return (
|
|
201
|
-
}, m: function
|
|
202
|
-
if (
|
|
203
|
-
var _ = 12 * (
|
|
204
|
-
return +(-(_ + (
|
|
205
|
-
}, a: function(
|
|
206
|
-
return
|
|
207
|
-
}, p: function(
|
|
208
|
-
return { M:
|
|
209
|
-
}, u: function(
|
|
210
|
-
return
|
|
211
|
-
} }, fe = "en",
|
|
212
|
-
|
|
213
|
-
var
|
|
214
|
-
return
|
|
215
|
-
},
|
|
216
|
-
var
|
|
217
|
-
if (
|
|
218
|
-
if (typeof
|
|
219
|
-
var
|
|
220
|
-
|
|
221
|
-
var
|
|
222
|
-
if (!
|
|
191
|
+
})(Yt, function() {
|
|
192
|
+
var t = 1e3, e = 6e4, r = 36e5, d = "millisecond", Y = "second", F = "minute", T = "hour", E = "day", D = "week", N = "month", te = "quarter", L = "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(x) {
|
|
193
|
+
var $ = ["th", "st", "nd", "rd"], g = x % 100;
|
|
194
|
+
return "[" + x + ($[(g - 20) % 10] || $[g] || $[0]) + "]";
|
|
195
|
+
} }, ne = function(x, $, g) {
|
|
196
|
+
var _ = String(x);
|
|
197
|
+
return !_ || _.length >= $ ? x : "" + Array($ + 1 - _.length).join(g) + x;
|
|
198
|
+
}, ie = { s: ne, z: function(x) {
|
|
199
|
+
var $ = -x.utcOffset(), g = Math.abs($), _ = Math.floor(g / 60), s = g % 60;
|
|
200
|
+
return ($ <= 0 ? "+" : "-") + ne(_, 2, "0") + ":" + ne(s, 2, "0");
|
|
201
|
+
}, m: function x($, g) {
|
|
202
|
+
if ($.date() < g.date()) return -x(g, $);
|
|
203
|
+
var _ = 12 * (g.year() - $.year()) + (g.month() - $.month()), s = $.clone().add(_, N), i = g - s < 0, A = $.clone().add(_ + (i ? -1 : 1), N);
|
|
204
|
+
return +(-(_ + (g - s) / (i ? s - A : A - s)) || 0);
|
|
205
|
+
}, a: function(x) {
|
|
206
|
+
return x < 0 ? Math.ceil(x) || 0 : Math.floor(x);
|
|
207
|
+
}, p: function(x) {
|
|
208
|
+
return { M: N, y: L, w: D, d: E, D: V, h: T, m: F, s: Y, ms: d, Q: te }[x] || String(x || "").toLowerCase().replace(/s$/, "");
|
|
209
|
+
}, u: function(x) {
|
|
210
|
+
return x === void 0;
|
|
211
|
+
} }, fe = "en", pe = {};
|
|
212
|
+
pe[fe] = K;
|
|
213
|
+
var m = "$isDayjsObject", M = function(x) {
|
|
214
|
+
return x instanceof ee || !(!x || !x[m]);
|
|
215
|
+
}, C = function x($, g, _) {
|
|
216
|
+
var s;
|
|
217
|
+
if (!$) return fe;
|
|
218
|
+
if (typeof $ == "string") {
|
|
219
|
+
var i = $.toLowerCase();
|
|
220
|
+
pe[i] && (s = i), g && (pe[i] = g, s = i);
|
|
221
|
+
var A = $.split("-");
|
|
222
|
+
if (!s && A.length > 1) return x(A[0]);
|
|
223
223
|
} else {
|
|
224
|
-
var
|
|
225
|
-
|
|
224
|
+
var H = $.name;
|
|
225
|
+
pe[H] = $, s = H;
|
|
226
226
|
}
|
|
227
|
-
return !_ &&
|
|
228
|
-
},
|
|
229
|
-
if (
|
|
230
|
-
var
|
|
231
|
-
return
|
|
232
|
-
},
|
|
233
|
-
|
|
234
|
-
return
|
|
227
|
+
return !_ && s && (fe = s), s || !_ && fe;
|
|
228
|
+
}, y = function(x, $) {
|
|
229
|
+
if (M(x)) return x.clone();
|
|
230
|
+
var g = typeof $ == "object" ? $ : {};
|
|
231
|
+
return g.date = x, g.args = arguments, new ee(g);
|
|
232
|
+
}, I = ie;
|
|
233
|
+
I.l = C, I.i = M, I.w = function(x, $) {
|
|
234
|
+
return y(x, { locale: $.$L, utc: $.$u, x: $.$x, $offset: $.$offset });
|
|
235
235
|
};
|
|
236
|
-
var
|
|
237
|
-
function
|
|
238
|
-
this.$L =
|
|
236
|
+
var ee = function() {
|
|
237
|
+
function x(g) {
|
|
238
|
+
this.$L = C(g.locale, null, !0), this.parse(g), this.$x = this.$x || g.x || {}, this[m] = !0;
|
|
239
239
|
}
|
|
240
|
-
var
|
|
241
|
-
return
|
|
240
|
+
var $ = x.prototype;
|
|
241
|
+
return $.parse = function(g) {
|
|
242
242
|
this.$d = function(_) {
|
|
243
|
-
var
|
|
244
|
-
if (
|
|
245
|
-
if (
|
|
246
|
-
if (
|
|
247
|
-
if (typeof
|
|
248
|
-
var
|
|
249
|
-
if (
|
|
250
|
-
var
|
|
251
|
-
return
|
|
243
|
+
var s = _.date, i = _.utc;
|
|
244
|
+
if (s === null) return /* @__PURE__ */ new Date(NaN);
|
|
245
|
+
if (I.u(s)) return /* @__PURE__ */ new Date();
|
|
246
|
+
if (s instanceof Date) return new Date(s);
|
|
247
|
+
if (typeof s == "string" && !/Z$/i.test(s)) {
|
|
248
|
+
var A = s.match(w);
|
|
249
|
+
if (A) {
|
|
250
|
+
var H = A[2] - 1 || 0, J = (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, J)) : new Date(A[1], H, A[3] || 1, A[4] || 0, A[5] || 0, A[6] || 0, J);
|
|
252
252
|
}
|
|
253
253
|
}
|
|
254
|
-
return new Date(
|
|
255
|
-
}(
|
|
256
|
-
},
|
|
257
|
-
var
|
|
258
|
-
this.$y =
|
|
259
|
-
},
|
|
260
|
-
return
|
|
261
|
-
},
|
|
262
|
-
return this.$d.toString() !==
|
|
263
|
-
},
|
|
264
|
-
var
|
|
265
|
-
return this.startOf(_) <=
|
|
266
|
-
},
|
|
267
|
-
return g
|
|
268
|
-
},
|
|
269
|
-
return this.endOf(_) < g
|
|
270
|
-
},
|
|
271
|
-
return
|
|
272
|
-
},
|
|
254
|
+
return new Date(s);
|
|
255
|
+
}(g), this.init();
|
|
256
|
+
}, $.init = function() {
|
|
257
|
+
var g = this.$d;
|
|
258
|
+
this.$y = g.getFullYear(), this.$M = g.getMonth(), this.$D = g.getDate(), this.$W = g.getDay(), this.$H = g.getHours(), this.$m = g.getMinutes(), this.$s = g.getSeconds(), this.$ms = g.getMilliseconds();
|
|
259
|
+
}, $.$utils = function() {
|
|
260
|
+
return I;
|
|
261
|
+
}, $.isValid = function() {
|
|
262
|
+
return this.$d.toString() !== b;
|
|
263
|
+
}, $.isSame = function(g, _) {
|
|
264
|
+
var s = y(g);
|
|
265
|
+
return this.startOf(_) <= s && s <= this.endOf(_);
|
|
266
|
+
}, $.isAfter = function(g, _) {
|
|
267
|
+
return y(g) < this.startOf(_);
|
|
268
|
+
}, $.isBefore = function(g, _) {
|
|
269
|
+
return this.endOf(_) < y(g);
|
|
270
|
+
}, $.$g = function(g, _, s) {
|
|
271
|
+
return I.u(g) ? this[_] : this.set(s, g);
|
|
272
|
+
}, $.unix = function() {
|
|
273
273
|
return Math.floor(this.valueOf() / 1e3);
|
|
274
|
-
},
|
|
274
|
+
}, $.valueOf = function() {
|
|
275
275
|
return this.$d.getTime();
|
|
276
|
-
},
|
|
277
|
-
var
|
|
278
|
-
var
|
|
279
|
-
return
|
|
280
|
-
},
|
|
281
|
-
return
|
|
282
|
-
},
|
|
283
|
-
switch (
|
|
284
|
-
case
|
|
285
|
-
return
|
|
286
|
-
case
|
|
287
|
-
return
|
|
288
|
-
case
|
|
289
|
-
var
|
|
290
|
-
return
|
|
291
|
-
case
|
|
292
|
-
case
|
|
293
|
-
return
|
|
276
|
+
}, $.startOf = function(g, _) {
|
|
277
|
+
var s = this, i = !!I.u(_) || _, A = I.p(g), H = function(De, u) {
|
|
278
|
+
var P = I.w(s.$u ? Date.UTC(s.$y, u, De) : new Date(s.$y, u, De), s);
|
|
279
|
+
return i ? P : P.endOf(E);
|
|
280
|
+
}, J = function(De, u) {
|
|
281
|
+
return I.w(s.toDate()[De].apply(s.toDate("s"), (i ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(u)), s);
|
|
282
|
+
}, ue = this.$W, de = this.$M, he = this.$D, $e = "set" + (this.$u ? "UTC" : "");
|
|
283
|
+
switch (A) {
|
|
284
|
+
case L:
|
|
285
|
+
return i ? H(1, 0) : H(31, 11);
|
|
286
|
+
case N:
|
|
287
|
+
return i ? H(1, de) : H(0, de + 1);
|
|
288
|
+
case D:
|
|
289
|
+
var Ce = this.$locale().weekStart || 0, Te = (ue < Ce ? ue + 7 : ue) - Ce;
|
|
290
|
+
return H(i ? he - Te : he + (6 - Te), de);
|
|
291
|
+
case E:
|
|
292
|
+
case V:
|
|
293
|
+
return J($e + "Hours", 0);
|
|
294
294
|
case T:
|
|
295
|
-
return
|
|
295
|
+
return J($e + "Minutes", 1);
|
|
296
296
|
case F:
|
|
297
|
-
return
|
|
298
|
-
case
|
|
299
|
-
return
|
|
297
|
+
return J($e + "Seconds", 2);
|
|
298
|
+
case Y:
|
|
299
|
+
return J($e + "Milliseconds", 3);
|
|
300
300
|
default:
|
|
301
301
|
return this.clone();
|
|
302
302
|
}
|
|
303
|
-
},
|
|
304
|
-
return this.startOf(
|
|
305
|
-
},
|
|
306
|
-
var
|
|
307
|
-
if (
|
|
308
|
-
var
|
|
309
|
-
|
|
310
|
-
} else
|
|
303
|
+
}, $.endOf = function(g) {
|
|
304
|
+
return this.startOf(g, !1);
|
|
305
|
+
}, $.$set = function(g, _) {
|
|
306
|
+
var s, i = I.p(g), A = "set" + (this.$u ? "UTC" : ""), H = (s = {}, s[E] = A + "Date", s[V] = A + "Date", s[N] = A + "Month", s[L] = A + "FullYear", s[T] = A + "Hours", s[F] = A + "Minutes", s[Y] = A + "Seconds", s[d] = A + "Milliseconds", s)[i], J = i === E ? this.$D + (_ - this.$W) : _;
|
|
307
|
+
if (i === N || i === L) {
|
|
308
|
+
var ue = this.clone().set(V, 1);
|
|
309
|
+
ue.$d[H](J), ue.init(), this.$d = ue.set(V, Math.min(this.$D, ue.daysInMonth())).$d;
|
|
310
|
+
} else H && this.$d[H](J);
|
|
311
311
|
return this.init(), this;
|
|
312
|
-
},
|
|
313
|
-
return this.clone().$set(
|
|
314
|
-
},
|
|
315
|
-
return this[
|
|
316
|
-
},
|
|
317
|
-
var
|
|
318
|
-
|
|
319
|
-
var
|
|
320
|
-
var
|
|
321
|
-
return
|
|
312
|
+
}, $.set = function(g, _) {
|
|
313
|
+
return this.clone().$set(g, _);
|
|
314
|
+
}, $.get = function(g) {
|
|
315
|
+
return this[I.p(g)]();
|
|
316
|
+
}, $.add = function(g, _) {
|
|
317
|
+
var s, i = this;
|
|
318
|
+
g = Number(g);
|
|
319
|
+
var A = I.p(_), H = function(de) {
|
|
320
|
+
var he = y(i);
|
|
321
|
+
return I.w(he.date(he.date() + Math.round(de * g)), i);
|
|
322
322
|
};
|
|
323
|
-
if (
|
|
324
|
-
if (
|
|
325
|
-
if (
|
|
326
|
-
if (
|
|
327
|
-
var
|
|
328
|
-
return
|
|
329
|
-
},
|
|
330
|
-
return this.add(-1 *
|
|
331
|
-
},
|
|
332
|
-
var _ = this,
|
|
333
|
-
if (!this.isValid()) return
|
|
334
|
-
var
|
|
335
|
-
return
|
|
336
|
-
},
|
|
337
|
-
return
|
|
338
|
-
},
|
|
339
|
-
var
|
|
340
|
-
return
|
|
323
|
+
if (A === N) return this.set(N, this.$M + g);
|
|
324
|
+
if (A === L) return this.set(L, this.$y + g);
|
|
325
|
+
if (A === E) return H(1);
|
|
326
|
+
if (A === D) return H(7);
|
|
327
|
+
var J = (s = {}, s[F] = e, s[T] = r, s[Y] = t, s)[A] || 1, ue = this.$d.getTime() + g * J;
|
|
328
|
+
return I.w(ue, this);
|
|
329
|
+
}, $.subtract = function(g, _) {
|
|
330
|
+
return this.add(-1 * g, _);
|
|
331
|
+
}, $.format = function(g) {
|
|
332
|
+
var _ = this, s = this.$locale();
|
|
333
|
+
if (!this.isValid()) return s.invalidDate || b;
|
|
334
|
+
var i = g || "YYYY-MM-DDTHH:mm:ssZ", A = I.z(this), H = this.$H, J = this.$m, ue = this.$M, de = s.weekdays, he = s.months, $e = s.meridiem, Ce = function(u, P, se, Ve) {
|
|
335
|
+
return u && (u[P] || u(_, i)) || se[P].slice(0, Ve);
|
|
336
|
+
}, Te = function(u) {
|
|
337
|
+
return I.s(H % 12 || 12, u, "0");
|
|
338
|
+
}, De = $e || function(u, P, se) {
|
|
339
|
+
var Ve = u < 12 ? "AM" : "PM";
|
|
340
|
+
return se ? Ve.toLowerCase() : Ve;
|
|
341
341
|
};
|
|
342
|
-
return
|
|
343
|
-
return
|
|
344
|
-
switch (
|
|
342
|
+
return i.replace(ae, function(u, P) {
|
|
343
|
+
return P || function(se) {
|
|
344
|
+
switch (se) {
|
|
345
345
|
case "YY":
|
|
346
346
|
return String(_.$y).slice(-2);
|
|
347
347
|
case "YYYY":
|
|
348
|
-
return
|
|
348
|
+
return I.s(_.$y, 4, "0");
|
|
349
349
|
case "M":
|
|
350
|
-
return
|
|
350
|
+
return ue + 1;
|
|
351
351
|
case "MM":
|
|
352
|
-
return
|
|
352
|
+
return I.s(ue + 1, 2, "0");
|
|
353
353
|
case "MMM":
|
|
354
|
-
return
|
|
354
|
+
return Ce(s.monthsShort, ue, he, 3);
|
|
355
355
|
case "MMMM":
|
|
356
|
-
return
|
|
356
|
+
return Ce(he, ue);
|
|
357
357
|
case "D":
|
|
358
358
|
return _.$D;
|
|
359
359
|
case "DD":
|
|
360
|
-
return
|
|
360
|
+
return I.s(_.$D, 2, "0");
|
|
361
361
|
case "d":
|
|
362
362
|
return String(_.$W);
|
|
363
363
|
case "dd":
|
|
364
|
-
return
|
|
364
|
+
return Ce(s.weekdaysMin, _.$W, de, 2);
|
|
365
365
|
case "ddd":
|
|
366
|
-
return
|
|
366
|
+
return Ce(s.weekdaysShort, _.$W, de, 3);
|
|
367
367
|
case "dddd":
|
|
368
|
-
return
|
|
368
|
+
return de[_.$W];
|
|
369
369
|
case "H":
|
|
370
|
-
return String(
|
|
370
|
+
return String(H);
|
|
371
371
|
case "HH":
|
|
372
|
-
return
|
|
372
|
+
return I.s(H, 2, "0");
|
|
373
373
|
case "h":
|
|
374
|
-
return
|
|
374
|
+
return Te(1);
|
|
375
375
|
case "hh":
|
|
376
|
-
return
|
|
376
|
+
return Te(2);
|
|
377
377
|
case "a":
|
|
378
|
-
return
|
|
378
|
+
return De(H, J, !0);
|
|
379
379
|
case "A":
|
|
380
|
-
return
|
|
380
|
+
return De(H, J, !1);
|
|
381
381
|
case "m":
|
|
382
|
-
return String(
|
|
382
|
+
return String(J);
|
|
383
383
|
case "mm":
|
|
384
|
-
return
|
|
384
|
+
return I.s(J, 2, "0");
|
|
385
385
|
case "s":
|
|
386
386
|
return String(_.$s);
|
|
387
387
|
case "ss":
|
|
388
|
-
return
|
|
388
|
+
return I.s(_.$s, 2, "0");
|
|
389
389
|
case "SSS":
|
|
390
|
-
return
|
|
390
|
+
return I.s(_.$ms, 3, "0");
|
|
391
391
|
case "Z":
|
|
392
|
-
return
|
|
392
|
+
return A;
|
|
393
393
|
}
|
|
394
394
|
return null;
|
|
395
|
-
}(
|
|
395
|
+
}(u) || A.replace(":", "");
|
|
396
396
|
});
|
|
397
|
-
},
|
|
397
|
+
}, $.utcOffset = function() {
|
|
398
398
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
399
|
-
},
|
|
400
|
-
var
|
|
401
|
-
return
|
|
399
|
+
}, $.diff = function(g, _, s) {
|
|
400
|
+
var i, A = this, H = I.p(_), J = y(g), ue = (J.utcOffset() - this.utcOffset()) * e, de = this - J, he = function() {
|
|
401
|
+
return I.m(A, J);
|
|
402
402
|
};
|
|
403
|
-
switch (
|
|
404
|
-
case
|
|
405
|
-
|
|
403
|
+
switch (H) {
|
|
404
|
+
case L:
|
|
405
|
+
i = he() / 12;
|
|
406
406
|
break;
|
|
407
|
-
case
|
|
408
|
-
|
|
407
|
+
case N:
|
|
408
|
+
i = he();
|
|
409
409
|
break;
|
|
410
|
-
case
|
|
411
|
-
|
|
410
|
+
case te:
|
|
411
|
+
i = he() / 3;
|
|
412
412
|
break;
|
|
413
|
-
case
|
|
414
|
-
|
|
413
|
+
case D:
|
|
414
|
+
i = (de - ue) / 6048e5;
|
|
415
415
|
break;
|
|
416
|
-
case
|
|
417
|
-
|
|
416
|
+
case E:
|
|
417
|
+
i = (de - ue) / 864e5;
|
|
418
418
|
break;
|
|
419
419
|
case T:
|
|
420
|
-
|
|
420
|
+
i = de / r;
|
|
421
421
|
break;
|
|
422
422
|
case F:
|
|
423
|
-
|
|
423
|
+
i = de / e;
|
|
424
424
|
break;
|
|
425
|
-
case
|
|
426
|
-
|
|
425
|
+
case Y:
|
|
426
|
+
i = de / t;
|
|
427
427
|
break;
|
|
428
428
|
default:
|
|
429
|
-
|
|
429
|
+
i = de;
|
|
430
430
|
}
|
|
431
|
-
return
|
|
432
|
-
},
|
|
433
|
-
return this.endOf(
|
|
434
|
-
},
|
|
435
|
-
return
|
|
436
|
-
},
|
|
437
|
-
if (!
|
|
438
|
-
var
|
|
439
|
-
return
|
|
440
|
-
},
|
|
441
|
-
return
|
|
442
|
-
},
|
|
431
|
+
return s ? i : I.a(i);
|
|
432
|
+
}, $.daysInMonth = function() {
|
|
433
|
+
return this.endOf(N).$D;
|
|
434
|
+
}, $.$locale = function() {
|
|
435
|
+
return pe[this.$L];
|
|
436
|
+
}, $.locale = function(g, _) {
|
|
437
|
+
if (!g) return this.$L;
|
|
438
|
+
var s = this.clone(), i = C(g, _, !0);
|
|
439
|
+
return i && (s.$L = i), s;
|
|
440
|
+
}, $.clone = function() {
|
|
441
|
+
return I.w(this.$d, this);
|
|
442
|
+
}, $.toDate = function() {
|
|
443
443
|
return new Date(this.valueOf());
|
|
444
|
-
},
|
|
444
|
+
}, $.toJSON = function() {
|
|
445
445
|
return this.isValid() ? this.toISOString() : null;
|
|
446
|
-
},
|
|
446
|
+
}, $.toISOString = function() {
|
|
447
447
|
return this.$d.toISOString();
|
|
448
|
-
},
|
|
448
|
+
}, $.toString = function() {
|
|
449
449
|
return this.$d.toUTCString();
|
|
450
|
-
},
|
|
451
|
-
}(),
|
|
452
|
-
return
|
|
453
|
-
|
|
454
|
-
return this.$g(
|
|
450
|
+
}, x;
|
|
451
|
+
}(), re = ee.prototype;
|
|
452
|
+
return y.prototype = re, [["$ms", d], ["$s", Y], ["$m", F], ["$H", T], ["$W", E], ["$M", N], ["$y", L], ["$D", V]].forEach(function(x) {
|
|
453
|
+
re[x[1]] = function($) {
|
|
454
|
+
return this.$g($, x[0], x[1]);
|
|
455
455
|
};
|
|
456
|
-
}),
|
|
457
|
-
return
|
|
458
|
-
},
|
|
459
|
-
return
|
|
460
|
-
},
|
|
456
|
+
}), y.extend = function(x, $) {
|
|
457
|
+
return x.$i || (x($, ee, y), x.$i = !0), y;
|
|
458
|
+
}, y.locale = C, y.isDayjs = M, y.unix = function(x) {
|
|
459
|
+
return y(1e3 * x);
|
|
460
|
+
}, y.en = pe[fe], y.Ls = pe, y.p = {}, y;
|
|
461
461
|
});
|
|
462
462
|
})($t);
|
|
463
|
-
var
|
|
464
|
-
const et = /* @__PURE__ */ jt
|
|
463
|
+
var jt = $t.exports;
|
|
464
|
+
const et = /* @__PURE__ */ Ut(jt), Rt = {
|
|
465
465
|
style: { display: "flex", width: "100%" },
|
|
466
466
|
class: "g-ctrl-container"
|
|
467
467
|
}, Lt = {
|
|
468
|
-
key:
|
|
468
|
+
key: 19,
|
|
469
469
|
style: { position: "relative" }
|
|
470
|
-
},
|
|
470
|
+
}, Ht = ["title"], Nt = { key: 20 }, Pt = { key: 21 }, Wt = ["innerHTML"], zt = ["innerHTML"], Xe = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
471
471
|
__name: "g-ctrl",
|
|
472
|
-
props: /* @__PURE__ */
|
|
472
|
+
props: /* @__PURE__ */ Be(["t", "ctrlKey", "item", "model", "ctrlType", "formInfo"], {
|
|
473
473
|
modelValue: { required: !0 },
|
|
474
474
|
modelModifiers: {}
|
|
475
475
|
}),
|
|
476
476
|
emits: ["update:modelValue"],
|
|
477
477
|
setup(f) {
|
|
478
|
-
const c =
|
|
478
|
+
const c = Ie(f, "modelValue"), t = f, e = t.item || {}, r = t.ctrlKey, d = t.ctrlType, Y = t.model, F = ve([]), T = ve([]), E = () => Object.keys(yt()).filter((b) => b.startsWith(`${t.t}-${r}-`)).map((b) => b.replace(`${t.t}-${r}-`, "")), D = (b) => [
|
|
479
|
+
"year",
|
|
480
|
+
"years",
|
|
481
|
+
"month",
|
|
482
|
+
"months",
|
|
483
|
+
"date",
|
|
484
|
+
"dates",
|
|
485
|
+
"datetime",
|
|
486
|
+
"week",
|
|
487
|
+
"datetimerange",
|
|
488
|
+
"daterange",
|
|
489
|
+
"monthrange",
|
|
490
|
+
"yearrange"
|
|
491
|
+
].includes(b), N = (b) => ({
|
|
492
|
+
year: "YYYY",
|
|
493
|
+
years: "YYYY",
|
|
494
|
+
month: "YYYY-MM",
|
|
495
|
+
months: "YYYY-MM",
|
|
496
|
+
date: "YYYY-MM-DD",
|
|
497
|
+
dates: "YYYY-MM-DD",
|
|
498
|
+
week: "YYYY-WW",
|
|
499
|
+
// 修复周格式
|
|
500
|
+
datetime: "YYYY-MM-DD HH:mm:ss",
|
|
501
|
+
datetimerange: "YYYY-MM-DD HH:mm:ss",
|
|
502
|
+
daterange: "YYYY-MM-DD",
|
|
503
|
+
monthrange: "YYYY-MM",
|
|
504
|
+
yearrange: "YYYY"
|
|
505
|
+
})[b] || "YYYY-MM-DD", te = ve({
|
|
479
506
|
filterable: !0,
|
|
480
507
|
remote: !!(e && e["remote-method"]),
|
|
481
508
|
...e
|
|
482
|
-
}),
|
|
483
|
-
e["remote-method"](
|
|
509
|
+
}), L = ve((b) => {
|
|
510
|
+
e["remote-method"](b, (w) => {
|
|
484
511
|
ht(() => {
|
|
485
|
-
T.value =
|
|
512
|
+
T.value = w;
|
|
486
513
|
});
|
|
487
514
|
});
|
|
488
|
-
}),
|
|
515
|
+
}), V = async (b = "options") => {
|
|
489
516
|
try {
|
|
490
|
-
const
|
|
491
|
-
if (typeof
|
|
492
|
-
T.value = [{ label:
|
|
517
|
+
const w = await (e == null ? void 0 : e.getDicts(t.formInfo));
|
|
518
|
+
if (typeof w == "string")
|
|
519
|
+
T.value = [{ label: w, value: c.value }];
|
|
493
520
|
else {
|
|
494
|
-
const
|
|
495
|
-
...
|
|
496
|
-
value:
|
|
497
|
-
label:
|
|
521
|
+
const ae = w == null ? void 0 : w.map((K, ne) => ({
|
|
522
|
+
...K,
|
|
523
|
+
value: K.value ?? K.label ?? ne,
|
|
524
|
+
label: K.label || "未知选项"
|
|
498
525
|
}));
|
|
499
|
-
T.value =
|
|
526
|
+
T.value = ae || [];
|
|
500
527
|
}
|
|
501
|
-
} catch (
|
|
502
|
-
throw console.error("获取选项失败:",
|
|
528
|
+
} catch (w) {
|
|
529
|
+
throw console.error("获取选项失败:", w), w;
|
|
503
530
|
}
|
|
504
531
|
};
|
|
505
|
-
return
|
|
506
|
-
var
|
|
507
|
-
e && e["remote-method"] && (
|
|
508
|
-
const
|
|
509
|
-
typeof e.getDicts == "function" &&
|
|
510
|
-
console.error(`Failed to load ${
|
|
532
|
+
return Ne(async () => {
|
|
533
|
+
var ae, K;
|
|
534
|
+
e && e["remote-method"] && (te.value["remote-method"] = L), (K = (ae = Y[r]) == null ? void 0 : ae.options) != null && K.length && (T.value = Y[r].options);
|
|
535
|
+
const b = (ne, ie = "options", fe = Y[r]) => {
|
|
536
|
+
typeof e.getDicts == "function" && V(ie).catch((pe) => {
|
|
537
|
+
console.error(`Failed to load ${ie} for ${ne}:`, pe);
|
|
511
538
|
});
|
|
512
539
|
};
|
|
513
|
-
["radio", "radio-button", "checkbox-group", "checkbox-group-button", "select", "cascader"].includes(
|
|
540
|
+
["radio", "radio-button", "checkbox-group", "checkbox-group-button", "select", "cascader"].includes(d) && b(d), d === ge.TREESELECT && await (async () => {
|
|
514
541
|
try {
|
|
515
542
|
typeof e.getDicts == "function" ? F.value = await e.getDicts(t.formInfo) : F.value = T.value;
|
|
516
|
-
} catch (
|
|
517
|
-
console.error("Failed to load data for tree-select:",
|
|
543
|
+
} catch (ie) {
|
|
544
|
+
console.error("Failed to load data for tree-select:", ie);
|
|
518
545
|
}
|
|
519
546
|
})();
|
|
520
|
-
}), (
|
|
521
|
-
var
|
|
522
|
-
const
|
|
523
|
-
return
|
|
524
|
-
o(
|
|
547
|
+
}), (b, w) => {
|
|
548
|
+
var Ce, Te, De;
|
|
549
|
+
const ae = R("el-radio"), K = R("el-radio-group"), ne = R("el-radio-button"), ie = R("el-checkbox"), fe = R("el-checkbox-group"), pe = R("el-checkbox-button"), m = R("g-select-option"), M = R("el-option"), C = R("el-select"), y = R("el-tree-select"), I = R("el-time-picker"), ee = R("el-time-select"), re = R("el-date-picker"), x = R("el-color-picker"), $ = R("el-rate"), g = R("el-slider"), _ = R("el-switch"), s = R("el-transfer"), i = R("el-cascader"), A = R("el-button"), H = R("el-upload"), J = R("el-autocomplete"), ue = R("el-input-number"), de = R("el-input"), he = R("el-link"), $e = R("el-tag");
|
|
550
|
+
return n(), q("div", Rt, [
|
|
551
|
+
o(d) == o(ge).RADIO ? (n(), O(K, S({
|
|
525
552
|
key: 0,
|
|
526
553
|
modelValue: c.value,
|
|
527
|
-
"onUpdate:modelValue":
|
|
554
|
+
"onUpdate:modelValue": w[0] || (w[0] = (u) => c.value = u)
|
|
528
555
|
}, o(e)), {
|
|
529
|
-
default:
|
|
530
|
-
|
|
531
|
-
(
|
|
532
|
-
default:
|
|
533
|
-
|
|
556
|
+
default: h(() => [
|
|
557
|
+
p(b.$slots, `${t.t}-${o(r)}`, { data: o(e) }, () => [
|
|
558
|
+
(n(!0), q(G, null, j(T.value, (u) => (n(), O(ae, S({ ref_for: !0 }, u), {
|
|
559
|
+
default: h(() => [
|
|
560
|
+
p(b.$slots, `${t.t}-${o(r)}-options`, { option: u })
|
|
534
561
|
]),
|
|
535
562
|
_: 2
|
|
536
563
|
}, 1040))), 256))
|
|
537
564
|
])
|
|
538
565
|
]),
|
|
539
566
|
_: 3
|
|
540
|
-
}, 16, ["modelValue"])) : o(
|
|
567
|
+
}, 16, ["modelValue"])) : o(d) == o(ge).RADIOBUTTON ? (n(), O(K, S({
|
|
541
568
|
key: 1,
|
|
542
569
|
modelValue: c.value,
|
|
543
|
-
"onUpdate:modelValue":
|
|
570
|
+
"onUpdate:modelValue": w[1] || (w[1] = (u) => c.value = u)
|
|
544
571
|
}, o(e)), {
|
|
545
|
-
default:
|
|
546
|
-
|
|
547
|
-
(
|
|
548
|
-
default:
|
|
549
|
-
|
|
572
|
+
default: h(() => [
|
|
573
|
+
p(b.$slots, `${t.t}-${o(r)}`, { data: o(e) }, () => [
|
|
574
|
+
(n(!0), q(G, null, j(T.value, (u) => (n(), O(ne, S({ ref_for: !0 }, u), {
|
|
575
|
+
default: h(() => [
|
|
576
|
+
p(b.$slots, `${t.t}-${o(r)}-options`, { option: u })
|
|
550
577
|
]),
|
|
551
578
|
_: 2
|
|
552
579
|
}, 1040))), 256))
|
|
553
580
|
])
|
|
554
581
|
]),
|
|
555
582
|
_: 3
|
|
556
|
-
}, 16, ["modelValue"])) : o(
|
|
583
|
+
}, 16, ["modelValue"])) : o(d) == o(ge).CHECKBOX ? (n(), O(ie, S({
|
|
557
584
|
key: 2,
|
|
558
585
|
modelValue: c.value,
|
|
559
|
-
"onUpdate:modelValue":
|
|
586
|
+
"onUpdate:modelValue": w[2] || (w[2] = (u) => c.value = u)
|
|
560
587
|
}, o(e)), {
|
|
561
|
-
default:
|
|
562
|
-
|
|
563
|
-
|
|
588
|
+
default: h(() => [
|
|
589
|
+
p(b.$slots, `${t.t}-${o(r)}`, { data: o(e) }, () => [
|
|
590
|
+
w[20] || (w[20] = we(Ee(" ")))
|
|
564
591
|
])
|
|
565
592
|
]),
|
|
566
593
|
_: 3
|
|
567
|
-
}, 16, ["modelValue"])) : o(
|
|
594
|
+
}, 16, ["modelValue"])) : o(d) == o(ge).CHECKBOXGROUP ? (n(), O(fe, S({
|
|
568
595
|
key: 3,
|
|
569
596
|
modelValue: c.value,
|
|
570
|
-
"onUpdate:modelValue":
|
|
597
|
+
"onUpdate:modelValue": w[3] || (w[3] = (u) => c.value = u)
|
|
571
598
|
}, o(e)), {
|
|
572
|
-
default:
|
|
573
|
-
|
|
574
|
-
(
|
|
575
|
-
default:
|
|
576
|
-
|
|
577
|
-
|
|
599
|
+
default: h(() => [
|
|
600
|
+
p(b.$slots, `${t.t}-${o(r)}`, { data: o(e) }, () => [
|
|
601
|
+
(n(!0), q(G, null, j(T.value, (u) => (n(), O(ie, S({ ref_for: !0 }, u), {
|
|
602
|
+
default: h(() => [
|
|
603
|
+
p(b.$slots, `${t.t}-${o(r)}-options`, { option: u }, () => [
|
|
604
|
+
we(Ee(u.label), 1)
|
|
578
605
|
])
|
|
579
606
|
]),
|
|
580
607
|
_: 2
|
|
@@ -582,122 +609,122 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
582
609
|
])
|
|
583
610
|
]),
|
|
584
611
|
_: 3
|
|
585
|
-
}, 16, ["modelValue"])) : o(
|
|
612
|
+
}, 16, ["modelValue"])) : o(d) == o(ge).CHECKBOXGROUPBUTTON ? (n(), O(fe, S({
|
|
586
613
|
key: 4,
|
|
587
614
|
modelValue: c.value,
|
|
588
|
-
"onUpdate:modelValue":
|
|
615
|
+
"onUpdate:modelValue": w[4] || (w[4] = (u) => c.value = u)
|
|
589
616
|
}, o(e)), {
|
|
590
|
-
default:
|
|
591
|
-
|
|
592
|
-
(
|
|
593
|
-
default:
|
|
594
|
-
|
|
617
|
+
default: h(() => [
|
|
618
|
+
p(b.$slots, `${t.t}-${o(r)}`, { data: o(e) }, () => [
|
|
619
|
+
(n(!0), q(G, null, j(T.value, (u) => (n(), O(pe, S({ ref_for: !0 }, u), {
|
|
620
|
+
default: h(() => [
|
|
621
|
+
p(b.$slots, `${t.t}-${o(r)}-options`, { option: u })
|
|
595
622
|
]),
|
|
596
623
|
_: 2
|
|
597
624
|
}, 1040))), 256))
|
|
598
625
|
])
|
|
599
626
|
]),
|
|
600
627
|
_: 3
|
|
601
|
-
}, 16, ["modelValue"])) : o(
|
|
628
|
+
}, 16, ["modelValue"])) : o(d) === o(ge).SELECT ? (n(), O(C, S({
|
|
602
629
|
key: 5,
|
|
603
630
|
modelValue: c.value,
|
|
604
|
-
"onUpdate:modelValue":
|
|
605
|
-
placeholder: o(
|
|
606
|
-
},
|
|
607
|
-
default:
|
|
608
|
-
|
|
609
|
-
(
|
|
610
|
-
key:
|
|
631
|
+
"onUpdate:modelValue": w[5] || (w[5] = (u) => c.value = u),
|
|
632
|
+
placeholder: o(Y)[o(r)].label
|
|
633
|
+
}, te.value), ce({
|
|
634
|
+
default: h(() => [
|
|
635
|
+
p(b.$slots, `${t.t}-${o(r)}`, { options: T.value }, () => [
|
|
636
|
+
(n(!0), q(G, null, j(T.value, (u) => (n(), q(G, {
|
|
637
|
+
key: u.value
|
|
611
638
|
}, [
|
|
612
|
-
|
|
613
|
-
onClick: (
|
|
639
|
+
X(M, S({ ref_for: !0 }, o(ke)(u, (P) => P != "children"), {
|
|
640
|
+
onClick: (P) => te.value.change && te.value.change(u)
|
|
614
641
|
}), {
|
|
615
|
-
default:
|
|
616
|
-
var
|
|
642
|
+
default: h(() => {
|
|
643
|
+
var P;
|
|
617
644
|
return [
|
|
618
|
-
(
|
|
645
|
+
(P = o(e)) != null && P.columns ? p(b.$slots, `${t.t}-${o(r)}-options`, {
|
|
619
646
|
key: 0,
|
|
620
|
-
option:
|
|
647
|
+
option: u
|
|
621
648
|
}, () => {
|
|
622
|
-
var
|
|
649
|
+
var se;
|
|
623
650
|
return [
|
|
624
|
-
|
|
625
|
-
columns: (
|
|
626
|
-
data:
|
|
651
|
+
X(m, {
|
|
652
|
+
columns: (se = o(e)) == null ? void 0 : se.columns,
|
|
653
|
+
data: u,
|
|
627
654
|
t: t.t
|
|
628
|
-
},
|
|
629
|
-
|
|
630
|
-
name:
|
|
631
|
-
fn:
|
|
632
|
-
|
|
633
|
-
option:
|
|
634
|
-
data:
|
|
655
|
+
}, ce({ _: 2 }, [
|
|
656
|
+
j(b.$slots, (Ve, l) => ({
|
|
657
|
+
name: l,
|
|
658
|
+
fn: h((a) => [
|
|
659
|
+
p(b.$slots, l, {
|
|
660
|
+
option: u,
|
|
661
|
+
data: a
|
|
635
662
|
})
|
|
636
663
|
])
|
|
637
664
|
}))
|
|
638
665
|
]), 1032, ["columns", "data", "t"])
|
|
639
666
|
];
|
|
640
|
-
}) :
|
|
667
|
+
}) : be("", !0)
|
|
641
668
|
];
|
|
642
669
|
}),
|
|
643
670
|
_: 2
|
|
644
671
|
}, 1040, ["onClick"]),
|
|
645
|
-
|
|
672
|
+
u.children && u.children.length ? (n(!0), q(G, { key: 0 }, j(u.children, (P) => (n(), O(M, S({
|
|
646
673
|
style: { "margin-left": "20px" },
|
|
647
|
-
key:
|
|
674
|
+
key: P.value,
|
|
648
675
|
ref_for: !0
|
|
649
|
-
}, o(
|
|
650
|
-
onClick: (
|
|
676
|
+
}, o(ke)(P, (se) => se != "children"), {
|
|
677
|
+
onClick: (se) => te.value.change && te.value.change(P)
|
|
651
678
|
}), {
|
|
652
|
-
default:
|
|
653
|
-
var
|
|
679
|
+
default: h(() => {
|
|
680
|
+
var se;
|
|
654
681
|
return [
|
|
655
|
-
(
|
|
682
|
+
(se = o(e)) != null && se.columns ? p(b.$slots, `${t.t}-${o(r)}-options`, {
|
|
656
683
|
key: 0,
|
|
657
|
-
option:
|
|
684
|
+
option: P
|
|
658
685
|
}, () => {
|
|
659
|
-
var
|
|
686
|
+
var Ve;
|
|
660
687
|
return [
|
|
661
|
-
|
|
662
|
-
columns: (
|
|
663
|
-
data:
|
|
688
|
+
X(m, {
|
|
689
|
+
columns: (Ve = o(e)) == null ? void 0 : Ve.columns,
|
|
690
|
+
data: P,
|
|
664
691
|
t: t.t
|
|
665
|
-
},
|
|
666
|
-
|
|
667
|
-
name:
|
|
668
|
-
fn:
|
|
669
|
-
|
|
670
|
-
option:
|
|
671
|
-
data:
|
|
692
|
+
}, ce({ _: 2 }, [
|
|
693
|
+
j(b.$slots, (l, a) => ({
|
|
694
|
+
name: a,
|
|
695
|
+
fn: h((v) => [
|
|
696
|
+
p(b.$slots, a, {
|
|
697
|
+
option: P,
|
|
698
|
+
data: v
|
|
672
699
|
})
|
|
673
700
|
])
|
|
674
701
|
}))
|
|
675
702
|
]), 1032, ["columns", "data", "t"])
|
|
676
703
|
];
|
|
677
|
-
}) :
|
|
704
|
+
}) : be("", !0)
|
|
678
705
|
];
|
|
679
706
|
}),
|
|
680
707
|
_: 2
|
|
681
|
-
}, 1040, ["onClick"]))), 128)) :
|
|
708
|
+
}, 1040, ["onClick"]))), 128)) : be("", !0)
|
|
682
709
|
], 64))), 128))
|
|
683
710
|
])
|
|
684
711
|
]),
|
|
685
712
|
_: 2
|
|
686
713
|
}, [
|
|
687
|
-
(
|
|
714
|
+
(Ce = o(e)) != null && Ce.columns ? {
|
|
688
715
|
name: "header",
|
|
689
|
-
fn:
|
|
690
|
-
var
|
|
716
|
+
fn: h(() => {
|
|
717
|
+
var u;
|
|
691
718
|
return [
|
|
692
|
-
|
|
693
|
-
columns: (
|
|
719
|
+
X(m, {
|
|
720
|
+
columns: (u = o(e)) == null ? void 0 : u.columns,
|
|
694
721
|
title: !0,
|
|
695
722
|
t: t.t
|
|
696
|
-
},
|
|
697
|
-
|
|
698
|
-
name:
|
|
699
|
-
fn:
|
|
700
|
-
|
|
723
|
+
}, ce({ _: 2 }, [
|
|
724
|
+
j(b.$slots, (P, se) => ({
|
|
725
|
+
name: se,
|
|
726
|
+
fn: h((Ve) => [
|
|
727
|
+
p(b.$slots, se, { data: Ve })
|
|
701
728
|
])
|
|
702
729
|
}))
|
|
703
730
|
]), 1032, ["columns", "t"])
|
|
@@ -705,191 +732,189 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
705
732
|
}),
|
|
706
733
|
key: "0"
|
|
707
734
|
} : void 0,
|
|
708
|
-
|
|
709
|
-
name:
|
|
710
|
-
fn:
|
|
711
|
-
|
|
735
|
+
j(E(), (u) => ({
|
|
736
|
+
name: u,
|
|
737
|
+
fn: h((P) => [
|
|
738
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: P })
|
|
712
739
|
])
|
|
713
740
|
}))
|
|
714
|
-
]), 1040, ["modelValue", "placeholder"])) : o(
|
|
741
|
+
]), 1040, ["modelValue", "placeholder"])) : o(d) == o(ge).TREESELECT ? (n(), O(y, S({
|
|
715
742
|
key: 6,
|
|
716
743
|
modelValue: c.value,
|
|
717
|
-
"onUpdate:modelValue":
|
|
718
|
-
placeholder: o(
|
|
719
|
-
}, o(e), { data: F.value }),
|
|
720
|
-
|
|
721
|
-
name:
|
|
722
|
-
fn:
|
|
723
|
-
|
|
744
|
+
"onUpdate:modelValue": w[6] || (w[6] = (u) => c.value = u),
|
|
745
|
+
placeholder: o(Y)[o(r)].label
|
|
746
|
+
}, o(e), { data: F.value }), ce({ _: 2 }, [
|
|
747
|
+
j(E(), (u) => ({
|
|
748
|
+
name: u,
|
|
749
|
+
fn: h((P) => [
|
|
750
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: P })
|
|
724
751
|
])
|
|
725
752
|
}))
|
|
726
|
-
]), 1040, ["modelValue", "placeholder", "data"])) : o(
|
|
753
|
+
]), 1040, ["modelValue", "placeholder", "data"])) : o(d) == o(ge).TIME ? (n(), O(I, S({
|
|
727
754
|
key: 7,
|
|
728
755
|
modelValue: c.value,
|
|
729
|
-
"onUpdate:modelValue":
|
|
756
|
+
"onUpdate:modelValue": w[7] || (w[7] = (u) => c.value = u),
|
|
730
757
|
"arrow-control": ""
|
|
731
758
|
}, o(e), {
|
|
732
|
-
placeholder: o(
|
|
733
|
-
}), null, 16, ["modelValue", "placeholder"])) : o(
|
|
759
|
+
placeholder: o(Y)[o(r)].label
|
|
760
|
+
}), null, 16, ["modelValue", "placeholder"])) : o(d) == o(ge).TIMESELECT ? (n(), O(ee, S({
|
|
734
761
|
key: 8,
|
|
735
762
|
modelValue: c.value,
|
|
736
|
-
"onUpdate:modelValue":
|
|
763
|
+
"onUpdate:modelValue": w[8] || (w[8] = (u) => c.value = u),
|
|
737
764
|
start: "06:30",
|
|
738
765
|
step: "00:15",
|
|
739
766
|
end: "23:30",
|
|
740
|
-
placeholder: o(
|
|
741
|
-
}, o(e)), null, 16, ["modelValue", "placeholder"])) :
|
|
767
|
+
placeholder: o(Y)[o(r)].label
|
|
768
|
+
}, o(e)), null, 16, ["modelValue", "placeholder"])) : D(o(d)) ? (n(), O(re, S({
|
|
742
769
|
key: 9,
|
|
743
770
|
modelValue: c.value,
|
|
744
|
-
"onUpdate:modelValue":
|
|
771
|
+
"onUpdate:modelValue": w[9] || (w[9] = (u) => c.value = u),
|
|
745
772
|
type: "date",
|
|
746
|
-
placeholder: o(
|
|
747
|
-
"value-format":
|
|
748
|
-
}, o(e)),
|
|
749
|
-
|
|
750
|
-
name:
|
|
751
|
-
fn:
|
|
752
|
-
|
|
773
|
+
placeholder: o(Y)[o(r)].label,
|
|
774
|
+
"value-format": N(o(d))
|
|
775
|
+
}, o(e)), ce({ _: 2 }, [
|
|
776
|
+
j(E(), (u) => ({
|
|
777
|
+
name: u,
|
|
778
|
+
fn: h((P) => [
|
|
779
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: P })
|
|
753
780
|
])
|
|
754
781
|
}))
|
|
755
|
-
]), 1040, ["modelValue", "placeholder"])) : o(
|
|
782
|
+
]), 1040, ["modelValue", "placeholder", "value-format"])) : o(d) == o(ge).COLOR ? (n(), O(x, S({
|
|
756
783
|
key: 10,
|
|
757
784
|
modelValue: c.value,
|
|
758
|
-
"onUpdate:modelValue":
|
|
759
|
-
|
|
760
|
-
placeholder: o(I)[o(a)].label,
|
|
761
|
-
"value-format": "YYYY-MM-DD HH:mm:ss"
|
|
762
|
-
}, o(e)), de({ _: 2 }, [
|
|
763
|
-
U(w(), (n) => ({
|
|
764
|
-
name: n,
|
|
765
|
-
fn: y((z) => [
|
|
766
|
-
m($.$slots, `${t.t}-${o(a)}-${n}`, { data: z })
|
|
767
|
-
])
|
|
768
|
-
}))
|
|
769
|
-
]), 1040, ["modelValue", "type", "placeholder"])) : o(v) == o(ce).COLOR ? (s(), S(Z, M({
|
|
785
|
+
"onUpdate:modelValue": w[10] || (w[10] = (u) => c.value = u)
|
|
786
|
+
}, o(e)), null, 16, ["modelValue"])) : o(d) == o(ge).RATE ? (n(), O($, S({
|
|
770
787
|
key: 11,
|
|
771
788
|
modelValue: c.value,
|
|
772
|
-
"onUpdate:modelValue":
|
|
773
|
-
}, o(e)), null, 16, ["modelValue"])) : o(
|
|
789
|
+
"onUpdate:modelValue": w[11] || (w[11] = (u) => c.value = u)
|
|
790
|
+
}, o(e)), null, 16, ["modelValue"])) : o(d) == o(ge).SLIDER ? (n(), O(g, S({
|
|
774
791
|
key: 12,
|
|
775
792
|
modelValue: c.value,
|
|
776
|
-
"onUpdate:modelValue":
|
|
777
|
-
}, o(e)), null, 16, ["modelValue"])) : o(
|
|
793
|
+
"onUpdate:modelValue": w[12] || (w[12] = (u) => c.value = u)
|
|
794
|
+
}, o(e)), null, 16, ["modelValue"])) : o(d) == o(ge).SWITCH ? (n(), O(_, S({
|
|
778
795
|
key: 13,
|
|
779
796
|
modelValue: c.value,
|
|
780
|
-
"onUpdate:modelValue":
|
|
781
|
-
}, o(e)),
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
U(w(), (n) => ({
|
|
787
|
-
name: n,
|
|
788
|
-
fn: y((z) => [
|
|
789
|
-
m($.$slots, `${t.t}-${o(a)}-${n}`, { data: z })
|
|
797
|
+
"onUpdate:modelValue": w[13] || (w[13] = (u) => c.value = u)
|
|
798
|
+
}, o(e)), ce({ _: 2 }, [
|
|
799
|
+
j(E(), (u) => ({
|
|
800
|
+
name: u,
|
|
801
|
+
fn: h((P) => [
|
|
802
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: P })
|
|
790
803
|
])
|
|
791
804
|
}))
|
|
792
|
-
]), 1040, ["modelValue"])) : o(
|
|
793
|
-
key:
|
|
805
|
+
]), 1040, ["modelValue"])) : o(d) == o(ge).TRANSFER ? (n(), O(s, S({
|
|
806
|
+
key: 14,
|
|
794
807
|
modelValue: c.value,
|
|
795
|
-
"onUpdate:modelValue":
|
|
796
|
-
}, o(e)),
|
|
797
|
-
|
|
798
|
-
name:
|
|
799
|
-
fn:
|
|
800
|
-
|
|
808
|
+
"onUpdate:modelValue": w[14] || (w[14] = (u) => c.value = u)
|
|
809
|
+
}, o(e)), ce({ _: 2 }, [
|
|
810
|
+
j(E(), (u) => ({
|
|
811
|
+
name: u,
|
|
812
|
+
fn: h((P) => [
|
|
813
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: P })
|
|
801
814
|
])
|
|
802
815
|
}))
|
|
803
|
-
]), 1040, ["modelValue"])) : o(
|
|
804
|
-
key:
|
|
816
|
+
]), 1040, ["modelValue"])) : o(d) == o(ge).CASCADER ? (n(), O(i, S({
|
|
817
|
+
key: 15,
|
|
805
818
|
modelValue: c.value,
|
|
806
|
-
"onUpdate:modelValue":
|
|
807
|
-
}, o(e), { options: T.value }),
|
|
808
|
-
|
|
809
|
-
name:
|
|
810
|
-
fn:
|
|
811
|
-
|
|
819
|
+
"onUpdate:modelValue": w[15] || (w[15] = (u) => c.value = u)
|
|
820
|
+
}, o(e), { options: T.value }), ce({ _: 2 }, [
|
|
821
|
+
j(E(), (u) => ({
|
|
822
|
+
name: u,
|
|
823
|
+
fn: h((P) => [
|
|
824
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: P })
|
|
812
825
|
])
|
|
813
826
|
}))
|
|
814
|
-
]), 1040, ["modelValue", "options"])) : o(
|
|
815
|
-
default:
|
|
816
|
-
|
|
817
|
-
default:
|
|
818
|
-
|
|
827
|
+
]), 1040, ["modelValue", "options"])) : o(d) == o(ge).IMAGE ? (n(), O(H, Qe(S({ key: 16 }, o(e))), ce({
|
|
828
|
+
default: h(() => [
|
|
829
|
+
X(A, { type: "primary" }, {
|
|
830
|
+
default: h(() => w[21] || (w[21] = [
|
|
831
|
+
we("点击上传")
|
|
819
832
|
])),
|
|
820
833
|
_: 1
|
|
821
834
|
})
|
|
822
835
|
]),
|
|
823
836
|
_: 2
|
|
824
837
|
}, [
|
|
825
|
-
|
|
826
|
-
name:
|
|
827
|
-
fn:
|
|
828
|
-
|
|
838
|
+
j(E(), (u, P) => ({
|
|
839
|
+
name: u,
|
|
840
|
+
fn: h((se) => [
|
|
841
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: se })
|
|
829
842
|
])
|
|
830
843
|
}))
|
|
831
|
-
]), 1040)) : o(
|
|
832
|
-
key:
|
|
844
|
+
]), 1040)) : o(d) == o(ge).AUTOCOMPLETE ? (n(), O(J, S({
|
|
845
|
+
key: 17,
|
|
833
846
|
modelValue: c.value,
|
|
834
|
-
"onUpdate:modelValue":
|
|
847
|
+
"onUpdate:modelValue": w[16] || (w[16] = (u) => c.value = u)
|
|
835
848
|
}, o(e), {
|
|
836
|
-
placeholder: o(
|
|
837
|
-
}),
|
|
838
|
-
|
|
839
|
-
name:
|
|
840
|
-
fn:
|
|
841
|
-
|
|
849
|
+
placeholder: o(Y)[o(r)].label
|
|
850
|
+
}), ce({ _: 2 }, [
|
|
851
|
+
j(E(), (u, P) => ({
|
|
852
|
+
name: u,
|
|
853
|
+
fn: h((se) => [
|
|
854
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: se })
|
|
842
855
|
])
|
|
843
856
|
}))
|
|
844
|
-
]), 1040, ["modelValue", "placeholder"])) : o(
|
|
845
|
-
key:
|
|
857
|
+
]), 1040, ["modelValue", "placeholder"])) : o(d) == o(ge).INPUTNUMBER ? (n(), O(ue, S({
|
|
858
|
+
key: 18,
|
|
846
859
|
modelValue: c.value,
|
|
847
|
-
"onUpdate:modelValue":
|
|
860
|
+
"onUpdate:modelValue": w[17] || (w[17] = (u) => c.value = u),
|
|
848
861
|
min: 0,
|
|
849
862
|
max: 1e8,
|
|
850
|
-
placeholder: o(
|
|
851
|
-
}, o(e)),
|
|
852
|
-
|
|
853
|
-
name:
|
|
854
|
-
fn:
|
|
855
|
-
|
|
863
|
+
placeholder: o(Y)[o(r)].label
|
|
864
|
+
}, o(e)), ce({ _: 2 }, [
|
|
865
|
+
j(E(), (u, P) => ({
|
|
866
|
+
name: u,
|
|
867
|
+
fn: h((se) => [
|
|
868
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: se })
|
|
856
869
|
])
|
|
857
870
|
}))
|
|
858
|
-
]), 1040, ["modelValue", "placeholder"])) : o(
|
|
859
|
-
|
|
871
|
+
]), 1040, ["modelValue", "placeholder"])) : o(d) == o(ge).MONEY ? (n(), q("div", Lt, [
|
|
872
|
+
X(de, S({
|
|
860
873
|
modelValue: c.value,
|
|
861
|
-
"onUpdate:modelValue":
|
|
862
|
-
placeholder: o(
|
|
863
|
-
type: o(
|
|
864
|
-
maxlength: ((
|
|
865
|
-
}, { ...o(e), type: o(
|
|
866
|
-
suffix:
|
|
867
|
-
|
|
874
|
+
"onUpdate:modelValue": w[18] || (w[18] = (u) => c.value = u),
|
|
875
|
+
placeholder: o(Y)[o(r)].label,
|
|
876
|
+
type: o(ge).NUMBER,
|
|
877
|
+
maxlength: ((Te = o(e)) == null ? void 0 : Te.max) || 25
|
|
878
|
+
}, { ...o(e), type: o(d) }), ce({
|
|
879
|
+
suffix: h(() => [
|
|
880
|
+
Z("div", {
|
|
868
881
|
title: o(at)(c.value),
|
|
869
882
|
style: { "font-size": "10px", display: "block", width: "80px", "text-align": "right", overflow: "hidden", "text-overflow": "ellipsis" }
|
|
870
|
-
}, Ee(o(at)(c.value)), 9,
|
|
883
|
+
}, Ee(o(at)(c.value)), 9, Ht)
|
|
871
884
|
]),
|
|
872
885
|
_: 2
|
|
873
886
|
}, [
|
|
874
|
-
|
|
875
|
-
name:
|
|
876
|
-
fn:
|
|
877
|
-
|
|
887
|
+
j(E(), (u, P) => ({
|
|
888
|
+
name: u,
|
|
889
|
+
fn: h((se) => [
|
|
890
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: se })
|
|
878
891
|
])
|
|
879
892
|
}))
|
|
880
893
|
]), 1040, ["modelValue", "placeholder", "type", "maxlength"])
|
|
881
|
-
])) : (
|
|
882
|
-
|
|
894
|
+
])) : (o(d) === "primary" || o(d) === "success" || o(d) === "warning" || o(d) == "danger" || o(d) === "info" || o(d) == "default") && o(e).isLink === !0 ? (n(), q("div", Nt, [
|
|
895
|
+
X(he, S(o(e), {
|
|
896
|
+
innerHTML: o(e).innerHtml || c.value
|
|
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(), q("div", Pt, [
|
|
899
|
+
X($e, S(o(e), {
|
|
900
|
+
innerHTML: o(e).innerHtml || c.value
|
|
901
|
+
}), null, 16, ["innerHTML"])
|
|
902
|
+
])) : o(d) == "div" ? (n(), q("div", S({ key: 22 }, o(e), {
|
|
903
|
+
innerHTML: o(e).innerHtml || c.value
|
|
904
|
+
}), null, 16, Wt)) : o(d) == "span" ? (n(), q("span", S({ key: 23 }, o(e), {
|
|
905
|
+
innerHTML: o(e).innerHtml || c.value
|
|
906
|
+
}), null, 16, zt)) : (n(), O(de, S({
|
|
907
|
+
key: 24,
|
|
883
908
|
modelValue: c.value,
|
|
884
|
-
"onUpdate:modelValue":
|
|
885
|
-
placeholder: o(
|
|
886
|
-
maxlength: ((
|
|
909
|
+
"onUpdate:modelValue": w[19] || (w[19] = (u) => c.value = u),
|
|
910
|
+
placeholder: o(Y)[o(r)].label,
|
|
911
|
+
maxlength: ((De = o(e)) == null ? void 0 : De.max) || 25,
|
|
887
912
|
clearable: !0
|
|
888
|
-
}, { ...o(e), type: o(
|
|
889
|
-
|
|
890
|
-
name:
|
|
891
|
-
fn:
|
|
892
|
-
|
|
913
|
+
}, { ...o(e), type: o(d) }), ce({ _: 2 }, [
|
|
914
|
+
j(E(), (u, P) => ({
|
|
915
|
+
name: u,
|
|
916
|
+
fn: h((se) => [
|
|
917
|
+
p(b.$slots, `${t.t}-${o(r)}-${u}`, { data: se })
|
|
893
918
|
])
|
|
894
919
|
}))
|
|
895
920
|
]), 1040, ["modelValue", "placeholder", "maxlength"]))
|
|
@@ -905,10 +930,10 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
905
930
|
modelValue: { required: !0 },
|
|
906
931
|
modelModifiers: {}
|
|
907
932
|
},
|
|
908
|
-
emits: /* @__PURE__ */
|
|
933
|
+
emits: /* @__PURE__ */ Be(["submit", "reset"], ["update:modelValue"]),
|
|
909
934
|
setup(f, { emit: c }) {
|
|
910
|
-
var
|
|
911
|
-
const t =
|
|
935
|
+
var ne, ie, fe, pe;
|
|
936
|
+
const t = Ie(f, "modelValue"), e = c, r = ve(null), d = rt("options"), Y = {
|
|
912
937
|
inline: !0,
|
|
913
938
|
type: "hidden",
|
|
914
939
|
"scroll-to-error": !0,
|
|
@@ -918,7 +943,7 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
918
943
|
style: {
|
|
919
944
|
display: "flex",
|
|
920
945
|
flexWrap: "wrap",
|
|
921
|
-
...(
|
|
946
|
+
...(ne = nt()) == null ? void 0 : ne.style
|
|
922
947
|
},
|
|
923
948
|
// 表单底部属性
|
|
924
949
|
footer: {
|
|
@@ -946,11 +971,11 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
946
971
|
hidden: !1,
|
|
947
972
|
plain: !0,
|
|
948
973
|
click: () => {
|
|
949
|
-
if (!
|
|
950
|
-
let
|
|
951
|
-
e("reset", (
|
|
952
|
-
|
|
953
|
-
}),
|
|
974
|
+
if (!r.value) return;
|
|
975
|
+
let m = !0;
|
|
976
|
+
e("reset", (M) => {
|
|
977
|
+
m = M;
|
|
978
|
+
}), m && r.value.resetFields();
|
|
954
979
|
}
|
|
955
980
|
},
|
|
956
981
|
slots: {},
|
|
@@ -959,21 +984,21 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
959
984
|
editable: !1
|
|
960
985
|
}
|
|
961
986
|
};
|
|
962
|
-
t.value.form =
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
(
|
|
987
|
+
t.value.form = Me(
|
|
988
|
+
Y,
|
|
989
|
+
d == null ? void 0 : d.form,
|
|
990
|
+
(ie = t.value) == null ? void 0 : ie.form
|
|
966
991
|
);
|
|
967
|
-
const F = async (
|
|
968
|
-
let
|
|
969
|
-
for (;
|
|
970
|
-
if (await ht(),
|
|
971
|
-
|
|
972
|
-
|
|
992
|
+
const F = async (m, M) => {
|
|
993
|
+
let C = 5;
|
|
994
|
+
for (; C > 0; ) {
|
|
995
|
+
if (await ht(), r.value) {
|
|
996
|
+
r.value.validate((y, I) => {
|
|
997
|
+
y ? e("submit", m, M) : console.log("表单验证不通过!", I);
|
|
973
998
|
});
|
|
974
999
|
return;
|
|
975
1000
|
}
|
|
976
|
-
|
|
1001
|
+
C--, await new Promise((y) => setTimeout(y, 50));
|
|
977
1002
|
}
|
|
978
1003
|
console.error("表单实例获取失败,请检查组件状态");
|
|
979
1004
|
};
|
|
@@ -985,26 +1010,26 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
985
1010
|
width: "100%"
|
|
986
1011
|
}
|
|
987
1012
|
};
|
|
988
|
-
t.value.formItems =
|
|
1013
|
+
t.value.formItems = Me(
|
|
989
1014
|
T,
|
|
990
|
-
|
|
1015
|
+
d == null ? void 0 : d.formItems,
|
|
991
1016
|
(fe = t == null ? void 0 : t.value) == null ? void 0 : fe.formItems
|
|
992
1017
|
);
|
|
993
|
-
const
|
|
1018
|
+
const E = {
|
|
994
1019
|
span: 12,
|
|
995
1020
|
offset: 0
|
|
996
1021
|
};
|
|
997
|
-
t.value.form.cols =
|
|
998
|
-
|
|
999
|
-
(
|
|
1022
|
+
t.value.form.cols = Me(
|
|
1023
|
+
E,
|
|
1024
|
+
(pe = d == null ? void 0 : d.form) == null ? void 0 : pe.cols,
|
|
1000
1025
|
t.value.form.cols
|
|
1001
1026
|
);
|
|
1002
|
-
const
|
|
1003
|
-
let
|
|
1004
|
-
if (
|
|
1005
|
-
|
|
1027
|
+
const D = (m) => {
|
|
1028
|
+
let M = [];
|
|
1029
|
+
if (m.rules)
|
|
1030
|
+
M = m.rules;
|
|
1006
1031
|
else {
|
|
1007
|
-
const
|
|
1032
|
+
const y = { ...{
|
|
1008
1033
|
required: void 0,
|
|
1009
1034
|
max: void 0,
|
|
1010
1035
|
min: void 0,
|
|
@@ -1012,73 +1037,73 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1012
1037
|
url: void 0,
|
|
1013
1038
|
pattern: void 0,
|
|
1014
1039
|
validate: void 0
|
|
1015
|
-
}, ...
|
|
1016
|
-
|
|
1017
|
-
validator: (
|
|
1018
|
-
|
|
1040
|
+
}, ...m };
|
|
1041
|
+
y.required && M.push({ required: !0, message: `${y.label}不能为空!`, trigger: "blur" }), y.max && y.min && M.push({
|
|
1042
|
+
validator: (I, ee, re) => {
|
|
1043
|
+
ee && m.type == "number" && (ee < y.min || ee > y.max) ? re(new Error(`${y.label} 必须在 ${y.min} 和 ${y.max} 之间!`)) : ee && m.type !== "number" && (ee.toString().length < y.min || ee.toString().length > y.max) ? re(new Error(`字符长度必须在 ${y.min} 和 ${y.max} 之间!`)) : re();
|
|
1019
1044
|
}
|
|
1020
|
-
}),
|
|
1021
|
-
validator: (
|
|
1022
|
-
|
|
1045
|
+
}), y.max && !y.min && m.type == "number" && M.push({
|
|
1046
|
+
validator: (I, ee, re) => {
|
|
1047
|
+
ee && ee > y.max ? re(new Error(`${y.label}不能大于${y.max}!`)) : re();
|
|
1023
1048
|
}
|
|
1024
|
-
}),
|
|
1025
|
-
validator: (
|
|
1026
|
-
|
|
1049
|
+
}), y.min && !y.max && m.type == "number" && M.push({
|
|
1050
|
+
validator: (I, ee, re) => {
|
|
1051
|
+
ee && ee < y.min ? re(new Error(`${y.label}不能小于${y.min}!`)) : re();
|
|
1027
1052
|
}
|
|
1028
|
-
}),
|
|
1029
|
-
validator: (
|
|
1053
|
+
}), y.type == "email" && M.push({ type: "email", message: "不是一个正确的邮箱地址!" }), y.type == "url" && M.push({ type: "url", message: "不是一个合正确的URL!" }), y.pattern && M.push({ pattern: y == null ? void 0 : y.pattern, message: (y == null ? void 0 : y.message) || "格式不正确!" }), y.validate && M.push({
|
|
1054
|
+
validator: (I, ee, re) => y.validate(I, ee, re)
|
|
1030
1055
|
});
|
|
1031
1056
|
}
|
|
1032
|
-
return
|
|
1033
|
-
},
|
|
1034
|
-
var
|
|
1035
|
-
const
|
|
1036
|
-
if (((
|
|
1037
|
-
const
|
|
1038
|
-
return { ...
|
|
1057
|
+
return M;
|
|
1058
|
+
}, N = (m, M = !1) => {
|
|
1059
|
+
var I, ee, re, x, $;
|
|
1060
|
+
const C = M ? m : m == null ? void 0 : m.item, y = 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) || {};
|
|
1061
|
+
if (((ee = t.value.form) == null ? void 0 : ee.modalState) === "edit") {
|
|
1062
|
+
const g = typeof (C == null ? void 0 : C.editor) == "object" ? (re = C.editor) == null ? void 0 : re.ep : typeof (C == null ? void 0 : C.editor) == "function" ? y == null ? void 0 : y.ep : {};
|
|
1063
|
+
return { ...y, ...g };
|
|
1039
1064
|
}
|
|
1040
|
-
if (((
|
|
1041
|
-
const
|
|
1042
|
-
return { ...
|
|
1065
|
+
if (((x = t.value.form) == null ? void 0 : x.modalState) === "add") {
|
|
1066
|
+
const g = typeof (C == null ? void 0 : C.editor) == "object" ? ($ = C.editor) == null ? void 0 : $.ap : typeof (C == null ? void 0 : C.editor) == "function" ? y == null ? void 0 : y.ap : {};
|
|
1067
|
+
return { ...y, ...g };
|
|
1043
1068
|
}
|
|
1044
|
-
return
|
|
1045
|
-
},
|
|
1046
|
-
var
|
|
1047
|
-
const
|
|
1048
|
-
return ((
|
|
1069
|
+
return y;
|
|
1070
|
+
}, te = (m) => {
|
|
1071
|
+
var C, y, I, ee, re;
|
|
1072
|
+
const M = typeof m.editor == "function" ? m.editor(b.value, (C = t.value.form) == null ? void 0 : C.modalState) : m.editor;
|
|
1073
|
+
return ((y = t.value.form) == null ? void 0 : y.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" ? ((re = M == null ? void 0 : M.ap) == null ? void 0 : re.type) ?? (M == null ? void 0 : M.type) ?? m.type : (M == null ? void 0 : M.type) ?? m.type;
|
|
1049
1074
|
};
|
|
1050
|
-
|
|
1051
|
-
|
|
1075
|
+
Ne(() => {
|
|
1076
|
+
L();
|
|
1052
1077
|
}), Dt(() => {
|
|
1053
|
-
|
|
1078
|
+
r.value = null;
|
|
1054
1079
|
});
|
|
1055
|
-
const
|
|
1056
|
-
for (const [
|
|
1057
|
-
t.value[
|
|
1058
|
-
},
|
|
1059
|
-
var
|
|
1060
|
-
const
|
|
1061
|
-
return t.value.form.modalState === "edit" ? ((
|
|
1062
|
-
}).map((
|
|
1063
|
-
const
|
|
1064
|
-
return Object.entries(
|
|
1065
|
-
if (
|
|
1066
|
-
const
|
|
1067
|
-
|
|
1068
|
-
groupName:
|
|
1080
|
+
const L = () => {
|
|
1081
|
+
for (const [m, M] of Object.entries(V.value))
|
|
1082
|
+
t.value[m].formItem = { ...t.value[m].formItem, ...M.formItem }, t.value[m].formItem.style = { ...t.value[m].formItem.style, ...M.formItem.style };
|
|
1083
|
+
}, 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) => {
|
|
1084
|
+
var C, y, I;
|
|
1085
|
+
const M = typeof m[1].editor == "function" ? m[1].editor(b.value, (C = t.value.form) == null ? void 0 : C.modalState) : m[1].editor;
|
|
1086
|
+
return t.value.form.modalState === "edit" ? ((y = M == null ? void 0 : M.ep) == null ? void 0 : y.editor) !== !1 : t.value.form.modalState === "add" ? ((I = M == null ? void 0 : M.ap) == null ? void 0 : I.editor) !== !1 : !0;
|
|
1087
|
+
}).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(() => {
|
|
1088
|
+
const m = /* @__PURE__ */ new Map();
|
|
1089
|
+
return Object.entries(V.value).forEach(([M, C]) => {
|
|
1090
|
+
if (C.groupName) {
|
|
1091
|
+
const y = C.groupName;
|
|
1092
|
+
m.has(y) || m.set(y, {
|
|
1093
|
+
groupName: y,
|
|
1069
1094
|
items: []
|
|
1070
|
-
}),
|
|
1095
|
+
}), m.get(y).items.push({ key: M, item: C });
|
|
1071
1096
|
}
|
|
1072
|
-
}),
|
|
1073
|
-
|
|
1074
|
-
}), Array.from(
|
|
1075
|
-
}),
|
|
1097
|
+
}), m.forEach((M) => {
|
|
1098
|
+
M.tabPane = Me(...M.items.map(({ item: C }) => C.tabPane || {}));
|
|
1099
|
+
}), Array.from(m.values());
|
|
1100
|
+
}), ae = [
|
|
1076
1101
|
{
|
|
1077
1102
|
name: "f-submit",
|
|
1078
1103
|
label: t.value.form.submit.label,
|
|
1079
1104
|
click: t.value.form.submit.click,
|
|
1080
1105
|
hidden: t.value.form.submit.hidden,
|
|
1081
|
-
info:
|
|
1106
|
+
info: ke(t.value.form.submit, (m) => !["click"].includes(m)),
|
|
1082
1107
|
sort: t.value.form.submit.sort ?? 1,
|
|
1083
1108
|
// 使用空值合并运算符
|
|
1084
1109
|
originalOrder: 0
|
|
@@ -1088,77 +1113,77 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1088
1113
|
name: "f-reset",
|
|
1089
1114
|
label: t.value.form.reset.label,
|
|
1090
1115
|
click: t.value.form.reset.click,
|
|
1091
|
-
info:
|
|
1116
|
+
info: ke(t.value.form.reset, (m) => !["click"].includes(m)),
|
|
1092
1117
|
hidden: t.value.form.reset.hidden,
|
|
1093
1118
|
sort: t.value.form.reset.sort ?? 2,
|
|
1094
1119
|
// 使用空值合并运算符
|
|
1095
1120
|
originalOrder: 1
|
|
1096
1121
|
// 添加原始顺序标识
|
|
1097
1122
|
}
|
|
1098
|
-
], K =
|
|
1099
|
-
return (
|
|
1100
|
-
const
|
|
1101
|
-
return
|
|
1123
|
+
], K = Ye(() => ae.filter((m) => !m.hidden).sort((m, M) => m.sort - M.sort || m.originalOrder - M.originalOrder));
|
|
1124
|
+
return (m, M) => {
|
|
1125
|
+
const C = R("el-form-item"), y = R("el-col"), I = R("el-tab-pane"), ee = R("el-tabs"), re = R("el-button"), x = R("el-form");
|
|
1126
|
+
return n(), O(x, S({
|
|
1102
1127
|
ref_key: "gform",
|
|
1103
|
-
ref:
|
|
1128
|
+
ref: r,
|
|
1104
1129
|
model: t.value,
|
|
1105
1130
|
style: { width: "98%", padding: 0, margin: 0, "box-sizing": "border-box" }
|
|
1106
|
-
}, o(
|
|
1107
|
-
default:
|
|
1108
|
-
|
|
1109
|
-
var
|
|
1131
|
+
}, o(ke)(t.value.form, ($) => !["footer", "submit", "reset", "slots", "type", "sort"].includes($)), { class: "g-form-container" }), {
|
|
1132
|
+
default: h(() => [
|
|
1133
|
+
w.value.length > 0 ? p(m.$slots, "default", { key: 0 }, () => {
|
|
1134
|
+
var $, g, _;
|
|
1110
1135
|
return [
|
|
1111
|
-
|
|
1136
|
+
X(ee, S({
|
|
1112
1137
|
class: "demo-tabs",
|
|
1113
|
-
modelValue:
|
|
1114
|
-
"onUpdate:modelValue":
|
|
1138
|
+
modelValue: w.value[0].groupName,
|
|
1139
|
+
"onUpdate:modelValue": M[0] || (M[0] = (s) => w.value[0].groupName = s),
|
|
1115
1140
|
style: { width: "100%" }
|
|
1116
1141
|
}, t.value.form.tabs), {
|
|
1117
|
-
default:
|
|
1118
|
-
(
|
|
1119
|
-
key:
|
|
1120
|
-
label:
|
|
1121
|
-
name:
|
|
1142
|
+
default: h(() => [
|
|
1143
|
+
(n(!0), q(G, null, j(w.value, (s) => (n(), O(I, S({
|
|
1144
|
+
key: s.groupName,
|
|
1145
|
+
label: s.groupName,
|
|
1146
|
+
name: s.groupName,
|
|
1122
1147
|
style: { width: "100%", display: "flex", "flex-wrap": "wrap" },
|
|
1123
1148
|
ref_for: !0
|
|
1124
|
-
},
|
|
1125
|
-
default:
|
|
1126
|
-
(
|
|
1127
|
-
key:
|
|
1149
|
+
}, s.tabPane), {
|
|
1150
|
+
default: h(() => [
|
|
1151
|
+
(n(!0), q(G, null, j(s.items, (i, A) => (n(), O(y, S({ ref_for: !0 }, { ...t.value.form.cols, ...i == null ? void 0 : i.item.col }, {
|
|
1152
|
+
key: i.key,
|
|
1128
1153
|
style: { width: "100%" }
|
|
1129
1154
|
}), {
|
|
1130
|
-
default:
|
|
1131
|
-
var
|
|
1155
|
+
default: h(() => {
|
|
1156
|
+
var H, J;
|
|
1132
1157
|
return [
|
|
1133
|
-
|
|
1134
|
-
label:
|
|
1135
|
-
prop: `${
|
|
1136
|
-
rules:
|
|
1158
|
+
X(C, S({
|
|
1159
|
+
label: i == null ? void 0 : i.item.label,
|
|
1160
|
+
prop: `${i.key}.value`,
|
|
1161
|
+
rules: D(i == null ? void 0 : i.item),
|
|
1137
1162
|
ref_for: !0
|
|
1138
|
-
}, { ...(
|
|
1139
|
-
default:
|
|
1140
|
-
m
|
|
1141
|
-
item:
|
|
1163
|
+
}, { ...(H = t.value) == null ? void 0 : H.formItems, ...(J = i == null ? void 0 : i.item) == null ? void 0 : J.formItem }, { style: { width: "100%" } }), {
|
|
1164
|
+
default: h(() => [
|
|
1165
|
+
p(m.$slots, "f-" + i.key, {
|
|
1166
|
+
item: i == null ? void 0 : i.item,
|
|
1142
1167
|
model: t.value
|
|
1143
1168
|
}, () => [
|
|
1144
|
-
(
|
|
1145
|
-
modelValue: t.value[
|
|
1146
|
-
"onUpdate:modelValue": (
|
|
1147
|
-
item:
|
|
1148
|
-
ctrlKey:
|
|
1149
|
-
ctrlType:
|
|
1169
|
+
(n(), O(Xe, {
|
|
1170
|
+
modelValue: t.value[i.key].value,
|
|
1171
|
+
"onUpdate:modelValue": (ue) => t.value[i.key].value = ue,
|
|
1172
|
+
item: N(i),
|
|
1173
|
+
ctrlKey: i.key,
|
|
1174
|
+
ctrlType: te(i == null ? void 0 : i.item),
|
|
1150
1175
|
model: t.value,
|
|
1151
|
-
key:
|
|
1176
|
+
key: i.key,
|
|
1152
1177
|
class: "g-ctrl-container",
|
|
1153
1178
|
t: "f",
|
|
1154
|
-
formInfo:
|
|
1155
|
-
},
|
|
1156
|
-
|
|
1157
|
-
name:
|
|
1158
|
-
fn:
|
|
1159
|
-
m
|
|
1160
|
-
data:
|
|
1161
|
-
item:
|
|
1179
|
+
formInfo: b.value
|
|
1180
|
+
}, ce({ _: 2 }, [
|
|
1181
|
+
j(m.$slots, (ue, de) => ({
|
|
1182
|
+
name: de,
|
|
1183
|
+
fn: h((he) => [
|
|
1184
|
+
p(m.$slots, de, {
|
|
1185
|
+
data: he,
|
|
1186
|
+
item: i.item,
|
|
1162
1187
|
model: t.value
|
|
1163
1188
|
})
|
|
1164
1189
|
])
|
|
@@ -1178,77 +1203,77 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1178
1203
|
]),
|
|
1179
1204
|
_: 3
|
|
1180
1205
|
}, 16, ["modelValue"]),
|
|
1181
|
-
(_ = (
|
|
1182
|
-
|
|
1183
|
-
style:
|
|
1206
|
+
(_ = (g = ($ = t.value) == null ? void 0 : $.form) == null ? void 0 : g.footer) != null && _.hidden ? be("", !0) : p(m.$slots, "f-footer", { key: 0 }, () => [
|
|
1207
|
+
Z("div", {
|
|
1208
|
+
style: Ae(t.value.form.footer.style)
|
|
1184
1209
|
}, [
|
|
1185
|
-
m
|
|
1186
|
-
(
|
|
1187
|
-
m
|
|
1188
|
-
m
|
|
1189
|
-
|
|
1190
|
-
onClick:
|
|
1210
|
+
p(m.$slots, "f-footer-left"),
|
|
1211
|
+
(n(!0), q(G, null, j(K.value, (s) => (n(), q(G, null, [
|
|
1212
|
+
p(m.$slots, s.name + "-left"),
|
|
1213
|
+
p(m.$slots, s.name, {}, () => [
|
|
1214
|
+
X(re, S({ ref_for: !0 }, s.info, {
|
|
1215
|
+
onClick: ct((i) => s.click(b.value, t.value), ["stop"])
|
|
1191
1216
|
}), {
|
|
1192
|
-
default:
|
|
1193
|
-
|
|
1217
|
+
default: h(() => [
|
|
1218
|
+
we(Ee(s == null ? void 0 : s.label), 1)
|
|
1194
1219
|
]),
|
|
1195
1220
|
_: 2
|
|
1196
1221
|
}, 1040, ["onClick"])
|
|
1197
1222
|
]),
|
|
1198
|
-
m
|
|
1223
|
+
p(m.$slots, s.name + "-right")
|
|
1199
1224
|
], 64))), 256)),
|
|
1200
|
-
m
|
|
1225
|
+
p(m.$slots, "f-footer-right")
|
|
1201
1226
|
], 4)
|
|
1202
1227
|
])
|
|
1203
1228
|
];
|
|
1204
|
-
}) : m
|
|
1205
|
-
var
|
|
1229
|
+
}) : p(m.$slots, "default", { key: 1 }, () => {
|
|
1230
|
+
var $, g, _;
|
|
1206
1231
|
return [
|
|
1207
|
-
(
|
|
1208
|
-
key:
|
|
1232
|
+
(n(!0), q(G, null, j(V.value, (s, i) => (n(), O(y, S({ ref_for: !0 }, { ...t.value.form.cols, ...s.col }, {
|
|
1233
|
+
key: i,
|
|
1209
1234
|
style: { width: "100%" }
|
|
1210
1235
|
}), {
|
|
1211
|
-
default:
|
|
1212
|
-
var
|
|
1236
|
+
default: h(() => {
|
|
1237
|
+
var A;
|
|
1213
1238
|
return [
|
|
1214
|
-
|
|
1215
|
-
label:
|
|
1216
|
-
prop: `${
|
|
1217
|
-
rules:
|
|
1239
|
+
X(C, S({
|
|
1240
|
+
label: s.label,
|
|
1241
|
+
prop: `${i}.value`,
|
|
1242
|
+
rules: D(s),
|
|
1218
1243
|
ref_for: !0
|
|
1219
|
-
}, { ...(
|
|
1220
|
-
label:
|
|
1221
|
-
m
|
|
1222
|
-
data:
|
|
1223
|
-
item:
|
|
1244
|
+
}, { ...(A = t.value) == null ? void 0 : A.formItems, ...s == null ? void 0 : s.formItem }, { style: { width: "100%" } }), {
|
|
1245
|
+
label: h((H) => [
|
|
1246
|
+
p(m.$slots, `f-${i}-label`, {
|
|
1247
|
+
data: H,
|
|
1248
|
+
item: s,
|
|
1224
1249
|
model: t.value
|
|
1225
1250
|
}, () => [
|
|
1226
|
-
|
|
1251
|
+
we(Ee(s.label), 1)
|
|
1227
1252
|
])
|
|
1228
1253
|
]),
|
|
1229
|
-
default:
|
|
1230
|
-
m
|
|
1231
|
-
item:
|
|
1254
|
+
default: h(() => [
|
|
1255
|
+
p(m.$slots, "f-" + i, {
|
|
1256
|
+
item: s,
|
|
1232
1257
|
model: t.value
|
|
1233
1258
|
}, () => [
|
|
1234
|
-
(
|
|
1235
|
-
modelValue: t.value[
|
|
1236
|
-
"onUpdate:modelValue": (
|
|
1237
|
-
item:
|
|
1238
|
-
ctrlKey:
|
|
1239
|
-
ctrlType:
|
|
1240
|
-
key:
|
|
1259
|
+
(n(), O(Xe, {
|
|
1260
|
+
modelValue: t.value[i].value,
|
|
1261
|
+
"onUpdate:modelValue": (H) => t.value[i].value = H,
|
|
1262
|
+
item: N(s, !0),
|
|
1263
|
+
ctrlKey: i,
|
|
1264
|
+
ctrlType: te(s),
|
|
1265
|
+
key: i,
|
|
1241
1266
|
model: t.value,
|
|
1242
1267
|
class: "g-ctrl-container",
|
|
1243
1268
|
t: "f",
|
|
1244
|
-
formInfo:
|
|
1245
|
-
},
|
|
1246
|
-
|
|
1247
|
-
name:
|
|
1248
|
-
fn:
|
|
1249
|
-
m
|
|
1250
|
-
data:
|
|
1251
|
-
item:
|
|
1269
|
+
formInfo: b.value
|
|
1270
|
+
}, ce({ _: 2 }, [
|
|
1271
|
+
j(m.$slots, (H, J) => ({
|
|
1272
|
+
name: J,
|
|
1273
|
+
fn: h((ue) => [
|
|
1274
|
+
p(m.$slots, J, {
|
|
1275
|
+
data: ue,
|
|
1276
|
+
item: s,
|
|
1252
1277
|
model: t.value
|
|
1253
1278
|
})
|
|
1254
1279
|
])
|
|
@@ -1262,26 +1287,26 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1262
1287
|
}),
|
|
1263
1288
|
_: 2
|
|
1264
1289
|
}, 1040))), 128)),
|
|
1265
|
-
(_ = (
|
|
1266
|
-
|
|
1267
|
-
style:
|
|
1290
|
+
(_ = (g = ($ = t.value) == null ? void 0 : $.form) == null ? void 0 : g.footer) != null && _.hidden ? be("", !0) : p(m.$slots, "f-footer", { key: 0 }, () => [
|
|
1291
|
+
Z("div", {
|
|
1292
|
+
style: Ae(t.value.form.footer.style)
|
|
1268
1293
|
}, [
|
|
1269
|
-
m
|
|
1270
|
-
(
|
|
1271
|
-
m
|
|
1272
|
-
m
|
|
1273
|
-
|
|
1274
|
-
onClick:
|
|
1294
|
+
p(m.$slots, "f-footer-left"),
|
|
1295
|
+
(n(!0), q(G, null, j(K.value, (s) => (n(), q(G, null, [
|
|
1296
|
+
p(m.$slots, s.name + "-left"),
|
|
1297
|
+
p(m.$slots, s.name, {}, () => [
|
|
1298
|
+
X(re, S({ ref_for: !0 }, s.info, {
|
|
1299
|
+
onClick: ct((i) => s.click(b.value, t.value), ["stop"])
|
|
1275
1300
|
}), {
|
|
1276
|
-
default:
|
|
1277
|
-
|
|
1301
|
+
default: h(() => [
|
|
1302
|
+
we(Ee(s == null ? void 0 : s.label), 1)
|
|
1278
1303
|
]),
|
|
1279
1304
|
_: 2
|
|
1280
1305
|
}, 1040, ["onClick"])
|
|
1281
1306
|
]),
|
|
1282
|
-
m
|
|
1307
|
+
p(m.$slots, s.name + "-right")
|
|
1283
1308
|
], 64))), 256)),
|
|
1284
|
-
m
|
|
1309
|
+
p(m.$slots, "f-footer-right")
|
|
1285
1310
|
], 4)
|
|
1286
1311
|
])
|
|
1287
1312
|
];
|
|
@@ -1293,7 +1318,7 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1293
1318
|
}
|
|
1294
1319
|
}), mt = {
|
|
1295
1320
|
__name: "g-query-item",
|
|
1296
|
-
props: /* @__PURE__ */
|
|
1321
|
+
props: /* @__PURE__ */ Be(["more"], {
|
|
1297
1322
|
modelValue: { required: !0 },
|
|
1298
1323
|
modelModifiers: {},
|
|
1299
1324
|
info: { required: !0 },
|
|
@@ -1301,44 +1326,44 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1301
1326
|
}),
|
|
1302
1327
|
emits: ["update:modelValue", "update:info"],
|
|
1303
1328
|
setup(f) {
|
|
1304
|
-
const c =
|
|
1305
|
-
const T =
|
|
1329
|
+
const c = Ie(f, "modelValue"), t = f, e = Ie(f, "info"), r = (F) => Ye(() => Object.fromEntries(Object.entries(c.value).filter((T) => T[1].search && T[1].search.more === F).map((T) => [T[0], T[1]]))).value, d = (F) => typeof F.search == "function" ? F.search(e.value) : F.search || {}, Y = (F) => {
|
|
1330
|
+
const T = d(F);
|
|
1306
1331
|
return (T == null ? void 0 : T.type) || F.type;
|
|
1307
1332
|
};
|
|
1308
1333
|
return (F, T) => {
|
|
1309
|
-
const
|
|
1310
|
-
return
|
|
1311
|
-
key:
|
|
1312
|
-
item:
|
|
1334
|
+
const E = R("el-form-item");
|
|
1335
|
+
return n(!0), q(G, null, j(r(t.more), (D, N) => p(F.$slots, `q-${N}`, {
|
|
1336
|
+
key: N,
|
|
1337
|
+
item: D,
|
|
1313
1338
|
model: c.value
|
|
1314
1339
|
}, () => [
|
|
1315
|
-
|
|
1316
|
-
label:
|
|
1340
|
+
X(E, S({
|
|
1341
|
+
label: D.label,
|
|
1317
1342
|
ref_for: !0
|
|
1318
|
-
}, { ...c.value.queryItems, ...
|
|
1319
|
-
label:
|
|
1320
|
-
|
|
1321
|
-
item:
|
|
1343
|
+
}, { ...c.value.queryItems, ...d(D) }), {
|
|
1344
|
+
label: h(() => [
|
|
1345
|
+
p(F.$slots, `q-${N}-label`, {
|
|
1346
|
+
item: D,
|
|
1322
1347
|
model: c.value
|
|
1323
1348
|
})
|
|
1324
1349
|
]),
|
|
1325
|
-
default:
|
|
1326
|
-
|
|
1327
|
-
modelValue: e.value[
|
|
1328
|
-
"onUpdate:modelValue": (
|
|
1329
|
-
item: { ...
|
|
1330
|
-
ctrlKey:
|
|
1331
|
-
ctrlType:
|
|
1350
|
+
default: h(() => [
|
|
1351
|
+
X(Xe, {
|
|
1352
|
+
modelValue: e.value[N],
|
|
1353
|
+
"onUpdate:modelValue": (te) => e.value[N] = te,
|
|
1354
|
+
item: { ...D == null ? void 0 : D.editor, ...d(D) },
|
|
1355
|
+
ctrlKey: N,
|
|
1356
|
+
ctrlType: Y(D),
|
|
1332
1357
|
model: c.value,
|
|
1333
1358
|
t: "q",
|
|
1334
1359
|
formInfo: e.value
|
|
1335
|
-
},
|
|
1336
|
-
|
|
1337
|
-
name:
|
|
1338
|
-
fn:
|
|
1339
|
-
|
|
1340
|
-
data:
|
|
1341
|
-
item:
|
|
1360
|
+
}, ce({ _: 2 }, [
|
|
1361
|
+
j(Object.keys(F.$slots), (te) => ({
|
|
1362
|
+
name: te,
|
|
1363
|
+
fn: h((L) => [
|
|
1364
|
+
p(F.$slots, te, {
|
|
1365
|
+
data: L,
|
|
1366
|
+
item: D,
|
|
1342
1367
|
model: c.value
|
|
1343
1368
|
})
|
|
1344
1369
|
])
|
|
@@ -1350,25 +1375,25 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1350
1375
|
])), 128);
|
|
1351
1376
|
};
|
|
1352
1377
|
}
|
|
1353
|
-
},
|
|
1378
|
+
}, Ue = (f, c) => {
|
|
1354
1379
|
const t = f.__vccOpts || f;
|
|
1355
|
-
for (const [e,
|
|
1356
|
-
t[e] =
|
|
1380
|
+
for (const [e, r] of c)
|
|
1381
|
+
t[e] = r;
|
|
1357
1382
|
return t;
|
|
1358
|
-
},
|
|
1383
|
+
}, Gt = {
|
|
1359
1384
|
key: 0,
|
|
1360
1385
|
class: "outer"
|
|
1361
|
-
},
|
|
1386
|
+
}, Qt = { class: "inner" }, Xt = {
|
|
1362
1387
|
__name: "g-query",
|
|
1363
1388
|
props: {
|
|
1364
1389
|
modelValue: { required: !0 },
|
|
1365
1390
|
modelModifiers: {}
|
|
1366
1391
|
},
|
|
1367
|
-
emits: /* @__PURE__ */
|
|
1392
|
+
emits: /* @__PURE__ */ Be(["query", "reset"], ["update:modelValue"]),
|
|
1368
1393
|
setup(f, { emit: c }) {
|
|
1369
|
-
const t =
|
|
1370
|
-
let
|
|
1371
|
-
const F =
|
|
1394
|
+
const t = Ie(f, "modelValue"), e = c, r = rt("options"), d = ve(!1);
|
|
1395
|
+
let Y = Object.fromEntries(Object.entries(t.value).filter((V) => V[1].search).map(([V, b]) => [V, b.value]));
|
|
1396
|
+
const F = ve(Y), T = {
|
|
1372
1397
|
hidden: !1,
|
|
1373
1398
|
type: "hidden",
|
|
1374
1399
|
labelWidth: 100,
|
|
@@ -1385,7 +1410,7 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1385
1410
|
type: "primary",
|
|
1386
1411
|
label: "更多",
|
|
1387
1412
|
click: () => {
|
|
1388
|
-
|
|
1413
|
+
d.value = !d.value;
|
|
1389
1414
|
}
|
|
1390
1415
|
},
|
|
1391
1416
|
reset: {
|
|
@@ -1394,7 +1419,7 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1394
1419
|
hidden: !1,
|
|
1395
1420
|
plain: !1,
|
|
1396
1421
|
click: () => {
|
|
1397
|
-
F.value =
|
|
1422
|
+
F.value = ve(Y), e("reset", F.value);
|
|
1398
1423
|
}
|
|
1399
1424
|
},
|
|
1400
1425
|
query: {
|
|
@@ -1402,7 +1427,7 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1402
1427
|
type: "primary",
|
|
1403
1428
|
label: "查询",
|
|
1404
1429
|
click: () => {
|
|
1405
|
-
e("query", F.value),
|
|
1430
|
+
e("query", F.value), d.value = !1;
|
|
1406
1431
|
}
|
|
1407
1432
|
},
|
|
1408
1433
|
btns: {
|
|
@@ -1414,8 +1439,8 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1414
1439
|
}
|
|
1415
1440
|
}
|
|
1416
1441
|
};
|
|
1417
|
-
t.value.query =
|
|
1418
|
-
const
|
|
1442
|
+
t.value.query = Me(T, r == null ? void 0 : r.query, t.value.query);
|
|
1443
|
+
const E = {
|
|
1419
1444
|
2: {
|
|
1420
1445
|
title: "更多查询",
|
|
1421
1446
|
showClose: !1,
|
|
@@ -1432,37 +1457,37 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1432
1457
|
trigger: "click"
|
|
1433
1458
|
}
|
|
1434
1459
|
};
|
|
1435
|
-
t.value.query.more.dialog =
|
|
1436
|
-
|
|
1460
|
+
t.value.query.more.dialog = Me(
|
|
1461
|
+
E[t.value.query.more.mode] || {},
|
|
1437
1462
|
t.value.query.more.dialog
|
|
1438
1463
|
);
|
|
1439
|
-
const
|
|
1464
|
+
const D = {
|
|
1440
1465
|
type: "hidden",
|
|
1441
1466
|
labelPosition: "right",
|
|
1442
1467
|
style: {
|
|
1443
1468
|
width: "280px"
|
|
1444
1469
|
}
|
|
1445
1470
|
};
|
|
1446
|
-
t.value.queryItems =
|
|
1447
|
-
const
|
|
1448
|
-
const
|
|
1471
|
+
t.value.queryItems = Me(D, r == null ? void 0 : r.queryItems, t.value.queryItems);
|
|
1472
|
+
const N = (V, b) => {
|
|
1473
|
+
const w = Object.keys(V.slots).filter((ae) => ae !== "default").reduce((ae, K) => (ae[K] = (ne) => V.slots[K]({
|
|
1449
1474
|
model: t.value
|
|
1450
1475
|
// 传递当前模型数据
|
|
1451
|
-
}),
|
|
1476
|
+
}), ae), {});
|
|
1452
1477
|
return qe(mt, {
|
|
1453
1478
|
modelValue: t.value,
|
|
1454
|
-
"onUpdate:modelValue": (
|
|
1479
|
+
"onUpdate:modelValue": (ae) => t.value = ae,
|
|
1455
1480
|
info: F.value,
|
|
1456
|
-
"onUpdate:info": (
|
|
1457
|
-
more:
|
|
1458
|
-
},
|
|
1459
|
-
},
|
|
1460
|
-
var
|
|
1461
|
-
const
|
|
1481
|
+
"onUpdate:info": (ae) => F.value = ae,
|
|
1482
|
+
more: b
|
|
1483
|
+
}, w);
|
|
1484
|
+
}, te = yt(), L = () => {
|
|
1485
|
+
var w, ae, K, ne, ie, fe, pe, m, M;
|
|
1486
|
+
const V = [
|
|
1462
1487
|
{
|
|
1463
1488
|
key: "query",
|
|
1464
|
-
hidden: (K = (
|
|
1465
|
-
component:
|
|
1489
|
+
hidden: (K = (ae = (w = t.value) == null ? void 0 : w.query) == null ? void 0 : ae.query) == null ? void 0 : K.hidden,
|
|
1490
|
+
component: _e,
|
|
1466
1491
|
props: {
|
|
1467
1492
|
...t.value.query.query,
|
|
1468
1493
|
onClick: t.value.query.query.click
|
|
@@ -1472,8 +1497,8 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1472
1497
|
},
|
|
1473
1498
|
{
|
|
1474
1499
|
key: "reset",
|
|
1475
|
-
hidden: (fe = (
|
|
1476
|
-
component:
|
|
1500
|
+
hidden: (fe = (ie = (ne = t.value) == null ? void 0 : ne.query) == null ? void 0 : ie.reset) == null ? void 0 : fe.hidden,
|
|
1501
|
+
component: _e,
|
|
1477
1502
|
props: {
|
|
1478
1503
|
...t.value.query.reset,
|
|
1479
1504
|
onClick: t.value.query.reset.click
|
|
@@ -1483,144 +1508,144 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1483
1508
|
},
|
|
1484
1509
|
{
|
|
1485
1510
|
key: "more",
|
|
1486
|
-
hidden: (
|
|
1487
|
-
component: t.value.query.more.mode === 3 ? Ke :
|
|
1511
|
+
hidden: (M = (m = (pe = t.value) == null ? void 0 : pe.query) == null ? void 0 : m.more) == null ? void 0 : M.hidden,
|
|
1512
|
+
component: t.value.query.more.mode === 3 ? Ke : _e,
|
|
1488
1513
|
props: t.value.query.more.mode === 3 ? { ...t.value.query.more.dialog } : {
|
|
1489
1514
|
...t.value.query.more,
|
|
1490
1515
|
onClick: t.value.query.more.click
|
|
1491
1516
|
},
|
|
1492
1517
|
label: t.value.query.more.label,
|
|
1493
1518
|
sort: t.value.query.more.sort || 0,
|
|
1494
|
-
content: t.value.query.more.mode === 3 ? () => qe(
|
|
1519
|
+
content: t.value.query.more.mode === 3 ? () => qe(ze, {
|
|
1495
1520
|
class: "query-form",
|
|
1496
|
-
...
|
|
1497
|
-
}, () =>
|
|
1521
|
+
...ke(t.value.query, (C) => !["query", "more", "reset"].includes(C))
|
|
1522
|
+
}, () => N({ slots: te }, !0)) : null
|
|
1498
1523
|
}
|
|
1499
1524
|
];
|
|
1500
|
-
return
|
|
1501
|
-
reference: () => qe(
|
|
1502
|
-
default:
|
|
1503
|
-
}) : (
|
|
1525
|
+
return V.sort((C, y) => C.sort - y.sort), V.filter((C) => !C.hidden).map((C) => C.key === "more" && C.component === Ke ? qe(Ke, C.props, {
|
|
1526
|
+
reference: () => qe(_e, t.value.query.more, () => C.label),
|
|
1527
|
+
default: C.content
|
|
1528
|
+
}) : (C.props.slot = "query-" + C.key, C.label ? qe(C.component, C.props, () => C.label) : qe(C.component, C.props)));
|
|
1504
1529
|
};
|
|
1505
|
-
return (
|
|
1506
|
-
var K,
|
|
1507
|
-
const
|
|
1508
|
-
return
|
|
1530
|
+
return (V, b) => {
|
|
1531
|
+
var K, ne, ie, fe, pe, m, M, C, y, I, ee, re, x, $, g, _, s;
|
|
1532
|
+
const w = R("el-form-item"), ae = R("el-drawer");
|
|
1533
|
+
return n(), q("div", {
|
|
1509
1534
|
class: "g-query-container",
|
|
1510
|
-
style:
|
|
1535
|
+
style: Ae((ne = (K = t.value.query) == null ? void 0 : K.container) == null ? void 0 : ne.style)
|
|
1511
1536
|
}, [
|
|
1512
|
-
|
|
1513
|
-
default:
|
|
1514
|
-
var
|
|
1537
|
+
X(o(ze), Qe(ft(o(ke)(t.value.query, (i) => !["query", "more", "reset", "btns"].includes(i)))), {
|
|
1538
|
+
default: h(() => {
|
|
1539
|
+
var i, A;
|
|
1515
1540
|
return [
|
|
1516
|
-
(
|
|
1517
|
-
((
|
|
1518
|
-
default:
|
|
1519
|
-
var
|
|
1541
|
+
(n(), O(xe(N({ slots: V.$slots }, void 0)))),
|
|
1542
|
+
((A = (i = t.value.query) == null ? void 0 : i.container) == null ? void 0 : A.inline) === !0 ? (n(), O(w, { key: 0 }, {
|
|
1543
|
+
default: h(() => {
|
|
1544
|
+
var H, J, ue, de, he;
|
|
1520
1545
|
return [
|
|
1521
|
-
|
|
1522
|
-
style:
|
|
1546
|
+
Z("div", {
|
|
1547
|
+
style: Ae((J = (H = t.value.query) == null ? void 0 : H.btns) == null ? void 0 : J.style)
|
|
1523
1548
|
}, [
|
|
1524
|
-
t.value.query.group ? (
|
|
1525
|
-
default:
|
|
1526
|
-
(
|
|
1527
|
-
(
|
|
1549
|
+
t.value.query.group ? (n(), O(o(Ge), { key: 0 }, {
|
|
1550
|
+
default: h(() => [
|
|
1551
|
+
(n(!0), q(G, null, j(L(), ($e) => p(V.$slots, $e.props.slot, {}, () => [
|
|
1552
|
+
(n(), O(xe($e)))
|
|
1528
1553
|
], !0)), 256)),
|
|
1529
|
-
|
|
1554
|
+
p(V.$slots, "q-btns", {}, void 0, !0)
|
|
1530
1555
|
]),
|
|
1531
1556
|
_: 3
|
|
1532
|
-
})) : (
|
|
1533
|
-
(
|
|
1534
|
-
default:
|
|
1535
|
-
(
|
|
1536
|
-
(
|
|
1557
|
+
})) : (n(), q(G, { key: 1 }, [
|
|
1558
|
+
(he = (de = (ue = t.value) == null ? void 0 : ue.query) == null ? void 0 : de.btns) != null && he.group ? (n(), O(o(Ge), { key: 0 }, {
|
|
1559
|
+
default: h(() => [
|
|
1560
|
+
(n(!0), q(G, null, j(L(), ($e) => p(V.$slots, $e.props.slot, {}, () => [
|
|
1561
|
+
(n(), O(xe($e)))
|
|
1537
1562
|
], !0)), 256))
|
|
1538
1563
|
]),
|
|
1539
1564
|
_: 3
|
|
1540
|
-
})) : (
|
|
1541
|
-
(
|
|
1565
|
+
})) : (n(!0), q(G, { key: 1 }, j(L(), ($e) => p(V.$slots, $e.props.slot, {}, () => [
|
|
1566
|
+
(n(), O(xe($e)))
|
|
1542
1567
|
], !0)), 256)),
|
|
1543
|
-
|
|
1568
|
+
p(V.$slots, "q-btns", {}, void 0, !0)
|
|
1544
1569
|
], 64))
|
|
1545
1570
|
], 4)
|
|
1546
1571
|
];
|
|
1547
1572
|
}),
|
|
1548
1573
|
_: 3
|
|
1549
|
-
})) :
|
|
1574
|
+
})) : be("", !0)
|
|
1550
1575
|
];
|
|
1551
1576
|
}),
|
|
1552
1577
|
_: 3
|
|
1553
1578
|
}, 16),
|
|
1554
|
-
((
|
|
1579
|
+
((pe = (fe = (ie = t.value) == null ? void 0 : ie.query) == null ? void 0 : fe.container) == null ? void 0 : pe.inline) === !1 ? (n(), q("div", {
|
|
1555
1580
|
key: 0,
|
|
1556
|
-
style:
|
|
1581
|
+
style: Ae((M = (m = t.value.query) == null ? void 0 : m.btns) == null ? void 0 : M.style)
|
|
1557
1582
|
}, [
|
|
1558
|
-
t.value.query.group ? (
|
|
1559
|
-
default:
|
|
1560
|
-
(
|
|
1561
|
-
(
|
|
1583
|
+
t.value.query.group ? (n(), O(o(Ge), { key: 0 }, {
|
|
1584
|
+
default: h(() => [
|
|
1585
|
+
(n(!0), q(G, null, j(L(), (i) => p(V.$slots, i.props.slot, {}, () => [
|
|
1586
|
+
(n(), O(xe(i)))
|
|
1562
1587
|
], !0)), 256)),
|
|
1563
|
-
|
|
1588
|
+
p(V.$slots, "q-btns", {}, void 0, !0)
|
|
1564
1589
|
]),
|
|
1565
1590
|
_: 3
|
|
1566
|
-
})) : (
|
|
1567
|
-
(
|
|
1568
|
-
default:
|
|
1569
|
-
(
|
|
1570
|
-
(
|
|
1591
|
+
})) : (n(), q(G, { key: 1 }, [
|
|
1592
|
+
(y = (C = t.value.query) == null ? void 0 : C.btns) != null && y.group ? (n(), O(o(Ge), { key: 0 }, {
|
|
1593
|
+
default: h(() => [
|
|
1594
|
+
(n(!0), q(G, null, j(L(), (i) => p(V.$slots, i.props.slot, {}, () => [
|
|
1595
|
+
(n(), O(xe(i)))
|
|
1571
1596
|
], !0)), 256))
|
|
1572
1597
|
]),
|
|
1573
1598
|
_: 3
|
|
1574
|
-
})) : (
|
|
1575
|
-
(
|
|
1599
|
+
})) : (n(!0), q(G, { key: 1 }, j(L(), (i) => p(V.$slots, i.props.slot, {}, () => [
|
|
1600
|
+
(n(), O(xe(i)))
|
|
1576
1601
|
], !0)), 256)),
|
|
1577
|
-
|
|
1602
|
+
p(V.$slots, "q-btns", {}, void 0, !0)
|
|
1578
1603
|
], 64))
|
|
1579
|
-
], 4)) :
|
|
1580
|
-
|
|
1604
|
+
], 4)) : be("", !0),
|
|
1605
|
+
X(Vt, {
|
|
1581
1606
|
duration: 300,
|
|
1582
1607
|
name: "nested"
|
|
1583
1608
|
}, {
|
|
1584
|
-
default:
|
|
1585
|
-
var
|
|
1609
|
+
default: h(() => {
|
|
1610
|
+
var i, A, H;
|
|
1586
1611
|
return [
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
t.value.query.more.mode == 1 ?
|
|
1590
|
-
default:
|
|
1591
|
-
(
|
|
1612
|
+
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(), q("div", Gt, [
|
|
1613
|
+
Z("div", Qt, [
|
|
1614
|
+
t.value.query.more.mode == 1 ? Mt((n(), O(o(ze), Qe(S({ key: 0 }, o(ke)(t.value.query, (J) => !["query", "more", "reset"].includes(J)))), {
|
|
1615
|
+
default: h(() => [
|
|
1616
|
+
(n(), O(xe(N({ slots: V.$slots }, !0))))
|
|
1592
1617
|
]),
|
|
1593
1618
|
_: 1
|
|
1594
1619
|
}, 16)), [
|
|
1595
|
-
[
|
|
1596
|
-
]) :
|
|
1620
|
+
[Ft, d.value]
|
|
1621
|
+
]) : be("", !0)
|
|
1597
1622
|
])
|
|
1598
|
-
])) :
|
|
1623
|
+
])) : be("", !0)
|
|
1599
1624
|
];
|
|
1600
1625
|
}),
|
|
1601
1626
|
_: 1
|
|
1602
1627
|
}),
|
|
1603
|
-
|
|
1628
|
+
d.value && !((re = (ee = (I = t.value) == null ? void 0 : I.query) == null ? void 0 : ee.more) != null && re.hidden) && t.value.query.more.mode == 2 ? (n(), O(ae, S({
|
|
1604
1629
|
key: 1,
|
|
1605
|
-
modelValue:
|
|
1606
|
-
"onUpdate:modelValue":
|
|
1630
|
+
modelValue: d.value,
|
|
1631
|
+
"onUpdate:modelValue": b[4] || (b[4] = (i) => d.value = i),
|
|
1607
1632
|
title: "更多查询",
|
|
1608
1633
|
"show-close": !1
|
|
1609
|
-
}, t.value.query.more.dialog),
|
|
1610
|
-
default:
|
|
1611
|
-
|
|
1612
|
-
default:
|
|
1613
|
-
|
|
1634
|
+
}, t.value.query.more.dialog), ce({
|
|
1635
|
+
default: h(() => [
|
|
1636
|
+
X(o(ze), S(o(ke)(t.value.query, (i) => !["query", "more", "reset"].includes(i)), { style: { width: "98%" } }), {
|
|
1637
|
+
default: h(() => [
|
|
1638
|
+
X(mt, {
|
|
1614
1639
|
modelValue: t.value,
|
|
1615
|
-
"onUpdate:modelValue":
|
|
1640
|
+
"onUpdate:modelValue": b[0] || (b[0] = (i) => t.value = i),
|
|
1616
1641
|
info: F.value,
|
|
1617
|
-
"onUpdate:info":
|
|
1642
|
+
"onUpdate:info": b[1] || (b[1] = (i) => F.value = i),
|
|
1618
1643
|
more: !0
|
|
1619
|
-
},
|
|
1620
|
-
|
|
1621
|
-
name:
|
|
1622
|
-
fn:
|
|
1623
|
-
|
|
1644
|
+
}, ce({ _: 2 }, [
|
|
1645
|
+
j(V.$slots, (i, A, H) => ({
|
|
1646
|
+
name: A,
|
|
1647
|
+
fn: h((J) => [
|
|
1648
|
+
p(V.$slots, A, { model: t.value }, void 0, !0)
|
|
1624
1649
|
])
|
|
1625
1650
|
}))
|
|
1626
1651
|
]), 1032, ["modelValue", "info"])
|
|
@@ -1630,23 +1655,23 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1630
1655
|
]),
|
|
1631
1656
|
_: 2
|
|
1632
1657
|
}, [
|
|
1633
|
-
(
|
|
1658
|
+
(s = (_ = (g = ($ = (x = t.value) == null ? void 0 : x.query) == null ? void 0 : $.more) == null ? void 0 : g.dialog) == null ? void 0 : _.footer) != null && s.hidden ? void 0 : {
|
|
1634
1659
|
name: "footer",
|
|
1635
|
-
fn:
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
onClick:
|
|
1660
|
+
fn: h(() => [
|
|
1661
|
+
Z("div", Qe(ft(t.value.query.more.dialog.footer)), [
|
|
1662
|
+
X(o(_e), S(t.value.query.query, {
|
|
1663
|
+
onClick: b[2] || (b[2] = (i) => t.value.query.query.click())
|
|
1639
1664
|
}), {
|
|
1640
|
-
default:
|
|
1641
|
-
|
|
1665
|
+
default: h(() => [
|
|
1666
|
+
we(Ee(t.value.query.query.label), 1)
|
|
1642
1667
|
]),
|
|
1643
1668
|
_: 1
|
|
1644
1669
|
}, 16),
|
|
1645
|
-
|
|
1646
|
-
onClick:
|
|
1670
|
+
X(o(_e), S(t.value.query.reset, {
|
|
1671
|
+
onClick: b[3] || (b[3] = (i) => t.value.query.reset.click())
|
|
1647
1672
|
}), {
|
|
1648
|
-
default:
|
|
1649
|
-
|
|
1673
|
+
default: h(() => [
|
|
1674
|
+
we(Ee(t.value.query.reset.label), 1)
|
|
1650
1675
|
]),
|
|
1651
1676
|
_: 1
|
|
1652
1677
|
}, 16)
|
|
@@ -1654,14 +1679,14 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1654
1679
|
]),
|
|
1655
1680
|
key: "0"
|
|
1656
1681
|
}
|
|
1657
|
-
]), 1040, ["modelValue"])) :
|
|
1682
|
+
]), 1040, ["modelValue"])) : be("", !0)
|
|
1658
1683
|
], 4);
|
|
1659
1684
|
};
|
|
1660
1685
|
}
|
|
1661
|
-
},
|
|
1686
|
+
}, Jt = /* @__PURE__ */ Ue(Xt, [["__scopeId", "data-v-ff97bb8a"]]), Zt = { style: { padding: "0", margin: "0", "box-sizing": "border-box" } }, Kt = { style: { padding: "10px", "box-sizing": "border-box" } }, el = { style: { margin: "10px" } }, tl = {
|
|
1662
1687
|
style: { display: "flex", "flex-wrap": "wrap" },
|
|
1663
1688
|
id: "excelSortEl"
|
|
1664
|
-
},
|
|
1689
|
+
}, ll = ["textContent"], ol = { style: { width: "100%", display: "flex", padding: "10px", "box-sizing": "border-box", "justify-content": "center", "border-top": "1px solid #dcdfe6" } }, al = {
|
|
1665
1690
|
__name: "check-excel-item",
|
|
1666
1691
|
props: {
|
|
1667
1692
|
items: Array,
|
|
@@ -1669,90 +1694,90 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1669
1694
|
},
|
|
1670
1695
|
emits: ["excel"],
|
|
1671
1696
|
setup(f, { emit: c }) {
|
|
1672
|
-
const t = f, e = c,
|
|
1673
|
-
|
|
1697
|
+
const t = f, e = c, r = ve(t.items), d = () => {
|
|
1698
|
+
r.value.forEach((T) => {
|
|
1674
1699
|
T.value = !0;
|
|
1675
1700
|
});
|
|
1676
|
-
},
|
|
1677
|
-
|
|
1701
|
+
}, Y = () => {
|
|
1702
|
+
r.value.forEach((T) => {
|
|
1678
1703
|
T.value = !1;
|
|
1679
1704
|
});
|
|
1680
1705
|
}, F = () => {
|
|
1681
|
-
e("excel",
|
|
1706
|
+
e("excel", r.value, (T, E = "excel.xls") => {
|
|
1682
1707
|
if (!T) {
|
|
1683
1708
|
console.error("下载链接无效");
|
|
1684
1709
|
return;
|
|
1685
1710
|
}
|
|
1686
1711
|
try {
|
|
1687
|
-
const
|
|
1688
|
-
|
|
1689
|
-
} catch (
|
|
1690
|
-
console.error("下载文件时出现错误:",
|
|
1712
|
+
const D = document.createElement("a");
|
|
1713
|
+
D.href = T, D.download = E, D.style.display = "none", document.body.appendChild(D), D.click(), document.body.removeChild(D);
|
|
1714
|
+
} catch (D) {
|
|
1715
|
+
console.error("下载文件时出现错误:", D);
|
|
1691
1716
|
}
|
|
1692
1717
|
});
|
|
1693
1718
|
};
|
|
1694
|
-
return
|
|
1719
|
+
return Ne(() => {
|
|
1695
1720
|
const T = new bt(document.getElementById("excelSortEl"), {
|
|
1696
1721
|
animation: 150,
|
|
1697
1722
|
onEnd: () => {
|
|
1698
|
-
let
|
|
1699
|
-
console.log(
|
|
1723
|
+
let D = T.toArray();
|
|
1724
|
+
console.log(D);
|
|
1700
1725
|
}
|
|
1701
|
-
}),
|
|
1702
|
-
|
|
1703
|
-
|
|
1726
|
+
}), E = T;
|
|
1727
|
+
Tt(() => {
|
|
1728
|
+
E && E.destroy();
|
|
1704
1729
|
});
|
|
1705
|
-
}), (T,
|
|
1706
|
-
const
|
|
1707
|
-
return
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
onClick:
|
|
1730
|
+
}), (T, E) => {
|
|
1731
|
+
const D = R("el-divider"), N = R("el-alert"), te = R("el-checkbox"), L = R("el-button");
|
|
1732
|
+
return n(), q("div", Zt, [
|
|
1733
|
+
Z("div", Kt, [
|
|
1734
|
+
Z("div", el, [
|
|
1735
|
+
Z("a", {
|
|
1736
|
+
onClick: d,
|
|
1712
1737
|
style: { cursor: "pointer" }
|
|
1713
1738
|
}, "全选"),
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
onClick:
|
|
1739
|
+
X(D, { direction: "vertical" }),
|
|
1740
|
+
Z("a", {
|
|
1741
|
+
onClick: Y,
|
|
1717
1742
|
style: { cursor: "pointer" }
|
|
1718
1743
|
}, "全不选")
|
|
1719
1744
|
]),
|
|
1720
|
-
|
|
1745
|
+
X(N, {
|
|
1721
1746
|
title: "拖动列标题可以改变表格列的生成顺序 !",
|
|
1722
1747
|
type: "warning",
|
|
1723
1748
|
"show-icon": "",
|
|
1724
1749
|
closable: !1,
|
|
1725
1750
|
style: { "margin-bottom": "10px" }
|
|
1726
1751
|
}),
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
(
|
|
1752
|
+
E[0] || (E[0] = Z("div", { style: { margin: "1px 0" } }, null, -1)),
|
|
1753
|
+
Z("div", tl, [
|
|
1754
|
+
(n(!0), q(G, null, j(r.value, (V) => (n(), O(te, {
|
|
1730
1755
|
class: "check-box-hover",
|
|
1731
1756
|
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" },
|
|
1732
|
-
"data-id":
|
|
1733
|
-
modelValue:
|
|
1734
|
-
"onUpdate:modelValue": (
|
|
1735
|
-
key:
|
|
1736
|
-
title:
|
|
1757
|
+
"data-id": V.key,
|
|
1758
|
+
modelValue: V.value,
|
|
1759
|
+
"onUpdate:modelValue": (b) => V.value = b,
|
|
1760
|
+
key: V.key,
|
|
1761
|
+
title: V.label
|
|
1737
1762
|
}, {
|
|
1738
|
-
default:
|
|
1739
|
-
|
|
1740
|
-
textContent: Ee(
|
|
1763
|
+
default: h(() => [
|
|
1764
|
+
Z("span", {
|
|
1765
|
+
textContent: Ee(V.label),
|
|
1741
1766
|
style: { display: "block", "text-overflow": "ellipsis", width: "95px", overflow: "hidden" }
|
|
1742
|
-
}, null, 8,
|
|
1767
|
+
}, null, 8, ll)
|
|
1743
1768
|
]),
|
|
1744
1769
|
_: 2
|
|
1745
1770
|
}, 1032, ["data-id", "modelValue", "onUpdate:modelValue", "title"]))), 128))
|
|
1746
1771
|
])
|
|
1747
1772
|
]),
|
|
1748
|
-
|
|
1749
|
-
|
|
1773
|
+
Z("div", ol, [
|
|
1774
|
+
X(L, {
|
|
1750
1775
|
type: "primary",
|
|
1751
1776
|
onClick: F,
|
|
1752
|
-
disabled:
|
|
1777
|
+
disabled: r.value.filter((V) => V.value).length < 1
|
|
1753
1778
|
}, {
|
|
1754
|
-
default:
|
|
1755
|
-
|
|
1779
|
+
default: h(() => [
|
|
1780
|
+
we(Ee(t.commitText), 1)
|
|
1756
1781
|
]),
|
|
1757
1782
|
_: 1
|
|
1758
1783
|
}, 8, ["disabled"])
|
|
@@ -1760,46 +1785,46 @@ const et = /* @__PURE__ */ jt(Rt), Nt = {
|
|
|
1760
1785
|
]);
|
|
1761
1786
|
};
|
|
1762
1787
|
}
|
|
1763
|
-
},
|
|
1764
|
-
|
|
1788
|
+
}, rl = /* @__PURE__ */ Ue(al, [["__scopeId", "data-v-51dfb7ef"]]), Oe = new Bt("gyc");
|
|
1789
|
+
Oe.version(1).stores({
|
|
1765
1790
|
tableInfo: "++id,[user+page+key],user,page,key,showCol,width,sort",
|
|
1766
1791
|
tableList: "++id,name"
|
|
1767
1792
|
});
|
|
1768
|
-
async function
|
|
1769
|
-
if (await
|
|
1770
|
-
let
|
|
1771
|
-
return await
|
|
1793
|
+
async function He(f, c, t, e = {}) {
|
|
1794
|
+
if (await Oe.tableInfo.where({ user: f, page: c, key: t }).count() > 0) {
|
|
1795
|
+
let d = await Oe.tableInfo.where({ user: f, page: c, key: t }).first();
|
|
1796
|
+
return await Oe.tableInfo.put({ ...d, ...e }), "update success";
|
|
1772
1797
|
} else {
|
|
1773
|
-
let
|
|
1774
|
-
return await
|
|
1798
|
+
let d = { showCol: !0, width: "auto", sort: 0, ...e };
|
|
1799
|
+
return await Oe.tableInfo.add({ user: f, page: c, key: t, ...d }), "add success";
|
|
1775
1800
|
}
|
|
1776
1801
|
}
|
|
1777
|
-
async function
|
|
1778
|
-
return await
|
|
1802
|
+
async function nl(f, c) {
|
|
1803
|
+
return await Oe.tableInfo.where({ user: f, page: c }).toArray();
|
|
1779
1804
|
}
|
|
1780
|
-
async function
|
|
1805
|
+
async function ul(f, c) {
|
|
1781
1806
|
try {
|
|
1782
|
-
const t = await
|
|
1807
|
+
const t = await Oe.tableInfo.where({ user: f, page: c }).delete();
|
|
1783
1808
|
return console.log("删除了" + t + "条数据"), t;
|
|
1784
1809
|
} catch (t) {
|
|
1785
1810
|
throw console.error("删除表格项设置信息时出错:", t), t;
|
|
1786
1811
|
}
|
|
1787
1812
|
}
|
|
1788
|
-
async function
|
|
1789
|
-
return await
|
|
1813
|
+
async function sl(f) {
|
|
1814
|
+
return await Oe.tableList.where({ name: f }).first();
|
|
1790
1815
|
}
|
|
1791
|
-
async function
|
|
1792
|
-
return typeof f == "string" && (f = { name: f }), await
|
|
1816
|
+
async function il(f) {
|
|
1817
|
+
return typeof f == "string" && (f = { name: f }), await Oe.tableList.add(f), "add success";
|
|
1793
1818
|
}
|
|
1794
|
-
const
|
|
1819
|
+
const dl = {
|
|
1795
1820
|
style: { margin: "10px" },
|
|
1796
1821
|
class: "allcheck"
|
|
1797
|
-
},
|
|
1822
|
+
}, cl = {
|
|
1798
1823
|
id: "cols",
|
|
1799
1824
|
style: { display: "flex", "flex-wrap": "wrap", margin: "0 !important", padding: "0 !important" }
|
|
1800
|
-
},
|
|
1825
|
+
}, fl = ["textContent"], ml = {
|
|
1801
1826
|
__name: "columns-setting",
|
|
1802
|
-
props: /* @__PURE__ */
|
|
1827
|
+
props: /* @__PURE__ */ Be({
|
|
1803
1828
|
name: {
|
|
1804
1829
|
type: String,
|
|
1805
1830
|
required: !0
|
|
@@ -1810,34 +1835,34 @@ const ul = {
|
|
|
1810
1835
|
}),
|
|
1811
1836
|
emits: ["update:modelValue"],
|
|
1812
1837
|
setup(f) {
|
|
1813
|
-
const c = f, t =
|
|
1814
|
-
|
|
1838
|
+
const c = f, t = ve([]), e = Ie(f, "modelValue"), r = async (E, D) => {
|
|
1839
|
+
E ? e.value[D].showCol = !0 : e.value[D].showCol = !1;
|
|
1815
1840
|
try {
|
|
1816
|
-
const
|
|
1817
|
-
console.log(
|
|
1818
|
-
} catch (
|
|
1819
|
-
console.error("列显示状态保存信息时出错:",
|
|
1841
|
+
const N = await He(e.value.table.user, c.name, D, { showCol: E });
|
|
1842
|
+
console.log(N);
|
|
1843
|
+
} catch (N) {
|
|
1844
|
+
console.error("列显示状态保存信息时出错:", N), Fe({
|
|
1820
1845
|
type: "error",
|
|
1821
1846
|
message: "列显示状态保存信息失败!"
|
|
1822
1847
|
});
|
|
1823
1848
|
}
|
|
1824
|
-
},
|
|
1825
|
-
const
|
|
1826
|
-
if (
|
|
1827
|
-
let
|
|
1849
|
+
}, d = () => {
|
|
1850
|
+
const E = document.getElementById("cols");
|
|
1851
|
+
if (E) {
|
|
1852
|
+
let D = bt.create(E, {
|
|
1828
1853
|
animation: 150,
|
|
1829
1854
|
filter: ".filtered",
|
|
1830
1855
|
//
|
|
1831
1856
|
sort: !0,
|
|
1832
1857
|
onEnd: () => {
|
|
1833
|
-
|
|
1834
|
-
e.value[
|
|
1835
|
-
let
|
|
1858
|
+
D.toArray().forEach(async (te, L) => {
|
|
1859
|
+
e.value[te].sort = L;
|
|
1860
|
+
let V = e.value[te].width || "auto";
|
|
1836
1861
|
try {
|
|
1837
|
-
const
|
|
1838
|
-
console.log(
|
|
1839
|
-
} catch (
|
|
1840
|
-
console.error("列排序和宽度保存信息时出错:",
|
|
1862
|
+
const b = await He(e.value.table.user, c.name, te, { sort: L, width: V });
|
|
1863
|
+
console.log(b);
|
|
1864
|
+
} catch (b) {
|
|
1865
|
+
console.error("列排序和宽度保存信息时出错:", b), Fe({
|
|
1841
1866
|
type: "error",
|
|
1842
1867
|
message: "列排序和宽度保存信息失败!"
|
|
1843
1868
|
});
|
|
@@ -1846,37 +1871,37 @@ const ul = {
|
|
|
1846
1871
|
}
|
|
1847
1872
|
});
|
|
1848
1873
|
}
|
|
1849
|
-
},
|
|
1874
|
+
}, Y = async () => {
|
|
1850
1875
|
try {
|
|
1851
|
-
for (const
|
|
1852
|
-
|
|
1853
|
-
const
|
|
1876
|
+
for (const E of t.value) {
|
|
1877
|
+
E.showCol = !0, e.value[E.value].showCol = !0;
|
|
1878
|
+
const D = await He(e.value.table.user, c.name, E.value, {
|
|
1854
1879
|
showCol: !0,
|
|
1855
|
-
width:
|
|
1856
|
-
sort:
|
|
1880
|
+
width: E.width,
|
|
1881
|
+
sort: E.sort
|
|
1857
1882
|
});
|
|
1858
|
-
console.log(
|
|
1883
|
+
console.log(D);
|
|
1859
1884
|
}
|
|
1860
|
-
} catch (
|
|
1861
|
-
console.error("全选列保存信息时出错:",
|
|
1885
|
+
} catch (E) {
|
|
1886
|
+
console.error("全选列保存信息时出错:", E), Fe({
|
|
1862
1887
|
type: "error",
|
|
1863
1888
|
message: "全选列保存信息失败!"
|
|
1864
1889
|
});
|
|
1865
1890
|
}
|
|
1866
1891
|
}, F = async () => {
|
|
1867
1892
|
try {
|
|
1868
|
-
const
|
|
1869
|
-
for (const
|
|
1870
|
-
|
|
1871
|
-
const
|
|
1893
|
+
const E = t.value.filter((D) => !D.alwaysShow);
|
|
1894
|
+
for (const D of E) {
|
|
1895
|
+
D.showCol = !1, e.value[D.value].showCol = !1;
|
|
1896
|
+
const N = await He(e.value.table.user, c.name, D.value, {
|
|
1872
1897
|
showCol: !1,
|
|
1873
|
-
width:
|
|
1874
|
-
sort:
|
|
1898
|
+
width: D.width,
|
|
1899
|
+
sort: D.sort
|
|
1875
1900
|
});
|
|
1876
|
-
console.log(
|
|
1901
|
+
console.log(N);
|
|
1877
1902
|
}
|
|
1878
|
-
} catch (
|
|
1879
|
-
console.error("清除列保存信息时出错:",
|
|
1903
|
+
} catch (E) {
|
|
1904
|
+
console.error("清除列保存信息时出错:", E), Fe({
|
|
1880
1905
|
type: "error",
|
|
1881
1906
|
message: "清除列保存信息失败!"
|
|
1882
1907
|
});
|
|
@@ -1887,61 +1912,61 @@ const ul = {
|
|
|
1887
1912
|
cancelButtonText: "取消",
|
|
1888
1913
|
type: "warning"
|
|
1889
1914
|
}).then(() => {
|
|
1890
|
-
|
|
1891
|
-
console.log(
|
|
1892
|
-
}).catch((
|
|
1893
|
-
console.error("复位操作出错:",
|
|
1915
|
+
ul(e.value.table.user, c.name).then((E) => {
|
|
1916
|
+
console.log(E), window.location.reload();
|
|
1917
|
+
}).catch((E) => {
|
|
1918
|
+
console.error("复位操作出错:", E), Fe({
|
|
1894
1919
|
type: "info",
|
|
1895
1920
|
message: "复位失败!"
|
|
1896
1921
|
});
|
|
1897
1922
|
});
|
|
1898
1923
|
});
|
|
1899
1924
|
};
|
|
1900
|
-
return
|
|
1901
|
-
t.value = Object.entries(e.value).filter(([,
|
|
1902
|
-
label:
|
|
1903
|
-
value:
|
|
1904
|
-
alwaysShow:
|
|
1905
|
-
showCol:
|
|
1906
|
-
sort:
|
|
1907
|
-
width:
|
|
1908
|
-
})).sort((
|
|
1909
|
-
}), (
|
|
1910
|
-
const
|
|
1911
|
-
return
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
|
|
1925
|
+
return Ne(async () => {
|
|
1926
|
+
t.value = Object.entries(e.value).filter(([, E]) => E.visible !== !1).filter(([, E]) => E.type != "hidden").map(([E, D]) => ({
|
|
1927
|
+
label: D.label,
|
|
1928
|
+
value: E,
|
|
1929
|
+
alwaysShow: D.alwaysShow,
|
|
1930
|
+
showCol: D.showCol !== !1,
|
|
1931
|
+
sort: D.sort || 0,
|
|
1932
|
+
width: D.width || "auto"
|
|
1933
|
+
})).sort((E, D) => E.sort - D.sort), d();
|
|
1934
|
+
}), (E, D) => {
|
|
1935
|
+
const N = R("el-divider"), te = R("el-alert"), L = R("el-checkbox");
|
|
1936
|
+
return n(), q("div", null, [
|
|
1937
|
+
Z("div", dl, [
|
|
1938
|
+
Z("a", { onClick: Y }, "全选"),
|
|
1939
|
+
X(N, { direction: "vertical" }),
|
|
1940
|
+
Z("a", { onClick: F }, "全不选"),
|
|
1941
|
+
X(N, { direction: "vertical" }),
|
|
1942
|
+
Z("a", { onClick: T }, "复位")
|
|
1918
1943
|
]),
|
|
1919
|
-
|
|
1944
|
+
X(te, {
|
|
1920
1945
|
title: "拖动表格列标题可以改变表格列显示顺序 !",
|
|
1921
1946
|
type: "warning",
|
|
1922
1947
|
"show-icon": "",
|
|
1923
1948
|
closable: !1,
|
|
1924
1949
|
style: { "margin-bottom": "10px" }
|
|
1925
1950
|
}),
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
(
|
|
1929
|
-
modelValue:
|
|
1930
|
-
"onUpdate:modelValue": (
|
|
1931
|
-
"data-id":
|
|
1932
|
-
class: gt(["check-box-hover",
|
|
1933
|
-
onChange: (
|
|
1951
|
+
Z("div", null, [
|
|
1952
|
+
Z("div", cl, [
|
|
1953
|
+
(n(!0), q(G, null, j(t.value, (V) => (n(), O(L, {
|
|
1954
|
+
modelValue: V.showCol,
|
|
1955
|
+
"onUpdate:modelValue": (b) => V.showCol = b,
|
|
1956
|
+
"data-id": V.value,
|
|
1957
|
+
class: gt(["check-box-hover", V.value == "control" ? "filtered" : ""]),
|
|
1958
|
+
onChange: (b) => r(b, V.value),
|
|
1934
1959
|
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" },
|
|
1935
|
-
value:
|
|
1936
|
-
title:
|
|
1937
|
-
disabled:
|
|
1938
|
-
key:
|
|
1960
|
+
value: V.value,
|
|
1961
|
+
title: V.label,
|
|
1962
|
+
disabled: V.alwaysShow,
|
|
1963
|
+
key: V.value
|
|
1939
1964
|
}, {
|
|
1940
|
-
default:
|
|
1941
|
-
|
|
1942
|
-
textContent: Ee(
|
|
1965
|
+
default: h(() => [
|
|
1966
|
+
Z("span", {
|
|
1967
|
+
textContent: Ee(V.label),
|
|
1943
1968
|
style: { display: "block", "text-overflow": "ellipsis", width: "95px", overflow: "hidden" }
|
|
1944
|
-
}, null, 8,
|
|
1969
|
+
}, null, 8, fl)
|
|
1945
1970
|
]),
|
|
1946
1971
|
_: 2
|
|
1947
1972
|
}, 1032, ["modelValue", "onUpdate:modelValue", "data-id", "class", "onChange", "value", "title", "disabled"]))), 128))
|
|
@@ -1950,30 +1975,30 @@ const ul = {
|
|
|
1950
1975
|
]);
|
|
1951
1976
|
};
|
|
1952
1977
|
}
|
|
1953
|
-
},
|
|
1978
|
+
}, pl = /* @__PURE__ */ Ue(ml, [["__scopeId", "data-v-c423ede0"]]), vl = { class: "g-table-container" }, hl = {
|
|
1954
1979
|
key: 0,
|
|
1955
1980
|
class: "table-query-container"
|
|
1956
|
-
},
|
|
1981
|
+
}, yl = { class: "table-container" }, gl = ["src"], bl = ["innerHTML"], $l = { key: 0 }, El = { style: { display: "flex", "margin-top": "-2px" } }, wl = { style: { display: "flex", flex: "1" } }, _l = {
|
|
1957
1982
|
style: { display: "flex", "justify-content": "center", width: "100%", height: "100%" },
|
|
1958
1983
|
id: "table-form"
|
|
1959
|
-
},
|
|
1984
|
+
}, kl = { key: 1 }, Cl = { style: { display: "flex" } }, Dl = { style: { display: "flex", flex: "1" } }, Vl = /* @__PURE__ */ Object.assign({
|
|
1960
1985
|
name: "g-table",
|
|
1961
1986
|
inheritAttrs: !1
|
|
1962
1987
|
}, {
|
|
1963
1988
|
__name: "g-table",
|
|
1964
|
-
props: /* @__PURE__ */
|
|
1989
|
+
props: /* @__PURE__ */ Be({
|
|
1965
1990
|
name: String,
|
|
1966
1991
|
require: !0
|
|
1967
1992
|
}, {
|
|
1968
1993
|
modelValue: { required: !0 },
|
|
1969
1994
|
modelModifiers: {}
|
|
1970
1995
|
}),
|
|
1971
|
-
emits: /* @__PURE__ */
|
|
1996
|
+
emits: /* @__PURE__ */ Be(["load", "open", "delete", "submit", "reset", "download", "row-save"], ["update:modelValue"]),
|
|
1972
1997
|
setup(f, { emit: c }) {
|
|
1973
|
-
var
|
|
1974
|
-
const t = c, e =
|
|
1975
|
-
|
|
1976
|
-
const F =
|
|
1998
|
+
var Ce, Te, De, u, P, se, Ve;
|
|
1999
|
+
const t = c, e = Ie(f, "modelValue"), r = rt("options"), d = ve({}), Y = Object.entries(e.value).filter(([l, a]) => (a == null ? void 0 : a.search) !== void 0).map(([l, a]) => [l, a.value]);
|
|
2000
|
+
d.value = Object.fromEntries(Y);
|
|
2001
|
+
const F = ve(!1), T = ["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 = ve([]), D = f, N = nt(), te = ve({}), L = ve([]), V = {
|
|
1977
2002
|
autoWatch: !1,
|
|
1978
2003
|
data: [],
|
|
1979
2004
|
border: !0,
|
|
@@ -1982,30 +2007,30 @@ const ul = {
|
|
|
1982
2007
|
fit: !1,
|
|
1983
2008
|
type: "hidden",
|
|
1984
2009
|
load: () => {
|
|
1985
|
-
let { currentPage: l, pageSize:
|
|
2010
|
+
let { currentPage: l, pageSize: a } = e.value.table.page;
|
|
1986
2011
|
try {
|
|
1987
|
-
t("load", { currentPage: l, pageSize:
|
|
1988
|
-
var
|
|
1989
|
-
if (!Array.isArray(
|
|
2012
|
+
t("load", { currentPage: l, pageSize: a, ...d.value }, (v, B, { fields: z = [], sums: Q = {} } = {}) => {
|
|
2013
|
+
var me, Se;
|
|
2014
|
+
if (!Array.isArray(v)) {
|
|
1990
2015
|
console.error("从 load 事件回调中接收到的数据不是数组格式。"), Fe.error("数据加载失败,请检查数据格式。");
|
|
1991
2016
|
return;
|
|
1992
2017
|
}
|
|
1993
|
-
if (typeof
|
|
2018
|
+
if (typeof B != "number") {
|
|
1994
2019
|
console.error("从 load 事件回调中接收到的 total 不是数字格式。"), Fe.error("数据加载失败,请检查数据格式。");
|
|
1995
2020
|
return;
|
|
1996
2021
|
}
|
|
1997
|
-
e.value.table.data =
|
|
2022
|
+
e.value.table.data = v, ((Se = (me = e.value.control) == null ? void 0 : me.add) == null ? void 0 : Se.inline) === !0 && e.value.table.data.unshift(ie), e.value.table.page.total = B, L.value = z, te.value = Q, de();
|
|
1998
2023
|
});
|
|
1999
|
-
} catch (
|
|
2000
|
-
console.error("触发 load 事件时出现错误:",
|
|
2024
|
+
} catch (v) {
|
|
2025
|
+
console.error("触发 load 事件时出现错误:", v), Fe.error("数据加载时出现错误,请稍后重试。");
|
|
2001
2026
|
}
|
|
2002
2027
|
},
|
|
2003
|
-
onHeaderDragend: (l,
|
|
2004
|
-
var
|
|
2005
|
-
|
|
2028
|
+
onHeaderDragend: (l, a, v) => {
|
|
2029
|
+
var B;
|
|
2030
|
+
He((B = e.value.table) == null ? void 0 : B.user, D.name, v.property, { width: l });
|
|
2006
2031
|
},
|
|
2007
|
-
onRowDblclick: (l,
|
|
2008
|
-
e.value.table.dblclickType == "edit" ?
|
|
2032
|
+
onRowDblclick: (l, a, v) => {
|
|
2033
|
+
e.value.table.dblclickType == "edit" ? C(l, a, v, e) : e.value.table.dblclickType == "view" && I(l, a, v, e);
|
|
2009
2034
|
},
|
|
2010
2035
|
style: { "min-height": "100px", backgroundColor: "var(--el-bg-color)" },
|
|
2011
2036
|
page: {
|
|
@@ -2029,23 +2054,23 @@ const ul = {
|
|
|
2029
2054
|
}
|
|
2030
2055
|
},
|
|
2031
2056
|
dblclickType: "edit",
|
|
2032
|
-
"summary-method": ({ columns: l, data:
|
|
2033
|
-
onSortChange: ({ column: l, prop:
|
|
2057
|
+
"summary-method": ({ columns: l, data: a }, v) => v,
|
|
2058
|
+
onSortChange: ({ column: l, prop: a, order: v }, B) => {
|
|
2034
2059
|
}
|
|
2035
2060
|
};
|
|
2036
|
-
e.value.table =
|
|
2037
|
-
|
|
2038
|
-
|
|
2061
|
+
e.value.table = Me(
|
|
2062
|
+
V,
|
|
2063
|
+
r == null ? void 0 : r.table,
|
|
2039
2064
|
e.value.table,
|
|
2040
|
-
|
|
2065
|
+
N
|
|
2041
2066
|
// 继承父组件的属性
|
|
2042
2067
|
);
|
|
2043
|
-
const
|
|
2068
|
+
const b = {
|
|
2044
2069
|
type: "control",
|
|
2045
2070
|
label: "操作",
|
|
2046
2071
|
width: 250,
|
|
2047
2072
|
fixed: "right",
|
|
2048
|
-
style: { ...(
|
|
2073
|
+
style: { ...(Te = (Ce = e.value) == null ? void 0 : Ce.control) == null ? void 0 : Te.style },
|
|
2049
2074
|
validate: (l) => !0,
|
|
2050
2075
|
add: {
|
|
2051
2076
|
label: "新增",
|
|
@@ -2061,25 +2086,25 @@ const ul = {
|
|
|
2061
2086
|
text: !0,
|
|
2062
2087
|
type: "success",
|
|
2063
2088
|
mode: "dialog",
|
|
2064
|
-
auth: (l,
|
|
2089
|
+
auth: (l, a, v) => !1
|
|
2065
2090
|
},
|
|
2066
2091
|
edit: {
|
|
2067
2092
|
label: "编辑",
|
|
2068
2093
|
text: !0,
|
|
2069
2094
|
type: "primary",
|
|
2070
2095
|
mode: "dialog",
|
|
2071
|
-
auth: (l,
|
|
2072
|
-
var
|
|
2073
|
-
return ((Q = (
|
|
2096
|
+
auth: (l, a, v) => {
|
|
2097
|
+
var B, z, Q;
|
|
2098
|
+
return ((Q = (z = (B = e.value) == null ? void 0 : B.control) == null ? void 0 : z.add) == null ? void 0 : Q.inline) === !1;
|
|
2074
2099
|
}
|
|
2075
2100
|
},
|
|
2076
2101
|
delete: {
|
|
2077
2102
|
text: !0,
|
|
2078
2103
|
label: "删除",
|
|
2079
2104
|
type: "danger",
|
|
2080
|
-
auth: (l,
|
|
2081
|
-
var
|
|
2082
|
-
return !(((Q = (
|
|
2105
|
+
auth: (l, a, v) => {
|
|
2106
|
+
var B, z, Q;
|
|
2107
|
+
return !(((Q = (z = (B = e.value) == null ? void 0 : B.control) == null ? void 0 : z.add) == null ? void 0 : Q.inline) === !0 && v === 0);
|
|
2083
2108
|
},
|
|
2084
2109
|
dialog: {
|
|
2085
2110
|
message: "此操作将永久删除该文件, 是否继续?",
|
|
@@ -2109,37 +2134,37 @@ const ul = {
|
|
|
2109
2134
|
sort: -1,
|
|
2110
2135
|
addLabel: "新增",
|
|
2111
2136
|
auth: () => {
|
|
2112
|
-
var l,
|
|
2113
|
-
return ((
|
|
2137
|
+
var l, a, v;
|
|
2138
|
+
return ((v = (a = (l = e.value) == null ? void 0 : l.control) == null ? void 0 : a.add) == null ? void 0 : v.inline) === !0;
|
|
2114
2139
|
}
|
|
2115
2140
|
}
|
|
2116
2141
|
};
|
|
2117
|
-
e.value.control =
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
(
|
|
2142
|
+
e.value.control = Me(
|
|
2143
|
+
b,
|
|
2144
|
+
r == null ? void 0 : r.control,
|
|
2145
|
+
(De = e.value) == null ? void 0 : De.control
|
|
2121
2146
|
);
|
|
2122
|
-
const
|
|
2147
|
+
const w = {
|
|
2123
2148
|
type: "hidden",
|
|
2124
2149
|
minWidth: 120,
|
|
2125
2150
|
align: "center",
|
|
2126
|
-
formatter: (l,
|
|
2151
|
+
formatter: (l, a, v, B) => v
|
|
2127
2152
|
};
|
|
2128
|
-
e.value.tableColumns =
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
(
|
|
2153
|
+
e.value.tableColumns = Me(
|
|
2154
|
+
w,
|
|
2155
|
+
r == null ? void 0 : r.tableColumns,
|
|
2156
|
+
(u = e.value) == null ? void 0 : u.tableColumns
|
|
2132
2157
|
);
|
|
2133
|
-
const
|
|
2158
|
+
const ae = {
|
|
2134
2159
|
type: "hidden",
|
|
2135
2160
|
disabled: void 0,
|
|
2136
2161
|
footer: { hidden: !1 },
|
|
2137
2162
|
modalState: void 0
|
|
2138
2163
|
};
|
|
2139
|
-
e.value.form =
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
(
|
|
2164
|
+
e.value.form = Me(
|
|
2165
|
+
ae,
|
|
2166
|
+
r == null ? void 0 : r.form,
|
|
2167
|
+
(P = e.value) == null ? void 0 : P.form
|
|
2143
2168
|
);
|
|
2144
2169
|
const K = {
|
|
2145
2170
|
type: "hidden",
|
|
@@ -2148,12 +2173,12 @@ const ul = {
|
|
|
2148
2173
|
width: "100%"
|
|
2149
2174
|
}
|
|
2150
2175
|
};
|
|
2151
|
-
e.value.formItems =
|
|
2176
|
+
e.value.formItems = Me(
|
|
2152
2177
|
K,
|
|
2153
|
-
|
|
2154
|
-
(
|
|
2178
|
+
r == null ? void 0 : r.formItems,
|
|
2179
|
+
(se = e == null ? void 0 : e.value) == null ? void 0 : se.formItems
|
|
2155
2180
|
);
|
|
2156
|
-
const
|
|
2181
|
+
const ne = {
|
|
2157
2182
|
title: "编辑",
|
|
2158
2183
|
mode: "drawer",
|
|
2159
2184
|
type: "hidden",
|
|
@@ -2161,257 +2186,257 @@ const ul = {
|
|
|
2161
2186
|
size: 700,
|
|
2162
2187
|
fullScreen: !1
|
|
2163
2188
|
};
|
|
2164
|
-
e.value.dialog =
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
(
|
|
2189
|
+
e.value.dialog = Me(
|
|
2190
|
+
ne,
|
|
2191
|
+
r == null ? void 0 : r.dialog,
|
|
2192
|
+
(Ve = e.value) == null ? void 0 : Ve.dialog
|
|
2168
2193
|
);
|
|
2169
|
-
const
|
|
2170
|
-
let
|
|
2171
|
-
if (l.decimals && !isNaN(parseFloat(
|
|
2172
|
-
const
|
|
2194
|
+
const ie = Object.fromEntries(Object.entries(ke(e.value, (l, a) => a.type != "control" && a.editor !== !1 && a.type != "hidden")).map(([l, a]) => [l, a.value])), fe = (l, a) => {
|
|
2195
|
+
let v = a;
|
|
2196
|
+
if (l.decimals && !isNaN(parseFloat(a)) && (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(a).isValid()) {
|
|
2197
|
+
const z = {
|
|
2173
2198
|
date: "YYYY-MM-DD",
|
|
2174
2199
|
datetime: "YYYY-MM-DD HH:mm:ss",
|
|
2175
2200
|
time: "HH:mm:ss"
|
|
2176
2201
|
};
|
|
2177
|
-
|
|
2202
|
+
v = l.format ? et(v).format(l.format) : et(v).format(z[l.type]);
|
|
2178
2203
|
}
|
|
2179
|
-
return l.type === "money" && (l.align = l.align || "right", l.width = l.width || 130,
|
|
2180
|
-
},
|
|
2181
|
-
|
|
2182
|
-
},
|
|
2183
|
-
|
|
2184
|
-
},
|
|
2185
|
-
var
|
|
2186
|
-
e.value.form.modalState = "add", (
|
|
2187
|
-
e.value[
|
|
2204
|
+
return l.type === "money" && (l.align = l.align || "right", l.width = l.width || 130, v = `<span title="${at(parseFloat(v))}">${Ll(parseFloat(v))}</span>`), l.prefix && v && (v = `<span>${l.prefix}${v}</span>`), l.suffix && v && (v = `${v}<span>${l.suffix}</span>`), v;
|
|
2205
|
+
}, pe = (l) => {
|
|
2206
|
+
d.value = l.value;
|
|
2207
|
+
}, m = (l) => {
|
|
2208
|
+
d.value = l, e.value.table.load();
|
|
2209
|
+
}, M = (l) => {
|
|
2210
|
+
var a, v;
|
|
2211
|
+
e.value.form.modalState = "add", (a = e.value.control) != null && a.validate("add", { m: l }) && ((v = e.value.control.add) != null && v.click ? e.value.control.add.click(l) : e.value.control.add.inline === !0 ? (console.log(ie), e.value.table.data.unshift(ie), t("open", "row-add", { initFormData: ie })) : (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(ie).forEach((B) => {
|
|
2212
|
+
e.value[B] && (e.value[B].value = ie[B]);
|
|
2188
2213
|
}), F.value = !0, t("open", "add", { m: l })));
|
|
2189
|
-
},
|
|
2190
|
-
var
|
|
2191
|
-
e.value.form.modalState = "edit", (
|
|
2192
|
-
e.value[
|
|
2193
|
-
}), F.value = !0, t("open", "edit", { m:
|
|
2194
|
-
},
|
|
2195
|
-
var
|
|
2196
|
-
if ((
|
|
2214
|
+
}, C = (l, a, v, B) => {
|
|
2215
|
+
var z, Q;
|
|
2216
|
+
e.value.form.modalState = "edit", (z = e.value.control) != null && z.validate("edit", { row: l, column: a, $index: v, m: B }) && ((Q = e.value.control.edit) != null && Q.click ? e.value.control.edit.click(l, a, v, B) : (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((me) => {
|
|
2217
|
+
e.value[me] && (e.value[me].value = l[me]);
|
|
2218
|
+
}), F.value = !0, t("open", "edit", { m: B, row: l, column: a, $index: v })));
|
|
2219
|
+
}, y = (l, a, v, B) => {
|
|
2220
|
+
var z, Q;
|
|
2221
|
+
if ((z = e.value.control) != null && z.validate("delete", { row: l, column: a, $index: v, m: B }))
|
|
2197
2222
|
if ((Q = e.value.control.delete) != null && Q.click)
|
|
2198
|
-
e.value.control.delete.click(l,
|
|
2223
|
+
e.value.control.delete.click(l, a, v, B);
|
|
2199
2224
|
else {
|
|
2200
|
-
let { message:
|
|
2201
|
-
vt.confirm(
|
|
2202
|
-
t("delete", { row: l, column:
|
|
2203
|
-
We && (e.value.table.data.splice(
|
|
2225
|
+
let { message: me, title: Se, options: Pe } = e.value.control.delete.dialog;
|
|
2226
|
+
vt.confirm(me, Se, Pe).then(() => {
|
|
2227
|
+
t("delete", { row: l, column: a, $index: v }, (We) => {
|
|
2228
|
+
We && (e.value.table.data.splice(v, 1), e.value.table.page.total--);
|
|
2204
2229
|
});
|
|
2205
2230
|
}).catch(() => {
|
|
2206
2231
|
});
|
|
2207
2232
|
}
|
|
2208
|
-
},
|
|
2209
|
-
var
|
|
2210
|
-
e.value.form.modalState = void 0, (
|
|
2211
|
-
e.value[
|
|
2212
|
-
}), F.value = !0, t("open", "view", { m:
|
|
2213
|
-
},
|
|
2214
|
-
var
|
|
2215
|
-
(
|
|
2233
|
+
}, I = (l, a, v, B) => {
|
|
2234
|
+
var z, Q;
|
|
2235
|
+
e.value.form.modalState = void 0, (z = e.value.control) != null && z.validate("view", { row: l, column: a, $index: v, m: B }) && ((Q = e.value.control.view) != null && Q.click ? e.value.control.view.click(l, a, v, B) : (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((me) => {
|
|
2236
|
+
e.value[me] && (e.value[me].value = l[me]);
|
|
2237
|
+
}), F.value = !0, t("open", "view", { m: B, row: l, column: a, $index: v })));
|
|
2238
|
+
}, ee = (l, a, v, B) => {
|
|
2239
|
+
var z;
|
|
2240
|
+
(z = e.value.control.save) != null && z.click ? e.value.control.save.click(l, a, v, B) : t("row-save", { row: l, column: a, $index: v, data: e.value.table.data }, (Q) => {
|
|
2216
2241
|
Q && e.value.table.load();
|
|
2217
2242
|
});
|
|
2218
|
-
},
|
|
2219
|
-
t("submit", e.value.form.modalState, l,
|
|
2220
|
-
|
|
2243
|
+
}, re = (l, a) => {
|
|
2244
|
+
t("submit", e.value.form.modalState, l, a, (v) => {
|
|
2245
|
+
v && (F.value = !1, a.table.load());
|
|
2221
2246
|
});
|
|
2222
|
-
},
|
|
2247
|
+
}, x = (l) => {
|
|
2223
2248
|
t("reset", l);
|
|
2224
|
-
},
|
|
2225
|
-
var
|
|
2226
|
-
if ((
|
|
2227
|
-
l.control.download.click(l,
|
|
2249
|
+
}, $ = (l, a) => {
|
|
2250
|
+
var v;
|
|
2251
|
+
if ((v = l.control.download) != null && v.click)
|
|
2252
|
+
l.control.download.click(l, a);
|
|
2228
2253
|
else {
|
|
2229
|
-
let
|
|
2254
|
+
let B = ot({
|
|
2230
2255
|
title: l.control.download.label,
|
|
2231
2256
|
size: 480,
|
|
2232
2257
|
width: 600,
|
|
2233
2258
|
slots: {
|
|
2234
|
-
default: () => qe(
|
|
2235
|
-
items:
|
|
2259
|
+
default: () => qe(rl, {
|
|
2260
|
+
items: a,
|
|
2236
2261
|
commitText: l.control.download.excelLabel,
|
|
2237
|
-
onExcel: (
|
|
2238
|
-
t("download",
|
|
2262
|
+
onExcel: (z, Q) => {
|
|
2263
|
+
t("download", z, Q), B();
|
|
2239
2264
|
}
|
|
2240
2265
|
})
|
|
2241
2266
|
}
|
|
2242
2267
|
}, l.control.download.mode);
|
|
2243
2268
|
}
|
|
2244
|
-
},
|
|
2245
|
-
var
|
|
2246
|
-
(
|
|
2269
|
+
}, g = (l) => {
|
|
2270
|
+
var a;
|
|
2271
|
+
(a = l.control.setting) != null && a.click ? l.control.setting.click(l) : ot({
|
|
2247
2272
|
title: l.control.setting.label,
|
|
2248
2273
|
size: 470,
|
|
2249
2274
|
width: 600,
|
|
2250
2275
|
slots: {
|
|
2251
|
-
default: () => qe(
|
|
2276
|
+
default: () => qe(pl, {
|
|
2252
2277
|
modelValue: l,
|
|
2253
|
-
name:
|
|
2278
|
+
name: D.name
|
|
2254
2279
|
})
|
|
2255
2280
|
}
|
|
2256
2281
|
}, l.control.setting.mode);
|
|
2257
|
-
}, _ = e.value.control,
|
|
2258
|
-
{ type: "add", func:
|
|
2259
|
-
{ type: "download", func:
|
|
2260
|
-
{ type: "setting", func:
|
|
2261
|
-
{ type: "view", func:
|
|
2262
|
-
{ type: "edit", func:
|
|
2263
|
-
{ type: "delete", func:
|
|
2264
|
-
{ type: "save", func:
|
|
2265
|
-
],
|
|
2266
|
-
var
|
|
2282
|
+
}, _ = e.value.control, s = [
|
|
2283
|
+
{ type: "add", func: M },
|
|
2284
|
+
{ type: "download", func: $ },
|
|
2285
|
+
{ type: "setting", func: g },
|
|
2286
|
+
{ type: "view", func: I },
|
|
2287
|
+
{ type: "edit", func: C },
|
|
2288
|
+
{ type: "delete", func: y },
|
|
2289
|
+
{ type: "save", func: ee }
|
|
2290
|
+
], i = (l) => s.filter((a) => l.includes(a.type)).map(({ type: a, func: v }) => {
|
|
2291
|
+
var B, z, Q;
|
|
2267
2292
|
return {
|
|
2268
|
-
name: `control-${
|
|
2269
|
-
attr: _ == null ? void 0 : _[
|
|
2270
|
-
func:
|
|
2271
|
-
label: (
|
|
2272
|
-
sort: ((
|
|
2273
|
-
groupName: ((Q = _ == null ? void 0 : _[
|
|
2293
|
+
name: `control-${a}`,
|
|
2294
|
+
attr: _ == null ? void 0 : _[a],
|
|
2295
|
+
func: v,
|
|
2296
|
+
label: (B = _ == null ? void 0 : _[a]) == null ? void 0 : B.label,
|
|
2297
|
+
sort: ((z = _ == null ? void 0 : _[a]) == null ? void 0 : z.sort) || 0,
|
|
2298
|
+
groupName: ((Q = _ == null ? void 0 : _[a]) == null ? void 0 : Q.groupName) || "default"
|
|
2274
2299
|
};
|
|
2275
|
-
}).sort((
|
|
2276
|
-
const
|
|
2277
|
-
return
|
|
2278
|
-
}, {}),
|
|
2279
|
-
Object.entries(e.value).filter(([l,
|
|
2280
|
-
)),
|
|
2281
|
-
const
|
|
2282
|
-
for (const Q of
|
|
2283
|
-
if (Q.value ==
|
|
2300
|
+
}).sort((a, v) => a.sort - v.sort), A = (l) => i(l).reduce((a, v) => {
|
|
2301
|
+
const B = v.groupName || "default";
|
|
2302
|
+
return a[B] || (a[B] = []), a[B].push(v), a;
|
|
2303
|
+
}, {}), H = Ye(() => Object.fromEntries(
|
|
2304
|
+
Object.entries(e.value).filter(([l, a]) => a.type !== "hidden").filter(([l, a]) => a.visible !== !1).filter(([l, a]) => a.showCol !== !1).map(([l, a]) => (a.sort = typeof a.sort == "number" ? a.sort : 0, [l, a])).sort((l, a) => l[1].sort - a[1].sort)
|
|
2305
|
+
)), J = ve({}), ue = (l, a) => {
|
|
2306
|
+
const v = (B, z) => {
|
|
2307
|
+
for (const Q of B) {
|
|
2308
|
+
if (Q.value == z) return Q.label;
|
|
2284
2309
|
if (Q.children) {
|
|
2285
|
-
const
|
|
2286
|
-
if (
|
|
2310
|
+
const me = v(Q.children, z);
|
|
2311
|
+
if (me) return me;
|
|
2287
2312
|
}
|
|
2288
2313
|
}
|
|
2289
2314
|
return null;
|
|
2290
2315
|
};
|
|
2291
2316
|
if (l.getDicts) {
|
|
2292
|
-
const
|
|
2293
|
-
return
|
|
2294
|
-
|
|
2317
|
+
const B = a.toString();
|
|
2318
|
+
return J.value[B] ? (l.options = J.value[B], l.formatter || (l.formatter = (z, Q, me, Se) => l.options && v(l.options, me) || me), Promise.resolve()) : l.getDicts(e.value.table.data).then((z) => {
|
|
2319
|
+
J.value[B] = z, l.options = z, l.formatter || (l.formatter = (Q, me, Se, Pe) => l.options && v(l.options, Se) || Se);
|
|
2295
2320
|
});
|
|
2296
2321
|
}
|
|
2297
2322
|
return Promise.resolve();
|
|
2298
|
-
},
|
|
2323
|
+
}, de = () => {
|
|
2299
2324
|
const l = [];
|
|
2300
|
-
Object.keys(e.value).forEach((
|
|
2301
|
-
if (e.value[
|
|
2302
|
-
const
|
|
2303
|
-
e.value.table.data.forEach((
|
|
2304
|
-
var
|
|
2305
|
-
if (e.value[
|
|
2306
|
-
const Q =
|
|
2307
|
-
|
|
2325
|
+
Object.keys(e.value).forEach((a) => {
|
|
2326
|
+
if (e.value[a].getDicts) {
|
|
2327
|
+
const v = ue(e.value[a], a).then(() => {
|
|
2328
|
+
e.value.table.data.forEach((B) => {
|
|
2329
|
+
var z;
|
|
2330
|
+
if (e.value[a].getDicts && ((z = e.value[a]) == null ? void 0 : z.forceString) !== !1) {
|
|
2331
|
+
const Q = B[a];
|
|
2332
|
+
B[a] = Q != null ? Q.toString() : Q;
|
|
2308
2333
|
}
|
|
2309
2334
|
});
|
|
2310
|
-
}).catch((
|
|
2311
|
-
console.error(`加载字典${
|
|
2335
|
+
}).catch((B) => {
|
|
2336
|
+
console.error(`加载字典${a}出错:`, B);
|
|
2312
2337
|
});
|
|
2313
|
-
l.push(
|
|
2338
|
+
l.push(v);
|
|
2314
2339
|
}
|
|
2315
|
-
}), Promise.all(l).catch((
|
|
2316
|
-
console.error("字典加载过程中发生错误:",
|
|
2340
|
+
}), Promise.all(l).catch((a) => {
|
|
2341
|
+
console.error("字典加载过程中发生错误:", a);
|
|
2317
2342
|
});
|
|
2318
|
-
},
|
|
2319
|
-
var
|
|
2320
|
-
return l.table ? (
|
|
2321
|
-
},
|
|
2322
|
-
return
|
|
2343
|
+
}, he = (l, a, v, B) => {
|
|
2344
|
+
var z, Q;
|
|
2345
|
+
return l.table ? (z = l.table(a, v, B)) != null && z.auth ? (Q = l.table(a, v, B)) == null ? void 0 : Q.auth(a, v, B) : !0 : !1;
|
|
2346
|
+
}, $e = (l, a) => l.name === "control-save" && a === 0 && e.value.control.add.inline === !0 ? l.attr.addLabel : l.label;
|
|
2347
|
+
return St(() => {
|
|
2323
2348
|
e.value.table.autoWatch && e.value.table.load();
|
|
2324
|
-
}),
|
|
2349
|
+
}), Ne(async () => {
|
|
2325
2350
|
var l;
|
|
2326
|
-
if (
|
|
2351
|
+
if (E.value = Object.values(e.value).filter((a) => a.type !== "hidden").filter((a) => a.type !== "control").filter((a) => a.visible !== !1).map((a) => ({ key: a.key || "", label: a.label, value: !0 })), !((l = e.value.table) != null && l.user)) {
|
|
2327
2352
|
Fe.error("必须给使用此表格的用户一个名字!");
|
|
2328
2353
|
return;
|
|
2329
2354
|
}
|
|
2330
|
-
if (!
|
|
2355
|
+
if (!D.name) {
|
|
2331
2356
|
Fe.error("必须给表格一个唯一的name属性");
|
|
2332
2357
|
return;
|
|
2333
2358
|
}
|
|
2334
2359
|
try {
|
|
2335
|
-
let
|
|
2336
|
-
if (
|
|
2337
|
-
if (
|
|
2360
|
+
let a = await sl(D.name);
|
|
2361
|
+
if (a) {
|
|
2362
|
+
if (D.name !== a.name) {
|
|
2338
2363
|
Fe.error("此表格已经存在,请换一个名字!");
|
|
2339
2364
|
return;
|
|
2340
2365
|
}
|
|
2341
2366
|
} else
|
|
2342
|
-
await
|
|
2343
|
-
} catch (
|
|
2344
|
-
console.error("检查表格名称时出现错误:",
|
|
2367
|
+
await il({ name: D.name });
|
|
2368
|
+
} catch (a) {
|
|
2369
|
+
console.error("检查表格名称时出现错误:", a), Fe.error("检查表格名称时出现错误,请稍后重试。");
|
|
2345
2370
|
}
|
|
2346
2371
|
try {
|
|
2347
|
-
const
|
|
2348
|
-
|
|
2349
|
-
e.value[
|
|
2372
|
+
const a = await nl(e.value.table.user, D.name);
|
|
2373
|
+
a && a.forEach((v) => {
|
|
2374
|
+
e.value[v.key] && (e.value[v.key].width = v.width, e.value[v.key].showCol = v.showCol, e.value[v.key].sort = v.sort);
|
|
2350
2375
|
});
|
|
2351
|
-
} catch (
|
|
2352
|
-
console.error("Error fetching table column settings:",
|
|
2376
|
+
} catch (a) {
|
|
2377
|
+
console.error("Error fetching table column settings:", a);
|
|
2353
2378
|
}
|
|
2354
2379
|
e.value.table.autoWatch || e.value.table.load();
|
|
2355
|
-
}), (l,
|
|
2356
|
-
var We,
|
|
2357
|
-
const
|
|
2358
|
-
return
|
|
2359
|
-
|
|
2360
|
-
((
|
|
2361
|
-
|
|
2362
|
-
|
|
2380
|
+
}), (l, a) => {
|
|
2381
|
+
var We, ut, st, it, dt;
|
|
2382
|
+
const v = R("el-button-group"), B = R("el-table-column"), z = R("el-table"), Q = R("el-pagination"), me = R("el-icon"), Se = R("el-dialog"), Pe = R("el-drawer");
|
|
2383
|
+
return n(), q(G, null, [
|
|
2384
|
+
Z("div", vl, [
|
|
2385
|
+
((ut = (We = e.value) == null ? void 0 : We.query) == null ? void 0 : ut.hidden) != !0 ? (n(), q("div", hl, [
|
|
2386
|
+
p(l.$slots, "query", {}, () => [
|
|
2387
|
+
X(Jt, {
|
|
2363
2388
|
modelValue: e.value,
|
|
2364
|
-
"onUpdate:modelValue":
|
|
2365
|
-
onQuery:
|
|
2366
|
-
onReset:
|
|
2367
|
-
},
|
|
2368
|
-
"q-btns":
|
|
2369
|
-
|
|
2370
|
-
(
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
(
|
|
2374
|
-
|
|
2389
|
+
"onUpdate:modelValue": a[0] || (a[0] = (U) => e.value = U),
|
|
2390
|
+
onQuery: m,
|
|
2391
|
+
onReset: pe
|
|
2392
|
+
}, ce({
|
|
2393
|
+
"q-btns": h(() => [
|
|
2394
|
+
p(l.$slots, "q-btns", {}, () => [
|
|
2395
|
+
(n(!0), q(G, null, j(A(["add", "download", "setting"]), (U, le) => (n(), q(G, null, [
|
|
2396
|
+
le == "default" ? (n(!0), q(G, { key: 0 }, j(U, (k) => (n(), q(G, null, [
|
|
2397
|
+
p(l.$slots, k.name + "-left", {}, void 0, !0),
|
|
2398
|
+
(k.name === "control-add" ? k.attr.auth() && k.attr.inline === !1 : k.attr.auth()) ? p(l.$slots, k.name, { key: 0 }, () => [
|
|
2399
|
+
k.label ? (n(), O(o(_e), S({
|
|
2375
2400
|
key: 0,
|
|
2376
2401
|
ref_for: !0
|
|
2377
|
-
},
|
|
2378
|
-
onClick: (
|
|
2402
|
+
}, k.attr, {
|
|
2403
|
+
onClick: (W) => k.func(e.value, E.value)
|
|
2379
2404
|
}), {
|
|
2380
|
-
default:
|
|
2381
|
-
|
|
2405
|
+
default: h(() => [
|
|
2406
|
+
we(Ee(k.label), 1)
|
|
2382
2407
|
]),
|
|
2383
2408
|
_: 2
|
|
2384
|
-
}, 1040, ["onClick"])) : (
|
|
2409
|
+
}, 1040, ["onClick"])) : (n(), O(o(_e), S({
|
|
2385
2410
|
key: 1,
|
|
2386
2411
|
ref_for: !0
|
|
2387
|
-
},
|
|
2388
|
-
onClick: (
|
|
2412
|
+
}, k.attr, {
|
|
2413
|
+
onClick: (W) => k.func(e.value, E.value)
|
|
2389
2414
|
}), null, 16, ["onClick"]))
|
|
2390
|
-
], !0) :
|
|
2391
|
-
|
|
2392
|
-
], 64))), 256)) : (
|
|
2393
|
-
default:
|
|
2394
|
-
(
|
|
2395
|
-
|
|
2396
|
-
(
|
|
2397
|
-
|
|
2415
|
+
], !0) : be("", !0),
|
|
2416
|
+
p(l.$slots, k.name + "-right", {}, void 0, !0)
|
|
2417
|
+
], 64))), 256)) : (n(), O(v, { key: 1 }, {
|
|
2418
|
+
default: h(() => [
|
|
2419
|
+
(n(!0), q(G, null, j(U, (k) => (n(), q(G, null, [
|
|
2420
|
+
p(l.$slots, k.name + "-left", {}, void 0, !0),
|
|
2421
|
+
(k.name === "control-add" ? k.attr.auth() && k.attr.inline === !1 : k.attr.auth()) ? p(l.$slots, k.name, { key: 0 }, () => [
|
|
2422
|
+
k.label ? (n(), O(o(_e), S({
|
|
2398
2423
|
key: 0,
|
|
2399
2424
|
ref_for: !0
|
|
2400
|
-
},
|
|
2401
|
-
onClick: (
|
|
2425
|
+
}, k.attr, {
|
|
2426
|
+
onClick: (W) => k.func(e.value, E.value)
|
|
2402
2427
|
}), {
|
|
2403
|
-
default:
|
|
2404
|
-
|
|
2428
|
+
default: h(() => [
|
|
2429
|
+
we(Ee(k.label), 1)
|
|
2405
2430
|
]),
|
|
2406
2431
|
_: 2
|
|
2407
|
-
}, 1040, ["onClick"])) : (
|
|
2432
|
+
}, 1040, ["onClick"])) : (n(), O(o(_e), S({
|
|
2408
2433
|
key: 1,
|
|
2409
2434
|
ref_for: !0
|
|
2410
|
-
},
|
|
2411
|
-
onClick: (
|
|
2435
|
+
}, k.attr, {
|
|
2436
|
+
onClick: (W) => k.func(e.value, E.value)
|
|
2412
2437
|
}), null, 16, ["onClick"]))
|
|
2413
|
-
], !0) :
|
|
2414
|
-
|
|
2438
|
+
], !0) : be("", !0),
|
|
2439
|
+
p(l.$slots, k.name + "-right", {}, void 0, !0)
|
|
2415
2440
|
], 64))), 256))
|
|
2416
2441
|
]),
|
|
2417
2442
|
_: 2
|
|
@@ -2421,225 +2446,225 @@ const ul = {
|
|
|
2421
2446
|
]),
|
|
2422
2447
|
_: 2
|
|
2423
2448
|
}, [
|
|
2424
|
-
|
|
2425
|
-
name:
|
|
2426
|
-
fn:
|
|
2427
|
-
|
|
2449
|
+
j(l.$slots, (U, le, k) => ({
|
|
2450
|
+
name: le,
|
|
2451
|
+
fn: h((W) => [
|
|
2452
|
+
p(l.$slots, le, { model: e.value }, void 0, !0)
|
|
2428
2453
|
])
|
|
2429
2454
|
}))
|
|
2430
2455
|
]), 1032, ["modelValue"])
|
|
2431
2456
|
], !0)
|
|
2432
|
-
])) :
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
"summary-method": (
|
|
2436
|
-
onSortChange:
|
|
2437
|
-
var
|
|
2438
|
-
e.value.table.onSortChange(
|
|
2457
|
+
])) : be("", !0),
|
|
2458
|
+
Z("div", yl, [
|
|
2459
|
+
X(z, S({ ...l.$attrs, ...o(ke)(e.value.table, (U) => !["dblclickType", "page"].includes(U)) }, {
|
|
2460
|
+
"summary-method": (U) => e.value.table["summary-method"](U, { fields: L.value, sums: te.value }),
|
|
2461
|
+
onSortChange: a[1] || (a[1] = (U) => {
|
|
2462
|
+
var le, k;
|
|
2463
|
+
e.value.table.onSortChange(U, d.value), ((le = U == null ? void 0 : U.column) == null ? void 0 : le.sortable) === "custom" && ((k = e.value.table) == null || k.load());
|
|
2439
2464
|
})
|
|
2440
2465
|
}), {
|
|
2441
|
-
append:
|
|
2442
|
-
|
|
2466
|
+
append: h(() => [
|
|
2467
|
+
p(l.$slots, "append", {}, void 0, !0)
|
|
2443
2468
|
]),
|
|
2444
|
-
empty:
|
|
2445
|
-
|
|
2469
|
+
empty: h(() => [
|
|
2470
|
+
p(l.$slots, "empty", {}, void 0, !0)
|
|
2446
2471
|
]),
|
|
2447
|
-
default:
|
|
2448
|
-
|
|
2449
|
-
(
|
|
2450
|
-
prop:
|
|
2451
|
-
key:
|
|
2472
|
+
default: h(() => [
|
|
2473
|
+
p(l.$slots, "default", {}, () => [
|
|
2474
|
+
(n(!0), q(G, null, j(H.value, (U, le) => (n(), O(B, S({
|
|
2475
|
+
prop: le,
|
|
2476
|
+
key: le,
|
|
2452
2477
|
ref_for: !0
|
|
2453
|
-
}, { ...e.value.tableColumns, ...o(
|
|
2454
|
-
header:
|
|
2455
|
-
|
|
2478
|
+
}, { ...e.value.tableColumns, ...o(ke)(U, (k) => T.includes(k)) }, { "header-align": "center" }), ce({
|
|
2479
|
+
header: h(({ column: k, $index: W }) => [
|
|
2480
|
+
le == "control" ? p(l.$slots, `${le}-header`, {
|
|
2456
2481
|
key: 0,
|
|
2457
|
-
column:
|
|
2458
|
-
$index:
|
|
2482
|
+
column: k,
|
|
2483
|
+
$index: W
|
|
2459
2484
|
}, () => [
|
|
2460
|
-
|
|
2461
|
-
], !0) :
|
|
2485
|
+
a[10] || (a[10] = Z("span", null, "操作", -1))
|
|
2486
|
+
], !0) : p(l.$slots, `${le}-header`, {
|
|
2462
2487
|
key: 1,
|
|
2463
|
-
column:
|
|
2464
|
-
$index:
|
|
2488
|
+
column: k,
|
|
2489
|
+
$index: W
|
|
2465
2490
|
}, void 0, !0)
|
|
2466
2491
|
]),
|
|
2467
|
-
"filter-icon":
|
|
2468
|
-
|
|
2492
|
+
"filter-icon": h((k) => [
|
|
2493
|
+
p(l.$slots, `${le}-filter-icon`, { data: k }, void 0, !0)
|
|
2469
2494
|
]),
|
|
2470
2495
|
_: 2
|
|
2471
2496
|
}, [
|
|
2472
|
-
|
|
2497
|
+
U.type === "image" ? {
|
|
2473
2498
|
name: "default",
|
|
2474
|
-
fn:
|
|
2475
|
-
|
|
2476
|
-
row:
|
|
2477
|
-
column:
|
|
2478
|
-
$index:
|
|
2499
|
+
fn: h(({ row: k, column: W, $index: oe }) => [
|
|
2500
|
+
p(l.$slots, `${le}`, {
|
|
2501
|
+
row: k,
|
|
2502
|
+
column: W,
|
|
2503
|
+
$index: oe
|
|
2479
2504
|
}, () => [
|
|
2480
|
-
|
|
2505
|
+
Z("img", S({
|
|
2481
2506
|
style: { width: "80px", height: "80px", "object-fit": "cover", "border-radius": "3px" },
|
|
2482
|
-
src:
|
|
2507
|
+
src: U.value,
|
|
2483
2508
|
ref_for: !0
|
|
2484
|
-
},
|
|
2509
|
+
}, U), null, 16, gl)
|
|
2485
2510
|
], !0)
|
|
2486
2511
|
]),
|
|
2487
2512
|
key: "0"
|
|
2488
|
-
} :
|
|
2513
|
+
} : U.type === "expand" ? {
|
|
2489
2514
|
name: "default",
|
|
2490
|
-
fn:
|
|
2491
|
-
|
|
2492
|
-
row:
|
|
2493
|
-
column:
|
|
2494
|
-
$index:
|
|
2515
|
+
fn: h(({ row: k, column: W, $index: oe }) => [
|
|
2516
|
+
p(l.$slots, `${le}`, {
|
|
2517
|
+
row: k,
|
|
2518
|
+
column: W,
|
|
2519
|
+
$index: oe
|
|
2495
2520
|
}, void 0, !0)
|
|
2496
2521
|
]),
|
|
2497
2522
|
key: "1"
|
|
2498
|
-
} :
|
|
2523
|
+
} : U.type == "control" ? {
|
|
2499
2524
|
name: "default",
|
|
2500
|
-
fn:
|
|
2501
|
-
var
|
|
2525
|
+
fn: h(({ row: k, column: W, $index: oe }) => {
|
|
2526
|
+
var je, Re;
|
|
2502
2527
|
return [
|
|
2503
|
-
|
|
2504
|
-
class: gt(["control", (
|
|
2505
|
-
style:
|
|
2528
|
+
Z("div", {
|
|
2529
|
+
class: gt(["control", (je = e.value.control) == null ? void 0 : je.class]),
|
|
2530
|
+
style: Ae((Re = e.value.control) == null ? void 0 : Re.style)
|
|
2506
2531
|
}, [
|
|
2507
|
-
|
|
2508
|
-
|
|
2509
|
-
row:
|
|
2510
|
-
column:
|
|
2511
|
-
$index:
|
|
2532
|
+
p(l.$slots, "control", {}, () => [
|
|
2533
|
+
p(l.$slots, "control-left", {
|
|
2534
|
+
row: k,
|
|
2535
|
+
column: W,
|
|
2536
|
+
$index: oe
|
|
2512
2537
|
}, void 0, !0),
|
|
2513
|
-
(
|
|
2514
|
-
Je == "default" ? (
|
|
2515
|
-
|
|
2516
|
-
row:
|
|
2517
|
-
column:
|
|
2518
|
-
$index:
|
|
2538
|
+
(n(!0), q(G, null, j(A(["view", "edit", "delete", "save"]), (Le, Je) => (n(), q(G, null, [
|
|
2539
|
+
Je == "default" ? (n(!0), q(G, { key: 0 }, j(Le, (ye) => (n(), q(G, null, [
|
|
2540
|
+
p(l.$slots, ye.name + "-left", {
|
|
2541
|
+
row: k,
|
|
2542
|
+
column: W,
|
|
2543
|
+
$index: oe
|
|
2519
2544
|
}, void 0, !0),
|
|
2520
|
-
|
|
2545
|
+
ye.attr.auth(k, W, oe) ? p(l.$slots, ye.name, {
|
|
2521
2546
|
key: 0,
|
|
2522
|
-
row:
|
|
2523
|
-
column:
|
|
2524
|
-
$index:
|
|
2547
|
+
row: k,
|
|
2548
|
+
column: W,
|
|
2549
|
+
$index: oe
|
|
2525
2550
|
}, () => [
|
|
2526
|
-
|
|
2551
|
+
ye.label ? (n(), O(o(_e), S({
|
|
2527
2552
|
key: 0,
|
|
2528
2553
|
ref_for: !0
|
|
2529
|
-
},
|
|
2530
|
-
onClick: (Ze) =>
|
|
2554
|
+
}, ye.attr, {
|
|
2555
|
+
onClick: (Ze) => ye.func(k, W, oe, e.value)
|
|
2531
2556
|
}), {
|
|
2532
|
-
default:
|
|
2533
|
-
|
|
2557
|
+
default: h(() => [
|
|
2558
|
+
we(Ee($e(ye, oe)), 1)
|
|
2534
2559
|
]),
|
|
2535
2560
|
_: 2
|
|
2536
|
-
}, 1040, ["onClick"])) : (
|
|
2561
|
+
}, 1040, ["onClick"])) : (n(), O(o(_e), S({
|
|
2537
2562
|
key: 1,
|
|
2538
2563
|
ref_for: !0
|
|
2539
|
-
},
|
|
2540
|
-
onClick: (Ze) =>
|
|
2564
|
+
}, ye.attr, {
|
|
2565
|
+
onClick: (Ze) => ye.func(k, W, oe, e.value)
|
|
2541
2566
|
}), null, 16, ["onClick"]))
|
|
2542
|
-
], !0) :
|
|
2543
|
-
|
|
2544
|
-
row:
|
|
2545
|
-
column:
|
|
2546
|
-
$index:
|
|
2567
|
+
], !0) : be("", !0),
|
|
2568
|
+
p(l.$slots, ye.name + "-right", {
|
|
2569
|
+
row: k,
|
|
2570
|
+
column: W,
|
|
2571
|
+
$index: oe
|
|
2547
2572
|
}, void 0, !0)
|
|
2548
|
-
], 64))), 256)) : (
|
|
2549
|
-
default:
|
|
2550
|
-
(
|
|
2551
|
-
|
|
2552
|
-
row:
|
|
2553
|
-
column:
|
|
2554
|
-
$index:
|
|
2573
|
+
], 64))), 256)) : (n(), O(v, { key: 1 }, {
|
|
2574
|
+
default: h(() => [
|
|
2575
|
+
(n(!0), q(G, null, j(Le, (ye) => (n(), q(G, null, [
|
|
2576
|
+
p(l.$slots, ye.name + "-left", {
|
|
2577
|
+
row: k,
|
|
2578
|
+
column: W,
|
|
2579
|
+
$index: oe
|
|
2555
2580
|
}, void 0, !0),
|
|
2556
|
-
|
|
2581
|
+
ye.attr.auth(k, W, oe) ? p(l.$slots, ye.name, {
|
|
2557
2582
|
key: 0,
|
|
2558
|
-
row:
|
|
2559
|
-
column:
|
|
2560
|
-
$index:
|
|
2583
|
+
row: k,
|
|
2584
|
+
column: W,
|
|
2585
|
+
$index: oe
|
|
2561
2586
|
}, () => [
|
|
2562
|
-
|
|
2587
|
+
ye.label ? (n(), O(o(_e), S({
|
|
2563
2588
|
key: 0,
|
|
2564
2589
|
ref_for: !0
|
|
2565
|
-
},
|
|
2566
|
-
onClick: (Ze) =>
|
|
2590
|
+
}, ye.attr, {
|
|
2591
|
+
onClick: (Ze) => ye.func(k, W, oe, e.value)
|
|
2567
2592
|
}), {
|
|
2568
|
-
default:
|
|
2569
|
-
|
|
2593
|
+
default: h(() => [
|
|
2594
|
+
we(Ee($e(ye, oe)), 1)
|
|
2570
2595
|
]),
|
|
2571
2596
|
_: 2
|
|
2572
|
-
}, 1040, ["onClick"])) : (
|
|
2597
|
+
}, 1040, ["onClick"])) : (n(), O(o(_e), S({
|
|
2573
2598
|
key: 1,
|
|
2574
2599
|
ref_for: !0
|
|
2575
|
-
},
|
|
2576
|
-
onClick: (Ze) =>
|
|
2600
|
+
}, ye.attr, {
|
|
2601
|
+
onClick: (Ze) => ye.func(k, W, oe, e.value)
|
|
2577
2602
|
}), null, 16, ["onClick"]))
|
|
2578
|
-
], !0) :
|
|
2579
|
-
|
|
2580
|
-
row:
|
|
2581
|
-
column:
|
|
2582
|
-
$index:
|
|
2603
|
+
], !0) : be("", !0),
|
|
2604
|
+
p(l.$slots, ye.name + "-right", {
|
|
2605
|
+
row: k,
|
|
2606
|
+
column: W,
|
|
2607
|
+
$index: oe
|
|
2583
2608
|
}, void 0, !0)
|
|
2584
2609
|
], 64))), 256))
|
|
2585
2610
|
]),
|
|
2586
2611
|
_: 2
|
|
2587
2612
|
}, 1024))
|
|
2588
2613
|
], 64))), 256)),
|
|
2589
|
-
|
|
2590
|
-
row:
|
|
2591
|
-
column:
|
|
2592
|
-
$index:
|
|
2614
|
+
p(l.$slots, "control-right", {
|
|
2615
|
+
row: k,
|
|
2616
|
+
column: W,
|
|
2617
|
+
$index: oe
|
|
2593
2618
|
}, void 0, !0)
|
|
2594
2619
|
], !0)
|
|
2595
2620
|
], 6)
|
|
2596
2621
|
];
|
|
2597
2622
|
}),
|
|
2598
2623
|
key: "2"
|
|
2599
|
-
} :
|
|
2624
|
+
} : U.type != "selection" && U.type != "index" ? {
|
|
2600
2625
|
name: "default",
|
|
2601
|
-
fn:
|
|
2602
|
-
|
|
2626
|
+
fn: h(({ row: k, column: W, $index: oe }) => [
|
|
2627
|
+
he(U, k, W, oe) && oe != -1 ? p(l.$slots, `${le}`, {
|
|
2603
2628
|
key: 0,
|
|
2604
|
-
row:
|
|
2605
|
-
column:
|
|
2606
|
-
$index:
|
|
2629
|
+
row: k,
|
|
2630
|
+
column: W,
|
|
2631
|
+
$index: oe
|
|
2607
2632
|
}, () => {
|
|
2608
|
-
var
|
|
2633
|
+
var je;
|
|
2609
2634
|
return [
|
|
2610
|
-
(
|
|
2611
|
-
modelValue:
|
|
2612
|
-
"onUpdate:modelValue": (
|
|
2613
|
-
item:
|
|
2614
|
-
ctrlKey:
|
|
2615
|
-
key:
|
|
2616
|
-
ctrlType: (
|
|
2635
|
+
(n(), O(Xe, {
|
|
2636
|
+
modelValue: k[le],
|
|
2637
|
+
"onUpdate:modelValue": (Re) => k[le] = Re,
|
|
2638
|
+
item: U == null ? void 0 : U.table(k, W, oe),
|
|
2639
|
+
ctrlKey: le,
|
|
2640
|
+
key: le + "-" + oe,
|
|
2641
|
+
ctrlType: (je = U.table(k, W, oe)) != null && je.type ? U.table(k, W, oe).type : U.type,
|
|
2617
2642
|
model: e.value,
|
|
2618
2643
|
class: "g-ctrl-container",
|
|
2619
2644
|
t: "t",
|
|
2620
|
-
formInfo:
|
|
2621
|
-
},
|
|
2622
|
-
|
|
2645
|
+
formInfo: k
|
|
2646
|
+
}, ce({ _: 2 }, [
|
|
2647
|
+
j(l.$slots, (Re, Le) => ({
|
|
2623
2648
|
name: Le,
|
|
2624
|
-
fn:
|
|
2625
|
-
|
|
2649
|
+
fn: h((Je) => [
|
|
2650
|
+
p(l.$slots, Le, {
|
|
2626
2651
|
data: Je,
|
|
2627
|
-
item:
|
|
2652
|
+
item: U,
|
|
2628
2653
|
model: e.value
|
|
2629
2654
|
}, void 0, !0)
|
|
2630
2655
|
])
|
|
2631
2656
|
}))
|
|
2632
2657
|
]), 1032, ["modelValue", "onUpdate:modelValue", "item", "ctrlKey", "ctrlType", "model", "formInfo"]))
|
|
2633
2658
|
];
|
|
2634
|
-
}, !0) :
|
|
2659
|
+
}, !0) : p(l.$slots, `${le}`, {
|
|
2635
2660
|
key: 1,
|
|
2636
|
-
row:
|
|
2637
|
-
column:
|
|
2638
|
-
$index:
|
|
2661
|
+
row: k,
|
|
2662
|
+
column: W,
|
|
2663
|
+
$index: oe
|
|
2639
2664
|
}, () => [
|
|
2640
|
-
|
|
2641
|
-
innerHTML: fe(
|
|
2642
|
-
}, null, 8,
|
|
2665
|
+
Z("div", {
|
|
2666
|
+
innerHTML: fe(U, W.formatter(k, W, k[le], oe))
|
|
2667
|
+
}, null, 8, bl)
|
|
2643
2668
|
], !0)
|
|
2644
2669
|
]),
|
|
2645
2670
|
key: "3"
|
|
@@ -2649,82 +2674,82 @@ const ul = {
|
|
|
2649
2674
|
]),
|
|
2650
2675
|
_: 3
|
|
2651
2676
|
}, 16, ["summary-method"]),
|
|
2652
|
-
(dt = (it = (st = e.value) == null ? void 0 : st.table) == null ? void 0 : it.page) != null && dt.hidden ?
|
|
2653
|
-
|
|
2677
|
+
(dt = (it = (st = e.value) == null ? void 0 : st.table) == null ? void 0 : it.page) != null && dt.hidden ? be("", !0) : p(l.$slots, "page", { key: 0 }, () => [
|
|
2678
|
+
X(Q, S({
|
|
2654
2679
|
"page-size": e.value.table.page.pageSize,
|
|
2655
|
-
"onUpdate:pageSize":
|
|
2680
|
+
"onUpdate:pageSize": a[2] || (a[2] = (U) => e.value.table.page.pageSize = U),
|
|
2656
2681
|
"current-page": e.value.table.page.currentPage,
|
|
2657
|
-
"onUpdate:currentPage":
|
|
2682
|
+
"onUpdate:currentPage": a[3] || (a[3] = (U) => e.value.table.page.currentPage = U)
|
|
2658
2683
|
}, e.value.table.page), {
|
|
2659
|
-
default:
|
|
2660
|
-
|
|
2684
|
+
default: h(() => [
|
|
2685
|
+
p(l.$slots, "table-page", {}, void 0, !0)
|
|
2661
2686
|
]),
|
|
2662
2687
|
_: 3
|
|
2663
2688
|
}, 16, ["page-size", "current-page"])
|
|
2664
2689
|
], !0)
|
|
2665
2690
|
])
|
|
2666
2691
|
]),
|
|
2667
|
-
e.value.dialog.mode == "dialog" && F.value ? (
|
|
2668
|
-
|
|
2692
|
+
e.value.dialog.mode == "dialog" && F.value ? (n(), q("div", $l, [
|
|
2693
|
+
X(Se, S({
|
|
2669
2694
|
modelValue: F.value,
|
|
2670
|
-
"onUpdate:modelValue":
|
|
2695
|
+
"onUpdate:modelValue": a[7] || (a[7] = (U) => F.value = U),
|
|
2671
2696
|
fullscreen: e.value.dialog.fullScreen
|
|
2672
|
-
}, o(
|
|
2697
|
+
}, o(ke)(e.value.dialog, (U) => !["size"].includes(U)), {
|
|
2673
2698
|
width: o(wt)(e.value.dialog.width) + 35
|
|
2674
2699
|
}), {
|
|
2675
|
-
header:
|
|
2676
|
-
var
|
|
2700
|
+
header: h(() => {
|
|
2701
|
+
var U, le, k, W;
|
|
2677
2702
|
return [
|
|
2678
|
-
|
|
2679
|
-
|
|
2680
|
-
|
|
2681
|
-
|
|
2703
|
+
Z("div", El, [
|
|
2704
|
+
Z("div", wl, [
|
|
2705
|
+
p(l.$slots, "f-header", {}, () => [
|
|
2706
|
+
Z("div", null, Ee(e.value.dialog.title), 1)
|
|
2682
2707
|
], !0)
|
|
2683
2708
|
]),
|
|
2684
|
-
((
|
|
2709
|
+
((le = (U = e.value) == null ? void 0 : U.dialog) == null ? void 0 : le.fullScreen) === !1 ? (n(), q("div", {
|
|
2685
2710
|
key: 0,
|
|
2686
|
-
onClick:
|
|
2711
|
+
onClick: a[4] || (a[4] = (oe) => {
|
|
2687
2712
|
e.value.dialog.fullScreen = !0;
|
|
2688
2713
|
}),
|
|
2689
2714
|
class: "max"
|
|
2690
2715
|
}, [
|
|
2691
|
-
|
|
2692
|
-
default:
|
|
2693
|
-
|
|
2716
|
+
X(me, null, {
|
|
2717
|
+
default: h(() => [
|
|
2718
|
+
X(o(At))
|
|
2694
2719
|
]),
|
|
2695
2720
|
_: 1
|
|
2696
2721
|
})
|
|
2697
|
-
])) :
|
|
2698
|
-
((
|
|
2722
|
+
])) : be("", !0),
|
|
2723
|
+
((W = (k = e.value) == null ? void 0 : k.dialog) == null ? void 0 : W.fullScreen) === !0 ? (n(), q("div", {
|
|
2699
2724
|
key: 1,
|
|
2700
|
-
onClick:
|
|
2725
|
+
onClick: a[5] || (a[5] = (oe) => {
|
|
2701
2726
|
e.value.dialog.fullScreen = !1;
|
|
2702
2727
|
}),
|
|
2703
2728
|
class: "max"
|
|
2704
2729
|
}, [
|
|
2705
|
-
|
|
2706
|
-
default:
|
|
2707
|
-
|
|
2730
|
+
X(me, null, {
|
|
2731
|
+
default: h(() => [
|
|
2732
|
+
X(o(xt))
|
|
2708
2733
|
]),
|
|
2709
2734
|
_: 1
|
|
2710
2735
|
})
|
|
2711
|
-
])) :
|
|
2736
|
+
])) : be("", !0)
|
|
2712
2737
|
])
|
|
2713
2738
|
];
|
|
2714
2739
|
}),
|
|
2715
|
-
default:
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2740
|
+
default: h(() => [
|
|
2741
|
+
Z("div", _l, [
|
|
2742
|
+
p(l.$slots, "table-dialog-form", { model: e.value }, () => [
|
|
2743
|
+
X(tt, {
|
|
2719
2744
|
modelValue: e.value,
|
|
2720
|
-
"onUpdate:modelValue":
|
|
2721
|
-
onSubmit:
|
|
2722
|
-
onReset:
|
|
2723
|
-
},
|
|
2724
|
-
|
|
2725
|
-
name:
|
|
2726
|
-
fn:
|
|
2727
|
-
|
|
2745
|
+
"onUpdate:modelValue": a[6] || (a[6] = (U) => e.value = U),
|
|
2746
|
+
onSubmit: re,
|
|
2747
|
+
onReset: x
|
|
2748
|
+
}, ce({ _: 2 }, [
|
|
2749
|
+
j(l.$slots, (U, le, k) => ({
|
|
2750
|
+
name: le,
|
|
2751
|
+
fn: h((W) => [
|
|
2752
|
+
p(l.$slots, le, { model: W }, void 0, !0)
|
|
2728
2753
|
])
|
|
2729
2754
|
}))
|
|
2730
2755
|
]), 1032, ["modelValue"])
|
|
@@ -2733,33 +2758,33 @@ const ul = {
|
|
|
2733
2758
|
]),
|
|
2734
2759
|
_: 3
|
|
2735
2760
|
}, 16, ["modelValue", "fullscreen", "width"])
|
|
2736
|
-
])) :
|
|
2737
|
-
e.value.dialog.mode == "drawer" && F.value ? (
|
|
2738
|
-
|
|
2761
|
+
])) : be("", !0),
|
|
2762
|
+
e.value.dialog.mode == "drawer" && F.value ? (n(), q("div", kl, [
|
|
2763
|
+
X(Pe, S({
|
|
2739
2764
|
modelValue: F.value,
|
|
2740
|
-
"onUpdate:modelValue":
|
|
2741
|
-
}, o(
|
|
2742
|
-
header:
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2765
|
+
"onUpdate:modelValue": a[9] || (a[9] = (U) => F.value = U)
|
|
2766
|
+
}, o(ke)(e.value.dialog, (U) => !["width"].includes(U))), {
|
|
2767
|
+
header: h(() => [
|
|
2768
|
+
Z("div", Cl, [
|
|
2769
|
+
Z("div", Dl, [
|
|
2770
|
+
p(l.$slots, "f-header", {}, () => [
|
|
2771
|
+
Z("div", null, Ee(e.value.dialog.title), 1)
|
|
2747
2772
|
], !0)
|
|
2748
2773
|
])
|
|
2749
2774
|
])
|
|
2750
2775
|
]),
|
|
2751
|
-
default:
|
|
2752
|
-
|
|
2753
|
-
|
|
2776
|
+
default: h(() => [
|
|
2777
|
+
p(l.$slots, "table-drawer-form", { model: e.value }, () => [
|
|
2778
|
+
X(tt, {
|
|
2754
2779
|
modelValue: e.value,
|
|
2755
|
-
"onUpdate:modelValue":
|
|
2756
|
-
onSubmit:
|
|
2757
|
-
onReset:
|
|
2758
|
-
},
|
|
2759
|
-
|
|
2760
|
-
name:
|
|
2761
|
-
fn:
|
|
2762
|
-
|
|
2780
|
+
"onUpdate:modelValue": a[8] || (a[8] = (U) => e.value = U),
|
|
2781
|
+
onSubmit: re,
|
|
2782
|
+
onReset: x
|
|
2783
|
+
}, ce({ _: 2 }, [
|
|
2784
|
+
j(l.$slots, (U, le, k) => ({
|
|
2785
|
+
name: le,
|
|
2786
|
+
fn: h((W) => [
|
|
2787
|
+
p(l.$slots, le, { model: W }, void 0, !0)
|
|
2763
2788
|
])
|
|
2764
2789
|
}))
|
|
2765
2790
|
]), 1032, ["modelValue"])
|
|
@@ -2767,11 +2792,11 @@ const ul = {
|
|
|
2767
2792
|
]),
|
|
2768
2793
|
_: 3
|
|
2769
2794
|
}, 16, ["modelValue"])
|
|
2770
|
-
])) :
|
|
2795
|
+
])) : be("", !0)
|
|
2771
2796
|
], 64);
|
|
2772
2797
|
};
|
|
2773
2798
|
}
|
|
2774
|
-
}),
|
|
2799
|
+
}), Ml = /* @__PURE__ */ Ue(Vl, [["__scopeId", "data-v-243728e0"]]), Fl = { class: "g-tree-table" }, Tl = { class: "g-tree-container" }, Sl = { class: "g-tree-table-container" }, ql = /* @__PURE__ */ Object.assign({
|
|
2775
2800
|
name: "g-tree-table",
|
|
2776
2801
|
inheritAttrs: !1
|
|
2777
2802
|
}, {
|
|
@@ -2780,72 +2805,72 @@ const ul = {
|
|
|
2780
2805
|
modelValue: { required: !0 },
|
|
2781
2806
|
modelModifiers: {}
|
|
2782
2807
|
},
|
|
2783
|
-
emits: /* @__PURE__ */
|
|
2808
|
+
emits: /* @__PURE__ */ Be(["load"], ["update:modelValue"]),
|
|
2784
2809
|
setup(f, { emit: c }) {
|
|
2785
|
-
const t = c, e =
|
|
2786
|
-
var
|
|
2787
|
-
if (
|
|
2788
|
-
const
|
|
2789
|
-
return
|
|
2790
|
-
},
|
|
2791
|
-
t("load", F.value,
|
|
2792
|
-
},
|
|
2793
|
-
F.value =
|
|
2810
|
+
const t = c, e = Ie(f, "modelValue"), r = nt(), d = ve((r == null ? void 0 : r.width) || "180px"), Y = ve((r == null ? void 0 : r.search) === void 0 ? !0 : r == null ? void 0 : r.search), F = ve({}), T = ve(""), E = ve(null), D = (L, V) => {
|
|
2811
|
+
var w, ae;
|
|
2812
|
+
if (!L) return !0;
|
|
2813
|
+
const b = ((ae = (w = r.tree) == null ? void 0 : w.props) == null ? void 0 : ae.label) || "label";
|
|
2814
|
+
return V[b].includes(L);
|
|
2815
|
+
}, N = (L, V) => {
|
|
2816
|
+
t("load", F.value, L, V);
|
|
2817
|
+
}, te = (L) => {
|
|
2818
|
+
F.value = L, e.value.table.load();
|
|
2794
2819
|
};
|
|
2795
|
-
return
|
|
2796
|
-
|
|
2797
|
-
}), (
|
|
2798
|
-
const
|
|
2799
|
-
return
|
|
2800
|
-
|
|
2820
|
+
return qt(T, (L) => {
|
|
2821
|
+
E.value.filter(L);
|
|
2822
|
+
}), (L, V) => {
|
|
2823
|
+
const b = R("el-input"), w = R("el-tree"), ae = R("g-table");
|
|
2824
|
+
return n(), q("div", Fl, [
|
|
2825
|
+
Z("div", {
|
|
2801
2826
|
class: "g-tree-left",
|
|
2802
|
-
style:
|
|
2827
|
+
style: Ae({ width: d.value })
|
|
2803
2828
|
}, [
|
|
2804
|
-
|
|
2829
|
+
Y.value ? (n(), O(b, {
|
|
2805
2830
|
key: 0,
|
|
2806
2831
|
modelValue: T.value,
|
|
2807
|
-
"onUpdate:modelValue":
|
|
2832
|
+
"onUpdate:modelValue": V[0] || (V[0] = (K) => T.value = K),
|
|
2808
2833
|
style: { width: "100%", padding: "0 10px", "box-sizing": "border-box" },
|
|
2809
2834
|
placeholder: "输入节点查询",
|
|
2810
2835
|
clearable: ""
|
|
2811
|
-
}, null, 8, ["modelValue"])) :
|
|
2812
|
-
|
|
2813
|
-
|
|
2814
|
-
style: { width:
|
|
2815
|
-
"filter-node-method":
|
|
2836
|
+
}, null, 8, ["modelValue"])) : be("", !0),
|
|
2837
|
+
Z("div", Tl, [
|
|
2838
|
+
X(w, S({
|
|
2839
|
+
style: { width: d.value },
|
|
2840
|
+
"filter-node-method": D,
|
|
2816
2841
|
"expand-on-click-node": !1,
|
|
2817
2842
|
ref_key: "treeRef",
|
|
2818
|
-
ref:
|
|
2819
|
-
onNodeClick:
|
|
2820
|
-
},
|
|
2821
|
-
default:
|
|
2822
|
-
|
|
2843
|
+
ref: E,
|
|
2844
|
+
onNodeClick: te
|
|
2845
|
+
}, L.$attrs.tree), ce({
|
|
2846
|
+
default: h(({ node: K, data: ne }) => [
|
|
2847
|
+
p(L.$slots, "tree", {
|
|
2823
2848
|
node: K,
|
|
2824
|
-
data:
|
|
2849
|
+
data: ne
|
|
2825
2850
|
}, () => [
|
|
2826
|
-
|
|
2851
|
+
Z("span", null, Ee(K.label), 1)
|
|
2827
2852
|
], !0)
|
|
2828
2853
|
]),
|
|
2829
2854
|
_: 2
|
|
2830
2855
|
}, [
|
|
2831
|
-
|
|
2832
|
-
name:
|
|
2833
|
-
fn:
|
|
2834
|
-
|
|
2856
|
+
j(L.$slots, (K, ne, ie) => ({
|
|
2857
|
+
name: ne,
|
|
2858
|
+
fn: h((fe) => [
|
|
2859
|
+
p(L.$slots, ne, { data: fe }, void 0, !0)
|
|
2835
2860
|
])
|
|
2836
2861
|
}))
|
|
2837
2862
|
]), 1040, ["style"])
|
|
2838
2863
|
])
|
|
2839
2864
|
], 4),
|
|
2840
|
-
|
|
2841
|
-
|
|
2865
|
+
Z("div", Sl, [
|
|
2866
|
+
X(ae, S({
|
|
2842
2867
|
modelValue: e.value,
|
|
2843
|
-
"onUpdate:modelValue":
|
|
2844
|
-
},
|
|
2845
|
-
|
|
2846
|
-
name:
|
|
2847
|
-
fn:
|
|
2848
|
-
|
|
2868
|
+
"onUpdate:modelValue": V[1] || (V[1] = (K) => e.value = K)
|
|
2869
|
+
}, L.$attrs, { onLoad: N }), ce({ _: 2 }, [
|
|
2870
|
+
j(L.$slots, (K, ne, ie) => ({
|
|
2871
|
+
name: ne,
|
|
2872
|
+
fn: h((fe) => [
|
|
2873
|
+
p(L.$slots, ne, { data: fe }, void 0, !0)
|
|
2849
2874
|
])
|
|
2850
2875
|
}))
|
|
2851
2876
|
]), 1040, ["modelValue"])
|
|
@@ -2853,13 +2878,13 @@ const ul = {
|
|
|
2853
2878
|
]);
|
|
2854
2879
|
};
|
|
2855
2880
|
}
|
|
2856
|
-
}),
|
|
2881
|
+
}), Ol = /* @__PURE__ */ Ue(ql, [["__scopeId", "data-v-5fb88c8a"]]), Al = {
|
|
2857
2882
|
key: 0,
|
|
2858
2883
|
class: "op-group"
|
|
2859
|
-
},
|
|
2884
|
+
}, xl = {
|
|
2860
2885
|
key: 1,
|
|
2861
2886
|
class: "op-items"
|
|
2862
|
-
},
|
|
2887
|
+
}, Bl = ["title"], pt = "100px", Il = /* @__PURE__ */ Object.assign({ name: "g-select-option" }, {
|
|
2863
2888
|
__name: "g-select-option",
|
|
2864
2889
|
props: {
|
|
2865
2890
|
columns: {
|
|
@@ -2881,69 +2906,69 @@ const ul = {
|
|
|
2881
2906
|
},
|
|
2882
2907
|
setup(f) {
|
|
2883
2908
|
const c = f;
|
|
2884
|
-
return (t, e) => c.title ? (
|
|
2885
|
-
(
|
|
2886
|
-
style:
|
|
2887
|
-
key:
|
|
2909
|
+
return (t, e) => c.title ? (n(), q("div", Al, [
|
|
2910
|
+
(n(!0), q(G, null, j(c.columns, (r) => (n(), q("span", {
|
|
2911
|
+
style: Ae({ width: (r == null ? void 0 : r.width) || pt, ...r == null ? void 0 : r.titleStyle, textAlign: (r == null ? void 0 : r.align) || "center" }),
|
|
2912
|
+
key: r.key
|
|
2888
2913
|
}, [
|
|
2889
|
-
|
|
2890
|
-
|
|
2914
|
+
p(t.$slots, `${f.t}-title-${r.key}`, { col: r }, () => [
|
|
2915
|
+
we(Ee(r.label), 1)
|
|
2891
2916
|
], !0)
|
|
2892
2917
|
], 4))), 128))
|
|
2893
|
-
])) : (
|
|
2894
|
-
(
|
|
2895
|
-
style:
|
|
2896
|
-
key:
|
|
2897
|
-
title: f.data[
|
|
2918
|
+
])) : (n(), q("div", xl, [
|
|
2919
|
+
(n(!0), q(G, null, j(c.columns, (r) => (n(), q("span", {
|
|
2920
|
+
style: Ae({ width: (r == null ? void 0 : r.width) || pt, textAlign: (r == null ? void 0 : r.align) || "center", ...r == null ? void 0 : r.style }),
|
|
2921
|
+
key: r.key,
|
|
2922
|
+
title: f.data[r.key]
|
|
2898
2923
|
}, [
|
|
2899
|
-
|
|
2900
|
-
|
|
2924
|
+
p(t.$slots, `${f.t}-option-${r.key}`, { col: r }, () => [
|
|
2925
|
+
we(Ee(f.data[r.key]), 1)
|
|
2901
2926
|
], !0)
|
|
2902
|
-
], 12,
|
|
2927
|
+
], 12, Bl))), 128))
|
|
2903
2928
|
]));
|
|
2904
2929
|
}
|
|
2905
|
-
}),
|
|
2930
|
+
}), Yl = /* @__PURE__ */ Ue(Il, [["__scopeId", "data-v-ba0fcda6"]]), Ul = Object.freeze({}), Et = [Ml, tt, Ol, Yl];
|
|
2906
2931
|
let lt = {};
|
|
2907
|
-
const
|
|
2932
|
+
const Gl = {
|
|
2908
2933
|
install: (f, c = {}) => {
|
|
2909
|
-
lt = Object.freeze({ ...
|
|
2934
|
+
lt = Object.freeze({ ...Ul, ...c }), Et.forEach((t) => {
|
|
2910
2935
|
f.component(t.name, t);
|
|
2911
2936
|
}), f.provide("options", lt), f.config.globalProperties.$openModal = ot;
|
|
2912
2937
|
}
|
|
2913
|
-
},
|
|
2938
|
+
}, jl = (f) => ({ dialog: kt, drawer: Ct })[f] || null, ot = (f = {}, c = "dialog") => {
|
|
2914
2939
|
if (typeof document > "u") return () => {
|
|
2915
2940
|
};
|
|
2916
2941
|
const t = document.createElement("div");
|
|
2917
2942
|
let e = () => {
|
|
2918
2943
|
};
|
|
2919
|
-
const
|
|
2920
|
-
if (!
|
|
2944
|
+
const r = jl(c);
|
|
2945
|
+
if (!r) return () => {
|
|
2921
2946
|
};
|
|
2922
|
-
const
|
|
2947
|
+
const d = ve(!0), Y = Ot({
|
|
2923
2948
|
setup() {
|
|
2924
2949
|
return e = () => {
|
|
2925
|
-
|
|
2926
|
-
|
|
2950
|
+
d.value = !1, setTimeout(() => {
|
|
2951
|
+
Y.unmount(), t.remove();
|
|
2927
2952
|
}, 300);
|
|
2928
2953
|
}, () => {
|
|
2929
|
-
var F, T,
|
|
2930
|
-
return qe(
|
|
2931
|
-
modelValue:
|
|
2932
|
-
"onUpdate:modelValue": (
|
|
2954
|
+
var F, T, E;
|
|
2955
|
+
return qe(r, {
|
|
2956
|
+
modelValue: d.value,
|
|
2957
|
+
"onUpdate:modelValue": (D) => d.value = D,
|
|
2933
2958
|
...f,
|
|
2934
2959
|
appendToBody: !0,
|
|
2935
2960
|
destroyOnClose: !0
|
|
2936
2961
|
}, {
|
|
2937
2962
|
default: (F = f.slots) == null ? void 0 : F.default,
|
|
2938
2963
|
header: (T = f.slots) == null ? void 0 : T.header,
|
|
2939
|
-
footer: (
|
|
2964
|
+
footer: (E = f.slots) == null ? void 0 : E.footer
|
|
2940
2965
|
});
|
|
2941
2966
|
};
|
|
2942
2967
|
}
|
|
2943
2968
|
});
|
|
2944
2969
|
return Et.forEach((F) => {
|
|
2945
|
-
|
|
2946
|
-
}),
|
|
2970
|
+
Y.component(F.name, F);
|
|
2971
|
+
}), Y.provide("options", lt), Y.use(_t, { locale: It }), document.body.appendChild(t), Y.mount(t), e;
|
|
2947
2972
|
};
|
|
2948
2973
|
function wt(f, c = window.innerWidth) {
|
|
2949
2974
|
if (typeof f == "number")
|
|
@@ -2961,36 +2986,36 @@ function wt(f, c = window.innerWidth) {
|
|
|
2961
2986
|
return c * parseFloat(f) / 100;
|
|
2962
2987
|
}
|
|
2963
2988
|
if (f.startsWith("calc(") && f.endsWith(")")) {
|
|
2964
|
-
let
|
|
2989
|
+
let d = function(F) {
|
|
2965
2990
|
if (/[0-9+\-*/().\s]+$/.test(F))
|
|
2966
2991
|
return new Function("return " + F)();
|
|
2967
2992
|
throw new Error("Invalid calc expression");
|
|
2968
2993
|
};
|
|
2969
|
-
const
|
|
2970
|
-
return
|
|
2994
|
+
const r = f.slice(5, -1).trim();
|
|
2995
|
+
return d(r.replace(/([0-9.]+)([a-z%]+)/g, (F, T, E) => wt(T + E, c)));
|
|
2971
2996
|
}
|
|
2972
2997
|
throw new Error("Unsupported unit in value: " + f);
|
|
2973
2998
|
}
|
|
2974
|
-
const
|
|
2975
|
-
const c = {}, t = (e,
|
|
2976
|
-
e[
|
|
2999
|
+
const Me = (...f) => {
|
|
3000
|
+
const c = {}, t = (e, r) => (Object.keys(r).forEach((d) => {
|
|
3001
|
+
e[d] = typeof r[d] == "object" && !Array.isArray(r[d]) ? t(e[d] || {}, r[d]) : r[d];
|
|
2977
3002
|
}), e);
|
|
2978
3003
|
return f.forEach((e = {}) => t(c, e)), c;
|
|
2979
3004
|
};
|
|
2980
|
-
function
|
|
3005
|
+
function ke(f, c = (t, e) => c(t, e)) {
|
|
2981
3006
|
const t = {};
|
|
2982
3007
|
for (const e in f)
|
|
2983
3008
|
f.hasOwnProperty(e) && c(e, f[e]) && (t[e] = f[e]);
|
|
2984
3009
|
return t;
|
|
2985
3010
|
}
|
|
2986
|
-
function
|
|
2987
|
-
for (const
|
|
2988
|
-
if (
|
|
2989
|
-
return
|
|
2990
|
-
if (
|
|
2991
|
-
const
|
|
2992
|
-
if (
|
|
2993
|
-
return
|
|
3011
|
+
function Rl(f, c, t = "value", e = "label", r = "children") {
|
|
3012
|
+
for (const d of f) {
|
|
3013
|
+
if (d[t] === c)
|
|
3014
|
+
return d[e];
|
|
3015
|
+
if (d[r] && d[r].length > 0) {
|
|
3016
|
+
const Y = Rl(d[r], c, t, e, r);
|
|
3017
|
+
if (Y)
|
|
3018
|
+
return Y;
|
|
2994
3019
|
}
|
|
2995
3020
|
}
|
|
2996
3021
|
return null;
|
|
@@ -3000,27 +3025,27 @@ function at(f) {
|
|
|
3000
3025
|
const c = ["角", "分"], t = ["零", "壹", "贰", "叁", "肆", "伍", "陆", "柒", "捌", "玖"], e = [
|
|
3001
3026
|
["元", "万", "亿"],
|
|
3002
3027
|
["", "拾", "佰", "仟"]
|
|
3003
|
-
],
|
|
3028
|
+
], r = f < 0 ? "欠" : "";
|
|
3004
3029
|
f = Math.abs(f);
|
|
3005
|
-
let
|
|
3006
|
-
for (let
|
|
3007
|
-
|
|
3008
|
-
|
|
3009
|
-
for (let
|
|
3030
|
+
let d = "";
|
|
3031
|
+
for (let Y = 0; Y < c.length; Y++)
|
|
3032
|
+
d += (t[Math.floor(f * 10 * Math.pow(10, Y)) % 10] + c[Y]).replace(/零./, "");
|
|
3033
|
+
d = d || "整", f = Math.floor(f);
|
|
3034
|
+
for (let Y = 0; Y < e[0].length && f > 0; Y++) {
|
|
3010
3035
|
let F = "";
|
|
3011
3036
|
for (let T = 0; T < e[1].length && f > 0; T++)
|
|
3012
3037
|
F = t[f % 10] + e[1][T] + F, f = Math.floor(f / 10);
|
|
3013
|
-
|
|
3038
|
+
d = F.replace(/(零.)*零$/, "").replace(/^$/, "零") + e[0][Y] + d;
|
|
3014
3039
|
}
|
|
3015
|
-
return
|
|
3040
|
+
return r + d.replace(/(零.)*零元/, "元").replace(/(零.)+/g, "零").replace(/^整$/, "零元整");
|
|
3016
3041
|
}
|
|
3017
|
-
function
|
|
3042
|
+
function Ll(f) {
|
|
3018
3043
|
if (typeof f != "number" || isNaN(f) || !isFinite(f))
|
|
3019
3044
|
return "0.00";
|
|
3020
3045
|
const c = f.toFixed(2), [t, e] = c.split(".");
|
|
3021
3046
|
return `${t.replace(/\B(?=(\d{3})+(?!\d))/g, ",")}.${e}`;
|
|
3022
3047
|
}
|
|
3023
|
-
const
|
|
3048
|
+
const ge = {
|
|
3024
3049
|
RADIO: "radio",
|
|
3025
3050
|
RADIOBUTTON: "radio-button",
|
|
3026
3051
|
CHECKBOX: "checkbox",
|
|
@@ -3050,13 +3075,13 @@ const ce = {
|
|
|
3050
3075
|
TEL: "tel"
|
|
3051
3076
|
};
|
|
3052
3077
|
export {
|
|
3053
|
-
|
|
3078
|
+
ge as CT,
|
|
3054
3079
|
wt as convertToPx,
|
|
3055
|
-
|
|
3056
|
-
|
|
3057
|
-
|
|
3058
|
-
|
|
3059
|
-
|
|
3080
|
+
Gl as default,
|
|
3081
|
+
ke as filterObject,
|
|
3082
|
+
Rl as findTreeLabelByValue,
|
|
3083
|
+
Ll as formatAmount,
|
|
3084
|
+
Me as mergeObjects,
|
|
3060
3085
|
at as moneyToChinese,
|
|
3061
3086
|
ot as openModal
|
|
3062
3087
|
};
|