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