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