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