vue-2024-ui 0.1.3 → 0.1.4
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 +824 -820
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { mergeModels as je, useModel as Le, ref as le, nextTick as et, onMounted as tt, computed as Pe, resolveComponent as B, openBlock as n, createElementBlock as q, Fragment as W, createElementVNode as X, createBlock as
|
|
3
|
-
import { Plus as
|
|
4
|
-
import
|
|
5
|
-
import { Dexie as
|
|
6
|
-
var
|
|
1
|
+
import qt, { ElForm as rt, ElButtonGroup as ot, ElButton as De, ElPopover as nt, ElMessage as xe, ElMessageBox as _t, ElDialog as Ot, ElDrawer as xt } from "element-plus";
|
|
2
|
+
import { mergeModels as je, useModel as Le, ref as le, nextTick as et, onMounted as tt, computed as Pe, resolveComponent as B, openBlock as n, createElementBlock as q, Fragment as W, createElementVNode as X, createBlock as D, createCommentVNode as ve, unref as I, mergeProps as S, withCtx as g, renderSlot as h, renderList as U, createTextVNode as Ve, toDisplayString as he, createSlots as me, createVNode as Q, useSlots as Ct, inject as vt, useAttrs as pt, onUnmounted as At, normalizeStyle as Ye, withModifiers as $t, normalizeProps as st, guardReactiveProps as wt, resolveDynamicComponent as Re, Transition as Bt, withDirectives as It, vShow as Ut, h as Ie, onBeforeUnmount as Yt, normalizeClass as Dt, watchEffect as jt, watch as Lt, createApp as Rt } from "vue";
|
|
3
|
+
import { Plus as Nt, ZoomOut as Pt, Delete as Ht, FullScreen as zt, Remove as Wt } from "@element-plus/icons-vue";
|
|
4
|
+
import Vt from "sortablejs";
|
|
5
|
+
import { Dexie as Gt } from "dexie";
|
|
6
|
+
var Qt = {
|
|
7
7
|
name: "zh-cn",
|
|
8
8
|
el: {
|
|
9
9
|
breadcrumb: {
|
|
@@ -180,28 +180,28 @@ var Gt = {
|
|
|
180
180
|
indicator: "幻灯片切换至索引 {index}"
|
|
181
181
|
}
|
|
182
182
|
}
|
|
183
|
-
},
|
|
184
|
-
function
|
|
183
|
+
}, Xt = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
184
|
+
function Zt(p) {
|
|
185
185
|
return p && p.__esModule && Object.prototype.hasOwnProperty.call(p, "default") ? p.default : p;
|
|
186
186
|
}
|
|
187
187
|
var Mt = { exports: {} };
|
|
188
188
|
(function(p, c) {
|
|
189
189
|
(function(t, e) {
|
|
190
190
|
p.exports = e();
|
|
191
|
-
})(
|
|
192
|
-
var t = 1e3, e = 6e4,
|
|
191
|
+
})(Xt, function() {
|
|
192
|
+
var t = 1e3, e = 6e4, o = 36e5, f = "millisecond", E = "second", x = "minute", F = "hour", _ = "day", k = "week", R = "month", ae = "quarter", Y = "year", A = "date", oe = "Invalid Date", ue = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, K = /\[([^\]]+)]|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, ce = { 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(u) {
|
|
193
193
|
var y = ["th", "st", "nd", "rd"], m = u % 100;
|
|
194
194
|
return "[" + u + (y[(m - 20) % 10] || y[m] || y[0]) + "]";
|
|
195
|
-
} },
|
|
195
|
+
} }, $e = function(u, y, m) {
|
|
196
196
|
var b = String(u);
|
|
197
197
|
return !b || b.length >= y ? u : "" + Array(y + 1 - b.length).join(m) + u;
|
|
198
|
-
},
|
|
198
|
+
}, ge = { s: $e, z: function(u) {
|
|
199
199
|
var y = -u.utcOffset(), m = Math.abs(y), b = Math.floor(m / 60), i = m % 60;
|
|
200
|
-
return (y <= 0 ? "+" : "-") +
|
|
200
|
+
return (y <= 0 ? "+" : "-") + $e(b, 2, "0") + ":" + $e(i, 2, "0");
|
|
201
201
|
}, m: function u(y, m) {
|
|
202
202
|
if (y.date() < m.date()) return -u(m, y);
|
|
203
|
-
var b = 12 * (m.year() - y.year()) + (m.month() - y.month()), i = y.clone().add(b, R), $ = m - i < 0,
|
|
204
|
-
return +(-(b + (m - i) / ($ ? i -
|
|
203
|
+
var b = 12 * (m.year() - y.year()) + (m.month() - y.month()), i = y.clone().add(b, R), $ = m - i < 0, V = y.clone().add(b + ($ ? -1 : 1), R);
|
|
204
|
+
return +(-(b + (m - i) / ($ ? i - V : V - i)) || 0);
|
|
205
205
|
}, a: function(u) {
|
|
206
206
|
return u < 0 ? Math.ceil(u) || 0 : Math.floor(u);
|
|
207
207
|
}, p: function(u) {
|
|
@@ -209,17 +209,17 @@ var Mt = { exports: {} };
|
|
|
209
209
|
}, u: function(u) {
|
|
210
210
|
return u === void 0;
|
|
211
211
|
} }, ye = "en", ne = {};
|
|
212
|
-
ne[ye] =
|
|
212
|
+
ne[ye] = ce;
|
|
213
213
|
var se = "$isDayjsObject", ee = function(u) {
|
|
214
214
|
return u instanceof s || !(!u || !u[se]);
|
|
215
|
-
},
|
|
215
|
+
}, be = function u(y, m, b) {
|
|
216
216
|
var i;
|
|
217
217
|
if (!y) return ye;
|
|
218
218
|
if (typeof y == "string") {
|
|
219
219
|
var $ = y.toLowerCase();
|
|
220
220
|
ne[$] && (i = $), m && (ne[$] = m, i = $);
|
|
221
|
-
var
|
|
222
|
-
if (!i &&
|
|
221
|
+
var V = y.split("-");
|
|
222
|
+
if (!i && V.length > 1) return u(V[0]);
|
|
223
223
|
} else {
|
|
224
224
|
var N = y.name;
|
|
225
225
|
ne[N] = y, i = N;
|
|
@@ -229,13 +229,13 @@ var Mt = { exports: {} };
|
|
|
229
229
|
if (ee(u)) return u.clone();
|
|
230
230
|
var m = typeof y == "object" ? y : {};
|
|
231
231
|
return m.date = u, m.args = arguments, new s(m);
|
|
232
|
-
}, a =
|
|
233
|
-
a.l =
|
|
232
|
+
}, a = ge;
|
|
233
|
+
a.l = be, a.i = ee, a.w = function(u, y) {
|
|
234
234
|
return ie(u, { locale: y.$L, utc: y.$u, x: y.$x, $offset: y.$offset });
|
|
235
235
|
};
|
|
236
236
|
var s = function() {
|
|
237
237
|
function u(m) {
|
|
238
|
-
this.$L =
|
|
238
|
+
this.$L = be(m.locale, null, !0), this.parse(m), this.$x = this.$x || m.x || {}, this[se] = !0;
|
|
239
239
|
}
|
|
240
240
|
var y = u.prototype;
|
|
241
241
|
return y.parse = function(m) {
|
|
@@ -245,10 +245,10 @@ var Mt = { exports: {} };
|
|
|
245
245
|
if (a.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 N =
|
|
251
|
-
return $ ? new Date(Date.UTC(
|
|
248
|
+
var V = i.match(ue);
|
|
249
|
+
if (V) {
|
|
250
|
+
var N = V[2] - 1 || 0, T = (V[7] || "0").substring(0, 3);
|
|
251
|
+
return $ ? new Date(Date.UTC(V[1], N, V[3] || 1, V[4] || 0, V[5] || 0, V[6] || 0, T)) : new Date(V[1], N, V[3] || 1, V[4] || 0, V[5] || 0, V[6] || 0, T);
|
|
252
252
|
}
|
|
253
253
|
}
|
|
254
254
|
return new Date(i);
|
|
@@ -259,7 +259,7 @@ var Mt = { exports: {} };
|
|
|
259
259
|
}, y.$utils = function() {
|
|
260
260
|
return a;
|
|
261
261
|
}, y.isValid = function() {
|
|
262
|
-
return this.$d.toString() !==
|
|
262
|
+
return this.$d.toString() !== oe;
|
|
263
263
|
}, y.isSame = function(m, b) {
|
|
264
264
|
var i = ie(m);
|
|
265
265
|
return this.startOf(b) <= i && i <= this.endOf(b);
|
|
@@ -274,36 +274,36 @@ var Mt = { exports: {} };
|
|
|
274
274
|
}, y.valueOf = function() {
|
|
275
275
|
return this.$d.getTime();
|
|
276
276
|
}, y.startOf = function(m, b) {
|
|
277
|
-
var i = this, $ = !!a.u(b) || b,
|
|
277
|
+
var i = this, $ = !!a.u(b) || b, V = a.p(m), N = function(Te, Ee) {
|
|
278
278
|
var qe = a.w(i.$u ? Date.UTC(i.$y, Ee, Te) : new Date(i.$y, Ee, Te), i);
|
|
279
279
|
return $ ? qe : qe.endOf(_);
|
|
280
280
|
}, T = function(Te, Ee) {
|
|
281
281
|
return a.w(i.toDate()[Te].apply(i.toDate("s"), ($ ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(Ee)), i);
|
|
282
|
-
}, O = this.$W, de = this.$M, te = this.$D,
|
|
283
|
-
switch (
|
|
282
|
+
}, O = this.$W, de = this.$M, te = this.$D, _e = "set" + (this.$u ? "UTC" : "");
|
|
283
|
+
switch (V) {
|
|
284
284
|
case Y:
|
|
285
285
|
return $ ? N(1, 0) : N(31, 11);
|
|
286
286
|
case R:
|
|
287
287
|
return $ ? N(1, de) : N(0, de + 1);
|
|
288
288
|
case k:
|
|
289
|
-
var
|
|
289
|
+
var Ce = this.$locale().weekStart || 0, Fe = (O < Ce ? O + 7 : O) - Ce;
|
|
290
290
|
return N($ ? te - Fe : te + (6 - Fe), de);
|
|
291
291
|
case _:
|
|
292
292
|
case A:
|
|
293
|
-
return T(
|
|
293
|
+
return T(_e + "Hours", 0);
|
|
294
294
|
case F:
|
|
295
|
-
return T(
|
|
295
|
+
return T(_e + "Minutes", 1);
|
|
296
296
|
case x:
|
|
297
|
-
return T(
|
|
297
|
+
return T(_e + "Seconds", 2);
|
|
298
298
|
case E:
|
|
299
|
-
return T(
|
|
299
|
+
return T(_e + "Milliseconds", 3);
|
|
300
300
|
default:
|
|
301
301
|
return this.clone();
|
|
302
302
|
}
|
|
303
303
|
}, y.endOf = function(m) {
|
|
304
304
|
return this.startOf(m, !1);
|
|
305
305
|
}, y.$set = function(m, b) {
|
|
306
|
-
var i, $ = a.p(m),
|
|
306
|
+
var i, $ = a.p(m), V = "set" + (this.$u ? "UTC" : ""), N = (i = {}, i[_] = V + "Date", i[A] = V + "Date", i[R] = V + "Month", i[Y] = V + "FullYear", i[F] = V + "Hours", i[x] = V + "Minutes", i[E] = V + "Seconds", i[f] = V + "Milliseconds", i)[$], T = $ === _ ? this.$D + (b - this.$W) : b;
|
|
307
307
|
if ($ === R || $ === Y) {
|
|
308
308
|
var O = this.clone().set(A, 1);
|
|
309
309
|
O.$d[N](T), O.init(), this.$d = O.set(A, Math.min(this.$D, O.daysInMonth())).$d;
|
|
@@ -316,32 +316,32 @@ var Mt = { exports: {} };
|
|
|
316
316
|
}, y.add = function(m, b) {
|
|
317
317
|
var i, $ = this;
|
|
318
318
|
m = Number(m);
|
|
319
|
-
var
|
|
319
|
+
var V = a.p(b), N = function(de) {
|
|
320
320
|
var te = ie($);
|
|
321
321
|
return a.w(te.date(te.date() + Math.round(de * m)), $);
|
|
322
322
|
};
|
|
323
|
-
if (
|
|
324
|
-
if (
|
|
325
|
-
if (
|
|
326
|
-
if (
|
|
327
|
-
var T = (i = {}, i[x] = e, i[F] =
|
|
323
|
+
if (V === R) return this.set(R, this.$M + m);
|
|
324
|
+
if (V === Y) return this.set(Y, this.$y + m);
|
|
325
|
+
if (V === _) return N(1);
|
|
326
|
+
if (V === k) return N(7);
|
|
327
|
+
var T = (i = {}, i[x] = e, i[F] = o, i[E] = t, i)[V] || 1, O = this.$d.getTime() + m * T;
|
|
328
328
|
return a.w(O, this);
|
|
329
329
|
}, y.subtract = function(m, b) {
|
|
330
330
|
return this.add(-1 * m, b);
|
|
331
331
|
}, y.format = function(m) {
|
|
332
332
|
var b = this, i = this.$locale();
|
|
333
|
-
if (!this.isValid()) return i.invalidDate ||
|
|
334
|
-
var $ = m || "YYYY-MM-DDTHH:mm:ssZ",
|
|
335
|
-
return Ee && (Ee[qe] || Ee(b, $)) ||
|
|
333
|
+
if (!this.isValid()) return i.invalidDate || oe;
|
|
334
|
+
var $ = m || "YYYY-MM-DDTHH:mm:ssZ", V = a.z(this), N = this.$H, T = this.$m, O = this.$M, de = i.weekdays, te = i.months, _e = i.meridiem, Ce = function(Ee, qe, Ae, Be) {
|
|
335
|
+
return Ee && (Ee[qe] || Ee(b, $)) || Ae[qe].slice(0, Be);
|
|
336
336
|
}, Fe = function(Ee) {
|
|
337
337
|
return a.s(N % 12 || 12, Ee, "0");
|
|
338
|
-
}, Te =
|
|
338
|
+
}, Te = _e || function(Ee, qe, Ae) {
|
|
339
339
|
var Be = Ee < 12 ? "AM" : "PM";
|
|
340
|
-
return
|
|
340
|
+
return Ae ? Be.toLowerCase() : Be;
|
|
341
341
|
};
|
|
342
342
|
return $.replace(K, function(Ee, qe) {
|
|
343
|
-
return qe || function(
|
|
344
|
-
switch (
|
|
343
|
+
return qe || function(Ae) {
|
|
344
|
+
switch (Ae) {
|
|
345
345
|
case "YY":
|
|
346
346
|
return String(b.$y).slice(-2);
|
|
347
347
|
case "YYYY":
|
|
@@ -351,9 +351,9 @@ var Mt = { exports: {} };
|
|
|
351
351
|
case "MM":
|
|
352
352
|
return a.s(O + 1, 2, "0");
|
|
353
353
|
case "MMM":
|
|
354
|
-
return
|
|
354
|
+
return Ce(i.monthsShort, O, te, 3);
|
|
355
355
|
case "MMMM":
|
|
356
|
-
return
|
|
356
|
+
return Ce(te, O);
|
|
357
357
|
case "D":
|
|
358
358
|
return b.$D;
|
|
359
359
|
case "DD":
|
|
@@ -361,9 +361,9 @@ var Mt = { exports: {} };
|
|
|
361
361
|
case "d":
|
|
362
362
|
return String(b.$W);
|
|
363
363
|
case "dd":
|
|
364
|
-
return
|
|
364
|
+
return Ce(i.weekdaysMin, b.$W, de, 2);
|
|
365
365
|
case "ddd":
|
|
366
|
-
return
|
|
366
|
+
return Ce(i.weekdaysShort, b.$W, de, 3);
|
|
367
367
|
case "dddd":
|
|
368
368
|
return de[b.$W];
|
|
369
369
|
case "H":
|
|
@@ -389,16 +389,16 @@ var Mt = { exports: {} };
|
|
|
389
389
|
case "SSS":
|
|
390
390
|
return a.s(b.$ms, 3, "0");
|
|
391
391
|
case "Z":
|
|
392
|
-
return
|
|
392
|
+
return V;
|
|
393
393
|
}
|
|
394
394
|
return null;
|
|
395
|
-
}(Ee) ||
|
|
395
|
+
}(Ee) || V.replace(":", "");
|
|
396
396
|
});
|
|
397
397
|
}, y.utcOffset = function() {
|
|
398
398
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
399
399
|
}, y.diff = function(m, b, i) {
|
|
400
|
-
var $,
|
|
401
|
-
return a.m(
|
|
400
|
+
var $, V = this, N = a.p(b), T = ie(m), O = (T.utcOffset() - this.utcOffset()) * e, de = this - T, te = function() {
|
|
401
|
+
return a.m(V, T);
|
|
402
402
|
};
|
|
403
403
|
switch (N) {
|
|
404
404
|
case Y:
|
|
@@ -417,7 +417,7 @@ var Mt = { exports: {} };
|
|
|
417
417
|
$ = (de - O) / 864e5;
|
|
418
418
|
break;
|
|
419
419
|
case F:
|
|
420
|
-
$ = de /
|
|
420
|
+
$ = de / o;
|
|
421
421
|
break;
|
|
422
422
|
case x:
|
|
423
423
|
$ = de / e;
|
|
@@ -435,7 +435,7 @@ var Mt = { exports: {} };
|
|
|
435
435
|
return ne[this.$L];
|
|
436
436
|
}, y.locale = function(m, b) {
|
|
437
437
|
if (!m) return this.$L;
|
|
438
|
-
var i = this.clone(), $ =
|
|
438
|
+
var i = this.clone(), $ = be(m, b, !0);
|
|
439
439
|
return $ && (i.$L = $), i;
|
|
440
440
|
}, y.clone = function() {
|
|
441
441
|
return a.w(this.$d, this);
|
|
@@ -455,24 +455,24 @@ var Mt = { exports: {} };
|
|
|
455
455
|
};
|
|
456
456
|
}), ie.extend = function(u, y) {
|
|
457
457
|
return u.$i || (u(y, s, ie), u.$i = !0), ie;
|
|
458
|
-
}, ie.locale =
|
|
458
|
+
}, ie.locale = be, ie.isDayjs = ee, ie.unix = function(u) {
|
|
459
459
|
return ie(1e3 * u);
|
|
460
460
|
}, ie.en = ne[ye], ie.Ls = ne, ie.p = {}, ie;
|
|
461
461
|
});
|
|
462
462
|
})(Mt);
|
|
463
|
-
var
|
|
464
|
-
const it = /* @__PURE__ */
|
|
463
|
+
var Jt = Mt.exports;
|
|
464
|
+
const it = /* @__PURE__ */ Zt(Jt), He = (p, c) => {
|
|
465
465
|
const t = p.__vccOpts || p;
|
|
466
|
-
for (const [e,
|
|
467
|
-
t[e] =
|
|
466
|
+
for (const [e, o] of c)
|
|
467
|
+
t[e] = o;
|
|
468
468
|
return t;
|
|
469
|
-
},
|
|
469
|
+
}, Kt = {
|
|
470
470
|
style: { display: "flex", width: "100%" },
|
|
471
471
|
class: "g-ctrl-container"
|
|
472
|
-
},
|
|
472
|
+
}, el = { style: { width: "var(--up-width)", height: "var(--up-height)", position: "relative", "box-sizing": "border-box" } }, tl = {
|
|
473
473
|
key: 19,
|
|
474
474
|
style: { position: "relative" }
|
|
475
|
-
},
|
|
475
|
+
}, ll = ["title"], al = { key: 20 }, rl = { key: 21 }, ol = ["innerHTML"], ul = ["innerHTML"], nl = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
476
476
|
__name: "g-ctrl",
|
|
477
477
|
props: /* @__PURE__ */ je(["t", "ctrlKey", "item", "model", "ctrlType", "formInfo"], {
|
|
478
478
|
modelValue: { required: !0 },
|
|
@@ -480,12 +480,12 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
480
480
|
}),
|
|
481
481
|
emits: ["update:modelValue"],
|
|
482
482
|
setup(p) {
|
|
483
|
-
var
|
|
484
|
-
const c = Le(p, "modelValue"), t = p, e = le(t.item || {}),
|
|
483
|
+
var be, ie;
|
|
484
|
+
const c = Le(p, "modelValue"), t = p, e = le(t.item || {}), o = le(t.ctrlKey), f = le(t.ctrlType), E = le(t.model), x = le([]), F = le([]), _ = le(!1), k = le(!1), R = () => Object.keys(Ct()).filter((a) => a.startsWith(`${t.t}-${o}-`)).map((a) => a.replace(`${t.t}-${o}-`, "")), ae = le({
|
|
485
485
|
multiple: !1,
|
|
486
486
|
"show-file-list": !1,
|
|
487
487
|
"file-list": [],
|
|
488
|
-
showDel: (
|
|
488
|
+
showDel: (be = e.value) != null && be.showDel ? (ie = e.value) == null ? void 0 : ie.showDel : t.t !== "t"
|
|
489
489
|
}), Y = le(e.value.innerHtml), A = (a) => [
|
|
490
490
|
"year",
|
|
491
491
|
"years",
|
|
@@ -499,7 +499,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
499
499
|
"daterange",
|
|
500
500
|
"monthrange",
|
|
501
501
|
"yearrange"
|
|
502
|
-
].includes(a),
|
|
502
|
+
].includes(a), oe = (a) => ({
|
|
503
503
|
year: "YYYY",
|
|
504
504
|
years: "YYYY",
|
|
505
505
|
month: "YYYY-MM",
|
|
@@ -523,7 +523,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
523
523
|
F.value = s;
|
|
524
524
|
});
|
|
525
525
|
});
|
|
526
|
-
}),
|
|
526
|
+
}), ce = async (a = "options") => {
|
|
527
527
|
var s;
|
|
528
528
|
try {
|
|
529
529
|
const M = await ((s = e.value) == null ? void 0 : s.getDicts(t.formInfo));
|
|
@@ -540,10 +540,10 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
540
540
|
} catch (M) {
|
|
541
541
|
throw console.error("获取选项失败:", M), M;
|
|
542
542
|
}
|
|
543
|
-
},
|
|
543
|
+
}, $e = () => {
|
|
544
544
|
var a, s;
|
|
545
545
|
e.value.noSearch !== !0 && t.t === "q" && ((s = (a = E.value) == null ? void 0 : a.table) == null || s.load());
|
|
546
|
-
},
|
|
546
|
+
}, ge = (a) => {
|
|
547
547
|
a.preventDefault(), a.stopPropagation(), c.value = "";
|
|
548
548
|
}, ye = (a) => {
|
|
549
549
|
_.value = !0;
|
|
@@ -552,9 +552,9 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
552
552
|
}, se = le(null);
|
|
553
553
|
tt(async () => {
|
|
554
554
|
var M, u, y, m, b;
|
|
555
|
-
e.value && e.value["remote-method"] && (ue.value["remote-method"] = K), (u = (M = E.value[
|
|
556
|
-
const a = (i, $ = "options",
|
|
557
|
-
typeof e.value.getDicts == "function" &&
|
|
555
|
+
e.value && e.value["remote-method"] && (ue.value["remote-method"] = K), (u = (M = E.value[o.value]) == null ? void 0 : M.options) != null && u.length && (F.value = E.value[o.value].options);
|
|
556
|
+
const a = (i, $ = "options", V = E.value[o.value]) => {
|
|
557
|
+
typeof e.value.getDicts == "function" && ce($).catch((N) => {
|
|
558
558
|
console.error(`Failed to load ${$} for ${i}:`, N);
|
|
559
559
|
});
|
|
560
560
|
};
|
|
@@ -567,8 +567,8 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
567
567
|
})(), t.t == "q") {
|
|
568
568
|
let i = e.value.type || f.value;
|
|
569
569
|
(i === void 0 || f.value === "input" || i == pe.NUMBER || i == pe.EMAIL || i == "url" || i == "text") && e.value.onKeyup == null && (e.value.onKeyup = ($) => {
|
|
570
|
-
var
|
|
571
|
-
console.log($.key), ($.keyCode === 13 || $.key === "Enter") && ((N = (
|
|
570
|
+
var V, N;
|
|
571
|
+
console.log($.key), ($.keyCode === 13 || $.key === "Enter") && ((N = (V = E.value) == null ? void 0 : V.table) == null || N.load());
|
|
572
572
|
}), [
|
|
573
573
|
"radio",
|
|
574
574
|
"switch",
|
|
@@ -586,8 +586,8 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
586
586
|
"datetimerange",
|
|
587
587
|
"week"
|
|
588
588
|
].includes(i) && e.value.onChange === void 0 && (e.value.onChange = ($) => {
|
|
589
|
-
var
|
|
590
|
-
(N = (
|
|
589
|
+
var V, N;
|
|
590
|
+
(N = (V = E.value) == null ? void 0 : V.table) == null || N.load();
|
|
591
591
|
});
|
|
592
592
|
}
|
|
593
593
|
f.value == "image" && (e.value.width && ((y = se.value) != null && y.$el) && se.value.$el.style.setProperty("--up-width", typeof e.value.width == "number" ? e.value.width + "px" : e.value.width), e.value.height && ((m = se.value) != null && m.$el) && se.value.$el.style.setProperty("--up-height", typeof e.value.height == "number" ? e.value.height + "px" : e.value.height), e.value.fontSize && ((b = se.value) != null && b.$el) && se.value.$el.style.setProperty("--up-font-size", typeof e.value.fontSize == "number" ? e.value.fontSize + "px" : e.value.fontSize));
|
|
@@ -597,72 +597,72 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
597
597
|
return e.value["file-list"] && e.value["file-list"].length ? (a = e.value["file-list"]) == null ? void 0 : a.map((s) => s == null ? void 0 : s.url) : [c.value];
|
|
598
598
|
});
|
|
599
599
|
return (a, s) => {
|
|
600
|
-
var
|
|
601
|
-
const M = B("el-image-viewer"), u = B("el-radio"), y = B("el-radio-group"), m = B("el-radio-button"), b = B("el-checkbox"), i = B("el-checkbox-group"), $ = B("el-checkbox-button"),
|
|
600
|
+
var J, we, ke;
|
|
601
|
+
const M = B("el-image-viewer"), u = B("el-radio"), y = B("el-radio-group"), m = B("el-radio-button"), b = B("el-checkbox"), i = B("el-checkbox-group"), $ = B("el-checkbox-button"), V = B("g-select-option"), N = B("el-option"), T = B("el-select"), O = B("el-tree-select"), de = B("el-time-picker"), te = B("el-time-select"), _e = B("el-date-picker"), Ce = B("el-color-picker"), Fe = B("el-rate"), Te = B("el-slider"), Ee = B("el-switch"), qe = B("el-transfer"), Ae = B("el-cascader"), Be = B("el-icon"), lt = B("el-image"), Xe = B("el-tooltip"), l = B("el-upload"), r = B("el-autocomplete"), v = B("el-input-number"), C = B("el-input"), P = B("el-link"), H = B("el-tag");
|
|
602
602
|
return n(), q(W, null, [
|
|
603
603
|
X("div", null, [
|
|
604
|
-
_.value ? (n(),
|
|
604
|
+
_.value ? (n(), D(M, {
|
|
605
605
|
key: 0,
|
|
606
606
|
teleported: !0,
|
|
607
607
|
"url-list": ee.value,
|
|
608
608
|
onClose: s[0] || (s[0] = (d) => _.value = !1)
|
|
609
609
|
}, null, 8, ["url-list"])) : ve("", !0)
|
|
610
610
|
]),
|
|
611
|
-
X("div",
|
|
612
|
-
f.value == I(pe).RADIO ? (n(),
|
|
611
|
+
X("div", Kt, [
|
|
612
|
+
f.value == I(pe).RADIO ? (n(), D(y, S({
|
|
613
613
|
key: 0,
|
|
614
614
|
modelValue: c.value,
|
|
615
615
|
"onUpdate:modelValue": s[1] || (s[1] = (d) => c.value = d)
|
|
616
616
|
}, e.value), {
|
|
617
617
|
default: g(() => [
|
|
618
|
-
h(a.$slots, `${t.t}-${
|
|
619
|
-
(n(!0), q(W, null, U(F.value, (d) => (n(),
|
|
618
|
+
h(a.$slots, `${t.t}-${o.value}`, { data: e.value }, () => [
|
|
619
|
+
(n(!0), q(W, null, U(F.value, (d) => (n(), D(u, S({ ref_for: !0 }, d), {
|
|
620
620
|
default: g(() => [
|
|
621
|
-
h(a.$slots, `${t.t}-${
|
|
621
|
+
h(a.$slots, `${t.t}-${o.value}-options`, { option: d }, void 0, !0)
|
|
622
622
|
]),
|
|
623
623
|
_: 2
|
|
624
624
|
}, 1040))), 256))
|
|
625
625
|
], !0)
|
|
626
626
|
]),
|
|
627
627
|
_: 3
|
|
628
|
-
}, 16, ["modelValue"])) : f.value == I(pe).RADIOBUTTON ? (n(),
|
|
628
|
+
}, 16, ["modelValue"])) : f.value == I(pe).RADIOBUTTON ? (n(), D(y, S({
|
|
629
629
|
key: 1,
|
|
630
630
|
modelValue: c.value,
|
|
631
631
|
"onUpdate:modelValue": s[2] || (s[2] = (d) => c.value = d)
|
|
632
632
|
}, e.value), {
|
|
633
633
|
default: g(() => [
|
|
634
|
-
h(a.$slots, `${t.t}-${
|
|
635
|
-
(n(!0), q(W, null, U(F.value, (d) => (n(),
|
|
634
|
+
h(a.$slots, `${t.t}-${o.value}`, { data: e.value }, () => [
|
|
635
|
+
(n(!0), q(W, null, U(F.value, (d) => (n(), D(m, S({ ref_for: !0 }, d), {
|
|
636
636
|
default: g(() => [
|
|
637
|
-
h(a.$slots, `${t.t}-${
|
|
637
|
+
h(a.$slots, `${t.t}-${o.value}-options`, { option: d }, void 0, !0)
|
|
638
638
|
]),
|
|
639
639
|
_: 2
|
|
640
640
|
}, 1040))), 256))
|
|
641
641
|
], !0)
|
|
642
642
|
]),
|
|
643
643
|
_: 3
|
|
644
|
-
}, 16, ["modelValue"])) : f.value == I(pe).CHECKBOX ? (n(),
|
|
644
|
+
}, 16, ["modelValue"])) : f.value == I(pe).CHECKBOX ? (n(), D(b, S({
|
|
645
645
|
key: 2,
|
|
646
646
|
modelValue: c.value,
|
|
647
647
|
"onUpdate:modelValue": s[3] || (s[3] = (d) => c.value = d)
|
|
648
648
|
}, e.value), {
|
|
649
649
|
default: g(() => [
|
|
650
|
-
h(a.$slots, `${t.t}-${
|
|
651
|
-
s[27] || (s[27] =
|
|
650
|
+
h(a.$slots, `${t.t}-${o.value}`, { data: e.value }, () => [
|
|
651
|
+
s[27] || (s[27] = Ve(he(" ")))
|
|
652
652
|
], !0)
|
|
653
653
|
]),
|
|
654
654
|
_: 3
|
|
655
|
-
}, 16, ["modelValue"])) : f.value == I(pe).CHECKBOXGROUP ? (n(),
|
|
655
|
+
}, 16, ["modelValue"])) : f.value == I(pe).CHECKBOXGROUP ? (n(), D(i, S({
|
|
656
656
|
key: 3,
|
|
657
657
|
modelValue: c.value,
|
|
658
658
|
"onUpdate:modelValue": s[4] || (s[4] = (d) => c.value = d)
|
|
659
659
|
}, e.value), {
|
|
660
660
|
default: g(() => [
|
|
661
|
-
h(a.$slots, `${t.t}-${
|
|
662
|
-
(n(!0), q(W, null, U(F.value, (d) => (n(),
|
|
661
|
+
h(a.$slots, `${t.t}-${o.value}`, { data: e.value }, () => [
|
|
662
|
+
(n(!0), q(W, null, U(F.value, (d) => (n(), D(b, S({ ref_for: !0 }, d), {
|
|
663
663
|
default: g(() => [
|
|
664
|
-
h(a.$slots, `${t.t}-${
|
|
665
|
-
|
|
664
|
+
h(a.$slots, `${t.t}-${o.value}-options`, { option: d }, () => [
|
|
665
|
+
Ve(he(d.label), 1)
|
|
666
666
|
], !0)
|
|
667
667
|
]),
|
|
668
668
|
_: 2
|
|
@@ -670,57 +670,57 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
670
670
|
], !0)
|
|
671
671
|
]),
|
|
672
672
|
_: 3
|
|
673
|
-
}, 16, ["modelValue"])) : f.value == I(pe).CHECKBOXGROUPBUTTON ? (n(),
|
|
673
|
+
}, 16, ["modelValue"])) : f.value == I(pe).CHECKBOXGROUPBUTTON ? (n(), D(i, S({
|
|
674
674
|
key: 4,
|
|
675
675
|
modelValue: c.value,
|
|
676
676
|
"onUpdate:modelValue": s[5] || (s[5] = (d) => c.value = d)
|
|
677
677
|
}, e.value), {
|
|
678
678
|
default: g(() => [
|
|
679
|
-
h(a.$slots, `${t.t}-${
|
|
680
|
-
(n(!0), q(W, null, U(F.value, (d) => (n(),
|
|
679
|
+
h(a.$slots, `${t.t}-${o.value}`, { data: e.value }, () => [
|
|
680
|
+
(n(!0), q(W, null, U(F.value, (d) => (n(), D($, S({ ref_for: !0 }, d), {
|
|
681
681
|
default: g(() => [
|
|
682
|
-
h(a.$slots, `${t.t}-${
|
|
682
|
+
h(a.$slots, `${t.t}-${o.value}-options`, { option: d }, void 0, !0)
|
|
683
683
|
]),
|
|
684
684
|
_: 2
|
|
685
685
|
}, 1040))), 256))
|
|
686
686
|
], !0)
|
|
687
687
|
]),
|
|
688
688
|
_: 3
|
|
689
|
-
}, 16, ["modelValue"])) : f.value === I(pe).SELECT ? (n(),
|
|
689
|
+
}, 16, ["modelValue"])) : f.value === I(pe).SELECT ? (n(), D(T, S({
|
|
690
690
|
key: 5,
|
|
691
691
|
modelValue: c.value,
|
|
692
692
|
"onUpdate:modelValue": s[6] || (s[6] = (d) => c.value = d),
|
|
693
|
-
placeholder: E.value[
|
|
693
|
+
placeholder: E.value[o.value].label,
|
|
694
694
|
clearable: !0,
|
|
695
695
|
onClear: s[7] || (s[7] = () => {
|
|
696
696
|
t.t == "q" && E.value.table.load();
|
|
697
697
|
})
|
|
698
698
|
}, ue.value), me({
|
|
699
699
|
default: g(() => [
|
|
700
|
-
h(a.$slots, `${t.t}-${
|
|
700
|
+
h(a.$slots, `${t.t}-${o.value}`, { options: F.value }, () => [
|
|
701
701
|
(n(!0), q(W, null, U(F.value, (d) => (n(), q(W, {
|
|
702
702
|
key: d.value
|
|
703
703
|
}, [
|
|
704
|
-
Q(N, S({ ref_for: !0 }, I(
|
|
705
|
-
onClick: (
|
|
706
|
-
ue.value.change && ue.value.change(d),
|
|
704
|
+
Q(N, S({ ref_for: !0 }, I(Me)(d, (G) => G != "children"), {
|
|
705
|
+
onClick: (G) => {
|
|
706
|
+
ue.value.change && ue.value.change(d), $e();
|
|
707
707
|
}
|
|
708
708
|
}), {
|
|
709
709
|
default: g(() => {
|
|
710
|
-
var
|
|
710
|
+
var G;
|
|
711
711
|
return [
|
|
712
|
-
(
|
|
712
|
+
(G = e.value) != null && G.columns ? h(a.$slots, `${t.t}-${o.value}-options`, {
|
|
713
713
|
key: 0,
|
|
714
714
|
option: d
|
|
715
715
|
}, () => {
|
|
716
|
-
var
|
|
716
|
+
var fe;
|
|
717
717
|
return [
|
|
718
|
-
Q(
|
|
719
|
-
columns: (
|
|
718
|
+
Q(V, {
|
|
719
|
+
columns: (fe = e.value) == null ? void 0 : fe.columns,
|
|
720
720
|
data: d,
|
|
721
721
|
t: t.t
|
|
722
722
|
}, me({ _: 2 }, [
|
|
723
|
-
U(a.$slots, (
|
|
723
|
+
U(a.$slots, (Oe, ze) => ({
|
|
724
724
|
name: ze,
|
|
725
725
|
fn: g((Ne) => [
|
|
726
726
|
h(a.$slots, ze, {
|
|
@@ -736,34 +736,34 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
736
736
|
}),
|
|
737
737
|
_: 2
|
|
738
738
|
}, 1040, ["onClick"]),
|
|
739
|
-
d.children && d.children.length ? (n(!0), q(W, { key: 0 }, U(d.children, (
|
|
739
|
+
d.children && d.children.length ? (n(!0), q(W, { key: 0 }, U(d.children, (G) => (n(), D(N, S({
|
|
740
740
|
style: { "margin-left": "20px" },
|
|
741
|
-
key:
|
|
741
|
+
key: G.value,
|
|
742
742
|
ref_for: !0
|
|
743
|
-
}, I(
|
|
744
|
-
onClick: (
|
|
745
|
-
ue.value.change && ue.value.change(
|
|
743
|
+
}, I(Me)(G, (fe) => fe != "children"), {
|
|
744
|
+
onClick: (fe) => {
|
|
745
|
+
ue.value.change && ue.value.change(G), $e();
|
|
746
746
|
}
|
|
747
747
|
}), {
|
|
748
748
|
default: g(() => {
|
|
749
|
-
var
|
|
749
|
+
var fe;
|
|
750
750
|
return [
|
|
751
|
-
(
|
|
751
|
+
(fe = e.value) != null && fe.columns ? h(a.$slots, `${t.t}-${o.value}-options`, {
|
|
752
752
|
key: 0,
|
|
753
|
-
option:
|
|
753
|
+
option: G
|
|
754
754
|
}, () => {
|
|
755
|
-
var
|
|
755
|
+
var Oe;
|
|
756
756
|
return [
|
|
757
|
-
Q(
|
|
758
|
-
columns: (
|
|
759
|
-
data:
|
|
757
|
+
Q(V, {
|
|
758
|
+
columns: (Oe = e.value) == null ? void 0 : Oe.columns,
|
|
759
|
+
data: G,
|
|
760
760
|
t: t.t
|
|
761
761
|
}, me({ _: 2 }, [
|
|
762
762
|
U(a.$slots, (ze, Ne) => ({
|
|
763
763
|
name: Ne,
|
|
764
764
|
fn: g((at) => [
|
|
765
765
|
h(a.$slots, Ne, {
|
|
766
|
-
option:
|
|
766
|
+
option: G,
|
|
767
767
|
data: at
|
|
768
768
|
}, void 0, !0)
|
|
769
769
|
])
|
|
@@ -780,20 +780,20 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
780
780
|
]),
|
|
781
781
|
_: 2
|
|
782
782
|
}, [
|
|
783
|
-
(
|
|
783
|
+
(J = e.value) != null && J.columns ? {
|
|
784
784
|
name: "header",
|
|
785
785
|
fn: g(() => {
|
|
786
786
|
var d;
|
|
787
787
|
return [
|
|
788
|
-
Q(
|
|
788
|
+
Q(V, {
|
|
789
789
|
columns: (d = e.value) == null ? void 0 : d.columns,
|
|
790
790
|
title: !0,
|
|
791
791
|
t: t.t
|
|
792
792
|
}, me({ _: 2 }, [
|
|
793
|
-
U(a.$slots, (
|
|
794
|
-
name:
|
|
795
|
-
fn: g((
|
|
796
|
-
h(a.$slots,
|
|
793
|
+
U(a.$slots, (G, fe) => ({
|
|
794
|
+
name: fe,
|
|
795
|
+
fn: g((Oe) => [
|
|
796
|
+
h(a.$slots, fe, { data: Oe }, void 0, !0)
|
|
797
797
|
])
|
|
798
798
|
}))
|
|
799
799
|
]), 1032, ["columns", "t"])
|
|
@@ -803,97 +803,97 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
803
803
|
} : void 0,
|
|
804
804
|
U(R(), (d) => ({
|
|
805
805
|
name: d,
|
|
806
|
-
fn: g((
|
|
807
|
-
h(a.$slots, `${t.t}-${
|
|
806
|
+
fn: g((G) => [
|
|
807
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: G }, void 0, !0)
|
|
808
808
|
])
|
|
809
809
|
}))
|
|
810
|
-
]), 1040, ["modelValue", "placeholder"])) : f.value == I(pe).TREESELECT ? (n(),
|
|
810
|
+
]), 1040, ["modelValue", "placeholder"])) : f.value == I(pe).TREESELECT ? (n(), D(O, S({
|
|
811
811
|
key: 6,
|
|
812
812
|
modelValue: c.value,
|
|
813
813
|
"onUpdate:modelValue": s[8] || (s[8] = (d) => c.value = d),
|
|
814
|
-
placeholder: E.value[
|
|
814
|
+
placeholder: E.value[o.value].label
|
|
815
815
|
}, e.value, { data: x.value }), me({ _: 2 }, [
|
|
816
816
|
U(R(), (d) => ({
|
|
817
817
|
name: d,
|
|
818
|
-
fn: g((
|
|
819
|
-
h(a.$slots, `${t.t}-${
|
|
818
|
+
fn: g((G) => [
|
|
819
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: G }, void 0, !0)
|
|
820
820
|
])
|
|
821
821
|
}))
|
|
822
|
-
]), 1040, ["modelValue", "placeholder", "data"])) : f.value == I(pe).TIME ? (n(),
|
|
822
|
+
]), 1040, ["modelValue", "placeholder", "data"])) : f.value == I(pe).TIME ? (n(), D(de, S({
|
|
823
823
|
key: 7,
|
|
824
824
|
modelValue: c.value,
|
|
825
825
|
"onUpdate:modelValue": s[9] || (s[9] = (d) => c.value = d),
|
|
826
826
|
"arrow-control": ""
|
|
827
827
|
}, e.value, {
|
|
828
|
-
placeholder: E.value[
|
|
829
|
-
}), null, 16, ["modelValue", "placeholder"])) : f.value == I(pe).TIMESELECT ? (n(),
|
|
828
|
+
placeholder: E.value[o.value].label
|
|
829
|
+
}), null, 16, ["modelValue", "placeholder"])) : f.value == I(pe).TIMESELECT ? (n(), D(te, S({
|
|
830
830
|
key: 8,
|
|
831
831
|
modelValue: c.value,
|
|
832
832
|
"onUpdate:modelValue": s[10] || (s[10] = (d) => c.value = d),
|
|
833
833
|
start: "06:30",
|
|
834
834
|
step: "00:15",
|
|
835
835
|
end: "23:30",
|
|
836
|
-
placeholder: E.value[
|
|
837
|
-
}, e.value), null, 16, ["modelValue", "placeholder"])) : A(f.value) ? (n(),
|
|
836
|
+
placeholder: E.value[o.value].label
|
|
837
|
+
}, e.value), null, 16, ["modelValue", "placeholder"])) : A(f.value) ? (n(), D(_e, S({
|
|
838
838
|
key: 9,
|
|
839
839
|
modelValue: c.value,
|
|
840
840
|
"onUpdate:modelValue": s[11] || (s[11] = (d) => c.value = d),
|
|
841
841
|
type: f.value,
|
|
842
|
-
placeholder: E.value[
|
|
843
|
-
"value-format":
|
|
842
|
+
placeholder: E.value[o.value].label,
|
|
843
|
+
"value-format": oe(f.value)
|
|
844
844
|
}, e.value), me({ _: 2 }, [
|
|
845
845
|
U(R(), (d) => ({
|
|
846
846
|
name: d,
|
|
847
|
-
fn: g((
|
|
848
|
-
h(a.$slots, `${t.t}-${
|
|
847
|
+
fn: g((G) => [
|
|
848
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: G }, void 0, !0)
|
|
849
849
|
])
|
|
850
850
|
}))
|
|
851
|
-
]), 1040, ["modelValue", "type", "placeholder", "value-format"])) : f.value == I(pe).COLOR ? (n(),
|
|
851
|
+
]), 1040, ["modelValue", "type", "placeholder", "value-format"])) : f.value == I(pe).COLOR ? (n(), D(Ce, S({
|
|
852
852
|
key: 10,
|
|
853
853
|
modelValue: c.value,
|
|
854
854
|
"onUpdate:modelValue": s[12] || (s[12] = (d) => c.value = d)
|
|
855
|
-
}, e.value), null, 16, ["modelValue"])) : f.value == I(pe).RATE ? (n(),
|
|
855
|
+
}, e.value), null, 16, ["modelValue"])) : f.value == I(pe).RATE ? (n(), D(Fe, S({
|
|
856
856
|
key: 11,
|
|
857
857
|
modelValue: c.value,
|
|
858
858
|
"onUpdate:modelValue": s[13] || (s[13] = (d) => c.value = d)
|
|
859
|
-
}, e.value), null, 16, ["modelValue"])) : f.value == I(pe).SLIDER ? (n(),
|
|
859
|
+
}, e.value), null, 16, ["modelValue"])) : f.value == I(pe).SLIDER ? (n(), D(Te, S({
|
|
860
860
|
key: 12,
|
|
861
861
|
modelValue: c.value,
|
|
862
862
|
"onUpdate:modelValue": s[14] || (s[14] = (d) => c.value = d)
|
|
863
|
-
}, e.value), null, 16, ["modelValue"])) : f.value == I(pe).SWITCH ? (n(),
|
|
863
|
+
}, e.value), null, 16, ["modelValue"])) : f.value == I(pe).SWITCH ? (n(), D(Ee, S({
|
|
864
864
|
key: 13,
|
|
865
865
|
modelValue: c.value,
|
|
866
866
|
"onUpdate:modelValue": s[15] || (s[15] = (d) => c.value = d)
|
|
867
867
|
}, e.value), me({ _: 2 }, [
|
|
868
868
|
U(R(), (d) => ({
|
|
869
869
|
name: d,
|
|
870
|
-
fn: g((
|
|
871
|
-
h(a.$slots, `${t.t}-${
|
|
870
|
+
fn: g((G) => [
|
|
871
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: G }, void 0, !0)
|
|
872
872
|
])
|
|
873
873
|
}))
|
|
874
|
-
]), 1040, ["modelValue"])) : f.value == I(pe).TRANSFER ? (n(),
|
|
874
|
+
]), 1040, ["modelValue"])) : f.value == I(pe).TRANSFER ? (n(), D(qe, S({
|
|
875
875
|
key: 14,
|
|
876
876
|
modelValue: c.value,
|
|
877
877
|
"onUpdate:modelValue": s[16] || (s[16] = (d) => c.value = d)
|
|
878
878
|
}, e.value), me({ _: 2 }, [
|
|
879
879
|
U(R(), (d) => ({
|
|
880
880
|
name: d,
|
|
881
|
-
fn: g((
|
|
882
|
-
h(a.$slots, `${t.t}-${
|
|
881
|
+
fn: g((G) => [
|
|
882
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: G }, void 0, !0)
|
|
883
883
|
])
|
|
884
884
|
}))
|
|
885
|
-
]), 1040, ["modelValue"])) : f.value == I(pe).CASCADER ? (n(),
|
|
885
|
+
]), 1040, ["modelValue"])) : f.value == I(pe).CASCADER ? (n(), D(Ae, S({
|
|
886
886
|
key: 15,
|
|
887
887
|
modelValue: c.value,
|
|
888
888
|
"onUpdate:modelValue": s[17] || (s[17] = (d) => c.value = d)
|
|
889
889
|
}, e.value, { options: F.value }), me({ _: 2 }, [
|
|
890
890
|
U(R(), (d) => ({
|
|
891
891
|
name: d,
|
|
892
|
-
fn: g((
|
|
893
|
-
h(a.$slots, `${t.t}-${
|
|
892
|
+
fn: g((G) => [
|
|
893
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: G }, void 0, !0)
|
|
894
894
|
])
|
|
895
895
|
}))
|
|
896
|
-
]), 1040, ["modelValue", "options"])) : f.value == I(pe).IMAGE ? (n(),
|
|
896
|
+
]), 1040, ["modelValue", "options"])) : f.value == I(pe).IMAGE ? (n(), D(l, S({
|
|
897
897
|
key: 16,
|
|
898
898
|
"file-list": e.value["file-list"],
|
|
899
899
|
"onUpdate:fileList": s[21] || (s[21] = (d) => e.value["file-list"] = d),
|
|
@@ -909,35 +909,35 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
909
909
|
return [
|
|
910
910
|
c.value ? (n(), q("div", {
|
|
911
911
|
key: 1,
|
|
912
|
-
onClick: s[20] || (s[20] = (
|
|
912
|
+
onClick: s[20] || (s[20] = (G) => G.stopPropagation()),
|
|
913
913
|
style: { display: "flex", width: "var(--up-width)", height: "var(--up-height)", position: "relative", "align-items": "center", "justify-content": "center", "box-sizing": "border-box" }
|
|
914
914
|
}, [
|
|
915
|
-
X("div",
|
|
915
|
+
X("div", el, [
|
|
916
916
|
Q(lt, S({
|
|
917
917
|
style: { width: "var(--up-width)", height: "var(--up-height)" },
|
|
918
918
|
src: c.value
|
|
919
919
|
}, { fit: "cover", lazy: !0, ...(d = e.value) == null ? void 0 : d.img }), me({ _: 2 }, [
|
|
920
|
-
U(R(), (
|
|
921
|
-
name:
|
|
922
|
-
fn: g((
|
|
923
|
-
h(a.$slots, `${t.t}-${
|
|
920
|
+
U(R(), (G, fe) => ({
|
|
921
|
+
name: G,
|
|
922
|
+
fn: g((Oe) => [
|
|
923
|
+
h(a.$slots, `${t.t}-${o.value}-${G}`, { data: Oe }, void 0, !0)
|
|
924
924
|
])
|
|
925
925
|
}))
|
|
926
926
|
]), 1040, ["src"])
|
|
927
927
|
]),
|
|
928
928
|
X("div", {
|
|
929
929
|
style: { display: "flex", width: "var(--up-width)", height: "var(--up-height)", position: "absolute", "align-items": "center", "justify-content": "center" },
|
|
930
|
-
onMouseenter: s[18] || (s[18] = (
|
|
931
|
-
onMouseleave: s[19] || (s[19] = (
|
|
930
|
+
onMouseenter: s[18] || (s[18] = (G) => k.value = !0),
|
|
931
|
+
onMouseleave: s[19] || (s[19] = (G) => k.value = !1),
|
|
932
932
|
class: "up-view"
|
|
933
933
|
}, [
|
|
934
|
-
k.value ? (n(),
|
|
934
|
+
k.value ? (n(), D(Xe, {
|
|
935
935
|
key: 0,
|
|
936
936
|
content: "查看大图",
|
|
937
937
|
placement: "top"
|
|
938
938
|
}, {
|
|
939
939
|
default: g(() => [
|
|
940
|
-
Q(I(
|
|
940
|
+
Q(I(Pt), {
|
|
941
941
|
style: { width: "1.5em", height: "1.5em", "margin-right": "12px" },
|
|
942
942
|
color: "white",
|
|
943
943
|
onClick: ne
|
|
@@ -945,24 +945,24 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
945
945
|
]),
|
|
946
946
|
_: 1
|
|
947
947
|
})) : ve("", !0),
|
|
948
|
-
ae.value.showDel && k.value ? (n(),
|
|
948
|
+
ae.value.showDel && k.value ? (n(), D(Xe, {
|
|
949
949
|
key: 1,
|
|
950
950
|
content: "删除",
|
|
951
951
|
placement: "top"
|
|
952
952
|
}, {
|
|
953
953
|
default: g(() => [
|
|
954
|
-
Q(I(
|
|
954
|
+
Q(I(Ht), {
|
|
955
955
|
style: { width: "1.5em", height: "1.5em" },
|
|
956
956
|
color: "white",
|
|
957
|
-
onClick:
|
|
957
|
+
onClick: ge
|
|
958
958
|
})
|
|
959
959
|
]),
|
|
960
960
|
_: 1
|
|
961
961
|
})) : ve("", !0)
|
|
962
962
|
], 32)
|
|
963
|
-
])) : (n(),
|
|
963
|
+
])) : (n(), D(Be, { key: 0 }, {
|
|
964
964
|
default: g(() => [
|
|
965
|
-
Q(I(
|
|
965
|
+
Q(I(Nt))
|
|
966
966
|
]),
|
|
967
967
|
_: 1
|
|
968
968
|
}))
|
|
@@ -970,103 +970,103 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
970
970
|
}),
|
|
971
971
|
_: 2
|
|
972
972
|
}, [
|
|
973
|
-
U(R(), (d,
|
|
973
|
+
U(R(), (d, G) => ({
|
|
974
974
|
name: d,
|
|
975
|
-
fn: g((
|
|
976
|
-
h(a.$slots, `${t.t}-${
|
|
975
|
+
fn: g((fe) => [
|
|
976
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: fe }, void 0, !0)
|
|
977
977
|
])
|
|
978
978
|
}))
|
|
979
|
-
]), 1040, ["file-list"])) : f.value == I(pe).AUTOCOMPLETE ? (n(),
|
|
979
|
+
]), 1040, ["file-list"])) : f.value == I(pe).AUTOCOMPLETE ? (n(), D(r, S({
|
|
980
980
|
key: 17,
|
|
981
981
|
modelValue: c.value,
|
|
982
982
|
"onUpdate:modelValue": s[22] || (s[22] = (d) => c.value = d)
|
|
983
983
|
}, e.value, {
|
|
984
|
-
placeholder: E.value[
|
|
984
|
+
placeholder: E.value[o.value].label
|
|
985
985
|
}), me({ _: 2 }, [
|
|
986
|
-
U(R(), (d,
|
|
986
|
+
U(R(), (d, G) => ({
|
|
987
987
|
name: d,
|
|
988
|
-
fn: g((
|
|
989
|
-
h(a.$slots, `${t.t}-${
|
|
988
|
+
fn: g((fe) => [
|
|
989
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: fe }, void 0, !0)
|
|
990
990
|
])
|
|
991
991
|
}))
|
|
992
|
-
]), 1040, ["modelValue", "placeholder"])) : f.value == I(pe).INPUTNUMBER ? (n(),
|
|
992
|
+
]), 1040, ["modelValue", "placeholder"])) : f.value == I(pe).INPUTNUMBER ? (n(), D(v, S({
|
|
993
993
|
key: 18,
|
|
994
994
|
modelValue: c.value,
|
|
995
995
|
"onUpdate:modelValue": s[23] || (s[23] = (d) => c.value = d),
|
|
996
996
|
min: 0,
|
|
997
997
|
max: 1e8,
|
|
998
|
-
placeholder: E.value[
|
|
998
|
+
placeholder: E.value[o.value].label
|
|
999
999
|
}, e.value), me({ _: 2 }, [
|
|
1000
|
-
U(R(), (d,
|
|
1000
|
+
U(R(), (d, G) => ({
|
|
1001
1001
|
name: d,
|
|
1002
|
-
fn: g((
|
|
1003
|
-
h(a.$slots, `${t.t}-${
|
|
1002
|
+
fn: g((fe) => [
|
|
1003
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: fe }, void 0, !0)
|
|
1004
1004
|
])
|
|
1005
1005
|
}))
|
|
1006
|
-
]), 1040, ["modelValue", "placeholder"])) : f.value == I(pe).MONEY ? (n(), q("div",
|
|
1007
|
-
Q(
|
|
1006
|
+
]), 1040, ["modelValue", "placeholder"])) : f.value == I(pe).MONEY ? (n(), q("div", tl, [
|
|
1007
|
+
Q(C, S({
|
|
1008
1008
|
modelValue: c.value,
|
|
1009
1009
|
"onUpdate:modelValue": s[24] || (s[24] = (d) => c.value = d),
|
|
1010
|
-
placeholder: E.value[
|
|
1010
|
+
placeholder: E.value[o.value].label,
|
|
1011
1011
|
type: I(pe).NUMBER,
|
|
1012
|
-
maxlength: ((
|
|
1012
|
+
maxlength: ((we = e.value) == null ? void 0 : we.max) || 25
|
|
1013
1013
|
}, { ...e.value, type: f.value }), me({
|
|
1014
1014
|
suffix: g(() => [
|
|
1015
1015
|
X("div", {
|
|
1016
1016
|
title: I(mt)(c.value),
|
|
1017
1017
|
style: { "font-size": "10px", display: "block", width: "80px", "text-align": "right", overflow: "hidden", "text-overflow": "ellipsis" }
|
|
1018
|
-
}, he(I(mt)(c.value)), 9,
|
|
1018
|
+
}, he(I(mt)(c.value)), 9, ll)
|
|
1019
1019
|
]),
|
|
1020
1020
|
_: 2
|
|
1021
1021
|
}, [
|
|
1022
|
-
U(R(), (d,
|
|
1022
|
+
U(R(), (d, G) => ({
|
|
1023
1023
|
name: d,
|
|
1024
|
-
fn: g((
|
|
1025
|
-
h(a.$slots, `${t.t}-${
|
|
1024
|
+
fn: g((fe) => [
|
|
1025
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: fe }, void 0, !0)
|
|
1026
1026
|
])
|
|
1027
1027
|
}))
|
|
1028
1028
|
]), 1040, ["modelValue", "placeholder", "type", "maxlength"])
|
|
1029
|
-
])) : (f.value === "primary" || f.value === "success" || f.value === "warning" || f.value == "danger" || f.value === "info" || f.value == "default") && e.value.isLink === !0 ? (n(), q("div",
|
|
1029
|
+
])) : (f.value === "primary" || f.value === "success" || f.value === "warning" || f.value == "danger" || f.value === "info" || f.value == "default") && e.value.isLink === !0 ? (n(), q("div", al, [
|
|
1030
1030
|
Q(P, S(e.value, {
|
|
1031
1031
|
innerHTML: Y.value || c.value
|
|
1032
1032
|
}), null, 16, ["innerHTML"])
|
|
1033
|
-
])) : (f.value === "primary" || f.value === "success" || f.value === "warning" || f.value == "danger" || f.value === "info") && e.value.isTag === !0 ? (n(), q("div",
|
|
1034
|
-
Array.isArray(Y.value) && Y.value.length > 0 ? (n(!0), q(W, { key: 0 }, U(Y.value, (d,
|
|
1035
|
-
typeof d == "object" ? (n(),
|
|
1033
|
+
])) : (f.value === "primary" || f.value === "success" || f.value === "warning" || f.value == "danger" || f.value === "info") && e.value.isTag === !0 ? (n(), q("div", rl, [
|
|
1034
|
+
Array.isArray(Y.value) && Y.value.length > 0 ? (n(!0), q(W, { key: 0 }, U(Y.value, (d, G) => (n(), q(W, { key: G }, [
|
|
1035
|
+
typeof d == "object" ? (n(), D(H, S({
|
|
1036
1036
|
key: 0,
|
|
1037
1037
|
ref_for: !0
|
|
1038
1038
|
}, d, {
|
|
1039
1039
|
innerHTML: d == null ? void 0 : d.value,
|
|
1040
1040
|
style: { "margin-right": "3px" }
|
|
1041
|
-
}), null, 16, ["innerHTML"])) : (n(),
|
|
1041
|
+
}), null, 16, ["innerHTML"])) : (n(), D(H, S({
|
|
1042
1042
|
key: 1,
|
|
1043
1043
|
ref_for: !0
|
|
1044
1044
|
}, e.value, {
|
|
1045
1045
|
innerHTML: d,
|
|
1046
1046
|
style: { "margin-right": "3px" }
|
|
1047
1047
|
}), null, 16, ["innerHTML"]))
|
|
1048
|
-
], 64))), 128)) : (n(),
|
|
1048
|
+
], 64))), 128)) : (n(), D(H, S({ key: 1 }, e.value, {
|
|
1049
1049
|
innerHTML: Y.value || c.value
|
|
1050
1050
|
}), null, 16, ["innerHTML"]))
|
|
1051
1051
|
])) : f.value == "div" ? (n(), q("div", S({ key: 22 }, e.value, {
|
|
1052
1052
|
innerHTML: Y.value || c.value
|
|
1053
1053
|
}), null, 16, ol)) : f.value == "span" ? (n(), q("span", S({ key: 23 }, e.value, {
|
|
1054
1054
|
innerHTML: Y.value || c.value
|
|
1055
|
-
}), null, 16,
|
|
1055
|
+
}), null, 16, ul)) : (n(), D(C, S({
|
|
1056
1056
|
key: 24,
|
|
1057
1057
|
modelValue: c.value,
|
|
1058
1058
|
"onUpdate:modelValue": s[25] || (s[25] = (d) => c.value = d),
|
|
1059
|
-
placeholder: E.value[
|
|
1060
|
-
maxlength: ((
|
|
1059
|
+
placeholder: E.value[o.value].label,
|
|
1060
|
+
maxlength: ((ke = e.value) == null ? void 0 : ke.max) || 25,
|
|
1061
1061
|
clearable: !0,
|
|
1062
1062
|
onClear: s[26] || (s[26] = () => {
|
|
1063
1063
|
t.t == "q" && E.value.table.load();
|
|
1064
1064
|
})
|
|
1065
1065
|
}, { ...e.value, type: f.value }), me({ _: 2 }, [
|
|
1066
|
-
U(R(), (d,
|
|
1066
|
+
U(R(), (d, G) => ({
|
|
1067
1067
|
name: d,
|
|
1068
|
-
fn: g((
|
|
1069
|
-
h(a.$slots, `${t.t}-${
|
|
1068
|
+
fn: g((fe) => [
|
|
1069
|
+
h(a.$slots, `${t.t}-${o.value}-${d}`, { data: fe }, void 0, !0)
|
|
1070
1070
|
])
|
|
1071
1071
|
}))
|
|
1072
1072
|
]), 1040, ["modelValue", "placeholder", "maxlength"]))
|
|
@@ -1074,7 +1074,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1074
1074
|
], 64);
|
|
1075
1075
|
};
|
|
1076
1076
|
}
|
|
1077
|
-
}), ut = /* @__PURE__ */ He(
|
|
1077
|
+
}), ut = /* @__PURE__ */ He(nl, [["__scopeId", "data-v-a78297fa"]]), dt = /* @__PURE__ */ Object.assign({
|
|
1078
1078
|
name: "g-form",
|
|
1079
1079
|
inheritAttrs: !1
|
|
1080
1080
|
}, {
|
|
@@ -1085,8 +1085,8 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1085
1085
|
}),
|
|
1086
1086
|
emits: /* @__PURE__ */ je(["submit", "reset"], ["update:modelValue"]),
|
|
1087
1087
|
setup(p, { emit: c }) {
|
|
1088
|
-
var se, ee,
|
|
1089
|
-
const t = Le(p, "modelValue"), e = c,
|
|
1088
|
+
var se, ee, be, ie;
|
|
1089
|
+
const t = Le(p, "modelValue"), e = c, o = le(null), f = vt("options"), E = le({}), x = le(""), F = p, _ = {
|
|
1090
1090
|
inline: !0,
|
|
1091
1091
|
type: "hidden",
|
|
1092
1092
|
"scroll-to-error": !0,
|
|
@@ -1138,8 +1138,8 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1138
1138
|
const k = async (a, s) => {
|
|
1139
1139
|
let M = 5;
|
|
1140
1140
|
for (; M > 0; ) {
|
|
1141
|
-
if (await et(),
|
|
1142
|
-
|
|
1141
|
+
if (await et(), o.value) {
|
|
1142
|
+
o.value.validate((u, y) => {
|
|
1143
1143
|
u ? e("submit", a, s) : console.log("表单验证不通过!", y);
|
|
1144
1144
|
});
|
|
1145
1145
|
return;
|
|
@@ -1150,7 +1150,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1150
1150
|
}, R = async () => {
|
|
1151
1151
|
let a = 5;
|
|
1152
1152
|
for (; a > 0; ) {
|
|
1153
|
-
if (await et(), !
|
|
1153
|
+
if (await et(), !o.value) {
|
|
1154
1154
|
a--, await new Promise((M) => setTimeout(M, 50));
|
|
1155
1155
|
continue;
|
|
1156
1156
|
}
|
|
@@ -1158,7 +1158,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1158
1158
|
if (e("reset", (M) => {
|
|
1159
1159
|
s = M;
|
|
1160
1160
|
}), s) {
|
|
1161
|
-
|
|
1161
|
+
o.value.resetFields();
|
|
1162
1162
|
return;
|
|
1163
1163
|
}
|
|
1164
1164
|
a--, await new Promise((M) => setTimeout(M, 50));
|
|
@@ -1176,7 +1176,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1176
1176
|
t.value.formItems = Se(
|
|
1177
1177
|
ae,
|
|
1178
1178
|
f == null ? void 0 : f.formItems,
|
|
1179
|
-
(
|
|
1179
|
+
(be = t == null ? void 0 : t.value) == null ? void 0 : be.formItems
|
|
1180
1180
|
);
|
|
1181
1181
|
const Y = {
|
|
1182
1182
|
span: 12,
|
|
@@ -1204,34 +1204,34 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1204
1204
|
u.required && s.push({ required: !0, message: `${u.label}不能为空!`, trigger: "blur" }), u.max !== void 0 && u.max !== null && u.max !== "" && (u.min === void 0 || u.min === null || u.min === "") && s.push({
|
|
1205
1205
|
validator: (y, m, b) => {
|
|
1206
1206
|
if (m == null || m === "") return b();
|
|
1207
|
-
u.type !== "number" && u.type !== "input-number"
|
|
1207
|
+
u.type !== "number" && u.type !== "input-number" ? ((m == null ? void 0 : m.toString()) || "").length > Number(u.max) ? b(new Error(`${u.label}长度不能超过${u.max}个字符!`)) : b() : Number(m) > Number(u.max) ? b(new Error(`${u.label}不能大于${u.max}!`)) : b();
|
|
1208
1208
|
}
|
|
1209
1209
|
}), u.min !== void 0 && u.min !== null && u.min !== "" && (u.max === void 0 || u.max === null || u.max === "") && s.push({
|
|
1210
1210
|
validator: (y, m, b) => {
|
|
1211
1211
|
if (m == null || m === "") return b();
|
|
1212
|
-
u.type !== "number" && u.type !== "input-number"
|
|
1212
|
+
u.type !== "number" && u.type !== "input-number" ? Number(u.min) < 1 ? b(new Error(`${u.label}长度最小值${u.min}设置错误!`)) : m.toString().length < Number(u.min) ? b(new Error(`${u.label}长度不能少于${u.min}个字符!`)) : b() : Number(m) < Number(u.min) ? b(new Error(`${u.label}不能小于${u.min}!`)) : b();
|
|
1213
1213
|
}
|
|
1214
1214
|
}), u.min !== void 0 && u.min !== null && u.min !== "" && u.max !== void 0 && u.max !== null && u.max !== "" && s.push({
|
|
1215
1215
|
validator: (y, m, b) => {
|
|
1216
1216
|
if (m == null || m === "") return b();
|
|
1217
1217
|
const i = Number(u.min), $ = Number(u.max);
|
|
1218
|
-
u.type !== "number" && u.type !== "input-number"
|
|
1218
|
+
u.type !== "number" && u.type !== "input-number" ? Number(u.min) < 1 ? b(new Error(`${u.label}长度最小值${u.min}设置错误!`)) : m.toString().length < i || m.toString().length > $ ? b(new Error(`${u.label}长度必须在${i}-${$}个字符之间!`)) : b() : Number(m) < i || m > $ ? b(new Error(`${u.label}必须在${i}-${$}之间!`)) : b();
|
|
1219
1219
|
}
|
|
1220
1220
|
}), u.type == "email" && s.push({ type: "email", message: "不是一个正确的邮箱地址!" }), u.type == "url" && s.push({ type: "url", message: "不是一个合正确的URL!" }), u.pattern && s.push({ pattern: u == null ? void 0 : u.pattern, message: (u == null ? void 0 : u.message) || "格式不正确!" }), u.validate && s.push({
|
|
1221
1221
|
validator: (y, m, b) => u.validate(y, m, b)
|
|
1222
1222
|
});
|
|
1223
1223
|
}
|
|
1224
1224
|
return s;
|
|
1225
|
-
},
|
|
1225
|
+
}, oe = (a, s = !1) => {
|
|
1226
1226
|
var y, m, b, i, $;
|
|
1227
1227
|
const M = s ? a : a == null ? void 0 : a.item, u = typeof (M == null ? void 0 : M.editor) == "function" ? M.editor(E.value, (y = t.value.form) == null ? void 0 : y.modalState) : (M == null ? void 0 : M.editor) || {};
|
|
1228
1228
|
if (((m = t.value.form) == null ? void 0 : m.modalState) === "edit") {
|
|
1229
|
-
const
|
|
1230
|
-
return { ...u, ...
|
|
1229
|
+
const V = typeof (M == null ? void 0 : M.editor) == "object" ? (b = M.editor) == null ? void 0 : b.ep : typeof (M == null ? void 0 : M.editor) == "function" ? u == null ? void 0 : u.ep : {};
|
|
1230
|
+
return { ...u, ...V };
|
|
1231
1231
|
}
|
|
1232
1232
|
if (((i = t.value.form) == null ? void 0 : i.modalState) === "add") {
|
|
1233
|
-
const
|
|
1234
|
-
return { ...u, ...
|
|
1233
|
+
const V = typeof (M == null ? void 0 : M.editor) == "object" ? ($ = M.editor) == null ? void 0 : $.ap : typeof (M == null ? void 0 : M.editor) == "function" ? u == null ? void 0 : u.ap : {};
|
|
1234
|
+
return { ...u, ...V };
|
|
1235
1235
|
}
|
|
1236
1236
|
return u;
|
|
1237
1237
|
}, ue = (a) => {
|
|
@@ -1240,21 +1240,21 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1240
1240
|
return ((u = t.value.form) == null ? void 0 : u.modalState) === "edit" ? ((y = s == null ? void 0 : s.ep) == null ? void 0 : y.type) ?? (s == null ? void 0 : s.type) ?? a.type : ((m = t.value.form) == null ? void 0 : m.modalState) === "add" ? ((b = s == null ? void 0 : s.ap) == null ? void 0 : b.type) ?? (s == null ? void 0 : s.type) ?? a.type : (s == null ? void 0 : s.type) ?? a.type;
|
|
1241
1241
|
};
|
|
1242
1242
|
tt(() => {
|
|
1243
|
-
K(), F != null && F.editForm ? E.value = F.editForm : E.value =
|
|
1244
|
-
}),
|
|
1245
|
-
|
|
1243
|
+
K(), F != null && F.editForm ? E.value = F.editForm : E.value = $e.value;
|
|
1244
|
+
}), At(() => {
|
|
1245
|
+
o.value = null;
|
|
1246
1246
|
});
|
|
1247
1247
|
const K = () => {
|
|
1248
1248
|
x.value = Math.random().toString(36).substring(2);
|
|
1249
|
-
for (const [a, s] of Object.entries(
|
|
1249
|
+
for (const [a, s] of Object.entries(ce.value))
|
|
1250
1250
|
t.value[a].formItem = { ...t.value[a].formItem, ...s.formItem }, t.value[a].formItem.style = { ...t.value[a].formItem.style, ...s.formItem.style };
|
|
1251
|
-
},
|
|
1251
|
+
}, ce = Pe(() => Object.fromEntries(Object.entries(t.value).filter((a) => a[1].type != "hidden").filter((a) => a[1].edit !== !1).filter((a) => !["table", "tableColumns", "query", "queryItems"].includes(a[0])).filter((a) => a[1].editor !== !1).filter((a) => a[1].type !== "control").filter((a) => {
|
|
1252
1252
|
var M, u, y;
|
|
1253
1253
|
const s = typeof a[1].editor == "function" ? a[1].editor(E.value, (M = t.value.form) == null ? void 0 : M.modalState) : a[1].editor;
|
|
1254
1254
|
return t.value.form.modalState === "edit" ? ((u = s == null ? void 0 : s.ep) == null ? void 0 : u.editor) !== !1 : t.value.form.modalState === "add" ? ((y = s == null ? void 0 : s.ap) == null ? void 0 : y.editor) !== !1 : !0;
|
|
1255
|
-
}).map((a) => [a[0], a[1]]))),
|
|
1255
|
+
}).map((a) => [a[0], a[1]]))), $e = Pe(() => Object.fromEntries(Object.entries(t.value).filter((a) => a[1].type != "hidden").filter((a) => a[1].type != "control").map((a) => [a[0], a[1].value]))), ge = Pe(() => {
|
|
1256
1256
|
const a = /* @__PURE__ */ new Map();
|
|
1257
|
-
return Object.entries(
|
|
1257
|
+
return Object.entries(ce.value).forEach(([s, M]) => {
|
|
1258
1258
|
if (M.groupName) {
|
|
1259
1259
|
const u = M.groupName;
|
|
1260
1260
|
a.has(u) || a.set(u, {
|
|
@@ -1271,7 +1271,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1271
1271
|
label: t.value.form.submit.label,
|
|
1272
1272
|
click: t.value.form.submit.click,
|
|
1273
1273
|
hidden: t.value.form.submit.hidden,
|
|
1274
|
-
info:
|
|
1274
|
+
info: Me(t.value.form.submit, (a) => !["click"].includes(a)),
|
|
1275
1275
|
sort: t.value.form.submit.sort ?? 1,
|
|
1276
1276
|
// 使用空值合并运算符
|
|
1277
1277
|
originalOrder: 0
|
|
@@ -1281,7 +1281,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1281
1281
|
name: "f-reset",
|
|
1282
1282
|
label: t.value.form.reset.label,
|
|
1283
1283
|
click: t.value.form.reset.click,
|
|
1284
|
-
info:
|
|
1284
|
+
info: Me(t.value.form.reset, (a) => !["click"].includes(a)),
|
|
1285
1285
|
hidden: t.value.form.reset.hidden,
|
|
1286
1286
|
sort: t.value.form.reset.sort ?? 2,
|
|
1287
1287
|
// 使用空值合并运算符
|
|
@@ -1291,24 +1291,24 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1291
1291
|
], ne = Pe(() => ye.filter((a) => !a.hidden).sort((a, s) => a.sort - s.sort || a.originalOrder - s.originalOrder));
|
|
1292
1292
|
return (a, s) => {
|
|
1293
1293
|
const M = B("el-form-item"), u = B("el-col"), y = B("el-tab-pane"), m = B("el-tabs"), b = B("el-button"), i = B("el-form");
|
|
1294
|
-
return n(),
|
|
1294
|
+
return n(), D(i, S({
|
|
1295
1295
|
ref_key: "gform",
|
|
1296
|
-
ref:
|
|
1296
|
+
ref: o,
|
|
1297
1297
|
model: E.value,
|
|
1298
1298
|
style: { width: "98%", padding: 0, margin: 0, "box-sizing": "border-box" }
|
|
1299
|
-
}, I(
|
|
1299
|
+
}, I(Me)(t.value.form, ($) => !["footer", "submit", "reset", "slots", "type", "sort"].includes($)), { class: "g-form-container" }), {
|
|
1300
1300
|
default: g(() => [
|
|
1301
|
-
|
|
1302
|
-
var $,
|
|
1301
|
+
ge.value.length > 0 ? h(a.$slots, "default", { key: 0 }, () => {
|
|
1302
|
+
var $, V, N;
|
|
1303
1303
|
return [
|
|
1304
1304
|
Q(m, S({
|
|
1305
1305
|
class: "demo-tabs",
|
|
1306
|
-
modelValue:
|
|
1307
|
-
"onUpdate:modelValue": s[0] || (s[0] = (T) =>
|
|
1306
|
+
modelValue: ge.value[0].groupName,
|
|
1307
|
+
"onUpdate:modelValue": s[0] || (s[0] = (T) => ge.value[0].groupName = T),
|
|
1308
1308
|
style: { width: "100%" }
|
|
1309
1309
|
}, t.value.form.tabs), {
|
|
1310
1310
|
default: g(() => [
|
|
1311
|
-
(n(!0), q(W, null, U(
|
|
1311
|
+
(n(!0), q(W, null, U(ge.value, (T) => (n(), D(y, S({
|
|
1312
1312
|
key: T.groupName,
|
|
1313
1313
|
label: T.groupName,
|
|
1314
1314
|
name: T.groupName,
|
|
@@ -1316,29 +1316,29 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1316
1316
|
ref_for: !0
|
|
1317
1317
|
}, T.tabPane), {
|
|
1318
1318
|
default: g(() => [
|
|
1319
|
-
(n(!0), q(W, null, U(T.items, (O, de) => (n(),
|
|
1319
|
+
(n(!0), q(W, null, U(T.items, (O, de) => (n(), D(u, S({ ref_for: !0 }, { ...t.value.form.cols, ...O == null ? void 0 : O.item.col }, {
|
|
1320
1320
|
key: O.key,
|
|
1321
1321
|
style: { width: "100%" }
|
|
1322
1322
|
}), {
|
|
1323
1323
|
default: g(() => {
|
|
1324
|
-
var te,
|
|
1324
|
+
var te, _e;
|
|
1325
1325
|
return [
|
|
1326
1326
|
Q(M, S({
|
|
1327
1327
|
label: O == null ? void 0 : O.item.label,
|
|
1328
1328
|
prop: O.key,
|
|
1329
1329
|
rules: A(O == null ? void 0 : O.item),
|
|
1330
1330
|
ref_for: !0
|
|
1331
|
-
}, { ...(te = t.value) == null ? void 0 : te.formItems, ...(
|
|
1331
|
+
}, { ...(te = t.value) == null ? void 0 : te.formItems, ...(_e = O == null ? void 0 : O.item) == null ? void 0 : _e.formItem }, { style: { width: "100%" } }), {
|
|
1332
1332
|
default: g(() => [
|
|
1333
1333
|
h(a.$slots, "f-" + O.key, {
|
|
1334
1334
|
item: O == null ? void 0 : O.item,
|
|
1335
1335
|
formInfo: E.value,
|
|
1336
1336
|
model: t.value
|
|
1337
1337
|
}, () => [
|
|
1338
|
-
(n(),
|
|
1338
|
+
(n(), D(ut, {
|
|
1339
1339
|
modelValue: E.value[O.key],
|
|
1340
|
-
"onUpdate:modelValue": (
|
|
1341
|
-
item:
|
|
1340
|
+
"onUpdate:modelValue": (Ce) => E.value[O.key] = Ce,
|
|
1341
|
+
item: oe(O),
|
|
1342
1342
|
ctrlKey: O.key,
|
|
1343
1343
|
ctrlType: ue(O == null ? void 0 : O.item),
|
|
1344
1344
|
model: t.value,
|
|
@@ -1347,7 +1347,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1347
1347
|
t: "f",
|
|
1348
1348
|
formInfo: E.value
|
|
1349
1349
|
}, me({ _: 2 }, [
|
|
1350
|
-
U(a.$slots, (
|
|
1350
|
+
U(a.$slots, (Ce, Fe) => ({
|
|
1351
1351
|
name: Fe,
|
|
1352
1352
|
fn: g((Te) => [
|
|
1353
1353
|
h(a.$slots, Fe, {
|
|
@@ -1372,7 +1372,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1372
1372
|
]),
|
|
1373
1373
|
_: 3
|
|
1374
1374
|
}, 16, ["modelValue"]),
|
|
1375
|
-
(N = (
|
|
1375
|
+
(N = (V = ($ = t.value) == null ? void 0 : $.form) == null ? void 0 : V.footer) != null && N.hidden ? ve("", !0) : h(a.$slots, "f-footer", { key: 0 }, () => [
|
|
1376
1376
|
X("div", {
|
|
1377
1377
|
style: Ye(t.value.form.footer.style)
|
|
1378
1378
|
}, [
|
|
@@ -1381,10 +1381,10 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1381
1381
|
h(a.$slots, T.name + "-left"),
|
|
1382
1382
|
h(a.$slots, T.name, {}, () => [
|
|
1383
1383
|
Q(b, S({ ref_for: !0 }, T.info, {
|
|
1384
|
-
onClick:
|
|
1384
|
+
onClick: $t((O) => T.click(E.value, t.value), ["stop"])
|
|
1385
1385
|
}), {
|
|
1386
1386
|
default: g(() => [
|
|
1387
|
-
|
|
1387
|
+
Ve(he(T == null ? void 0 : T.label), 1)
|
|
1388
1388
|
]),
|
|
1389
1389
|
_: 2
|
|
1390
1390
|
}, 1040, ["onClick"])
|
|
@@ -1396,9 +1396,9 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1396
1396
|
])
|
|
1397
1397
|
];
|
|
1398
1398
|
}) : h(a.$slots, "default", { key: 1 }, () => {
|
|
1399
|
-
var $,
|
|
1399
|
+
var $, V, N;
|
|
1400
1400
|
return [
|
|
1401
|
-
(n(!0), q(W, null, U(
|
|
1401
|
+
(n(!0), q(W, null, U(ce.value, (T, O) => (n(), D(u, S({ ref_for: !0 }, { ...t.value.form.cols, ...T.col }, {
|
|
1402
1402
|
key: O,
|
|
1403
1403
|
style: { width: "100%" }
|
|
1404
1404
|
}), {
|
|
@@ -1417,7 +1417,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1417
1417
|
item: T,
|
|
1418
1418
|
model: t.value
|
|
1419
1419
|
}, () => [
|
|
1420
|
-
|
|
1420
|
+
Ve(he(T.label), 1)
|
|
1421
1421
|
])
|
|
1422
1422
|
]),
|
|
1423
1423
|
default: g(() => [
|
|
@@ -1426,10 +1426,10 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1426
1426
|
formInfo: E.value,
|
|
1427
1427
|
model: t.value
|
|
1428
1428
|
}, () => [
|
|
1429
|
-
(n(),
|
|
1429
|
+
(n(), D(ut, {
|
|
1430
1430
|
modelValue: E.value[O],
|
|
1431
1431
|
"onUpdate:modelValue": (te) => E.value[O] = te,
|
|
1432
|
-
item:
|
|
1432
|
+
item: oe(T, !0),
|
|
1433
1433
|
ctrlKey: O,
|
|
1434
1434
|
ctrlType: ue(T),
|
|
1435
1435
|
key: `${O}-${x.value}`,
|
|
@@ -1438,11 +1438,11 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1438
1438
|
t: "f",
|
|
1439
1439
|
formInfo: E.value
|
|
1440
1440
|
}, me({ _: 2 }, [
|
|
1441
|
-
U(a.$slots, (te,
|
|
1442
|
-
name:
|
|
1443
|
-
fn: g((
|
|
1444
|
-
h(a.$slots,
|
|
1445
|
-
data:
|
|
1441
|
+
U(a.$slots, (te, _e) => ({
|
|
1442
|
+
name: _e,
|
|
1443
|
+
fn: g((Ce) => [
|
|
1444
|
+
h(a.$slots, _e, {
|
|
1445
|
+
data: Ce,
|
|
1446
1446
|
item: T,
|
|
1447
1447
|
model: t.value
|
|
1448
1448
|
})
|
|
@@ -1457,7 +1457,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1457
1457
|
}),
|
|
1458
1458
|
_: 2
|
|
1459
1459
|
}, 1040))), 128)),
|
|
1460
|
-
(N = (
|
|
1460
|
+
(N = (V = ($ = t.value) == null ? void 0 : $.form) == null ? void 0 : V.footer) != null && N.hidden ? ve("", !0) : h(a.$slots, "f-footer", { key: 0 }, () => [
|
|
1461
1461
|
X("div", {
|
|
1462
1462
|
style: Ye(t.value.form.footer.style)
|
|
1463
1463
|
}, [
|
|
@@ -1466,10 +1466,10 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1466
1466
|
h(a.$slots, T.name + "-left"),
|
|
1467
1467
|
h(a.$slots, T.name, {}, () => [
|
|
1468
1468
|
Q(b, S({ ref_for: !0 }, T.info, {
|
|
1469
|
-
onClick:
|
|
1469
|
+
onClick: $t((O) => T.click(E.value, t.value), ["stop"])
|
|
1470
1470
|
}), {
|
|
1471
1471
|
default: g(() => [
|
|
1472
|
-
|
|
1472
|
+
Ve(he(T == null ? void 0 : T.label), 1)
|
|
1473
1473
|
]),
|
|
1474
1474
|
_: 2
|
|
1475
1475
|
}, 1040, ["onClick"])
|
|
@@ -1486,7 +1486,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1486
1486
|
}, 16, ["model"]);
|
|
1487
1487
|
};
|
|
1488
1488
|
}
|
|
1489
|
-
}),
|
|
1489
|
+
}), Et = {
|
|
1490
1490
|
__name: "g-query-item",
|
|
1491
1491
|
props: /* @__PURE__ */ je(["more"], {
|
|
1492
1492
|
modelValue: { required: !0 },
|
|
@@ -1496,7 +1496,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1496
1496
|
}),
|
|
1497
1497
|
emits: ["update:modelValue", "update:info"],
|
|
1498
1498
|
setup(p) {
|
|
1499
|
-
const c = Le(p, "modelValue"), t = p, e = Le(p, "info"),
|
|
1499
|
+
const c = Le(p, "modelValue"), t = p, e = Le(p, "info"), o = (x) => Pe(() => Object.fromEntries(Object.entries(c.value).filter((F) => {
|
|
1500
1500
|
var _;
|
|
1501
1501
|
return typeof F[1].search == "function" ? F[1].search && ((_ = F[1].search(e.value, c.value.table)) == null ? void 0 : _.more) === x : F[1].search && F[1].search.more === x;
|
|
1502
1502
|
}).map((F) => [F[0], F[1]]))).value, f = (x) => typeof x.search == "function" ? x.search(e.value, c.value.table) : x.search || {}, E = (x) => {
|
|
@@ -1505,7 +1505,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1505
1505
|
};
|
|
1506
1506
|
return (x, F) => {
|
|
1507
1507
|
const _ = B("el-form-item");
|
|
1508
|
-
return n(!0), q(W, null, U(
|
|
1508
|
+
return n(!0), q(W, null, U(o(t.more), (k, R) => h(x.$slots, `q-${R}`, {
|
|
1509
1509
|
key: R,
|
|
1510
1510
|
item: k,
|
|
1511
1511
|
queryModel: e.value,
|
|
@@ -1549,10 +1549,10 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1549
1549
|
])), 128);
|
|
1550
1550
|
};
|
|
1551
1551
|
}
|
|
1552
|
-
},
|
|
1552
|
+
}, sl = {
|
|
1553
1553
|
key: 0,
|
|
1554
1554
|
class: "outer"
|
|
1555
|
-
},
|
|
1555
|
+
}, il = { class: "inner" }, dl = {
|
|
1556
1556
|
__name: "g-query",
|
|
1557
1557
|
props: {
|
|
1558
1558
|
modelValue: { required: !0 },
|
|
@@ -1562,7 +1562,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1562
1562
|
},
|
|
1563
1563
|
emits: /* @__PURE__ */ je(["query", "reset"], ["update:modelValue", "update:info"]),
|
|
1564
1564
|
setup(p, { emit: c }) {
|
|
1565
|
-
const t = Le(p, "modelValue"), e = c,
|
|
1565
|
+
const t = Le(p, "modelValue"), e = c, o = vt("options"), f = le(!1), E = Le(p, "info"), x = {
|
|
1566
1566
|
hidden: !1,
|
|
1567
1567
|
type: "hidden",
|
|
1568
1568
|
labelWidth: 100,
|
|
@@ -1610,7 +1610,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1610
1610
|
}
|
|
1611
1611
|
}
|
|
1612
1612
|
};
|
|
1613
|
-
t.value.query = Se(x,
|
|
1613
|
+
t.value.query = Se(x, o == null ? void 0 : o.query, t.value.query);
|
|
1614
1614
|
const F = {
|
|
1615
1615
|
2: {
|
|
1616
1616
|
title: "更多查询",
|
|
@@ -1639,25 +1639,25 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1639
1639
|
width: "280px"
|
|
1640
1640
|
}
|
|
1641
1641
|
};
|
|
1642
|
-
t.value.queryItems = Se(_,
|
|
1642
|
+
t.value.queryItems = Se(_, o == null ? void 0 : o.queryItems, t.value.queryItems);
|
|
1643
1643
|
const k = (Y, A) => {
|
|
1644
|
-
const
|
|
1644
|
+
const oe = Object.keys(Y.slots).filter((ue) => ue !== "default").reduce((ue, K) => (ue[K] = (ce) => Y.slots[K]({
|
|
1645
1645
|
model: t.value
|
|
1646
1646
|
// 传递当前模型数据
|
|
1647
1647
|
}), ue), {});
|
|
1648
|
-
return Ie(
|
|
1648
|
+
return Ie(Et, {
|
|
1649
1649
|
modelValue: t.value,
|
|
1650
1650
|
"onUpdate:modelValue": (ue) => t.value = ue,
|
|
1651
1651
|
info: E.value,
|
|
1652
1652
|
"onUpdate:info": (ue) => E.value = ue,
|
|
1653
1653
|
more: A
|
|
1654
|
-
},
|
|
1655
|
-
}, R =
|
|
1656
|
-
var
|
|
1654
|
+
}, oe);
|
|
1655
|
+
}, R = Ct(), ae = () => {
|
|
1656
|
+
var oe, ue, K, ce, $e, ge, ye, ne, se;
|
|
1657
1657
|
const Y = [
|
|
1658
1658
|
{
|
|
1659
1659
|
key: "query",
|
|
1660
|
-
hidden: (K = (ue = (
|
|
1660
|
+
hidden: (K = (ue = (oe = t.value) == null ? void 0 : oe.query) == null ? void 0 : ue.query) == null ? void 0 : K.hidden,
|
|
1661
1661
|
component: De,
|
|
1662
1662
|
props: {
|
|
1663
1663
|
...t.value.query.query,
|
|
@@ -1668,7 +1668,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1668
1668
|
},
|
|
1669
1669
|
{
|
|
1670
1670
|
key: "reset",
|
|
1671
|
-
hidden: (
|
|
1671
|
+
hidden: (ge = ($e = (ce = t.value) == null ? void 0 : ce.query) == null ? void 0 : $e.reset) == null ? void 0 : ge.hidden,
|
|
1672
1672
|
component: De,
|
|
1673
1673
|
props: {
|
|
1674
1674
|
...t.value.query.reset,
|
|
@@ -1687,55 +1687,55 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1687
1687
|
},
|
|
1688
1688
|
label: t.value.query.more.label,
|
|
1689
1689
|
sort: t.value.query.more.sort || 0,
|
|
1690
|
-
content: t.value.query.more.mode === 3 ? () => Ie(
|
|
1690
|
+
content: t.value.query.more.mode === 3 ? () => Ie(rt, {
|
|
1691
1691
|
class: "query-form",
|
|
1692
|
-
...
|
|
1692
|
+
...Me(t.value.query, (ee) => !["query", "more", "reset"].includes(ee))
|
|
1693
1693
|
}, () => k({ slots: R }, !0)) : null
|
|
1694
1694
|
}
|
|
1695
1695
|
];
|
|
1696
|
-
return Y.sort((ee,
|
|
1696
|
+
return Y.sort((ee, be) => ee.sort - be.sort), Y.filter((ee) => !ee.hidden).map((ee) => ee.key === "more" && ee.component === nt ? Ie(nt, ee.props, {
|
|
1697
1697
|
reference: () => Ie(De, t.value.query.more, () => ee.label),
|
|
1698
1698
|
default: ee.content
|
|
1699
1699
|
}) : (ee.props.slot = "query-" + ee.key, ee.label ? Ie(ee.component, ee.props, () => ee.label) : Ie(ee.component, ee.props)));
|
|
1700
1700
|
};
|
|
1701
1701
|
return (Y, A) => {
|
|
1702
|
-
var K,
|
|
1703
|
-
const
|
|
1702
|
+
var K, ce, $e, ge, ye, ne, se, ee, be, ie, a, s, M, u, y, m, b;
|
|
1703
|
+
const oe = B("el-form-item"), ue = B("el-drawer");
|
|
1704
1704
|
return n(), q(W, null, [
|
|
1705
1705
|
X("div", {
|
|
1706
1706
|
class: "g-query-container",
|
|
1707
|
-
style: Ye((
|
|
1707
|
+
style: Ye((ce = (K = t.value.query) == null ? void 0 : K.container) == null ? void 0 : ce.style)
|
|
1708
1708
|
}, [
|
|
1709
|
-
Q(I(
|
|
1709
|
+
Q(I(rt), st(wt(I(Me)(t.value.query, (i) => !["query", "more", "reset", "btns"].includes(i)))), {
|
|
1710
1710
|
default: g(() => {
|
|
1711
1711
|
var i, $;
|
|
1712
1712
|
return [
|
|
1713
|
-
(n(),
|
|
1714
|
-
(($ = (i = t.value.query) == null ? void 0 : i.container) == null ? void 0 : $.inline) === !0 ? (n(),
|
|
1713
|
+
(n(), D(Re(k({ slots: Y.$slots }, void 0)))),
|
|
1714
|
+
(($ = (i = t.value.query) == null ? void 0 : i.container) == null ? void 0 : $.inline) === !0 ? (n(), D(oe, { key: 0 }, {
|
|
1715
1715
|
default: g(() => {
|
|
1716
|
-
var
|
|
1716
|
+
var V, N, T, O, de;
|
|
1717
1717
|
return [
|
|
1718
1718
|
X("div", {
|
|
1719
|
-
style: Ye((N = (
|
|
1719
|
+
style: Ye((N = (V = t.value.query) == null ? void 0 : V.btns) == null ? void 0 : N.style)
|
|
1720
1720
|
}, [
|
|
1721
|
-
t.value.query.group ? (n(),
|
|
1721
|
+
t.value.query.group ? (n(), D(I(ot), { key: 0 }, {
|
|
1722
1722
|
default: g(() => [
|
|
1723
1723
|
(n(!0), q(W, null, U(ae(), (te) => h(Y.$slots, te.props.slot, {}, () => [
|
|
1724
|
-
(n(),
|
|
1724
|
+
(n(), D(Re(te)))
|
|
1725
1725
|
], !0)), 256)),
|
|
1726
1726
|
h(Y.$slots, "q-btns", {}, void 0, !0)
|
|
1727
1727
|
]),
|
|
1728
1728
|
_: 3
|
|
1729
1729
|
})) : (n(), q(W, { key: 1 }, [
|
|
1730
|
-
(de = (O = (T = t.value) == null ? void 0 : T.query) == null ? void 0 : O.btns) != null && de.group ? (n(),
|
|
1730
|
+
(de = (O = (T = t.value) == null ? void 0 : T.query) == null ? void 0 : O.btns) != null && de.group ? (n(), D(I(ot), { key: 0 }, {
|
|
1731
1731
|
default: g(() => [
|
|
1732
1732
|
(n(!0), q(W, null, U(ae(), (te) => h(Y.$slots, te.props.slot, {}, () => [
|
|
1733
|
-
(n(),
|
|
1733
|
+
(n(), D(Re(te)))
|
|
1734
1734
|
], !0)), 256))
|
|
1735
1735
|
]),
|
|
1736
1736
|
_: 3
|
|
1737
1737
|
})) : (n(!0), q(W, { key: 1 }, U(ae(), (te) => h(Y.$slots, te.props.slot, {}, () => [
|
|
1738
|
-
(n(),
|
|
1738
|
+
(n(), D(Re(te)))
|
|
1739
1739
|
], !0)), 256)),
|
|
1740
1740
|
h(Y.$slots, "q-btns", {}, void 0, !0)
|
|
1741
1741
|
], 64))
|
|
@@ -1748,34 +1748,34 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1748
1748
|
}),
|
|
1749
1749
|
_: 3
|
|
1750
1750
|
}, 16),
|
|
1751
|
-
((ye = (
|
|
1751
|
+
((ye = (ge = ($e = t.value) == null ? void 0 : $e.query) == null ? void 0 : ge.container) == null ? void 0 : ye.inline) === !1 ? (n(), q("div", {
|
|
1752
1752
|
key: 0,
|
|
1753
1753
|
style: Ye((se = (ne = t.value.query) == null ? void 0 : ne.btns) == null ? void 0 : se.style)
|
|
1754
1754
|
}, [
|
|
1755
|
-
t.value.query.group ? (n(),
|
|
1755
|
+
t.value.query.group ? (n(), D(I(ot), { key: 0 }, {
|
|
1756
1756
|
default: g(() => [
|
|
1757
1757
|
(n(!0), q(W, null, U(ae(), (i) => h(Y.$slots, i.props.slot, {}, () => [
|
|
1758
|
-
(n(),
|
|
1758
|
+
(n(), D(Re(i)))
|
|
1759
1759
|
], !0)), 256)),
|
|
1760
1760
|
h(Y.$slots, "q-btns", {}, void 0, !0)
|
|
1761
1761
|
]),
|
|
1762
1762
|
_: 3
|
|
1763
1763
|
})) : (n(), q(W, { key: 1 }, [
|
|
1764
|
-
(
|
|
1764
|
+
(be = (ee = t.value.query) == null ? void 0 : ee.btns) != null && be.group ? (n(), D(I(ot), { key: 0 }, {
|
|
1765
1765
|
default: g(() => [
|
|
1766
1766
|
(n(!0), q(W, null, U(ae(), (i) => h(Y.$slots, i.props.slot, {}, () => [
|
|
1767
|
-
(n(),
|
|
1767
|
+
(n(), D(Re(i)))
|
|
1768
1768
|
], !0)), 256))
|
|
1769
1769
|
]),
|
|
1770
1770
|
_: 3
|
|
1771
1771
|
})) : (n(!0), q(W, { key: 1 }, U(ae(), (i) => h(Y.$slots, i.props.slot, {}, () => [
|
|
1772
|
-
(n(),
|
|
1772
|
+
(n(), D(Re(i)))
|
|
1773
1773
|
], !0)), 256)),
|
|
1774
1774
|
h(Y.$slots, "q-btns", {}, void 0, !0)
|
|
1775
1775
|
], 64))
|
|
1776
1776
|
], 4)) : ve("", !0)
|
|
1777
1777
|
], 4),
|
|
1778
|
-
f.value && !((s = (a = (ie = t.value) == null ? void 0 : ie.query) == null ? void 0 : a.more) != null && s.hidden) && t.value.query.more.mode == 2 ? (n(),
|
|
1778
|
+
f.value && !((s = (a = (ie = t.value) == null ? void 0 : ie.query) == null ? void 0 : a.more) != null && s.hidden) && t.value.query.more.mode == 2 ? (n(), D(ue, S({
|
|
1779
1779
|
key: 0,
|
|
1780
1780
|
modelValue: f.value,
|
|
1781
1781
|
"onUpdate:modelValue": A[4] || (A[4] = (i) => f.value = i),
|
|
@@ -1783,16 +1783,16 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1783
1783
|
"show-close": !1
|
|
1784
1784
|
}, t.value.query.more.dialog), me({
|
|
1785
1785
|
default: g(() => [
|
|
1786
|
-
Q(I(
|
|
1786
|
+
Q(I(rt), S(I(Me)(t.value.query, (i) => !["query", "more", "reset"].includes(i)), { style: { width: "98%" } }), {
|
|
1787
1787
|
default: g(() => [
|
|
1788
|
-
Q(
|
|
1788
|
+
Q(Et, {
|
|
1789
1789
|
modelValue: t.value,
|
|
1790
1790
|
"onUpdate:modelValue": A[0] || (A[0] = (i) => t.value = i),
|
|
1791
1791
|
info: E.value,
|
|
1792
1792
|
"onUpdate:info": A[1] || (A[1] = (i) => E.value = i),
|
|
1793
1793
|
more: !0
|
|
1794
1794
|
}, me({ _: 2 }, [
|
|
1795
|
-
U(Y.$slots, (i, $,
|
|
1795
|
+
U(Y.$slots, (i, $, V) => ({
|
|
1796
1796
|
name: $,
|
|
1797
1797
|
fn: g((N) => [
|
|
1798
1798
|
h(Y.$slots, $, { model: t.value }, void 0, !0)
|
|
@@ -1808,12 +1808,12 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1808
1808
|
(b = (m = (y = (u = (M = t.value) == null ? void 0 : M.query) == null ? void 0 : u.more) == null ? void 0 : y.dialog) == null ? void 0 : m.footer) != null && b.hidden ? void 0 : {
|
|
1809
1809
|
name: "footer",
|
|
1810
1810
|
fn: g(() => [
|
|
1811
|
-
X("div", st(
|
|
1811
|
+
X("div", st(wt(t.value.query.more.dialog.footer)), [
|
|
1812
1812
|
Q(I(De), S(t.value.query.query, {
|
|
1813
1813
|
onClick: A[2] || (A[2] = (i) => t.value.query.query.click())
|
|
1814
1814
|
}), {
|
|
1815
1815
|
default: g(() => [
|
|
1816
|
-
|
|
1816
|
+
Ve(he(t.value.query.query.label), 1)
|
|
1817
1817
|
]),
|
|
1818
1818
|
_: 1
|
|
1819
1819
|
}, 16),
|
|
@@ -1821,7 +1821,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1821
1821
|
onClick: A[3] || (A[3] = (i) => t.value.query.reset.click())
|
|
1822
1822
|
}), {
|
|
1823
1823
|
default: g(() => [
|
|
1824
|
-
|
|
1824
|
+
Ve(he(t.value.query.reset.label), 1)
|
|
1825
1825
|
]),
|
|
1826
1826
|
_: 1
|
|
1827
1827
|
}, 16)
|
|
@@ -1830,23 +1830,23 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1830
1830
|
key: "0"
|
|
1831
1831
|
}
|
|
1832
1832
|
]), 1040, ["modelValue"])) : ve("", !0),
|
|
1833
|
-
Q(
|
|
1833
|
+
Q(Bt, {
|
|
1834
1834
|
duration: 300,
|
|
1835
1835
|
name: "nested",
|
|
1836
1836
|
style: { padding: "10px" }
|
|
1837
1837
|
}, {
|
|
1838
1838
|
default: g(() => {
|
|
1839
|
-
var i, $,
|
|
1839
|
+
var i, $, V;
|
|
1840
1840
|
return [
|
|
1841
|
-
f.value && !((
|
|
1842
|
-
X("div",
|
|
1843
|
-
t.value.query.more.mode == 1 ?
|
|
1841
|
+
f.value && !((V = ($ = (i = t.value) == null ? void 0 : i.query) == null ? void 0 : $.more) != null && V.hidden) && t.value.query.more.mode == 1 ? (n(), q("div", sl, [
|
|
1842
|
+
X("div", il, [
|
|
1843
|
+
t.value.query.more.mode == 1 ? It((n(), D(I(rt), st(S({ key: 0 }, I(Me)(t.value.query, (N) => !["query", "more", "reset"].includes(N)))), {
|
|
1844
1844
|
default: g(() => [
|
|
1845
|
-
(n(),
|
|
1845
|
+
(n(), D(Re(k({ slots: Y.$slots }, !0))))
|
|
1846
1846
|
]),
|
|
1847
1847
|
_: 1
|
|
1848
1848
|
}, 16)), [
|
|
1849
|
-
[
|
|
1849
|
+
[Ut, f.value]
|
|
1850
1850
|
]) : ve("", !0)
|
|
1851
1851
|
])
|
|
1852
1852
|
])) : ve("", !0)
|
|
@@ -1857,10 +1857,10 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1857
1857
|
], 64);
|
|
1858
1858
|
};
|
|
1859
1859
|
}
|
|
1860
|
-
},
|
|
1860
|
+
}, fl = /* @__PURE__ */ He(dl, [["__scopeId", "data-v-80ccf765"]]), cl = { style: { padding: "0", margin: "0", "box-sizing": "border-box" } }, ml = { style: { padding: "10px", "box-sizing": "border-box" } }, vl = { style: { margin: "10px" } }, pl = {
|
|
1861
1861
|
style: { display: "flex", "flex-wrap": "wrap" },
|
|
1862
1862
|
id: "excelSortEl"
|
|
1863
|
-
},
|
|
1863
|
+
}, hl = ["textContent"], yl = { style: { width: "100%", display: "flex", padding: "10px", "box-sizing": "border-box", "justify-content": "center", "border-top": "1px solid #dcdfe6" } }, gl = {
|
|
1864
1864
|
__name: "check-excel-item",
|
|
1865
1865
|
props: {
|
|
1866
1866
|
items: Array,
|
|
@@ -1868,16 +1868,16 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1868
1868
|
},
|
|
1869
1869
|
emits: ["excel"],
|
|
1870
1870
|
setup(p, { emit: c }) {
|
|
1871
|
-
const t = p, e = c,
|
|
1872
|
-
|
|
1871
|
+
const t = p, e = c, o = le(t.items), f = () => {
|
|
1872
|
+
o.value.forEach((F) => {
|
|
1873
1873
|
F.value = !0;
|
|
1874
1874
|
});
|
|
1875
1875
|
}, E = () => {
|
|
1876
|
-
|
|
1876
|
+
o.value.forEach((F) => {
|
|
1877
1877
|
F.value = !1;
|
|
1878
1878
|
});
|
|
1879
1879
|
}, x = () => {
|
|
1880
|
-
e("excel",
|
|
1880
|
+
e("excel", o.value, (F, _ = "excel.xls") => {
|
|
1881
1881
|
if (!F) {
|
|
1882
1882
|
console.error("下载链接无效");
|
|
1883
1883
|
return;
|
|
@@ -1891,21 +1891,21 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1891
1891
|
});
|
|
1892
1892
|
};
|
|
1893
1893
|
return tt(() => {
|
|
1894
|
-
const F = new
|
|
1894
|
+
const F = new Vt(document.getElementById("excelSortEl"), {
|
|
1895
1895
|
animation: 150,
|
|
1896
1896
|
onEnd: () => {
|
|
1897
1897
|
let k = F.toArray();
|
|
1898
1898
|
console.log(k);
|
|
1899
1899
|
}
|
|
1900
1900
|
}), _ = F;
|
|
1901
|
-
|
|
1901
|
+
Yt(() => {
|
|
1902
1902
|
_ && _.destroy();
|
|
1903
1903
|
});
|
|
1904
1904
|
}), (F, _) => {
|
|
1905
1905
|
const k = B("el-divider"), R = B("el-alert"), ae = B("el-checkbox"), Y = B("el-button");
|
|
1906
|
-
return n(), q("div",
|
|
1907
|
-
X("div",
|
|
1908
|
-
X("div",
|
|
1906
|
+
return n(), q("div", cl, [
|
|
1907
|
+
X("div", ml, [
|
|
1908
|
+
X("div", vl, [
|
|
1909
1909
|
X("a", {
|
|
1910
1910
|
onClick: f,
|
|
1911
1911
|
style: { cursor: "pointer" }
|
|
@@ -1924,13 +1924,13 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1924
1924
|
style: { "margin-bottom": "10px" }
|
|
1925
1925
|
}),
|
|
1926
1926
|
_[0] || (_[0] = X("div", { style: { margin: "1px 0" } }, null, -1)),
|
|
1927
|
-
X("div",
|
|
1928
|
-
(n(!0), q(W, null, U(
|
|
1927
|
+
X("div", pl, [
|
|
1928
|
+
(n(!0), q(W, null, U(o.value, (A) => (n(), D(ae, {
|
|
1929
1929
|
class: "check-box-hover",
|
|
1930
1930
|
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" },
|
|
1931
1931
|
"data-id": A.key,
|
|
1932
1932
|
modelValue: A.value,
|
|
1933
|
-
"onUpdate:modelValue": (
|
|
1933
|
+
"onUpdate:modelValue": (oe) => A.value = oe,
|
|
1934
1934
|
key: A.key,
|
|
1935
1935
|
title: A.label
|
|
1936
1936
|
}, {
|
|
@@ -1938,20 +1938,20 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1938
1938
|
X("span", {
|
|
1939
1939
|
textContent: he(A.label),
|
|
1940
1940
|
style: { display: "block", "text-overflow": "ellipsis", width: "95px", overflow: "hidden" }
|
|
1941
|
-
}, null, 8,
|
|
1941
|
+
}, null, 8, hl)
|
|
1942
1942
|
]),
|
|
1943
1943
|
_: 2
|
|
1944
1944
|
}, 1032, ["data-id", "modelValue", "onUpdate:modelValue", "title"]))), 128))
|
|
1945
1945
|
])
|
|
1946
1946
|
]),
|
|
1947
|
-
X("div",
|
|
1947
|
+
X("div", yl, [
|
|
1948
1948
|
Q(Y, {
|
|
1949
1949
|
type: "primary",
|
|
1950
1950
|
onClick: x,
|
|
1951
|
-
disabled:
|
|
1951
|
+
disabled: o.value.filter((A) => A.value).length < 1
|
|
1952
1952
|
}, {
|
|
1953
1953
|
default: g(() => [
|
|
1954
|
-
|
|
1954
|
+
Ve(he(t.commitText), 1)
|
|
1955
1955
|
]),
|
|
1956
1956
|
_: 1
|
|
1957
1957
|
}, 8, ["disabled"])
|
|
@@ -1959,7 +1959,7 @@ const it = /* @__PURE__ */ Xt(Zt), He = (p, c) => {
|
|
|
1959
1959
|
]);
|
|
1960
1960
|
};
|
|
1961
1961
|
}
|
|
1962
|
-
},
|
|
1962
|
+
}, bl = /* @__PURE__ */ He(gl, [["__scopeId", "data-v-51dfb7ef"]]), Ue = new Gt("gyc");
|
|
1963
1963
|
Ue.version(1).stores({
|
|
1964
1964
|
tableInfo: "++id,[user+page+key],user,page,key,showCol,width,sort",
|
|
1965
1965
|
tableList: "++id,name"
|
|
@@ -1973,10 +1973,10 @@ async function Ke(p, c, t, e = {}) {
|
|
|
1973
1973
|
return await Ue.tableInfo.add({ user: p, page: c, key: t, ...f }), "add success";
|
|
1974
1974
|
}
|
|
1975
1975
|
}
|
|
1976
|
-
async function
|
|
1976
|
+
async function $l(p, c) {
|
|
1977
1977
|
return await Ue.tableInfo.where({ user: p, page: c }).toArray();
|
|
1978
1978
|
}
|
|
1979
|
-
async function
|
|
1979
|
+
async function wl(p, c) {
|
|
1980
1980
|
try {
|
|
1981
1981
|
const t = await Ue.tableInfo.where({ user: p, page: c }).delete();
|
|
1982
1982
|
return console.log("删除了" + t + "条数据"), t;
|
|
@@ -1984,19 +1984,19 @@ async function $l(p, c) {
|
|
|
1984
1984
|
throw console.error("删除表格项设置信息时出错:", t), t;
|
|
1985
1985
|
}
|
|
1986
1986
|
}
|
|
1987
|
-
async function
|
|
1987
|
+
async function El(p) {
|
|
1988
1988
|
return await Ue.tableList.where({ name: p }).first();
|
|
1989
1989
|
}
|
|
1990
|
-
async function
|
|
1990
|
+
async function kl(p) {
|
|
1991
1991
|
return typeof p == "string" && (p = { name: p }), await Ue.tableList.add(p), "add success";
|
|
1992
1992
|
}
|
|
1993
|
-
const
|
|
1993
|
+
const _l = {
|
|
1994
1994
|
style: { margin: "10px" },
|
|
1995
1995
|
class: "allcheck"
|
|
1996
|
-
},
|
|
1996
|
+
}, Cl = {
|
|
1997
1997
|
id: "cols",
|
|
1998
1998
|
style: { display: "flex", "flex-wrap": "wrap", margin: "0 !important", padding: "0 !important" }
|
|
1999
|
-
},
|
|
1999
|
+
}, Dl = ["textContent"], Vl = {
|
|
2000
2000
|
__name: "columns-setting",
|
|
2001
2001
|
props: /* @__PURE__ */ je({
|
|
2002
2002
|
name: {
|
|
@@ -2009,13 +2009,13 @@ const kl = {
|
|
|
2009
2009
|
}),
|
|
2010
2010
|
emits: ["update:modelValue"],
|
|
2011
2011
|
setup(p) {
|
|
2012
|
-
const c = p, t = le([]), e = Le(p, "modelValue"),
|
|
2012
|
+
const c = p, t = le([]), e = Le(p, "modelValue"), o = async (_, k) => {
|
|
2013
2013
|
_ ? e.value[k].showCol = !0 : e.value[k].showCol = !1;
|
|
2014
2014
|
try {
|
|
2015
2015
|
const R = await Ke(e.value.table.user, c.name, k, { showCol: _ });
|
|
2016
2016
|
console.log(R);
|
|
2017
2017
|
} catch (R) {
|
|
2018
|
-
console.error("列显示状态保存信息时出错:", R),
|
|
2018
|
+
console.error("列显示状态保存信息时出错:", R), xe({
|
|
2019
2019
|
type: "error",
|
|
2020
2020
|
message: "列显示状态保存信息失败!"
|
|
2021
2021
|
});
|
|
@@ -2023,7 +2023,7 @@ const kl = {
|
|
|
2023
2023
|
}, f = () => {
|
|
2024
2024
|
const _ = document.getElementById("cols");
|
|
2025
2025
|
if (_) {
|
|
2026
|
-
let k =
|
|
2026
|
+
let k = Vt.create(_, {
|
|
2027
2027
|
animation: 150,
|
|
2028
2028
|
filter: ".filtered",
|
|
2029
2029
|
//
|
|
@@ -2033,10 +2033,10 @@ const kl = {
|
|
|
2033
2033
|
e.value[ae].sort = Y;
|
|
2034
2034
|
let A = e.value[ae].width || "auto";
|
|
2035
2035
|
try {
|
|
2036
|
-
const
|
|
2037
|
-
console.log(
|
|
2038
|
-
} catch (
|
|
2039
|
-
console.error("列排序和宽度保存信息时出错:",
|
|
2036
|
+
const oe = await Ke(e.value.table.user, c.name, ae, { sort: Y, width: A });
|
|
2037
|
+
console.log(oe);
|
|
2038
|
+
} catch (oe) {
|
|
2039
|
+
console.error("列排序和宽度保存信息时出错:", oe), xe({
|
|
2040
2040
|
type: "error",
|
|
2041
2041
|
message: "列排序和宽度保存信息失败!"
|
|
2042
2042
|
});
|
|
@@ -2057,7 +2057,7 @@ const kl = {
|
|
|
2057
2057
|
console.log(k);
|
|
2058
2058
|
}
|
|
2059
2059
|
} catch (_) {
|
|
2060
|
-
console.error("全选列保存信息时出错:", _),
|
|
2060
|
+
console.error("全选列保存信息时出错:", _), xe({
|
|
2061
2061
|
type: "error",
|
|
2062
2062
|
message: "全选列保存信息失败!"
|
|
2063
2063
|
});
|
|
@@ -2075,21 +2075,21 @@ const kl = {
|
|
|
2075
2075
|
console.log(R);
|
|
2076
2076
|
}
|
|
2077
2077
|
} catch (_) {
|
|
2078
|
-
console.error("清除列保存信息时出错:", _),
|
|
2078
|
+
console.error("清除列保存信息时出错:", _), xe({
|
|
2079
2079
|
type: "error",
|
|
2080
2080
|
message: "清除列保存信息失败!"
|
|
2081
2081
|
});
|
|
2082
2082
|
}
|
|
2083
2083
|
}, F = () => {
|
|
2084
|
-
|
|
2084
|
+
_t.confirm("确定要复位吗?", "提示", {
|
|
2085
2085
|
confirmButtonText: "确定",
|
|
2086
2086
|
cancelButtonText: "取消",
|
|
2087
2087
|
type: "warning"
|
|
2088
2088
|
}).then(() => {
|
|
2089
|
-
|
|
2089
|
+
wl(e.value.table.user, c.name).then((_) => {
|
|
2090
2090
|
console.log(_), window.location.reload();
|
|
2091
2091
|
}).catch((_) => {
|
|
2092
|
-
console.error("复位操作出错:", _),
|
|
2092
|
+
console.error("复位操作出错:", _), xe({
|
|
2093
2093
|
type: "info",
|
|
2094
2094
|
message: "复位失败!"
|
|
2095
2095
|
});
|
|
@@ -2108,7 +2108,7 @@ const kl = {
|
|
|
2108
2108
|
}), (_, k) => {
|
|
2109
2109
|
const R = B("el-divider"), ae = B("el-alert"), Y = B("el-checkbox");
|
|
2110
2110
|
return n(), q("div", null, [
|
|
2111
|
-
X("div",
|
|
2111
|
+
X("div", _l, [
|
|
2112
2112
|
X("a", { onClick: E }, "全选"),
|
|
2113
2113
|
Q(R, { direction: "vertical" }),
|
|
2114
2114
|
X("a", { onClick: x }, "全不选"),
|
|
@@ -2123,13 +2123,13 @@ const kl = {
|
|
|
2123
2123
|
style: { "margin-bottom": "10px" }
|
|
2124
2124
|
}),
|
|
2125
2125
|
X("div", null, [
|
|
2126
|
-
X("div",
|
|
2127
|
-
(n(!0), q(W, null, U(t.value, (A) => (n(),
|
|
2126
|
+
X("div", Cl, [
|
|
2127
|
+
(n(!0), q(W, null, U(t.value, (A) => (n(), D(Y, {
|
|
2128
2128
|
modelValue: A.showCol,
|
|
2129
|
-
"onUpdate:modelValue": (
|
|
2129
|
+
"onUpdate:modelValue": (oe) => A.showCol = oe,
|
|
2130
2130
|
"data-id": A.value,
|
|
2131
|
-
class:
|
|
2132
|
-
onChange: (
|
|
2131
|
+
class: Dt(["check-box-hover", A.value == "control" ? "filtered" : ""]),
|
|
2132
|
+
onChange: (oe) => o(oe, A.value),
|
|
2133
2133
|
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" },
|
|
2134
2134
|
value: A.value,
|
|
2135
2135
|
title: A.label,
|
|
@@ -2140,7 +2140,7 @@ const kl = {
|
|
|
2140
2140
|
X("span", {
|
|
2141
2141
|
textContent: he(A.label),
|
|
2142
2142
|
style: { display: "block", "text-overflow": "ellipsis", width: "95px", overflow: "hidden" }
|
|
2143
|
-
}, null, 8,
|
|
2143
|
+
}, null, 8, Dl)
|
|
2144
2144
|
]),
|
|
2145
2145
|
_: 2
|
|
2146
2146
|
}, 1032, ["modelValue", "onUpdate:modelValue", "data-id", "class", "onChange", "value", "title", "disabled"]))), 128))
|
|
@@ -2149,13 +2149,13 @@ const kl = {
|
|
|
2149
2149
|
]);
|
|
2150
2150
|
};
|
|
2151
2151
|
}
|
|
2152
|
-
}, Ml = /* @__PURE__ */ He(
|
|
2152
|
+
}, Ml = /* @__PURE__ */ He(Vl, [["__scopeId", "data-v-c423ede0"]]), Fl = { class: "g-table-container" }, Tl = {
|
|
2153
2153
|
key: 0,
|
|
2154
2154
|
class: "table-query-container"
|
|
2155
|
-
},
|
|
2155
|
+
}, Sl = { class: "table-container" }, ql = ["innerHTML"], Ol = { key: 0 }, xl = { style: { display: "flex", "margin-top": "-2px" } }, Al = { style: { display: "flex", flex: "1" } }, Bl = {
|
|
2156
2156
|
style: { display: "flex", "justify-content": "center", width: "100%", height: "100%" },
|
|
2157
2157
|
id: "table-form"
|
|
2158
|
-
},
|
|
2158
|
+
}, Il = { key: 1 }, Ul = { style: { display: "flex" } }, Yl = { style: { display: "flex", flex: "1" } }, jl = /* @__PURE__ */ Object.assign({
|
|
2159
2159
|
name: "g-table",
|
|
2160
2160
|
inheritAttrs: !1
|
|
2161
2161
|
}, {
|
|
@@ -2169,10 +2169,10 @@ const kl = {
|
|
|
2169
2169
|
}),
|
|
2170
2170
|
emits: /* @__PURE__ */ je(["load", "open", "delete", "submit", "reset", "download", "row-save"], ["update:modelValue"]),
|
|
2171
2171
|
setup(p, { emit: c }) {
|
|
2172
|
-
var Te, Ee, qe,
|
|
2173
|
-
const t = c, e = Le(p, "modelValue"),
|
|
2172
|
+
var Te, Ee, qe, Ae, Be, lt, Xe;
|
|
2173
|
+
const t = c, e = Le(p, "modelValue"), o = vt("options"), f = le({}), E = Object.entries(e.value).filter(([l, r]) => (r == null ? void 0 : r.search) !== void 0).map(([l, r]) => [l, r.value]);
|
|
2174
2174
|
f.value = Object.fromEntries(E);
|
|
2175
|
-
const x = le(!1), F = ["type", "index", "label", "column-key", "prop", "width", "min-width", "fixed", "render-header", "sortable", "sort-method", "sort-by", "sort-orders", "resizable", "formatter", "show-overflow-tooltip", "align", "header-align", "class-name", "label-class-name", "selectable", "reserve-selection", "filters", "filter-placement", "filter-class-name", "filter-multiple", "filter-method", "filtered-value"], _ = le([]), k = p, R = pt(), ae = le({}), Y = le([]), A = le(null),
|
|
2175
|
+
const x = le(!1), F = ["type", "index", "label", "column-key", "prop", "width", "min-width", "fixed", "render-header", "sortable", "sort-method", "sort-by", "sort-orders", "resizable", "formatter", "show-overflow-tooltip", "align", "header-align", "class-name", "label-class-name", "selectable", "reserve-selection", "filters", "filter-placement", "filter-class-name", "filter-multiple", "filter-method", "filtered-value"], _ = le([]), k = p, R = pt(), ae = le({}), Y = le([]), A = le(null), oe = le(""), ue = {
|
|
2176
2176
|
autoWatch: !1,
|
|
2177
2177
|
data: [],
|
|
2178
2178
|
border: !0,
|
|
@@ -2181,30 +2181,30 @@ const kl = {
|
|
|
2181
2181
|
fit: !1,
|
|
2182
2182
|
type: "hidden",
|
|
2183
2183
|
load: () => {
|
|
2184
|
-
let { currentPage: l, pageSize:
|
|
2184
|
+
let { currentPage: l, pageSize: r } = e.value.table.page;
|
|
2185
2185
|
try {
|
|
2186
|
-
t("load", { currentPage: l, pageSize:
|
|
2187
|
-
var
|
|
2186
|
+
t("load", { currentPage: l, pageSize: r, ...f.value }, (v, C, { fields: P = [], sums: H = {} } = {}) => {
|
|
2187
|
+
var J, we;
|
|
2188
2188
|
if (!Array.isArray(v)) {
|
|
2189
|
-
console.error("从 load 事件回调中接收到的数据不是数组格式。"),
|
|
2189
|
+
console.error("从 load 事件回调中接收到的数据不是数组格式。"), xe.error("数据加载失败,请检查数据格式。");
|
|
2190
2190
|
return;
|
|
2191
2191
|
}
|
|
2192
|
-
if (typeof
|
|
2193
|
-
console.error("从 load 事件回调中接收到的 total 不是数字格式。"),
|
|
2192
|
+
if (typeof C != "number") {
|
|
2193
|
+
console.error("从 load 事件回调中接收到的 total 不是数字格式。"), xe.error("数据加载失败,请检查数据格式。");
|
|
2194
2194
|
return;
|
|
2195
2195
|
}
|
|
2196
|
-
e.value.table.data = v, ((
|
|
2196
|
+
e.value.table.data = v, ((we = (J = e.value.control) == null ? void 0 : J.add) == null ? void 0 : we.inline) === !0 && e.value.table.data.unshift(A.value), e.value.table.page.total = C, Y.value = P, ae.value = H, _e(), oe.value = Math.random().toString(36).substring(2);
|
|
2197
2197
|
}, A.value);
|
|
2198
2198
|
} catch (v) {
|
|
2199
|
-
console.error("触发 load 事件时出现错误:", v),
|
|
2199
|
+
console.error("触发 load 事件时出现错误:", v), xe.error("数据加载时出现错误,请稍后重试。");
|
|
2200
2200
|
}
|
|
2201
2201
|
},
|
|
2202
|
-
onHeaderDragend: (l,
|
|
2203
|
-
var
|
|
2204
|
-
Ke((
|
|
2202
|
+
onHeaderDragend: (l, r, v) => {
|
|
2203
|
+
var C;
|
|
2204
|
+
Ke((C = e.value.table) == null ? void 0 : C.user, k.name, v.property, { width: l });
|
|
2205
2205
|
},
|
|
2206
|
-
onRowDblclick: (l,
|
|
2207
|
-
e.value.table.dblclickType == "edit" ? a(l,
|
|
2206
|
+
onRowDblclick: (l, r, v) => {
|
|
2207
|
+
e.value.table.dblclickType == "edit" ? a(l, r, v, e) : e.value.table.dblclickType == "view" && M(l, r, v, e);
|
|
2208
2208
|
},
|
|
2209
2209
|
style: { "min-height": "100px", backgroundColor: "var(--el-bg-color)" },
|
|
2210
2210
|
page: {
|
|
@@ -2228,13 +2228,13 @@ const kl = {
|
|
|
2228
2228
|
}
|
|
2229
2229
|
},
|
|
2230
2230
|
dblclickType: "edit",
|
|
2231
|
-
"summary-method": ({ columns: l, data:
|
|
2232
|
-
onSortChange: ({ column: l, prop:
|
|
2231
|
+
"summary-method": ({ columns: l, data: r }, v) => v,
|
|
2232
|
+
onSortChange: ({ column: l, prop: r, order: v }, C) => {
|
|
2233
2233
|
}
|
|
2234
2234
|
};
|
|
2235
2235
|
e.value.table = Se(
|
|
2236
2236
|
ue,
|
|
2237
|
-
|
|
2237
|
+
o == null ? void 0 : o.table,
|
|
2238
2238
|
e.value.table,
|
|
2239
2239
|
R
|
|
2240
2240
|
// 继承父组件的属性
|
|
@@ -2259,25 +2259,25 @@ const kl = {
|
|
|
2259
2259
|
text: !0,
|
|
2260
2260
|
type: "success",
|
|
2261
2261
|
mode: "dialog",
|
|
2262
|
-
auth: (l,
|
|
2262
|
+
auth: (l, r, v) => !1
|
|
2263
2263
|
},
|
|
2264
2264
|
edit: {
|
|
2265
2265
|
label: "编辑",
|
|
2266
2266
|
text: !0,
|
|
2267
2267
|
type: "primary",
|
|
2268
2268
|
mode: "dialog",
|
|
2269
|
-
auth: (l,
|
|
2270
|
-
var
|
|
2271
|
-
return ((
|
|
2269
|
+
auth: (l, r, v) => {
|
|
2270
|
+
var C, P, H;
|
|
2271
|
+
return ((H = (P = (C = e.value) == null ? void 0 : C.control) == null ? void 0 : P.add) == null ? void 0 : H.inline) === !1;
|
|
2272
2272
|
}
|
|
2273
2273
|
},
|
|
2274
2274
|
delete: {
|
|
2275
2275
|
text: !0,
|
|
2276
2276
|
label: "删除",
|
|
2277
2277
|
type: "danger",
|
|
2278
|
-
auth: (l,
|
|
2279
|
-
var
|
|
2280
|
-
return !(((
|
|
2278
|
+
auth: (l, r, v) => {
|
|
2279
|
+
var C, P, H;
|
|
2280
|
+
return !(((H = (P = (C = e.value) == null ? void 0 : C.control) == null ? void 0 : P.add) == null ? void 0 : H.inline) === !0 && v === 0);
|
|
2281
2281
|
},
|
|
2282
2282
|
dialog: {
|
|
2283
2283
|
message: "此操作将永久删除该文件, 是否继续?",
|
|
@@ -2307,55 +2307,56 @@ const kl = {
|
|
|
2307
2307
|
sort: -1,
|
|
2308
2308
|
addLabel: "新增",
|
|
2309
2309
|
auth: () => {
|
|
2310
|
-
var l,
|
|
2311
|
-
return ((v = (
|
|
2310
|
+
var l, r, v;
|
|
2311
|
+
return ((v = (r = (l = e.value) == null ? void 0 : l.control) == null ? void 0 : r.add) == null ? void 0 : v.inline) === !0;
|
|
2312
2312
|
}
|
|
2313
2313
|
},
|
|
2314
|
-
dropdown: (l,
|
|
2314
|
+
dropdown: (l, r, v, C) => ({
|
|
2315
2315
|
label: "编辑",
|
|
2316
2316
|
operate: "edit",
|
|
2317
2317
|
"split-button": !0,
|
|
2318
2318
|
type: "primary",
|
|
2319
2319
|
size: "small",
|
|
2320
|
+
auth: () => !(C.control.add.inline === !0 && v == 0),
|
|
2320
2321
|
onClick: () => {
|
|
2321
|
-
var
|
|
2322
|
-
let
|
|
2323
|
-
|
|
2322
|
+
var H;
|
|
2323
|
+
let P = (H = ce(l, r, v, C)) == null ? void 0 : H.operate;
|
|
2324
|
+
P === "edit" ? a(l, r, v, C) : P === "delete" ? s(l, r, v, C) : P === "view" && M(l, r, v, C);
|
|
2324
2325
|
},
|
|
2325
2326
|
"button-props": { round: !0, plain: !0 }
|
|
2326
2327
|
})
|
|
2327
2328
|
};
|
|
2328
2329
|
e.value.control = Se(
|
|
2329
2330
|
K,
|
|
2330
|
-
|
|
2331
|
+
o == null ? void 0 : o.control,
|
|
2331
2332
|
(qe = e.value) == null ? void 0 : qe.control
|
|
2332
2333
|
);
|
|
2333
|
-
const
|
|
2334
|
-
var
|
|
2335
|
-
if (!l || !
|
|
2334
|
+
const ce = (l, r, v, C) => {
|
|
2335
|
+
var we, ke, d, G, fe, Oe;
|
|
2336
|
+
if (!l || !r || v == null)
|
|
2336
2337
|
return console.warn("mergeDropdown: 缺少必要的参数(row, column或index)"), {};
|
|
2337
|
-
const
|
|
2338
|
-
return Se(
|
|
2339
|
-
},
|
|
2338
|
+
const P = ((we = K.dropdown) == null ? void 0 : we.call(K, l, r, v, C)) || {}, H = ((d = (ke = o == null ? void 0 : o.control) == null ? void 0 : ke.dropdown) == null ? void 0 : d.call(ke, l, r, v, C)) || {}, J = ((Oe = (fe = (G = e.value) == null ? void 0 : G.control) == null ? void 0 : fe.dropdown) == null ? void 0 : Oe.call(fe, l, r, v, C)) || {};
|
|
2339
|
+
return Se(P, H, J) || {};
|
|
2340
|
+
}, $e = {
|
|
2340
2341
|
type: "hidden",
|
|
2341
2342
|
minWidth: 120,
|
|
2342
2343
|
align: "center",
|
|
2343
|
-
formatter: (l,
|
|
2344
|
+
formatter: (l, r, v, C) => v
|
|
2344
2345
|
};
|
|
2345
2346
|
e.value.tableColumns = Se(
|
|
2346
|
-
|
|
2347
|
-
|
|
2348
|
-
(
|
|
2347
|
+
$e,
|
|
2348
|
+
o == null ? void 0 : o.tableColumns,
|
|
2349
|
+
(Ae = e.value) == null ? void 0 : Ae.tableColumns
|
|
2349
2350
|
);
|
|
2350
|
-
const
|
|
2351
|
+
const ge = {
|
|
2351
2352
|
type: "hidden",
|
|
2352
2353
|
disabled: void 0,
|
|
2353
2354
|
footer: { hidden: !1 },
|
|
2354
2355
|
modalState: void 0
|
|
2355
2356
|
};
|
|
2356
2357
|
e.value.form = Se(
|
|
2357
|
-
|
|
2358
|
-
|
|
2358
|
+
ge,
|
|
2359
|
+
o == null ? void 0 : o.form,
|
|
2359
2360
|
(Be = e.value) == null ? void 0 : Be.form
|
|
2360
2361
|
);
|
|
2361
2362
|
const ye = {
|
|
@@ -2367,7 +2368,7 @@ const kl = {
|
|
|
2367
2368
|
};
|
|
2368
2369
|
e.value.formItems = Se(
|
|
2369
2370
|
ye,
|
|
2370
|
-
|
|
2371
|
+
o == null ? void 0 : o.formItems,
|
|
2371
2372
|
(lt = e == null ? void 0 : e.value) == null ? void 0 : lt.formItems
|
|
2372
2373
|
);
|
|
2373
2374
|
const ne = {
|
|
@@ -2381,12 +2382,12 @@ const kl = {
|
|
|
2381
2382
|
};
|
|
2382
2383
|
e.value.dialog = Se(
|
|
2383
2384
|
ne,
|
|
2384
|
-
|
|
2385
|
+
o == null ? void 0 : o.dialog,
|
|
2385
2386
|
(Xe = e.value) == null ? void 0 : Xe.dialog
|
|
2386
2387
|
);
|
|
2387
|
-
const se = (l,
|
|
2388
|
-
let v =
|
|
2389
|
-
if (l.decimals && !isNaN(parseFloat(
|
|
2388
|
+
const se = (l, r) => {
|
|
2389
|
+
let v = r;
|
|
2390
|
+
if (l.decimals && !isNaN(parseFloat(r)) && (typeof l.decimals == "number" ? v = parseFloat(v).toFixed(l.decimals) : typeof l.decimals == "object" && l.decimals.num && (l.decimals.pad ? v = parseFloat(v).toFixed(l.decimals.num) : v = parseFloat(parseFloat(v).toFixed(l.decimals.num)).toString())), ["date", "datetime", "time", "time-select"].includes(l.type) && it(r).isValid()) {
|
|
2390
2391
|
const P = {
|
|
2391
2392
|
date: "YYYY-MM-DD",
|
|
2392
2393
|
datetime: "YYYY-MM-DD HH:mm:ss",
|
|
@@ -2394,102 +2395,102 @@ const kl = {
|
|
|
2394
2395
|
};
|
|
2395
2396
|
v = l.format ? it(v).format(l.format) : it(v).format(P[l.type]);
|
|
2396
2397
|
}
|
|
2397
|
-
return l.type === "money" && (l.align = l.align || "right", l.width = l.width || 130, v = `<span title="${mt(parseFloat(v))}">${
|
|
2398
|
+
return l.type === "money" && (l.align = l.align || "right", l.width = l.width || 130, v = `<span title="${mt(parseFloat(v))}">${ta(parseFloat(v))}</span>`), l.prefix && v && (v = `<span>${l.prefix}${v}</span>`), l.suffix && v && (v = `${v}<span>${l.suffix}</span>`), v;
|
|
2398
2399
|
}, ee = (l) => {
|
|
2399
2400
|
f.value = Object.fromEntries(E), e.value.table.load();
|
|
2400
|
-
},
|
|
2401
|
+
}, be = (l) => {
|
|
2401
2402
|
f.value = l, e.value.table.load();
|
|
2402
2403
|
}, ie = async (l) => {
|
|
2403
|
-
var
|
|
2404
|
+
var r, v;
|
|
2404
2405
|
e.value.form.modalState = "add";
|
|
2405
2406
|
try {
|
|
2406
|
-
if (!await ((
|
|
2407
|
-
} catch (
|
|
2408
|
-
console.error("验证失败:",
|
|
2407
|
+
if (!await ((r = e.value.control) == null ? void 0 : r.validate("add", { m: l }))) return;
|
|
2408
|
+
} catch (C) {
|
|
2409
|
+
console.error("验证失败:", C);
|
|
2409
2410
|
return;
|
|
2410
2411
|
}
|
|
2411
|
-
(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(A.value), t("open", "row-add", { initFormData: A.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(A.value).forEach((
|
|
2412
|
-
e.value[
|
|
2412
|
+
(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(A.value), t("open", "row-add", { initFormData: A.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(A.value).forEach((C) => {
|
|
2413
|
+
e.value[C] && (e.value[C].value = A.value[C]);
|
|
2413
2414
|
}), x.value = !0, t("open", "add", { m: l }));
|
|
2414
|
-
}, a = async (l,
|
|
2415
|
-
var P,
|
|
2415
|
+
}, a = async (l, r, v, C) => {
|
|
2416
|
+
var P, H;
|
|
2416
2417
|
e.value.form.modalState = "edit";
|
|
2417
2418
|
try {
|
|
2418
|
-
if (!await ((P = e.value.control) == null ? void 0 : P.validate("edit", { row: l, column:
|
|
2419
|
-
} catch (
|
|
2420
|
-
console.error("验证失败:",
|
|
2419
|
+
if (!await ((P = e.value.control) == null ? void 0 : P.validate("edit", { row: l, column: r, $index: v, m: C }))) return;
|
|
2420
|
+
} catch (J) {
|
|
2421
|
+
console.error("验证失败:", J);
|
|
2421
2422
|
return;
|
|
2422
2423
|
}
|
|
2423
|
-
(
|
|
2424
|
-
e.value[
|
|
2425
|
-
}), x.value = !0, t("open", "edit", { m:
|
|
2426
|
-
}, s = async (l,
|
|
2427
|
-
var P,
|
|
2424
|
+
(H = e.value.control.edit) != null && H.click ? e.value.control.edit.click(l, r, v, C) : (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((J) => {
|
|
2425
|
+
e.value[J] && (e.value[J].value = l[J]);
|
|
2426
|
+
}), x.value = !0, t("open", "edit", { m: C, row: l, column: r, $index: v }));
|
|
2427
|
+
}, s = async (l, r, v, C) => {
|
|
2428
|
+
var P, H;
|
|
2428
2429
|
try {
|
|
2429
|
-
if (!await ((P = e.value.control) == null ? void 0 : P.validate("delete", { row: l, column:
|
|
2430
|
-
} catch (
|
|
2431
|
-
console.error("验证失败:",
|
|
2430
|
+
if (!await ((P = e.value.control) == null ? void 0 : P.validate("delete", { row: l, column: r, $index: v, m: C }))) return;
|
|
2431
|
+
} catch (J) {
|
|
2432
|
+
console.error("验证失败:", J);
|
|
2432
2433
|
return;
|
|
2433
2434
|
}
|
|
2434
|
-
if ((
|
|
2435
|
-
e.value.control.delete.click(l,
|
|
2435
|
+
if ((H = e.value.control.delete) != null && H.click)
|
|
2436
|
+
e.value.control.delete.click(l, r, v, C);
|
|
2436
2437
|
else {
|
|
2437
|
-
let { message:
|
|
2438
|
-
|
|
2439
|
-
t("delete", { row: l, column:
|
|
2440
|
-
d && (e.value.table.data.splice(v, 1), e.value.table.page.total--),
|
|
2438
|
+
let { message: J, title: we, options: ke } = e.value.control.delete.dialog;
|
|
2439
|
+
_t.confirm(J, we, ke).then(() => {
|
|
2440
|
+
t("delete", { row: l, column: r, $index: v }, (d = !0, G = !1) => {
|
|
2441
|
+
d && (e.value.table.data.splice(v, 1), e.value.table.page.total--), G && e.value.table.load();
|
|
2441
2442
|
});
|
|
2442
2443
|
}).catch(() => {
|
|
2443
2444
|
});
|
|
2444
2445
|
}
|
|
2445
|
-
}, M = async (l,
|
|
2446
|
-
var P,
|
|
2446
|
+
}, M = async (l, r, v, C) => {
|
|
2447
|
+
var P, H;
|
|
2447
2448
|
e.value.form.modalState = void 0;
|
|
2448
2449
|
try {
|
|
2449
|
-
if (!await ((P = e.value.control) == null ? void 0 : P.validate("view", { row: l, column:
|
|
2450
|
-
} catch (
|
|
2451
|
-
console.error("验证失败:",
|
|
2450
|
+
if (!await ((P = e.value.control) == null ? void 0 : P.validate("view", { row: l, column: r, $index: v, m: C }))) return;
|
|
2451
|
+
} catch (J) {
|
|
2452
|
+
console.error("验证失败:", J);
|
|
2452
2453
|
return;
|
|
2453
2454
|
}
|
|
2454
|
-
(
|
|
2455
|
-
e.value[
|
|
2456
|
-
}), x.value = !0, t("open", "view", { m:
|
|
2457
|
-
}, u = (l,
|
|
2455
|
+
(H = e.value.control.view) != null && H.click ? e.value.control.view.click(l, r, v, C) : (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((J) => {
|
|
2456
|
+
e.value[J] && (e.value[J].value = l[J]);
|
|
2457
|
+
}), x.value = !0, t("open", "view", { m: C, row: l, column: r, $index: v }));
|
|
2458
|
+
}, u = (l, r, v, C) => {
|
|
2458
2459
|
var P;
|
|
2459
|
-
(P = e.value.control.save) != null && P.click ? e.value.control.save.click(l,
|
|
2460
|
-
|
|
2461
|
-
A.value = Object.assign({}, Object.fromEntries(Object.entries(
|
|
2460
|
+
(P = e.value.control.save) != null && P.click ? e.value.control.save.click(l, r, v, C) : t("row-save", { row: l, column: r, $index: v, data: e.value.table.data }, (H = !0, J = !0) => {
|
|
2461
|
+
H && (e.value.table.load(), console.log("load")), J && et(() => {
|
|
2462
|
+
A.value = Object.assign({}, Object.fromEntries(Object.entries(Me(e.value, (we, ke) => ke.type != "control" && ke.editor !== !1 && ke.type != "hidden")).map(([we, ke]) => [we, ke.value])));
|
|
2462
2463
|
});
|
|
2463
2464
|
});
|
|
2464
|
-
}, y = (l,
|
|
2465
|
-
t("submit", e.value.form.modalState, l,
|
|
2466
|
-
v && (x.value = !1,
|
|
2465
|
+
}, y = (l, r) => {
|
|
2466
|
+
t("submit", e.value.form.modalState, l, r, (v) => {
|
|
2467
|
+
v && (x.value = !1, r.table.load());
|
|
2467
2468
|
});
|
|
2468
2469
|
}, m = (l) => {
|
|
2469
2470
|
t("reset", l);
|
|
2470
|
-
}, b = (l,
|
|
2471
|
+
}, b = (l, r) => {
|
|
2471
2472
|
var v;
|
|
2472
2473
|
if ((v = l.control.download) != null && v.click)
|
|
2473
|
-
l.control.download.click(l,
|
|
2474
|
+
l.control.download.click(l, r);
|
|
2474
2475
|
else {
|
|
2475
|
-
let
|
|
2476
|
+
let C = ct({
|
|
2476
2477
|
title: l.control.download.label,
|
|
2477
2478
|
size: 480,
|
|
2478
2479
|
width: 600,
|
|
2479
2480
|
slots: {
|
|
2480
|
-
default: () => Ie(
|
|
2481
|
-
items:
|
|
2481
|
+
default: () => Ie(bl, {
|
|
2482
|
+
items: r,
|
|
2482
2483
|
commitText: l.control.download.excelLabel,
|
|
2483
|
-
onExcel: (P,
|
|
2484
|
-
t("download", P,
|
|
2484
|
+
onExcel: (P, H) => {
|
|
2485
|
+
t("download", P, H), C();
|
|
2485
2486
|
}
|
|
2486
2487
|
})
|
|
2487
2488
|
}
|
|
2488
2489
|
}, l.control.download.mode);
|
|
2489
2490
|
}
|
|
2490
2491
|
}, i = (l) => {
|
|
2491
|
-
var
|
|
2492
|
-
(
|
|
2492
|
+
var r;
|
|
2493
|
+
(r = l.control.setting) != null && r.click ? l.control.setting.click(l) : ct({
|
|
2493
2494
|
title: l.control.setting.label,
|
|
2494
2495
|
size: 470,
|
|
2495
2496
|
width: 600,
|
|
@@ -2500,7 +2501,7 @@ const kl = {
|
|
|
2500
2501
|
})
|
|
2501
2502
|
}
|
|
2502
2503
|
}, l.control.setting.mode);
|
|
2503
|
-
}, $ = e.value.control,
|
|
2504
|
+
}, $ = e.value.control, V = [
|
|
2504
2505
|
{ type: "add", func: ie },
|
|
2505
2506
|
{ type: "download", func: b },
|
|
2506
2507
|
{ type: "setting", func: i },
|
|
@@ -2508,122 +2509,122 @@ const kl = {
|
|
|
2508
2509
|
{ type: "edit", func: a },
|
|
2509
2510
|
{ type: "delete", func: s },
|
|
2510
2511
|
{ type: "save", func: u }
|
|
2511
|
-
], N = (l) =>
|
|
2512
|
-
var
|
|
2512
|
+
], N = (l) => V.filter((r) => l.includes(r.type)).map(({ type: r, func: v }) => {
|
|
2513
|
+
var C, P, H;
|
|
2513
2514
|
return {
|
|
2514
|
-
name: `control-${
|
|
2515
|
-
attr: $ == null ? void 0 : $[
|
|
2515
|
+
name: `control-${r}`,
|
|
2516
|
+
attr: $ == null ? void 0 : $[r],
|
|
2516
2517
|
func: v,
|
|
2517
|
-
label: (
|
|
2518
|
-
sort: ((P = $ == null ? void 0 : $[
|
|
2519
|
-
groupName: ((
|
|
2518
|
+
label: (C = $ == null ? void 0 : $[r]) == null ? void 0 : C.label,
|
|
2519
|
+
sort: ((P = $ == null ? void 0 : $[r]) == null ? void 0 : P.sort) || 0,
|
|
2520
|
+
groupName: ((H = $ == null ? void 0 : $[r]) == null ? void 0 : H.groupName) || "default"
|
|
2520
2521
|
};
|
|
2521
|
-
}).sort((
|
|
2522
|
-
const
|
|
2523
|
-
return
|
|
2522
|
+
}).sort((r, v) => r.sort - v.sort), T = (l) => N(l).reduce((r, v) => {
|
|
2523
|
+
const C = v.groupName || "default";
|
|
2524
|
+
return r[C] || (r[C] = []), r[C].push(v), r;
|
|
2524
2525
|
}, {}), O = Pe(() => Object.fromEntries(
|
|
2525
|
-
Object.entries(e.value).filter(([l,
|
|
2526
|
-
)), de = le({}), te = (l,
|
|
2527
|
-
const v = (
|
|
2528
|
-
for (const
|
|
2529
|
-
if (
|
|
2530
|
-
if (
|
|
2531
|
-
const
|
|
2532
|
-
if (
|
|
2526
|
+
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)
|
|
2527
|
+
)), de = le({}), te = (l, r) => {
|
|
2528
|
+
const v = (C, P) => {
|
|
2529
|
+
for (const H of C) {
|
|
2530
|
+
if (H.value == P) return H.label;
|
|
2531
|
+
if (H.children) {
|
|
2532
|
+
const J = v(H.children, P);
|
|
2533
|
+
if (J) return J;
|
|
2533
2534
|
}
|
|
2534
2535
|
}
|
|
2535
2536
|
return null;
|
|
2536
2537
|
};
|
|
2537
2538
|
if (l.getDicts) {
|
|
2538
|
-
const
|
|
2539
|
-
return de.value[
|
|
2540
|
-
de.value[
|
|
2539
|
+
const C = r.toString();
|
|
2540
|
+
return de.value[C] ? (l.options = de.value[C], l.formatter || (l.formatter = (P, H, J, we) => l.options && v(l.options, J) || J), Promise.resolve()) : l.getDicts(e.value.table.data).then((P) => {
|
|
2541
|
+
de.value[C] = P, l.options = P, l.formatter || (l.formatter = (H, J, we, ke) => l.options && v(l.options, we) || we);
|
|
2541
2542
|
});
|
|
2542
2543
|
}
|
|
2543
2544
|
return Promise.resolve();
|
|
2544
|
-
},
|
|
2545
|
+
}, _e = () => {
|
|
2545
2546
|
const l = [];
|
|
2546
|
-
Object.keys(e.value).forEach((
|
|
2547
|
-
if (e.value[
|
|
2548
|
-
const v = te(e.value[
|
|
2549
|
-
e.value.table.data.forEach((
|
|
2547
|
+
Object.keys(e.value).forEach((r) => {
|
|
2548
|
+
if (e.value[r].getDicts) {
|
|
2549
|
+
const v = te(e.value[r], r).then(() => {
|
|
2550
|
+
e.value.table.data.forEach((C) => {
|
|
2550
2551
|
var P;
|
|
2551
|
-
if (e.value[
|
|
2552
|
-
const
|
|
2553
|
-
|
|
2552
|
+
if (e.value[r].getDicts && ((P = e.value[r]) == null ? void 0 : P.forceString) !== !1) {
|
|
2553
|
+
const H = C[r];
|
|
2554
|
+
C[r] = H != null ? H.toString() : H;
|
|
2554
2555
|
}
|
|
2555
2556
|
});
|
|
2556
|
-
}).catch((
|
|
2557
|
-
console.error(`加载字典${
|
|
2557
|
+
}).catch((C) => {
|
|
2558
|
+
console.error(`加载字典${r}出错:`, C);
|
|
2558
2559
|
});
|
|
2559
2560
|
l.push(v);
|
|
2560
2561
|
}
|
|
2561
|
-
}), Promise.all(l).catch((
|
|
2562
|
-
console.error("字典加载过程中发生错误:",
|
|
2562
|
+
}), Promise.all(l).catch((r) => {
|
|
2563
|
+
console.error("字典加载过程中发生错误:", r);
|
|
2563
2564
|
});
|
|
2564
|
-
},
|
|
2565
|
-
var P,
|
|
2566
|
-
return l.table ? (P = l.table(
|
|
2567
|
-
}, Fe = (l,
|
|
2568
|
-
return
|
|
2565
|
+
}, Ce = (l, r, v, C) => {
|
|
2566
|
+
var P, H;
|
|
2567
|
+
return l.table ? (P = l.table(r, v, C)) != null && P.auth ? (H = l.table(r, v, C)) == null ? void 0 : H.auth(r, v, C) : !0 : !1;
|
|
2568
|
+
}, Fe = (l, r) => l.name === "control-save" && r === 0 && e.value.control.add.inline === !0 ? l.attr.addLabel : l.label;
|
|
2569
|
+
return jt(() => {
|
|
2569
2570
|
e.value.table.autoWatch && e.value.table.load();
|
|
2570
2571
|
}), tt(async () => {
|
|
2571
2572
|
var l;
|
|
2572
|
-
if (_.value = Object.values(e.value).filter((
|
|
2573
|
+
if (_.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 })), et(() => {
|
|
2573
2574
|
A.value = Object.assign({}, Object.fromEntries(
|
|
2574
|
-
Object.entries(
|
|
2575
|
+
Object.entries(Me(e.value, (r, v) => v.type != "control" && v.editor !== !1 && v.type != "hidden")).map(([r, v]) => [r, v.value])
|
|
2575
2576
|
));
|
|
2576
2577
|
}), !((l = e.value.table) != null && l.user)) {
|
|
2577
|
-
|
|
2578
|
+
xe.error("必须给使用此表格的用户一个名字!");
|
|
2578
2579
|
return;
|
|
2579
2580
|
}
|
|
2580
2581
|
if (!k.name) {
|
|
2581
|
-
|
|
2582
|
+
xe.error("必须给表格一个唯一的name属性");
|
|
2582
2583
|
return;
|
|
2583
2584
|
}
|
|
2584
2585
|
try {
|
|
2585
|
-
let
|
|
2586
|
-
if (
|
|
2587
|
-
if (k.name !==
|
|
2588
|
-
|
|
2586
|
+
let r = await El(k.name);
|
|
2587
|
+
if (r) {
|
|
2588
|
+
if (k.name !== r.name) {
|
|
2589
|
+
xe.error("此表格已经存在,请换一个名字!");
|
|
2589
2590
|
return;
|
|
2590
2591
|
}
|
|
2591
2592
|
} else
|
|
2592
|
-
await
|
|
2593
|
-
} catch (
|
|
2594
|
-
console.error("检查表格名称时出现错误:",
|
|
2593
|
+
await kl({ name: k.name });
|
|
2594
|
+
} catch (r) {
|
|
2595
|
+
console.error("检查表格名称时出现错误:", r), xe.error("检查表格名称时出现错误,请稍后重试。");
|
|
2595
2596
|
}
|
|
2596
2597
|
try {
|
|
2597
|
-
const
|
|
2598
|
-
|
|
2598
|
+
const r = await $l(e.value.table.user, k.name);
|
|
2599
|
+
r && r.forEach((v) => {
|
|
2599
2600
|
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);
|
|
2600
2601
|
});
|
|
2601
|
-
} catch (
|
|
2602
|
-
console.error("Error fetching table column settings:",
|
|
2602
|
+
} catch (r) {
|
|
2603
|
+
console.error("Error fetching table column settings:", r);
|
|
2603
2604
|
}
|
|
2604
2605
|
e.value.table.autoWatch || e.value.table.load();
|
|
2605
|
-
}), (l,
|
|
2606
|
-
var
|
|
2607
|
-
const v = B("el-button-group"),
|
|
2606
|
+
}), (l, r) => {
|
|
2607
|
+
var Oe, ze, Ne, at, ht;
|
|
2608
|
+
const v = B("el-button-group"), C = B("el-dropdown-item"), P = B("el-dropdown-menu"), H = B("el-dropdown"), J = B("el-table-column"), we = B("el-table"), ke = B("el-pagination"), d = B("el-icon"), G = B("el-dialog"), fe = B("el-drawer");
|
|
2608
2609
|
return n(), q(W, null, [
|
|
2609
|
-
X("div",
|
|
2610
|
-
((ze = (
|
|
2610
|
+
X("div", Fl, [
|
|
2611
|
+
((ze = (Oe = e.value) == null ? void 0 : Oe.query) == null ? void 0 : ze.hidden) != !0 ? (n(), q("div", Tl, [
|
|
2611
2612
|
h(l.$slots, "query", {}, () => [
|
|
2612
|
-
Q(
|
|
2613
|
+
Q(fl, {
|
|
2613
2614
|
modelValue: e.value,
|
|
2614
|
-
"onUpdate:modelValue":
|
|
2615
|
+
"onUpdate:modelValue": r[0] || (r[0] = (j) => e.value = j),
|
|
2615
2616
|
info: f.value,
|
|
2616
|
-
"onUpdate:info":
|
|
2617
|
-
onQuery:
|
|
2617
|
+
"onUpdate:info": r[1] || (r[1] = (j) => f.value = j),
|
|
2618
|
+
onQuery: be,
|
|
2618
2619
|
onReset: ee
|
|
2619
2620
|
}, me({
|
|
2620
2621
|
"q-btns": g(() => [
|
|
2621
2622
|
h(l.$slots, "q-btns", {}, () => [
|
|
2622
|
-
(n(!0), q(W, null, U(T(["add", "download", "setting"]), (j,
|
|
2623
|
-
|
|
2623
|
+
(n(!0), q(W, null, U(T(["add", "download", "setting"]), (j, re) => (n(), q(W, null, [
|
|
2624
|
+
re == "default" ? (n(!0), q(W, { key: 0 }, U(j, (w) => (n(), q(W, null, [
|
|
2624
2625
|
h(l.$slots, w.name + "-left", {}, void 0, !0),
|
|
2625
2626
|
(w.name === "control-add" ? w.attr.auth() && w.attr.inline === !1 : w.attr.auth()) ? h(l.$slots, w.name, { key: 0 }, () => [
|
|
2626
|
-
w.label ? (n(),
|
|
2627
|
+
w.label ? (n(), D(I(De), S({
|
|
2627
2628
|
key: 0,
|
|
2628
2629
|
title: w.label,
|
|
2629
2630
|
ref_for: !0
|
|
@@ -2631,10 +2632,10 @@ const kl = {
|
|
|
2631
2632
|
onClick: (z) => w.func(e.value, _.value)
|
|
2632
2633
|
}), {
|
|
2633
2634
|
default: g(() => [
|
|
2634
|
-
|
|
2635
|
+
Ve(he(w.label), 1)
|
|
2635
2636
|
]),
|
|
2636
2637
|
_: 2
|
|
2637
|
-
}, 1040, ["title", "onClick"])) : (n(),
|
|
2638
|
+
}, 1040, ["title", "onClick"])) : (n(), D(I(De), S({
|
|
2638
2639
|
key: 1,
|
|
2639
2640
|
title: w.label,
|
|
2640
2641
|
ref_for: !0
|
|
@@ -2643,12 +2644,12 @@ const kl = {
|
|
|
2643
2644
|
}), null, 16, ["title", "onClick"]))
|
|
2644
2645
|
], !0) : ve("", !0),
|
|
2645
2646
|
h(l.$slots, w.name + "-right", {}, void 0, !0)
|
|
2646
|
-
], 64))), 256)) : (n(),
|
|
2647
|
+
], 64))), 256)) : (n(), D(v, { key: 1 }, {
|
|
2647
2648
|
default: g(() => [
|
|
2648
2649
|
(n(!0), q(W, null, U(j, (w) => (n(), q(W, null, [
|
|
2649
2650
|
h(l.$slots, w.name + "-left", {}, void 0, !0),
|
|
2650
2651
|
(w.name === "control-add" ? w.attr.auth() && w.attr.inline === !1 : w.attr.auth()) ? h(l.$slots, w.name, { key: 0 }, () => [
|
|
2651
|
-
w.label ? (n(),
|
|
2652
|
+
w.label ? (n(), D(I(De), S({
|
|
2652
2653
|
key: 0,
|
|
2653
2654
|
title: w.label,
|
|
2654
2655
|
ref_for: !0
|
|
@@ -2656,10 +2657,10 @@ const kl = {
|
|
|
2656
2657
|
onClick: (z) => w.func(e.value, _.value)
|
|
2657
2658
|
}), {
|
|
2658
2659
|
default: g(() => [
|
|
2659
|
-
|
|
2660
|
+
Ve(he(w.label), 1)
|
|
2660
2661
|
]),
|
|
2661
2662
|
_: 2
|
|
2662
|
-
}, 1040, ["title", "onClick"])) : (n(),
|
|
2663
|
+
}, 1040, ["title", "onClick"])) : (n(), D(I(De), S({
|
|
2663
2664
|
key: 1,
|
|
2664
2665
|
title: w.label,
|
|
2665
2666
|
ref_for: !0
|
|
@@ -2677,21 +2678,21 @@ const kl = {
|
|
|
2677
2678
|
]),
|
|
2678
2679
|
_: 2
|
|
2679
2680
|
}, [
|
|
2680
|
-
U(l.$slots, (j,
|
|
2681
|
-
name:
|
|
2681
|
+
U(l.$slots, (j, re, w) => ({
|
|
2682
|
+
name: re,
|
|
2682
2683
|
fn: g((z) => [
|
|
2683
|
-
h(l.$slots,
|
|
2684
|
+
h(l.$slots, re, { model: e.value }, void 0, !0)
|
|
2684
2685
|
])
|
|
2685
2686
|
}))
|
|
2686
2687
|
]), 1032, ["modelValue", "info"])
|
|
2687
2688
|
], !0)
|
|
2688
2689
|
])) : ve("", !0),
|
|
2689
|
-
X("div",
|
|
2690
|
-
Q(
|
|
2690
|
+
X("div", Sl, [
|
|
2691
|
+
Q(we, S({ ...l.$attrs, ...I(Me)(e.value.table, (j) => !["dblclickType", "page"].includes(j)) }, {
|
|
2691
2692
|
"summary-method": (j) => e.value.table["summary-method"](j, { fields: Y.value, sums: ae.value }),
|
|
2692
|
-
onSortChange:
|
|
2693
|
-
var
|
|
2694
|
-
e.value.table.onSortChange(j, f.value), ((
|
|
2693
|
+
onSortChange: r[2] || (r[2] = (j) => {
|
|
2694
|
+
var re, w;
|
|
2695
|
+
e.value.table.onSortChange(j, f.value), ((re = j == null ? void 0 : j.column) == null ? void 0 : re.sortable) === "custom" && ((w = e.value.table) == null || w.load());
|
|
2695
2696
|
})
|
|
2696
2697
|
}), {
|
|
2697
2698
|
append: g(() => [
|
|
@@ -2702,205 +2703,208 @@ const kl = {
|
|
|
2702
2703
|
]),
|
|
2703
2704
|
default: g(() => [
|
|
2704
2705
|
h(l.$slots, "default", {}, () => [
|
|
2705
|
-
(n(!0), q(W, null, U(O.value, (j,
|
|
2706
|
-
prop:
|
|
2707
|
-
key:
|
|
2706
|
+
(n(!0), q(W, null, U(O.value, (j, re) => (n(), D(J, S({
|
|
2707
|
+
prop: re,
|
|
2708
|
+
key: re,
|
|
2708
2709
|
ref_for: !0
|
|
2709
|
-
}, { ...e.value.tableColumns, ...I(
|
|
2710
|
+
}, { ...e.value.tableColumns, ...I(Me)(j, (w) => F.includes(w)) }, { "header-align": "center" }), me({
|
|
2710
2711
|
header: g(({ column: w, $index: z }) => [
|
|
2711
|
-
|
|
2712
|
+
re == "control" ? h(l.$slots, `${re}-header`, {
|
|
2712
2713
|
key: 0,
|
|
2713
2714
|
column: w,
|
|
2714
2715
|
$index: z
|
|
2715
2716
|
}, () => [
|
|
2716
2717
|
X("span", null, he(w.label), 1)
|
|
2717
|
-
], !0) : h(l.$slots, `${
|
|
2718
|
+
], !0) : h(l.$slots, `${re}-header`, {
|
|
2718
2719
|
key: 1,
|
|
2719
2720
|
column: w,
|
|
2720
2721
|
$index: z
|
|
2721
2722
|
}, void 0, !0)
|
|
2722
2723
|
]),
|
|
2723
2724
|
"filter-icon": g((w) => [
|
|
2724
|
-
h(l.$slots, `${
|
|
2725
|
+
h(l.$slots, `${re}-filter-icon`, { data: w }, void 0, !0)
|
|
2725
2726
|
]),
|
|
2726
2727
|
_: 2
|
|
2727
2728
|
}, [
|
|
2728
2729
|
j.type === "expand" ? {
|
|
2729
2730
|
name: "default",
|
|
2730
|
-
fn: g(({ row: w, column: z, $index:
|
|
2731
|
-
h(l.$slots, `${
|
|
2731
|
+
fn: g(({ row: w, column: z, $index: Z }) => [
|
|
2732
|
+
h(l.$slots, `${re}`, {
|
|
2732
2733
|
row: w,
|
|
2733
2734
|
column: z,
|
|
2734
|
-
$index:
|
|
2735
|
+
$index: Z
|
|
2735
2736
|
}, void 0, !0)
|
|
2736
2737
|
]),
|
|
2737
2738
|
key: "0"
|
|
2738
2739
|
} : j.type == "control" ? {
|
|
2739
2740
|
name: "default",
|
|
2740
|
-
fn: g(({ row: w, column: z, $index:
|
|
2741
|
+
fn: g(({ row: w, column: z, $index: Z }) => {
|
|
2741
2742
|
var Ze, Je;
|
|
2742
2743
|
return [
|
|
2743
2744
|
X("div", {
|
|
2744
|
-
class:
|
|
2745
|
+
class: Dt(["control", (Ze = e.value.control) == null ? void 0 : Ze.class]),
|
|
2745
2746
|
style: Ye((Je = e.value.control) == null ? void 0 : Je.style)
|
|
2746
2747
|
}, [
|
|
2747
2748
|
h(l.$slots, "control", {}, () => [
|
|
2748
2749
|
h(l.$slots, "control-left", {
|
|
2749
2750
|
row: w,
|
|
2750
2751
|
column: z,
|
|
2751
|
-
$index:
|
|
2752
|
+
$index: Z
|
|
2752
2753
|
}, void 0, !0),
|
|
2753
|
-
(n(!0), q(W, null, U(T(["view", "edit", "delete", "save"]), (We, Ge) =>
|
|
2754
|
-
|
|
2755
|
-
|
|
2756
|
-
|
|
2757
|
-
|
|
2758
|
-
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
|
|
2763
|
-
column: z,
|
|
2764
|
-
$index: J
|
|
2765
|
-
}, () => [
|
|
2766
|
-
L.label ? (n(), C(I(De), S({
|
|
2754
|
+
(n(!0), q(W, null, U(T(["view", "edit", "delete", "save"]), (We, Ge) => {
|
|
2755
|
+
var yt;
|
|
2756
|
+
return n(), q(W, null, [
|
|
2757
|
+
Ge == "default" ? (n(!0), q(W, { key: 0 }, U(We, (L) => (n(), q(W, null, [
|
|
2758
|
+
h(l.$slots, L.name + "-left", {
|
|
2759
|
+
row: w,
|
|
2760
|
+
column: z,
|
|
2761
|
+
$index: Z
|
|
2762
|
+
}, void 0, !0),
|
|
2763
|
+
L.attr.auth(w, z, Z) ? h(l.$slots, L.name, {
|
|
2767
2764
|
key: 0,
|
|
2768
|
-
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
default: g(() => [
|
|
2774
|
-
Me(he(Fe(L, J)), 1)
|
|
2775
|
-
]),
|
|
2776
|
-
_: 2
|
|
2777
|
-
}, 1040, ["title", "onClick"])) : (n(), C(I(De), S({
|
|
2778
|
-
key: 1,
|
|
2779
|
-
title: L.label,
|
|
2780
|
-
ref_for: !0
|
|
2781
|
-
}, L.attr, {
|
|
2782
|
-
onClick: (Qe) => L.func(w, z, J, e.value)
|
|
2783
|
-
}), null, 16, ["title", "onClick"]))
|
|
2784
|
-
], !0) : ve("", !0),
|
|
2785
|
-
h(l.$slots, L.name + "-right", {
|
|
2786
|
-
row: w,
|
|
2787
|
-
column: z,
|
|
2788
|
-
$index: J
|
|
2789
|
-
}, void 0, !0)
|
|
2790
|
-
], 64))), 256)) : Ge != null && Ge.startsWith("dropdown") ? (n(), C(G, S({
|
|
2791
|
-
key: 1,
|
|
2792
|
-
ref_for: !0
|
|
2793
|
-
}, fe(w, z, J)), {
|
|
2794
|
-
dropdown: g(() => [
|
|
2795
|
-
Q(P, null, {
|
|
2796
|
-
default: g(() => [
|
|
2797
|
-
(n(!0), q(W, null, U(We, (L) => {
|
|
2798
|
-
var Qe, yt, gt;
|
|
2799
|
-
return n(), q(W, null, [
|
|
2800
|
-
l.$slots[L.name + "-left"] ? h(l.$slots, L.name + "-left", {
|
|
2801
|
-
key: 0,
|
|
2802
|
-
row: w,
|
|
2803
|
-
column: z,
|
|
2804
|
-
$index: J
|
|
2805
|
-
}, void 0, !0) : ve("", !0),
|
|
2806
|
-
L.attr.auth(w, z, J) ? (n(), C(V, S({
|
|
2807
|
-
key: 1,
|
|
2808
|
-
ref_for: !0
|
|
2809
|
-
}, { command: (Qe = L == null ? void 0 : L.attr) == null ? void 0 : Qe.command, divided: (yt = L == null ? void 0 : L.attr) == null ? void 0 : yt.divided, disabled: (gt = L == null ? void 0 : L.attr) == null ? void 0 : gt.disabled }), {
|
|
2810
|
-
default: g(() => [
|
|
2811
|
-
h(l.$slots, L.name, {
|
|
2812
|
-
row: w,
|
|
2813
|
-
column: z,
|
|
2814
|
-
$index: J
|
|
2815
|
-
}, () => [
|
|
2816
|
-
L.label ? (n(), C(I(De), S({
|
|
2817
|
-
key: 0,
|
|
2818
|
-
title: L.label,
|
|
2819
|
-
ref_for: !0
|
|
2820
|
-
}, L.attr, {
|
|
2821
|
-
onClick: (Tt) => L.func(w, z, J, e.value)
|
|
2822
|
-
}), {
|
|
2823
|
-
default: g(() => [
|
|
2824
|
-
Me(he(Fe(L, J)), 1)
|
|
2825
|
-
]),
|
|
2826
|
-
_: 2
|
|
2827
|
-
}, 1040, ["title", "onClick"])) : (n(), C(I(De), S({
|
|
2828
|
-
key: 1,
|
|
2829
|
-
title: L.label,
|
|
2830
|
-
ref_for: !0
|
|
2831
|
-
}, L.attr, {
|
|
2832
|
-
onClick: (Tt) => L.func(w, z, J, e.value)
|
|
2833
|
-
}), null, 16, ["title", "onClick"]))
|
|
2834
|
-
], !0)
|
|
2835
|
-
]),
|
|
2836
|
-
_: 2
|
|
2837
|
-
}, 1040)) : ve("", !0),
|
|
2838
|
-
l.$slots[L.name + "-right"] ? h(l.$slots, L.name + "-right", {
|
|
2839
|
-
key: 2,
|
|
2840
|
-
row: w,
|
|
2841
|
-
column: z,
|
|
2842
|
-
$index: J
|
|
2843
|
-
}, void 0, !0) : ve("", !0)
|
|
2844
|
-
], 64);
|
|
2845
|
-
}), 256))
|
|
2846
|
-
]),
|
|
2847
|
-
_: 2
|
|
2848
|
-
}, 1024)
|
|
2849
|
-
]),
|
|
2850
|
-
default: g(() => {
|
|
2851
|
-
var L;
|
|
2852
|
-
return [
|
|
2853
|
-
Me(he((L = fe(w, z, J)) == null ? void 0 : L.label) + " ", 1)
|
|
2854
|
-
];
|
|
2855
|
-
}),
|
|
2856
|
-
_: 2
|
|
2857
|
-
}, 1040)) : (n(), C(v, { key: 2 }, {
|
|
2858
|
-
default: g(() => [
|
|
2859
|
-
(n(!0), q(W, null, U(We, (L) => (n(), q(W, null, [
|
|
2860
|
-
h(l.$slots, L.name + "-left", {
|
|
2861
|
-
row: w,
|
|
2862
|
-
column: z,
|
|
2863
|
-
$index: J
|
|
2864
|
-
}, void 0, !0),
|
|
2865
|
-
L.attr.auth(w, z, J) ? h(l.$slots, L.name, {
|
|
2765
|
+
row: w,
|
|
2766
|
+
column: z,
|
|
2767
|
+
$index: Z
|
|
2768
|
+
}, () => [
|
|
2769
|
+
L.label ? (n(), D(I(De), S({
|
|
2866
2770
|
key: 0,
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
|
|
2771
|
+
title: L.label,
|
|
2772
|
+
ref_for: !0
|
|
2773
|
+
}, L.attr, {
|
|
2774
|
+
onClick: (Qe) => L.func(w, z, Z, e.value)
|
|
2775
|
+
}), {
|
|
2776
|
+
default: g(() => [
|
|
2777
|
+
Ve(he(Fe(L, Z)), 1)
|
|
2778
|
+
]),
|
|
2779
|
+
_: 2
|
|
2780
|
+
}, 1040, ["title", "onClick"])) : (n(), D(I(De), S({
|
|
2781
|
+
key: 1,
|
|
2782
|
+
title: L.label,
|
|
2783
|
+
ref_for: !0
|
|
2784
|
+
}, L.attr, {
|
|
2785
|
+
onClick: (Qe) => L.func(w, z, Z, e.value)
|
|
2786
|
+
}), null, 16, ["title", "onClick"]))
|
|
2787
|
+
], !0) : ve("", !0),
|
|
2788
|
+
h(l.$slots, L.name + "-right", {
|
|
2789
|
+
row: w,
|
|
2790
|
+
column: z,
|
|
2791
|
+
$index: Z
|
|
2792
|
+
}, void 0, !0)
|
|
2793
|
+
], 64))), 256)) : Ge != null && Ge.startsWith("dropdown") && ((yt = ce(w, z, Z, e.value)) != null && yt.auth()) ? (n(), D(H, S({
|
|
2794
|
+
key: 1,
|
|
2795
|
+
ref_for: !0
|
|
2796
|
+
}, ce(w, z, Z, e.value)), {
|
|
2797
|
+
dropdown: g(() => [
|
|
2798
|
+
Q(P, null, {
|
|
2799
|
+
default: g(() => [
|
|
2800
|
+
(n(!0), q(W, null, U(We, (L) => {
|
|
2801
|
+
var Qe, gt, bt;
|
|
2802
|
+
return n(), q(W, null, [
|
|
2803
|
+
l.$slots[L.name + "-left"] ? h(l.$slots, L.name + "-left", {
|
|
2804
|
+
key: 0,
|
|
2805
|
+
row: w,
|
|
2806
|
+
column: z,
|
|
2807
|
+
$index: Z
|
|
2808
|
+
}, void 0, !0) : ve("", !0),
|
|
2809
|
+
L.attr.auth(w, z, Z) ? (n(), D(C, S({
|
|
2810
|
+
key: 1,
|
|
2811
|
+
ref_for: !0
|
|
2812
|
+
}, { command: (Qe = L == null ? void 0 : L.attr) == null ? void 0 : Qe.command, divided: (gt = L == null ? void 0 : L.attr) == null ? void 0 : gt.divided, disabled: (bt = L == null ? void 0 : L.attr) == null ? void 0 : bt.disabled }), {
|
|
2813
|
+
default: g(() => [
|
|
2814
|
+
h(l.$slots, L.name, {
|
|
2815
|
+
row: w,
|
|
2816
|
+
column: z,
|
|
2817
|
+
$index: Z
|
|
2818
|
+
}, () => [
|
|
2819
|
+
L.label ? (n(), D(I(De), S({
|
|
2820
|
+
key: 0,
|
|
2821
|
+
title: L.label,
|
|
2822
|
+
ref_for: !0
|
|
2823
|
+
}, L.attr, {
|
|
2824
|
+
onClick: (St) => L.func(w, z, Z, e.value)
|
|
2825
|
+
}), {
|
|
2826
|
+
default: g(() => [
|
|
2827
|
+
Ve(he(Fe(L, Z)), 1)
|
|
2828
|
+
]),
|
|
2829
|
+
_: 2
|
|
2830
|
+
}, 1040, ["title", "onClick"])) : (n(), D(I(De), S({
|
|
2831
|
+
key: 1,
|
|
2832
|
+
title: L.label,
|
|
2833
|
+
ref_for: !0
|
|
2834
|
+
}, L.attr, {
|
|
2835
|
+
onClick: (St) => L.func(w, z, Z, e.value)
|
|
2836
|
+
}), null, 16, ["title", "onClick"]))
|
|
2837
|
+
], !0)
|
|
2838
|
+
]),
|
|
2839
|
+
_: 2
|
|
2840
|
+
}, 1040)) : ve("", !0),
|
|
2841
|
+
l.$slots[L.name + "-right"] ? h(l.$slots, L.name + "-right", {
|
|
2842
|
+
key: 2,
|
|
2843
|
+
row: w,
|
|
2844
|
+
column: z,
|
|
2845
|
+
$index: Z
|
|
2846
|
+
}, void 0, !0) : ve("", !0)
|
|
2847
|
+
], 64);
|
|
2848
|
+
}), 256))
|
|
2849
|
+
]),
|
|
2850
|
+
_: 2
|
|
2851
|
+
}, 1024)
|
|
2852
|
+
]),
|
|
2853
|
+
default: g(() => {
|
|
2854
|
+
var L;
|
|
2855
|
+
return [
|
|
2856
|
+
Ve(he((L = ce(w, z, Z, e.value)) == null ? void 0 : L.label) + " ", 1)
|
|
2857
|
+
];
|
|
2858
|
+
}),
|
|
2859
|
+
_: 2
|
|
2860
|
+
}, 1040)) : (n(), D(v, { key: 2 }, {
|
|
2861
|
+
default: g(() => [
|
|
2862
|
+
(n(!0), q(W, null, U(We, (L) => (n(), q(W, null, [
|
|
2863
|
+
h(l.$slots, L.name + "-left", {
|
|
2864
|
+
row: w,
|
|
2865
|
+
column: z,
|
|
2866
|
+
$index: Z
|
|
2867
|
+
}, void 0, !0),
|
|
2868
|
+
L.attr.auth(w, z, Z) ? h(l.$slots, L.name, {
|
|
2872
2869
|
key: 0,
|
|
2873
|
-
|
|
2874
|
-
|
|
2875
|
-
|
|
2876
|
-
|
|
2877
|
-
|
|
2878
|
-
|
|
2879
|
-
|
|
2880
|
-
|
|
2881
|
-
|
|
2882
|
-
|
|
2883
|
-
|
|
2884
|
-
|
|
2885
|
-
|
|
2886
|
-
|
|
2887
|
-
|
|
2888
|
-
|
|
2889
|
-
|
|
2890
|
-
|
|
2891
|
-
|
|
2892
|
-
|
|
2893
|
-
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
|
|
2899
|
-
|
|
2870
|
+
row: w,
|
|
2871
|
+
column: z,
|
|
2872
|
+
$index: Z
|
|
2873
|
+
}, () => [
|
|
2874
|
+
L.label ? (n(), D(I(De), S({
|
|
2875
|
+
key: 0,
|
|
2876
|
+
title: L.label,
|
|
2877
|
+
ref_for: !0
|
|
2878
|
+
}, L.attr, {
|
|
2879
|
+
onClick: (Qe) => L.func(w, z, Z, e.value)
|
|
2880
|
+
}), {
|
|
2881
|
+
default: g(() => [
|
|
2882
|
+
Ve(he(Fe(L, Z)), 1)
|
|
2883
|
+
]),
|
|
2884
|
+
_: 2
|
|
2885
|
+
}, 1040, ["title", "onClick"])) : (n(), D(I(De), S({
|
|
2886
|
+
key: 1,
|
|
2887
|
+
title: L.label,
|
|
2888
|
+
ref_for: !0
|
|
2889
|
+
}, L.attr, {
|
|
2890
|
+
onClick: (Qe) => L.func(w, z, Z, e.value)
|
|
2891
|
+
}), null, 16, ["title", "onClick"]))
|
|
2892
|
+
], !0) : ve("", !0),
|
|
2893
|
+
h(l.$slots, L.name + "-right", {
|
|
2894
|
+
row: w,
|
|
2895
|
+
column: z,
|
|
2896
|
+
$index: Z
|
|
2897
|
+
}, void 0, !0)
|
|
2898
|
+
], 64))), 256))
|
|
2899
|
+
]),
|
|
2900
|
+
_: 2
|
|
2901
|
+
}, 1024))
|
|
2902
|
+
], 64);
|
|
2903
|
+
}), 256)),
|
|
2900
2904
|
h(l.$slots, "control-right", {
|
|
2901
2905
|
row: w,
|
|
2902
2906
|
column: z,
|
|
2903
|
-
$index:
|
|
2907
|
+
$index: Z
|
|
2904
2908
|
}, void 0, !0)
|
|
2905
2909
|
], !0)
|
|
2906
2910
|
], 6)
|
|
@@ -2909,22 +2913,22 @@ const kl = {
|
|
|
2909
2913
|
key: "1"
|
|
2910
2914
|
} : j.type != "selection" && j.type != "index" ? {
|
|
2911
2915
|
name: "default",
|
|
2912
|
-
fn: g(({ row: w, column: z, $index:
|
|
2913
|
-
|
|
2916
|
+
fn: g(({ row: w, column: z, $index: Z }) => [
|
|
2917
|
+
Ce(j, w, z, Z) && Z != -1 ? h(l.$slots, `${re}`, {
|
|
2914
2918
|
key: 0,
|
|
2915
2919
|
row: w,
|
|
2916
2920
|
column: z,
|
|
2917
|
-
$index:
|
|
2921
|
+
$index: Z
|
|
2918
2922
|
}, () => {
|
|
2919
2923
|
var Ze;
|
|
2920
2924
|
return [
|
|
2921
|
-
(n(),
|
|
2922
|
-
modelValue: w[
|
|
2923
|
-
"onUpdate:modelValue": (Je) => w[
|
|
2924
|
-
item: j == null ? void 0 : j.table(w, z,
|
|
2925
|
-
ctrlKey:
|
|
2926
|
-
key: `${
|
|
2927
|
-
ctrlType: (Ze = j.table(w, z,
|
|
2925
|
+
(n(), D(ut, {
|
|
2926
|
+
modelValue: w[re],
|
|
2927
|
+
"onUpdate:modelValue": (Je) => w[re] = Je,
|
|
2928
|
+
item: j == null ? void 0 : j.table(w, z, Z),
|
|
2929
|
+
ctrlKey: re,
|
|
2930
|
+
key: `${re}-${Z} -${oe.value}`,
|
|
2931
|
+
ctrlType: (Ze = j.table(w, z, Z)) != null && Ze.type ? j.table(w, z, Z).type : j.type,
|
|
2928
2932
|
model: e.value,
|
|
2929
2933
|
class: "g-ctrl-container",
|
|
2930
2934
|
t: "t",
|
|
@@ -2942,15 +2946,15 @@ const kl = {
|
|
|
2942
2946
|
}))
|
|
2943
2947
|
]), 1032, ["modelValue", "onUpdate:modelValue", "item", "ctrlKey", "ctrlType", "model", "formInfo"]))
|
|
2944
2948
|
];
|
|
2945
|
-
}, !0) : h(l.$slots, `${
|
|
2949
|
+
}, !0) : h(l.$slots, `${re}`, {
|
|
2946
2950
|
key: 1,
|
|
2947
2951
|
row: w,
|
|
2948
2952
|
column: z,
|
|
2949
|
-
$index:
|
|
2953
|
+
$index: Z
|
|
2950
2954
|
}, () => [
|
|
2951
2955
|
X("div", {
|
|
2952
|
-
innerHTML: se(j, z.formatter(w, z, w[
|
|
2953
|
-
}, null, 8,
|
|
2956
|
+
innerHTML: se(j, z.formatter(w, z, w[re], Z))
|
|
2957
|
+
}, null, 8, ql)
|
|
2954
2958
|
], !0)
|
|
2955
2959
|
]),
|
|
2956
2960
|
key: "2"
|
|
@@ -2961,11 +2965,11 @@ const kl = {
|
|
|
2961
2965
|
_: 3
|
|
2962
2966
|
}, 16, ["summary-method"]),
|
|
2963
2967
|
(ht = (at = (Ne = e.value) == null ? void 0 : Ne.table) == null ? void 0 : at.page) != null && ht.hidden ? ve("", !0) : h(l.$slots, "page", { key: 0 }, () => [
|
|
2964
|
-
Q(
|
|
2968
|
+
Q(ke, S({
|
|
2965
2969
|
"page-size": e.value.table.page.pageSize,
|
|
2966
|
-
"onUpdate:pageSize":
|
|
2970
|
+
"onUpdate:pageSize": r[3] || (r[3] = (j) => e.value.table.page.pageSize = j),
|
|
2967
2971
|
"current-page": e.value.table.page.currentPage,
|
|
2968
|
-
"onUpdate:currentPage":
|
|
2972
|
+
"onUpdate:currentPage": r[4] || (r[4] = (j) => e.value.table.page.currentPage = j)
|
|
2969
2973
|
}, e.value.table.page), {
|
|
2970
2974
|
default: g(() => [
|
|
2971
2975
|
h(l.$slots, "table-page", {}, void 0, !0)
|
|
@@ -2975,47 +2979,47 @@ const kl = {
|
|
|
2975
2979
|
], !0)
|
|
2976
2980
|
])
|
|
2977
2981
|
]),
|
|
2978
|
-
e.value.dialog.mode == "dialog" && x.value ? (n(), q("div",
|
|
2979
|
-
Q(
|
|
2982
|
+
e.value.dialog.mode == "dialog" && x.value ? (n(), q("div", Ol, [
|
|
2983
|
+
Q(G, S({
|
|
2980
2984
|
modelValue: x.value,
|
|
2981
|
-
"onUpdate:modelValue":
|
|
2985
|
+
"onUpdate:modelValue": r[8] || (r[8] = (j) => x.value = j),
|
|
2982
2986
|
fullscreen: e.value.dialog.fullScreen
|
|
2983
|
-
}, I(
|
|
2984
|
-
width: I(
|
|
2987
|
+
}, I(Me)(e.value.dialog, (j) => !["size"].includes(j)), {
|
|
2988
|
+
width: I(Tt)(e.value.dialog.width) + 35
|
|
2985
2989
|
}), {
|
|
2986
2990
|
header: g(() => {
|
|
2987
|
-
var j,
|
|
2991
|
+
var j, re, w, z;
|
|
2988
2992
|
return [
|
|
2989
|
-
X("div",
|
|
2990
|
-
X("div",
|
|
2993
|
+
X("div", xl, [
|
|
2994
|
+
X("div", Al, [
|
|
2991
2995
|
h(l.$slots, "f-header", {}, () => [
|
|
2992
2996
|
X("div", null, he(e.value.dialog.title), 1)
|
|
2993
2997
|
], !0)
|
|
2994
2998
|
]),
|
|
2995
|
-
((
|
|
2999
|
+
((re = (j = e.value) == null ? void 0 : j.dialog) == null ? void 0 : re.fullScreen) === !1 ? (n(), q("div", {
|
|
2996
3000
|
key: 0,
|
|
2997
|
-
onClick:
|
|
3001
|
+
onClick: r[5] || (r[5] = (Z) => {
|
|
2998
3002
|
e.value.dialog.fullScreen = !0;
|
|
2999
3003
|
}),
|
|
3000
3004
|
class: "max"
|
|
3001
3005
|
}, [
|
|
3002
3006
|
Q(d, null, {
|
|
3003
3007
|
default: g(() => [
|
|
3004
|
-
Q(I(
|
|
3008
|
+
Q(I(zt))
|
|
3005
3009
|
]),
|
|
3006
3010
|
_: 1
|
|
3007
3011
|
})
|
|
3008
3012
|
])) : ve("", !0),
|
|
3009
3013
|
((z = (w = e.value) == null ? void 0 : w.dialog) == null ? void 0 : z.fullScreen) === !0 ? (n(), q("div", {
|
|
3010
3014
|
key: 1,
|
|
3011
|
-
onClick:
|
|
3015
|
+
onClick: r[6] || (r[6] = (Z) => {
|
|
3012
3016
|
e.value.dialog.fullScreen = !1;
|
|
3013
3017
|
}),
|
|
3014
3018
|
class: "max"
|
|
3015
3019
|
}, [
|
|
3016
3020
|
Q(d, null, {
|
|
3017
3021
|
default: g(() => [
|
|
3018
|
-
Q(I(
|
|
3022
|
+
Q(I(Wt))
|
|
3019
3023
|
]),
|
|
3020
3024
|
_: 1
|
|
3021
3025
|
})
|
|
@@ -3024,18 +3028,18 @@ const kl = {
|
|
|
3024
3028
|
];
|
|
3025
3029
|
}),
|
|
3026
3030
|
default: g(() => [
|
|
3027
|
-
X("div",
|
|
3031
|
+
X("div", Bl, [
|
|
3028
3032
|
h(l.$slots, "table-dialog-form", { model: e.value }, () => [
|
|
3029
3033
|
Q(dt, {
|
|
3030
3034
|
modelValue: e.value,
|
|
3031
|
-
"onUpdate:modelValue":
|
|
3035
|
+
"onUpdate:modelValue": r[7] || (r[7] = (j) => e.value = j),
|
|
3032
3036
|
onSubmit: y,
|
|
3033
3037
|
onReset: m
|
|
3034
3038
|
}, me({ _: 2 }, [
|
|
3035
|
-
U(l.$slots, (j,
|
|
3036
|
-
name:
|
|
3039
|
+
U(l.$slots, (j, re, w) => ({
|
|
3040
|
+
name: re,
|
|
3037
3041
|
fn: g((z) => [
|
|
3038
|
-
h(l.$slots,
|
|
3042
|
+
h(l.$slots, re, { model: z }, void 0, !0)
|
|
3039
3043
|
])
|
|
3040
3044
|
}))
|
|
3041
3045
|
]), 1032, ["modelValue"])
|
|
@@ -3045,14 +3049,14 @@ const kl = {
|
|
|
3045
3049
|
_: 3
|
|
3046
3050
|
}, 16, ["modelValue", "fullscreen", "width"])
|
|
3047
3051
|
])) : ve("", !0),
|
|
3048
|
-
e.value.dialog.mode == "drawer" && x.value ? (n(), q("div",
|
|
3049
|
-
Q(
|
|
3052
|
+
e.value.dialog.mode == "drawer" && x.value ? (n(), q("div", Il, [
|
|
3053
|
+
Q(fe, S({
|
|
3050
3054
|
modelValue: x.value,
|
|
3051
|
-
"onUpdate:modelValue":
|
|
3052
|
-
}, I(
|
|
3055
|
+
"onUpdate:modelValue": r[10] || (r[10] = (j) => x.value = j)
|
|
3056
|
+
}, I(Me)(e.value.dialog, (j) => !["width"].includes(j))), {
|
|
3053
3057
|
header: g(() => [
|
|
3054
|
-
X("div",
|
|
3055
|
-
X("div",
|
|
3058
|
+
X("div", Ul, [
|
|
3059
|
+
X("div", Yl, [
|
|
3056
3060
|
h(l.$slots, "f-header", {}, () => [
|
|
3057
3061
|
X("div", null, he(e.value.dialog.title), 1)
|
|
3058
3062
|
], !0)
|
|
@@ -3063,14 +3067,14 @@ const kl = {
|
|
|
3063
3067
|
h(l.$slots, "table-drawer-form", { model: e.value }, () => [
|
|
3064
3068
|
Q(dt, {
|
|
3065
3069
|
modelValue: e.value,
|
|
3066
|
-
"onUpdate:modelValue":
|
|
3070
|
+
"onUpdate:modelValue": r[9] || (r[9] = (j) => e.value = j),
|
|
3067
3071
|
onSubmit: y,
|
|
3068
3072
|
onReset: m
|
|
3069
3073
|
}, me({ _: 2 }, [
|
|
3070
|
-
U(l.$slots, (j,
|
|
3071
|
-
name:
|
|
3074
|
+
U(l.$slots, (j, re, w) => ({
|
|
3075
|
+
name: re,
|
|
3072
3076
|
fn: g((z) => [
|
|
3073
|
-
h(l.$slots,
|
|
3077
|
+
h(l.$slots, re, { model: z }, void 0, !0)
|
|
3074
3078
|
])
|
|
3075
3079
|
}))
|
|
3076
3080
|
]), 1032, ["modelValue"])
|
|
@@ -3082,7 +3086,7 @@ const kl = {
|
|
|
3082
3086
|
], 64);
|
|
3083
3087
|
};
|
|
3084
3088
|
}
|
|
3085
|
-
}),
|
|
3089
|
+
}), Ll = /* @__PURE__ */ He(jl, [["__scopeId", "data-v-589329aa"]]), Rl = { class: "g-tree-table" }, Nl = { class: "g-tree-container" }, Pl = { class: "g-tree-table-container" }, Hl = /* @__PURE__ */ Object.assign({
|
|
3086
3090
|
name: "g-tree-table",
|
|
3087
3091
|
inheritAttrs: !1
|
|
3088
3092
|
}, {
|
|
@@ -3093,38 +3097,38 @@ const kl = {
|
|
|
3093
3097
|
},
|
|
3094
3098
|
emits: /* @__PURE__ */ je(["load"], ["update:modelValue"]),
|
|
3095
3099
|
setup(p, { emit: c }) {
|
|
3096
|
-
var Y, A,
|
|
3097
|
-
const t = c, e = Le(p, "modelValue"),
|
|
3098
|
-
typeof ((Y =
|
|
3099
|
-
), E = le(((
|
|
3100
|
-
var
|
|
3100
|
+
var Y, A, oe, ue;
|
|
3101
|
+
const t = c, e = Le(p, "modelValue"), o = pt(), f = le(
|
|
3102
|
+
typeof ((Y = o == null ? void 0 : o.tree) == null ? void 0 : Y.width) == "number" ? `${o.tree.width}px` : ((A = o == null ? void 0 : o.tree) == null ? void 0 : A.width) || "180px"
|
|
3103
|
+
), E = le(((oe = o == null ? void 0 : o.tree) == null ? void 0 : oe.search) === void 0 ? !0 : (ue = o == null ? void 0 : o.tree) == null ? void 0 : ue.search), x = le({}), F = le(""), _ = le(null), k = (K, ce) => {
|
|
3104
|
+
var ge, ye;
|
|
3101
3105
|
if (!K) return !0;
|
|
3102
|
-
const
|
|
3103
|
-
return
|
|
3104
|
-
}, R = (K,
|
|
3105
|
-
t("load", x.value, K,
|
|
3106
|
+
const $e = ((ye = (ge = o.tree) == null ? void 0 : ge.props) == null ? void 0 : ye.label) || "label";
|
|
3107
|
+
return ce[$e].includes(K);
|
|
3108
|
+
}, R = (K, ce) => {
|
|
3109
|
+
t("load", x.value, K, ce);
|
|
3106
3110
|
}, ae = (K) => {
|
|
3107
3111
|
x.value = K, e.value.table.load();
|
|
3108
3112
|
};
|
|
3109
|
-
return
|
|
3113
|
+
return Lt(F, (K) => {
|
|
3110
3114
|
_.value.filter(K);
|
|
3111
|
-
}), (K,
|
|
3112
|
-
const
|
|
3113
|
-
return n(), q("div",
|
|
3115
|
+
}), (K, ce) => {
|
|
3116
|
+
const $e = B("el-input"), ge = B("el-tree"), ye = B("g-table");
|
|
3117
|
+
return n(), q("div", Rl, [
|
|
3114
3118
|
X("div", {
|
|
3115
3119
|
class: "g-tree-left",
|
|
3116
3120
|
style: Ye({ width: f.value })
|
|
3117
3121
|
}, [
|
|
3118
|
-
E.value ? (n(),
|
|
3122
|
+
E.value ? (n(), D($e, {
|
|
3119
3123
|
key: 0,
|
|
3120
3124
|
modelValue: F.value,
|
|
3121
|
-
"onUpdate:modelValue":
|
|
3125
|
+
"onUpdate:modelValue": ce[0] || (ce[0] = (ne) => F.value = ne),
|
|
3122
3126
|
style: { width: "100%", padding: "0 10px", "box-sizing": "border-box" },
|
|
3123
3127
|
placeholder: "输入节点查询",
|
|
3124
3128
|
clearable: ""
|
|
3125
3129
|
}, null, 8, ["modelValue"])) : ve("", !0),
|
|
3126
|
-
X("div",
|
|
3127
|
-
Q(
|
|
3130
|
+
X("div", Nl, [
|
|
3131
|
+
Q(ge, S({
|
|
3128
3132
|
style: { width: f.value },
|
|
3129
3133
|
"filter-node-method": k,
|
|
3130
3134
|
"expand-on-click-node": !1,
|
|
@@ -3144,22 +3148,22 @@ const kl = {
|
|
|
3144
3148
|
}, [
|
|
3145
3149
|
U(K.$slots, (ne, se, ee) => ({
|
|
3146
3150
|
name: se,
|
|
3147
|
-
fn: g((
|
|
3148
|
-
h(K.$slots, se, { data:
|
|
3151
|
+
fn: g((be) => [
|
|
3152
|
+
h(K.$slots, se, { data: be }, void 0, !0)
|
|
3149
3153
|
])
|
|
3150
3154
|
}))
|
|
3151
3155
|
]), 1040, ["style"])
|
|
3152
3156
|
])
|
|
3153
3157
|
], 4),
|
|
3154
|
-
X("div",
|
|
3158
|
+
X("div", Pl, [
|
|
3155
3159
|
Q(ye, S({
|
|
3156
3160
|
modelValue: e.value,
|
|
3157
|
-
"onUpdate:modelValue":
|
|
3161
|
+
"onUpdate:modelValue": ce[1] || (ce[1] = (ne) => e.value = ne)
|
|
3158
3162
|
}, K.$attrs, { onLoad: R }), me({ _: 2 }, [
|
|
3159
3163
|
U(K.$slots, (ne, se, ee) => ({
|
|
3160
3164
|
name: se,
|
|
3161
|
-
fn: g((
|
|
3162
|
-
h(K.$slots, se, { data:
|
|
3165
|
+
fn: g((be) => [
|
|
3166
|
+
h(K.$slots, se, { data: be }, void 0, !0)
|
|
3163
3167
|
])
|
|
3164
3168
|
}))
|
|
3165
3169
|
]), 1040, ["modelValue"])
|
|
@@ -3167,14 +3171,14 @@ const kl = {
|
|
|
3167
3171
|
]);
|
|
3168
3172
|
};
|
|
3169
3173
|
}
|
|
3170
|
-
}),
|
|
3174
|
+
}), zl = /* @__PURE__ */ He(Hl, [["__scopeId", "data-v-2d8b16ed"]]), Wl = {
|
|
3171
3175
|
key: 0,
|
|
3172
3176
|
class: "op-group"
|
|
3173
|
-
},
|
|
3177
|
+
}, Gl = {
|
|
3174
3178
|
key: 1,
|
|
3175
3179
|
class: "op-items",
|
|
3176
3180
|
style: { width: "100%", height: "100%" }
|
|
3177
|
-
},
|
|
3181
|
+
}, Ql = ["title"], kt = "100px", Xl = /* @__PURE__ */ Object.assign({ name: "g-select-option" }, {
|
|
3178
3182
|
__name: "g-select-option",
|
|
3179
3183
|
props: {
|
|
3180
3184
|
columns: {
|
|
@@ -3196,45 +3200,45 @@ const kl = {
|
|
|
3196
3200
|
},
|
|
3197
3201
|
setup(p) {
|
|
3198
3202
|
const c = p;
|
|
3199
|
-
return (t, e) => c.title ? (n(), q("div",
|
|
3200
|
-
(n(!0), q(W, null, U(c.columns, (
|
|
3201
|
-
style: Ye({ width: (
|
|
3202
|
-
key:
|
|
3203
|
+
return (t, e) => c.title ? (n(), q("div", Wl, [
|
|
3204
|
+
(n(!0), q(W, null, U(c.columns, (o) => (n(), q("span", {
|
|
3205
|
+
style: Ye({ width: (o == null ? void 0 : o.width) || kt, ...o == null ? void 0 : o.titleStyle, textAlign: (o == null ? void 0 : o.align) || "center" }),
|
|
3206
|
+
key: o.key
|
|
3203
3207
|
}, [
|
|
3204
|
-
h(t.$slots, `${p.t}-title-${
|
|
3205
|
-
|
|
3208
|
+
h(t.$slots, `${p.t}-title-${o.key}`, { col: o }, () => [
|
|
3209
|
+
Ve(he(o.label), 1)
|
|
3206
3210
|
], !0)
|
|
3207
3211
|
], 4))), 128))
|
|
3208
|
-
])) : (n(), q("div",
|
|
3209
|
-
(n(!0), q(W, null, U(c.columns, (
|
|
3210
|
-
style: Ye({ width: (
|
|
3211
|
-
key:
|
|
3212
|
-
title: p.data[
|
|
3212
|
+
])) : (n(), q("div", Gl, [
|
|
3213
|
+
(n(!0), q(W, null, U(c.columns, (o) => (n(), q("span", {
|
|
3214
|
+
style: Ye({ width: (o == null ? void 0 : o.width) || kt, textAlign: (o == null ? void 0 : o.align) || "center", ...o == null ? void 0 : o.style }),
|
|
3215
|
+
key: o.key,
|
|
3216
|
+
title: p.data[o.key]
|
|
3213
3217
|
}, [
|
|
3214
|
-
h(t.$slots, `${p.t}-option-${
|
|
3215
|
-
|
|
3218
|
+
h(t.$slots, `${p.t}-option-${o.key}`, { col: o }, () => [
|
|
3219
|
+
Ve(he(p.data[o.key] ?? "-"), 1)
|
|
3216
3220
|
], !0)
|
|
3217
|
-
], 12,
|
|
3221
|
+
], 12, Ql))), 128))
|
|
3218
3222
|
]));
|
|
3219
3223
|
}
|
|
3220
|
-
}),
|
|
3224
|
+
}), Zl = /* @__PURE__ */ He(Xl, [["__scopeId", "data-v-c0ac6b77"]]), Jl = Object.freeze({}), Ft = [Ll, dt, zl, Zl];
|
|
3221
3225
|
let ft = {};
|
|
3222
|
-
const
|
|
3226
|
+
const na = {
|
|
3223
3227
|
install: (p, c = {}) => {
|
|
3224
|
-
ft = Object.freeze({ ...
|
|
3228
|
+
ft = Object.freeze({ ...Jl, ...c }), Ft.forEach((t) => {
|
|
3225
3229
|
p.component(t.name, t);
|
|
3226
3230
|
}), p.provide("options", ft), p.config.globalProperties.$openModal = ct;
|
|
3227
3231
|
}
|
|
3228
|
-
},
|
|
3232
|
+
}, Kl = (p) => ({ dialog: Ot, drawer: xt })[p] || null, ct = (p = {}, c = "dialog") => {
|
|
3229
3233
|
if (typeof document > "u") return () => {
|
|
3230
3234
|
};
|
|
3231
3235
|
const t = document.createElement("div");
|
|
3232
3236
|
let e = () => {
|
|
3233
3237
|
};
|
|
3234
|
-
const
|
|
3235
|
-
if (!
|
|
3238
|
+
const o = Kl(c);
|
|
3239
|
+
if (!o) return () => {
|
|
3236
3240
|
};
|
|
3237
|
-
const f = le(!0), E =
|
|
3241
|
+
const f = le(!0), E = Rt({
|
|
3238
3242
|
setup() {
|
|
3239
3243
|
return e = () => {
|
|
3240
3244
|
f.value = !1, setTimeout(() => {
|
|
@@ -3242,7 +3246,7 @@ const ua = {
|
|
|
3242
3246
|
}, 300);
|
|
3243
3247
|
}, () => {
|
|
3244
3248
|
var x, F, _;
|
|
3245
|
-
return Ie(
|
|
3249
|
+
return Ie(o, {
|
|
3246
3250
|
modelValue: f.value,
|
|
3247
3251
|
"onUpdate:modelValue": (k) => f.value = k,
|
|
3248
3252
|
appendToBody: !0,
|
|
@@ -3257,11 +3261,11 @@ const ua = {
|
|
|
3257
3261
|
};
|
|
3258
3262
|
}
|
|
3259
3263
|
});
|
|
3260
|
-
return
|
|
3264
|
+
return Ft.forEach((x) => {
|
|
3261
3265
|
E.component(x.name, x);
|
|
3262
|
-
}), E.provide("options", ft), E.use(
|
|
3266
|
+
}), E.provide("options", ft), E.use(qt, { locale: Qt }), document.body.appendChild(t), E.mount(t), e;
|
|
3263
3267
|
};
|
|
3264
|
-
function
|
|
3268
|
+
function Tt(p, c = window.innerWidth) {
|
|
3265
3269
|
if (typeof p == "number")
|
|
3266
3270
|
return p;
|
|
3267
3271
|
if (p.endsWith("px"))
|
|
@@ -3282,29 +3286,29 @@ function Ft(p, c = window.innerWidth) {
|
|
|
3282
3286
|
return new Function("return " + x)();
|
|
3283
3287
|
throw new Error("Invalid calc expression");
|
|
3284
3288
|
};
|
|
3285
|
-
const
|
|
3286
|
-
return f(
|
|
3289
|
+
const o = p.slice(5, -1).trim();
|
|
3290
|
+
return f(o.replace(/([0-9.]+)([a-z%]+)/g, (x, F, _) => Tt(F + _, c)));
|
|
3287
3291
|
}
|
|
3288
3292
|
throw new Error("Unsupported unit in value: " + p);
|
|
3289
3293
|
}
|
|
3290
3294
|
const Se = (...p) => {
|
|
3291
|
-
const c = {}, t = (e,
|
|
3292
|
-
e[f] = typeof
|
|
3295
|
+
const c = {}, t = (e, o) => (Object.keys(o).forEach((f) => {
|
|
3296
|
+
e[f] = typeof o[f] == "object" && !Array.isArray(o[f]) ? t(e[f] || {}, o[f]) : o[f];
|
|
3293
3297
|
}), e);
|
|
3294
3298
|
return p.forEach((e = {}) => t(c, e)), c;
|
|
3295
3299
|
};
|
|
3296
|
-
function
|
|
3300
|
+
function Me(p, c = (t, e) => c(t, e)) {
|
|
3297
3301
|
const t = {};
|
|
3298
3302
|
for (const e in p)
|
|
3299
3303
|
p.hasOwnProperty(e) && c(e, p[e]) && (t[e] = p[e]);
|
|
3300
3304
|
return t;
|
|
3301
3305
|
}
|
|
3302
|
-
function
|
|
3306
|
+
function ea(p, c, t = "value", e = "label", o = "children") {
|
|
3303
3307
|
for (const f of p) {
|
|
3304
3308
|
if (f[t] === c)
|
|
3305
3309
|
return f[e];
|
|
3306
|
-
if (f[
|
|
3307
|
-
const E =
|
|
3310
|
+
if (f[o] && f[o].length > 0) {
|
|
3311
|
+
const E = ea(f[o], c, t, e, o);
|
|
3308
3312
|
if (E)
|
|
3309
3313
|
return E;
|
|
3310
3314
|
}
|
|
@@ -3316,7 +3320,7 @@ function mt(p) {
|
|
|
3316
3320
|
const c = ["角", "分"], t = ["零", "壹", "贰", "叁", "肆", "伍", "陆", "柒", "捌", "玖"], e = [
|
|
3317
3321
|
["元", "万", "亿"],
|
|
3318
3322
|
["", "拾", "佰", "仟"]
|
|
3319
|
-
],
|
|
3323
|
+
], o = p < 0 ? "欠" : "";
|
|
3320
3324
|
p = Math.abs(p);
|
|
3321
3325
|
let f = "";
|
|
3322
3326
|
for (let E = 0; E < c.length; E++)
|
|
@@ -3328,9 +3332,9 @@ function mt(p) {
|
|
|
3328
3332
|
x = t[p % 10] + e[1][F] + x, p = Math.floor(p / 10);
|
|
3329
3333
|
f = x.replace(/(零.)*零$/, "").replace(/^$/, "零") + e[0][E] + f;
|
|
3330
3334
|
}
|
|
3331
|
-
return
|
|
3335
|
+
return o + f.replace(/(零.)*零元/, "元").replace(/(零.)+/g, "零").replace(/^整$/, "零元整");
|
|
3332
3336
|
}
|
|
3333
|
-
function
|
|
3337
|
+
function ta(p) {
|
|
3334
3338
|
if (typeof p != "number" || isNaN(p) || !isFinite(p))
|
|
3335
3339
|
return "0.00";
|
|
3336
3340
|
const c = p.toFixed(2), [t, e] = c.split(".");
|
|
@@ -3367,11 +3371,11 @@ const pe = {
|
|
|
3367
3371
|
};
|
|
3368
3372
|
export {
|
|
3369
3373
|
pe as CT,
|
|
3370
|
-
|
|
3371
|
-
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
|
|
3374
|
+
Tt as convertToPx,
|
|
3375
|
+
na as default,
|
|
3376
|
+
Me as filterObject,
|
|
3377
|
+
ea as findTreeLabelByValue,
|
|
3378
|
+
ta as formatAmount,
|
|
3375
3379
|
Se as mergeObjects,
|
|
3376
3380
|
mt as moneyToChinese,
|
|
3377
3381
|
ct as openModal
|