vue-2024-ui 0.1.24 → 0.1.26
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 +817 -818
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { mergeModels as Ne, useModel as Pe, ref as le, nextTick as et, onMounted as
|
|
3
|
-
import { Plus as
|
|
4
|
-
import
|
|
5
|
-
import { Dexie as
|
|
6
|
-
var
|
|
1
|
+
import Bt, { ElForm as dt, ElButtonGroup as ft, ElButton as De, ElPopover as ht, ElMessage as Fe, ElMessageBox as Tt, ElDialog as Yt, ElDrawer as Ut } from "element-plus";
|
|
2
|
+
import { mergeModels as Ne, useModel as Pe, ref as le, nextTick as et, onMounted as rt, computed as Je, resolveComponent as I, openBlock as n, createElementBlock as F, Fragment as G, createElementVNode as X, createBlock as C, 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 Z, normalizeProps as gt, useSlots as St, inject as _t, useAttrs as kt, onUnmounted as Rt, normalizeStyle as Ie, withModifiers as ct, resolveDynamicComponent as Ye, guardReactiveProps as Lt, Transition as jt, withDirectives as zt, vShow as Ht, h as Ae, onBeforeUnmount as Nt, normalizeClass as xt, watchEffect as Pt, watch as Wt, createApp as Xt } from "vue";
|
|
3
|
+
import { Plus as Gt, ZoomIn as Qt, Delete as Zt, DocumentCopy as Jt, FullScreen as Kt, CopyDocument as el } from "@element-plus/icons-vue";
|
|
4
|
+
import Ft from "sortablejs";
|
|
5
|
+
import { Dexie as tl } from "dexie";
|
|
6
|
+
var ll = {
|
|
7
7
|
name: "zh-cn",
|
|
8
8
|
el: {
|
|
9
9
|
breadcrumb: {
|
|
@@ -180,67 +180,67 @@ var tl = {
|
|
|
180
180
|
indicator: "幻灯片切换至索引 {index}"
|
|
181
181
|
}
|
|
182
182
|
}
|
|
183
|
-
},
|
|
184
|
-
function
|
|
185
|
-
return
|
|
183
|
+
}, al = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
184
|
+
function rl(d) {
|
|
185
|
+
return d && d.__esModule && Object.prototype.hasOwnProperty.call(d, "default") ? d.default : d;
|
|
186
186
|
}
|
|
187
|
-
var
|
|
188
|
-
(function(
|
|
189
|
-
(function(
|
|
190
|
-
|
|
191
|
-
})(
|
|
192
|
-
var
|
|
193
|
-
var
|
|
194
|
-
return "[" + p + (
|
|
195
|
-
} }, ge = function(p,
|
|
187
|
+
var qt = { exports: {} };
|
|
188
|
+
(function(d, f) {
|
|
189
|
+
(function(a, t) {
|
|
190
|
+
d.exports = t();
|
|
191
|
+
})(al, function() {
|
|
192
|
+
var a = 1e3, t = 6e4, e = 36e5, i = "millisecond", E = "second", x = "minute", T = "hour", D = "day", $ = "week", z = "month", te = "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+)?$/, K = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, 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
|
+
var r = ["th", "st", "nd", "rd"], v = p % 100;
|
|
194
|
+
return "[" + p + (r[(v - 20) % 10] || r[v] || r[0]) + "]";
|
|
195
|
+
} }, ge = function(p, r, v) {
|
|
196
196
|
var g = String(p);
|
|
197
|
-
return !g || g.length >=
|
|
197
|
+
return !g || g.length >= r ? p : "" + Array(r + 1 - g.length).join(v) + p;
|
|
198
198
|
}, be = { s: ge, z: function(p) {
|
|
199
|
-
var
|
|
200
|
-
return (
|
|
201
|
-
}, m: function p(
|
|
202
|
-
if (
|
|
203
|
-
var g = 12 * (v.year() -
|
|
204
|
-
return +(-(g + (v - s) / (
|
|
199
|
+
var r = -p.utcOffset(), v = Math.abs(r), g = Math.floor(v / 60), s = v % 60;
|
|
200
|
+
return (r <= 0 ? "+" : "-") + ge(g, 2, "0") + ":" + ge(s, 2, "0");
|
|
201
|
+
}, m: function p(r, v) {
|
|
202
|
+
if (r.date() < v.date()) return -p(v, r);
|
|
203
|
+
var g = 12 * (v.year() - r.year()) + (v.month() - r.month()), s = r.clone().add(g, z), k = v - s < 0, V = r.clone().add(g + (k ? -1 : 1), z);
|
|
204
|
+
return +(-(g + (v - s) / (k ? 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: z, y: q, w
|
|
208
|
+
return { M: z, y: q, w: $, d: D, D: B, h: T, m: x, s: E, ms: i, Q: te }[p] || String(p || "").toLowerCase().replace(/s$/, "");
|
|
209
209
|
}, u: function(p) {
|
|
210
210
|
return p === void 0;
|
|
211
211
|
} }, ie = "en", de = {};
|
|
212
212
|
de[ie] = ve;
|
|
213
213
|
var fe = "$isDayjsObject", ae = function(p) {
|
|
214
214
|
return p instanceof o || !(!p || !p[fe]);
|
|
215
|
-
}, $e = function p(
|
|
215
|
+
}, $e = function p(r, v, g) {
|
|
216
216
|
var s;
|
|
217
|
-
if (!
|
|
218
|
-
if (typeof
|
|
219
|
-
var
|
|
220
|
-
de[
|
|
221
|
-
var V =
|
|
217
|
+
if (!r) return ie;
|
|
218
|
+
if (typeof r == "string") {
|
|
219
|
+
var k = r.toLowerCase();
|
|
220
|
+
de[k] && (s = k), v && (de[k] = v, s = k);
|
|
221
|
+
var V = r.split("-");
|
|
222
222
|
if (!s && V.length > 1) return p(V[0]);
|
|
223
223
|
} else {
|
|
224
|
-
var j =
|
|
225
|
-
de[j] =
|
|
224
|
+
var j = r.name;
|
|
225
|
+
de[j] = r, s = j;
|
|
226
226
|
}
|
|
227
227
|
return !g && s && (ie = s), s || !g && ie;
|
|
228
|
-
}, ne = function(p,
|
|
228
|
+
}, ne = function(p, r) {
|
|
229
229
|
if (ae(p)) return p.clone();
|
|
230
|
-
var v = typeof
|
|
230
|
+
var v = typeof r == "object" ? r : {};
|
|
231
231
|
return v.date = p, v.args = arguments, new o(v);
|
|
232
232
|
}, b = be;
|
|
233
|
-
b.l = $e, b.i = ae, b.w = function(p,
|
|
234
|
-
return ne(p, { locale:
|
|
233
|
+
b.l = $e, b.i = ae, b.w = function(p, r) {
|
|
234
|
+
return ne(p, { locale: r.$L, utc: r.$u, x: r.$x, $offset: r.$offset });
|
|
235
235
|
};
|
|
236
236
|
var o = function() {
|
|
237
237
|
function p(v) {
|
|
238
238
|
this.$L = $e(v.locale, null, !0), this.parse(v), this.$x = this.$x || v.x || {}, this[fe] = !0;
|
|
239
239
|
}
|
|
240
|
-
var
|
|
241
|
-
return
|
|
240
|
+
var r = p.prototype;
|
|
241
|
+
return r.parse = function(v) {
|
|
242
242
|
this.$d = function(g) {
|
|
243
|
-
var s = g.date,
|
|
243
|
+
var s = g.date, k = 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);
|
|
@@ -248,47 +248,47 @@ var Ft = { exports: {} };
|
|
|
248
248
|
var V = s.match(re);
|
|
249
249
|
if (V) {
|
|
250
250
|
var j = V[2] - 1 || 0, J = (V[7] || "0").substring(0, 3);
|
|
251
|
-
return
|
|
251
|
+
return k ? new Date(Date.UTC(V[1], j, V[3] || 1, V[4] || 0, V[5] || 0, V[6] || 0, J)) : new Date(V[1], j, V[3] || 1, V[4] || 0, V[5] || 0, V[6] || 0, J);
|
|
252
252
|
}
|
|
253
253
|
}
|
|
254
254
|
return new Date(s);
|
|
255
255
|
}(v), this.init();
|
|
256
|
-
},
|
|
256
|
+
}, r.init = function() {
|
|
257
257
|
var v = this.$d;
|
|
258
258
|
this.$y = v.getFullYear(), this.$M = v.getMonth(), this.$D = v.getDate(), this.$W = v.getDay(), this.$H = v.getHours(), this.$m = v.getMinutes(), this.$s = v.getSeconds(), this.$ms = v.getMilliseconds();
|
|
259
|
-
},
|
|
259
|
+
}, r.$utils = function() {
|
|
260
260
|
return b;
|
|
261
|
-
},
|
|
261
|
+
}, r.isValid = function() {
|
|
262
262
|
return this.$d.toString() !== se;
|
|
263
|
-
},
|
|
263
|
+
}, r.isSame = function(v, g) {
|
|
264
264
|
var s = ne(v);
|
|
265
265
|
return this.startOf(g) <= s && s <= this.endOf(g);
|
|
266
|
-
},
|
|
266
|
+
}, r.isAfter = function(v, g) {
|
|
267
267
|
return ne(v) < this.startOf(g);
|
|
268
|
-
},
|
|
268
|
+
}, r.isBefore = function(v, g) {
|
|
269
269
|
return this.endOf(g) < ne(v);
|
|
270
|
-
},
|
|
270
|
+
}, r.$g = function(v, g, s) {
|
|
271
271
|
return b.u(v) ? this[g] : this.set(s, v);
|
|
272
|
-
},
|
|
272
|
+
}, r.unix = function() {
|
|
273
273
|
return Math.floor(this.valueOf() / 1e3);
|
|
274
|
-
},
|
|
274
|
+
}, r.valueOf = function() {
|
|
275
275
|
return this.$d.getTime();
|
|
276
|
-
},
|
|
277
|
-
var s = this,
|
|
276
|
+
}, r.startOf = function(v, g) {
|
|
277
|
+
var s = this, k = !!b.u(g) || g, V = b.p(v), j = function(Se, we) {
|
|
278
278
|
var xe = b.w(s.$u ? Date.UTC(s.$y, we, Se) : new Date(s.$y, we, Se), s);
|
|
279
|
-
return
|
|
279
|
+
return k ? xe : xe.endOf(D);
|
|
280
280
|
}, J = function(Se, we) {
|
|
281
|
-
return b.w(s.toDate()[Se].apply(s.toDate("s"), (
|
|
281
|
+
return b.w(s.toDate()[Se].apply(s.toDate("s"), (k ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(we)), s);
|
|
282
282
|
}, Y = this.$W, O = this.$M, ue = this.$D, ke = "set" + (this.$u ? "UTC" : "");
|
|
283
283
|
switch (V) {
|
|
284
284
|
case q:
|
|
285
|
-
return
|
|
285
|
+
return k ? j(1, 0) : j(31, 11);
|
|
286
286
|
case z:
|
|
287
|
-
return
|
|
288
|
-
case
|
|
287
|
+
return k ? j(1, O) : j(0, O + 1);
|
|
288
|
+
case $:
|
|
289
289
|
var _e = this.$locale().weekStart || 0, Te = (Y < _e ? Y + 7 : Y) - _e;
|
|
290
|
-
return j(
|
|
291
|
-
case
|
|
290
|
+
return j(k ? ue - Te : ue + (6 - Te), O);
|
|
291
|
+
case D:
|
|
292
292
|
case B:
|
|
293
293
|
return J(ke + "Hours", 0);
|
|
294
294
|
case T:
|
|
@@ -300,46 +300,46 @@ var Ft = { exports: {} };
|
|
|
300
300
|
default:
|
|
301
301
|
return this.clone();
|
|
302
302
|
}
|
|
303
|
-
},
|
|
303
|
+
}, r.endOf = function(v) {
|
|
304
304
|
return this.startOf(v, !1);
|
|
305
|
-
},
|
|
306
|
-
var s,
|
|
307
|
-
if (
|
|
305
|
+
}, r.$set = function(v, g) {
|
|
306
|
+
var s, k = b.p(v), V = "set" + (this.$u ? "UTC" : ""), j = (s = {}, s[D] = V + "Date", s[B] = V + "Date", s[z] = V + "Month", s[q] = V + "FullYear", s[T] = V + "Hours", s[x] = V + "Minutes", s[E] = V + "Seconds", s[i] = V + "Milliseconds", s)[k], J = k === D ? this.$D + (g - this.$W) : g;
|
|
307
|
+
if (k === z || k === q) {
|
|
308
308
|
var Y = this.clone().set(B, 1);
|
|
309
309
|
Y.$d[j](J), Y.init(), this.$d = Y.set(B, Math.min(this.$D, Y.daysInMonth())).$d;
|
|
310
310
|
} else j && this.$d[j](J);
|
|
311
311
|
return this.init(), this;
|
|
312
|
-
},
|
|
312
|
+
}, r.set = function(v, g) {
|
|
313
313
|
return this.clone().$set(v, g);
|
|
314
|
-
},
|
|
314
|
+
}, r.get = function(v) {
|
|
315
315
|
return this[b.p(v)]();
|
|
316
|
-
},
|
|
317
|
-
var s,
|
|
316
|
+
}, r.add = function(v, g) {
|
|
317
|
+
var s, k = this;
|
|
318
318
|
v = Number(v);
|
|
319
319
|
var V = b.p(g), j = function(O) {
|
|
320
|
-
var ue = ne(
|
|
321
|
-
return b.w(ue.date(ue.date() + Math.round(O * v)),
|
|
320
|
+
var ue = ne(k);
|
|
321
|
+
return b.w(ue.date(ue.date() + Math.round(O * v)), k);
|
|
322
322
|
};
|
|
323
323
|
if (V === z) return this.set(z, this.$M + v);
|
|
324
324
|
if (V === q) return this.set(q, this.$y + v);
|
|
325
|
-
if (V ===
|
|
326
|
-
if (V ===
|
|
327
|
-
var J = (s = {}, s[x] = t, s[T] = e, s[E] =
|
|
325
|
+
if (V === D) return j(1);
|
|
326
|
+
if (V === $) return j(7);
|
|
327
|
+
var J = (s = {}, s[x] = t, s[T] = e, s[E] = a, s)[V] || 1, Y = this.$d.getTime() + v * J;
|
|
328
328
|
return b.w(Y, this);
|
|
329
|
-
},
|
|
329
|
+
}, r.subtract = function(v, g) {
|
|
330
330
|
return this.add(-1 * v, g);
|
|
331
|
-
},
|
|
331
|
+
}, r.format = function(v) {
|
|
332
332
|
var g = this, s = this.$locale();
|
|
333
333
|
if (!this.isValid()) return s.invalidDate || se;
|
|
334
|
-
var
|
|
335
|
-
return we && (we[xe] || we(g,
|
|
334
|
+
var k = v || "YYYY-MM-DDTHH:mm:ssZ", V = b.z(this), j = this.$H, J = 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, k)) || Ue[xe].slice(0, Re);
|
|
336
336
|
}, Te = function(we) {
|
|
337
337
|
return b.s(j % 12 || 12, we, "0");
|
|
338
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
|
|
342
|
+
return k.replace(K, function(we, xe) {
|
|
343
343
|
return xe || function(Ue) {
|
|
344
344
|
switch (Ue) {
|
|
345
345
|
case "YY":
|
|
@@ -394,98 +394,98 @@ var Ft = { exports: {} };
|
|
|
394
394
|
return null;
|
|
395
395
|
}(we) || V.replace(":", "");
|
|
396
396
|
});
|
|
397
|
-
},
|
|
397
|
+
}, r.utcOffset = function() {
|
|
398
398
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
399
|
-
},
|
|
400
|
-
var
|
|
399
|
+
}, r.diff = function(v, g, s) {
|
|
400
|
+
var k, V = this, j = b.p(g), J = ne(v), Y = (J.utcOffset() - this.utcOffset()) * t, O = this - J, ue = function() {
|
|
401
401
|
return b.m(V, J);
|
|
402
402
|
};
|
|
403
403
|
switch (j) {
|
|
404
404
|
case q:
|
|
405
|
-
|
|
405
|
+
k = ue() / 12;
|
|
406
406
|
break;
|
|
407
407
|
case z:
|
|
408
|
-
|
|
408
|
+
k = ue();
|
|
409
409
|
break;
|
|
410
410
|
case te:
|
|
411
|
-
|
|
411
|
+
k = ue() / 3;
|
|
412
412
|
break;
|
|
413
|
-
case
|
|
414
|
-
|
|
413
|
+
case $:
|
|
414
|
+
k = (O - Y) / 6048e5;
|
|
415
415
|
break;
|
|
416
|
-
case
|
|
417
|
-
|
|
416
|
+
case D:
|
|
417
|
+
k = (O - Y) / 864e5;
|
|
418
418
|
break;
|
|
419
419
|
case T:
|
|
420
|
-
|
|
420
|
+
k = O / e;
|
|
421
421
|
break;
|
|
422
422
|
case x:
|
|
423
|
-
|
|
423
|
+
k = O / t;
|
|
424
424
|
break;
|
|
425
425
|
case E:
|
|
426
|
-
|
|
426
|
+
k = O / a;
|
|
427
427
|
break;
|
|
428
428
|
default:
|
|
429
|
-
|
|
429
|
+
k = O;
|
|
430
430
|
}
|
|
431
|
-
return s ?
|
|
432
|
-
},
|
|
431
|
+
return s ? k : b.a(k);
|
|
432
|
+
}, r.daysInMonth = function() {
|
|
433
433
|
return this.endOf(z).$D;
|
|
434
|
-
},
|
|
434
|
+
}, r.$locale = function() {
|
|
435
435
|
return de[this.$L];
|
|
436
|
-
},
|
|
436
|
+
}, r.locale = function(v, g) {
|
|
437
437
|
if (!v) return this.$L;
|
|
438
|
-
var s = this.clone(),
|
|
439
|
-
return
|
|
440
|
-
},
|
|
438
|
+
var s = this.clone(), k = $e(v, g, !0);
|
|
439
|
+
return k && (s.$L = k), s;
|
|
440
|
+
}, r.clone = function() {
|
|
441
441
|
return b.w(this.$d, this);
|
|
442
|
-
},
|
|
442
|
+
}, r.toDate = function() {
|
|
443
443
|
return new Date(this.valueOf());
|
|
444
|
-
},
|
|
444
|
+
}, r.toJSON = function() {
|
|
445
445
|
return this.isValid() ? this.toISOString() : null;
|
|
446
|
-
},
|
|
446
|
+
}, r.toISOString = function() {
|
|
447
447
|
return this.$d.toISOString();
|
|
448
|
-
},
|
|
448
|
+
}, r.toString = function() {
|
|
449
449
|
return this.$d.toUTCString();
|
|
450
450
|
}, p;
|
|
451
|
-
}(),
|
|
452
|
-
return ne.prototype =
|
|
453
|
-
|
|
454
|
-
return this.$g(
|
|
451
|
+
}(), _ = o.prototype;
|
|
452
|
+
return ne.prototype = _, [["$ms", i], ["$s", E], ["$m", x], ["$H", T], ["$W", D], ["$M", z], ["$y", q], ["$D", B]].forEach(function(p) {
|
|
453
|
+
_[p[1]] = function(r) {
|
|
454
|
+
return this.$g(r, p[0], p[1]);
|
|
455
455
|
};
|
|
456
|
-
}), ne.extend = function(p,
|
|
457
|
-
return p.$i || (p(
|
|
456
|
+
}), ne.extend = function(p, r) {
|
|
457
|
+
return p.$i || (p(r, o, ne), p.$i = !0), ne;
|
|
458
458
|
}, ne.locale = $e, ne.isDayjs = ae, ne.unix = function(p) {
|
|
459
459
|
return ne(1e3 * p);
|
|
460
460
|
}, ne.en = de[ie], ne.Ls = de, ne.p = {}, ne;
|
|
461
461
|
});
|
|
462
|
-
})(
|
|
463
|
-
var
|
|
464
|
-
const yt = /* @__PURE__ */
|
|
465
|
-
const
|
|
462
|
+
})(qt);
|
|
463
|
+
var ol = qt.exports;
|
|
464
|
+
const yt = /* @__PURE__ */ rl(ol), We = (d, f) => {
|
|
465
|
+
const a = d.__vccOpts || d;
|
|
466
466
|
for (const [t, e] of f)
|
|
467
|
-
|
|
468
|
-
return
|
|
469
|
-
},
|
|
467
|
+
a[t] = e;
|
|
468
|
+
return a;
|
|
469
|
+
}, ul = {
|
|
470
470
|
style: { display: "flex", width: "100%" },
|
|
471
471
|
class: "g-ctrl-container"
|
|
472
|
-
},
|
|
472
|
+
}, nl = { style: { width: "var(--up-width)", height: "var(--up-height)", position: "relative", "box-sizing": "border-box" } }, sl = {
|
|
473
473
|
key: 19,
|
|
474
474
|
style: { position: "relative" }
|
|
475
|
-
},
|
|
475
|
+
}, il = ["title"], dl = { key: 20 }, fl = { key: 21 }, cl = { key: 22 }, ml = ["innerHTML"], pl = { key: 23 }, vl = ["innerHTML"], hl = ["innerHTML"], yl = /* @__PURE__ */ Object.assign({ inheritAttrs: !1 }, {
|
|
476
476
|
__name: "g-ctrl",
|
|
477
477
|
props: /* @__PURE__ */ Ne(["t", "ctrlKey", "item", "model", "ctrlType", "formInfo"], {
|
|
478
478
|
modelValue: { required: !0 },
|
|
479
479
|
modelModifiers: {}
|
|
480
480
|
}),
|
|
481
481
|
emits: ["update:modelValue"],
|
|
482
|
-
setup(
|
|
482
|
+
setup(d) {
|
|
483
483
|
var $e, ne;
|
|
484
|
-
const f = Pe(
|
|
484
|
+
const f = Pe(d, "modelValue"), a = d, t = le(a.item || {}), e = le(a.ctrlKey), i = le(a.ctrlType), E = le(a.model), x = le([]), T = le([]), D = le(!1), $ = le(!1), z = () => Object.keys(St()).filter((b) => b.startsWith(`${a.t}-${e}-`)).map((b) => b.replace(`${a.t}-${e}-`, "")), te = le({
|
|
485
485
|
multiple: !1,
|
|
486
486
|
"show-file-list": !1,
|
|
487
487
|
"file-list": [],
|
|
488
|
-
showDel: ($e = t.value) != null && $e.showDel ? (ne = t.value) == null ? void 0 : ne.showDel :
|
|
488
|
+
showDel: ($e = t.value) != null && $e.showDel ? (ne = t.value) == null ? void 0 : ne.showDel : a.t !== "t"
|
|
489
489
|
}), q = le(t.value.innerHtml), B = (b) => [
|
|
490
490
|
"year",
|
|
491
491
|
"years",
|
|
@@ -526,49 +526,49 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
526
526
|
}), ve = async (b = "options") => {
|
|
527
527
|
var o;
|
|
528
528
|
try {
|
|
529
|
-
const
|
|
530
|
-
if (typeof
|
|
531
|
-
T.value = [{ label:
|
|
529
|
+
const _ = await ((o = t.value) == null ? void 0 : o.getDicts(a.formInfo));
|
|
530
|
+
if (typeof _ == "string")
|
|
531
|
+
T.value = [{ label: _, value: f.value }];
|
|
532
532
|
else {
|
|
533
|
-
const p =
|
|
534
|
-
...
|
|
535
|
-
value:
|
|
536
|
-
label:
|
|
533
|
+
const p = _ == null ? void 0 : _.map((r, v) => ({
|
|
534
|
+
...r,
|
|
535
|
+
value: r.value ?? r.label ?? v,
|
|
536
|
+
label: r.label || "未知选项"
|
|
537
537
|
}));
|
|
538
538
|
T.value = p || [];
|
|
539
539
|
}
|
|
540
|
-
} catch (
|
|
541
|
-
throw console.error("获取选项失败:",
|
|
540
|
+
} catch (_) {
|
|
541
|
+
throw console.error("获取选项失败:", _), _;
|
|
542
542
|
}
|
|
543
543
|
}, ge = () => {
|
|
544
544
|
var b, o;
|
|
545
|
-
t.value.noSearch !== !0 &&
|
|
545
|
+
t.value.noSearch !== !0 && a.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
548
|
}, ie = (b) => {
|
|
549
|
-
|
|
549
|
+
D.value = !0;
|
|
550
550
|
}, de = (b) => {
|
|
551
|
-
b.preventDefault(), b.stopPropagation(),
|
|
551
|
+
b.preventDefault(), b.stopPropagation(), D.value = !0;
|
|
552
552
|
}, fe = le(null);
|
|
553
|
-
|
|
554
|
-
var
|
|
555
|
-
t.value && t.value["remote-method"] && (re.value["remote-method"] = K), (p = (
|
|
556
|
-
const b = (s,
|
|
557
|
-
typeof t.value.getDicts == "function" && ve(
|
|
558
|
-
console.error(`Failed to load ${
|
|
553
|
+
rt(async () => {
|
|
554
|
+
var _, p, r, v, g;
|
|
555
|
+
t.value && t.value["remote-method"] && (re.value["remote-method"] = K), (p = (_ = E.value[e.value]) == null ? void 0 : _.options) != null && p.length && (T.value = E.value[e.value].options);
|
|
556
|
+
const b = (s, k = "options", V = E.value[e.value]) => {
|
|
557
|
+
typeof t.value.getDicts == "function" && ve(k).catch((j) => {
|
|
558
|
+
console.error(`Failed to load ${k} 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(i.value) && b(i.value), i.value === he.TREESELECT && await (async () => {
|
|
562
562
|
try {
|
|
563
|
-
typeof t.value.getDicts == "function" ? x.value = await t.value.getDicts(
|
|
564
|
-
} catch (
|
|
565
|
-
console.error("Failed to load data for tree-select:",
|
|
563
|
+
typeof t.value.getDicts == "function" ? x.value = await t.value.getDicts(a.formInfo) : x.value = T.value;
|
|
564
|
+
} catch (k) {
|
|
565
|
+
console.error("Failed to load data for tree-select:", k);
|
|
566
566
|
}
|
|
567
|
-
})(),
|
|
568
|
-
let s = t.value.type ||
|
|
569
|
-
(s === void 0 ||
|
|
567
|
+
})(), a.t == "q") {
|
|
568
|
+
let s = t.value.type || i.value;
|
|
569
|
+
(s === void 0 || i.value === "input" || s == he.NUMBER || s == he.EMAIL || s == "url" || s == "text") && t.value.onKeyup == null && (t.value.onKeyup = (k) => {
|
|
570
570
|
var V, j;
|
|
571
|
-
(
|
|
571
|
+
(k.keyCode === 13 || k.key === "Enter") && ((j = (V = E.value) == null ? void 0 : V.table) == null || j.load());
|
|
572
572
|
}), [
|
|
573
573
|
"radio",
|
|
574
574
|
"switch",
|
|
@@ -585,12 +585,12 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
585
585
|
"datetime",
|
|
586
586
|
"datetimerange",
|
|
587
587
|
"week"
|
|
588
|
-
].includes(s) && t.value.onChange === void 0 && (t.value.onChange = (
|
|
588
|
+
].includes(s) && t.value.onChange === void 0 && (t.value.onChange = (k) => {
|
|
589
589
|
var V, j;
|
|
590
590
|
(j = (V = E.value) == null ? void 0 : V.table) == null || j.load();
|
|
591
591
|
});
|
|
592
592
|
}
|
|
593
|
-
|
|
593
|
+
i.value == "image" && (t.value.width && ((r = fe.value) != null && r.$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
595
|
const ae = Je(() => {
|
|
596
596
|
var b;
|
|
@@ -598,70 +598,70 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
598
598
|
});
|
|
599
599
|
return (b, o) => {
|
|
600
600
|
var H, N, Q, Ee, Ce, Le;
|
|
601
|
-
const
|
|
601
|
+
const _ = I("el-image-viewer"), p = I("el-radio"), r = I("el-radio-group"), v = I("el-radio-button"), g = I("el-checkbox"), s = I("el-checkbox-group"), k = I("el-checkbox-button"), V = I("g-select-option"), j = I("el-option"), J = 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"), ot = I("el-image"), tt = I("el-tooltip"), ut = I("el-upload"), nt = I("el-autocomplete"), st = I("el-input-number"), lt = I("el-input"), l = I("el-link"), u = I("el-text"), c = I("el-avatar"), M = I("el-tag");
|
|
602
602
|
return n(), F(G, null, [
|
|
603
603
|
X("div", null, [
|
|
604
|
-
|
|
604
|
+
D.value ? (n(), C(_, {
|
|
605
605
|
key: 0,
|
|
606
606
|
teleported: !0,
|
|
607
607
|
"url-list": ae.value,
|
|
608
|
-
onClose: o[0] || (o[0] = (m) =>
|
|
608
|
+
onClose: o[0] || (o[0] = (m) => D.value = !1)
|
|
609
609
|
}, null, 8, ["url-list"])) : pe("", !0)
|
|
610
610
|
]),
|
|
611
|
-
X("div",
|
|
612
|
-
|
|
611
|
+
X("div", ul, [
|
|
612
|
+
i.value == U(he).RADIO ? (n(), C(r, S({
|
|
613
613
|
key: 0,
|
|
614
614
|
modelValue: f.value,
|
|
615
615
|
"onUpdate:modelValue": o[1] || (o[1] = (m) => f.value = m)
|
|
616
616
|
}, t.value), {
|
|
617
617
|
default: h(() => [
|
|
618
|
-
y(b.$slots, `${
|
|
619
|
-
(n(!0), F(G, null, L(T.value, (m) => (n(),
|
|
618
|
+
y(b.$slots, `${a.t}-${e.value}`, { data: t.value }, () => [
|
|
619
|
+
(n(!0), F(G, null, L(T.value, (m) => (n(), C(p, S({ ref_for: !0 }, m), {
|
|
620
620
|
default: h(() => [
|
|
621
|
-
y(b.$slots, `${
|
|
621
|
+
y(b.$slots, `${a.t}-${e.value}-options`, { option: m }, 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"])) : i.value == U(he).RADIOBUTTON ? (n(), C(r, S({
|
|
629
629
|
key: 1,
|
|
630
630
|
modelValue: f.value,
|
|
631
631
|
"onUpdate:modelValue": o[2] || (o[2] = (m) => f.value = m)
|
|
632
632
|
}, t.value), {
|
|
633
633
|
default: h(() => [
|
|
634
|
-
y(b.$slots, `${
|
|
635
|
-
(n(!0), F(G, null, L(T.value, (m) => (n(),
|
|
634
|
+
y(b.$slots, `${a.t}-${e.value}`, { data: t.value }, () => [
|
|
635
|
+
(n(!0), F(G, null, L(T.value, (m) => (n(), C(v, S({ ref_for: !0 }, m), {
|
|
636
636
|
default: h(() => [
|
|
637
|
-
y(b.$slots, `${
|
|
637
|
+
y(b.$slots, `${a.t}-${e.value}-options`, { option: m }, 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"])) : i.value == U(he).CHECKBOX ? (n(), C(g, S({
|
|
645
645
|
key: 2,
|
|
646
646
|
modelValue: f.value,
|
|
647
647
|
"onUpdate:modelValue": o[3] || (o[3] = (m) => f.value = m)
|
|
648
648
|
}, t.value), {
|
|
649
649
|
default: h(() => [
|
|
650
|
-
y(b.$slots, `${
|
|
650
|
+
y(b.$slots, `${a.t}-${e.value}`, { data: t.value }, () => [
|
|
651
651
|
o[27] || (o[27] = Me(ye(" ")))
|
|
652
652
|
], !0)
|
|
653
653
|
]),
|
|
654
654
|
_: 3
|
|
655
|
-
}, 16, ["modelValue"])) :
|
|
655
|
+
}, 16, ["modelValue"])) : i.value == U(he).CHECKBOXGROUP ? (n(), C(s, S({
|
|
656
656
|
key: 3,
|
|
657
657
|
modelValue: f.value,
|
|
658
658
|
"onUpdate:modelValue": o[4] || (o[4] = (m) => f.value = m)
|
|
659
659
|
}, t.value), {
|
|
660
660
|
default: h(() => [
|
|
661
|
-
y(b.$slots, `${
|
|
662
|
-
(n(!0), F(G, null, L(T.value, (m) => (n(),
|
|
661
|
+
y(b.$slots, `${a.t}-${e.value}`, { data: t.value }, () => [
|
|
662
|
+
(n(!0), F(G, null, L(T.value, (m) => (n(), C(g, S({ ref_for: !0 }, m), {
|
|
663
663
|
default: h(() => [
|
|
664
|
-
y(b.$slots, `${
|
|
664
|
+
y(b.$slots, `${a.t}-${e.value}-options`, { option: m }, () => [
|
|
665
665
|
Me(ye(m.label), 1)
|
|
666
666
|
], !0)
|
|
667
667
|
]),
|
|
@@ -670,34 +670,34 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
670
670
|
], !0)
|
|
671
671
|
]),
|
|
672
672
|
_: 3
|
|
673
|
-
}, 16, ["modelValue"])) :
|
|
673
|
+
}, 16, ["modelValue"])) : i.value == U(he).CHECKBOXGROUPBUTTON ? (n(), C(s, S({
|
|
674
674
|
key: 4,
|
|
675
675
|
modelValue: f.value,
|
|
676
676
|
"onUpdate:modelValue": o[5] || (o[5] = (m) => f.value = m)
|
|
677
677
|
}, t.value), {
|
|
678
678
|
default: h(() => [
|
|
679
|
-
y(b.$slots, `${
|
|
680
|
-
(n(!0), F(G, null, L(T.value, (m) => (n(),
|
|
679
|
+
y(b.$slots, `${a.t}-${e.value}`, { data: t.value }, () => [
|
|
680
|
+
(n(!0), F(G, null, L(T.value, (m) => (n(), C(k, S({ ref_for: !0 }, m), {
|
|
681
681
|
default: h(() => [
|
|
682
|
-
y(b.$slots, `${
|
|
682
|
+
y(b.$slots, `${a.t}-${e.value}-options`, { option: m }, 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"])) : i.value === U(he).SELECT ? (n(), C(J, S({
|
|
690
690
|
key: 5,
|
|
691
691
|
modelValue: f.value,
|
|
692
692
|
"onUpdate:modelValue": o[6] || (o[6] = (m) => f.value = m),
|
|
693
693
|
placeholder: E.value[e.value].label,
|
|
694
694
|
clearable: !0,
|
|
695
695
|
onClear: o[7] || (o[7] = () => {
|
|
696
|
-
|
|
696
|
+
a.t == "q" && E.value.table.load();
|
|
697
697
|
})
|
|
698
698
|
}, re.value), me({
|
|
699
699
|
default: h(() => [
|
|
700
|
-
y(b.$slots, `${
|
|
700
|
+
y(b.$slots, `${a.t}-${e.value}`, { options: T.value }, () => [
|
|
701
701
|
(n(!0), F(G, null, L(T.value, (m) => (n(), F(G, {
|
|
702
702
|
key: m.value
|
|
703
703
|
}, [
|
|
@@ -709,7 +709,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
709
709
|
default: h(() => {
|
|
710
710
|
var W;
|
|
711
711
|
return [
|
|
712
|
-
(W = t.value) != null && W.columns ? y(b.$slots, `${
|
|
712
|
+
(W = t.value) != null && W.columns ? y(b.$slots, `${a.t}-${e.value}-options`, {
|
|
713
713
|
key: 0,
|
|
714
714
|
option: m
|
|
715
715
|
}, () => {
|
|
@@ -718,7 +718,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
718
718
|
Z(V, {
|
|
719
719
|
columns: (ce = t.value) == null ? void 0 : ce.columns,
|
|
720
720
|
data: m,
|
|
721
|
-
t:
|
|
721
|
+
t: a.t
|
|
722
722
|
}, me({ _: 2 }, [
|
|
723
723
|
L(b.$slots, (Be, Ke) => ({
|
|
724
724
|
name: Ke,
|
|
@@ -736,7 +736,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
736
736
|
}),
|
|
737
737
|
_: 2
|
|
738
738
|
}, 1040, ["onClick"]),
|
|
739
|
-
m.children && m.children.length ? (n(!0), F(G, { key: 0 }, L(m.children, (W) => (n(),
|
|
739
|
+
m.children && m.children.length ? (n(!0), F(G, { key: 0 }, L(m.children, (W) => (n(), C(j, S({
|
|
740
740
|
style: { "margin-left": "20px" },
|
|
741
741
|
key: W.value,
|
|
742
742
|
ref_for: !0
|
|
@@ -748,7 +748,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
748
748
|
default: h(() => {
|
|
749
749
|
var ce;
|
|
750
750
|
return [
|
|
751
|
-
(ce = t.value) != null && ce.columns ? y(b.$slots, `${
|
|
751
|
+
(ce = t.value) != null && ce.columns ? y(b.$slots, `${a.t}-${e.value}-options`, {
|
|
752
752
|
key: 0,
|
|
753
753
|
option: W
|
|
754
754
|
}, () => {
|
|
@@ -757,14 +757,14 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
757
757
|
Z(V, {
|
|
758
758
|
columns: (Be = t.value) == null ? void 0 : Be.columns,
|
|
759
759
|
data: W,
|
|
760
|
-
t:
|
|
760
|
+
t: a.t
|
|
761
761
|
}, me({ _: 2 }, [
|
|
762
762
|
L(b.$slots, (Ke, Ze) => ({
|
|
763
763
|
name: Ze,
|
|
764
|
-
fn: h((
|
|
764
|
+
fn: h((it) => [
|
|
765
765
|
y(b.$slots, Ze, {
|
|
766
766
|
option: W,
|
|
767
|
-
data:
|
|
767
|
+
data: it
|
|
768
768
|
}, void 0, !0)
|
|
769
769
|
])
|
|
770
770
|
}))
|
|
@@ -788,7 +788,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
788
788
|
Z(V, {
|
|
789
789
|
columns: (m = t.value) == null ? void 0 : m.columns,
|
|
790
790
|
title: !0,
|
|
791
|
-
t:
|
|
791
|
+
t: a.t
|
|
792
792
|
}, me({ _: 2 }, [
|
|
793
793
|
L(b.$slots, (W, ce) => ({
|
|
794
794
|
name: ce,
|
|
@@ -804,10 +804,10 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
804
804
|
L(z(), (m) => ({
|
|
805
805
|
name: m,
|
|
806
806
|
fn: h((W) => [
|
|
807
|
-
y(b.$slots, `${
|
|
807
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: W }, void 0, !0)
|
|
808
808
|
])
|
|
809
809
|
}))
|
|
810
|
-
]), 1040, ["modelValue", "placeholder"])) :
|
|
810
|
+
]), 1040, ["modelValue", "placeholder"])) : i.value == U(he).TREESELECT ? (n(), C(Y, S({
|
|
811
811
|
key: 6,
|
|
812
812
|
modelValue: f.value,
|
|
813
813
|
"onUpdate:modelValue": o[8] || (o[8] = (m) => f.value = m),
|
|
@@ -816,17 +816,17 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
816
816
|
L(z(), (m) => ({
|
|
817
817
|
name: m,
|
|
818
818
|
fn: h((W) => [
|
|
819
|
-
y(b.$slots, `${
|
|
819
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: W }, void 0, !0)
|
|
820
820
|
])
|
|
821
821
|
}))
|
|
822
|
-
]), 1040, ["modelValue", "placeholder", "data"])) :
|
|
822
|
+
]), 1040, ["modelValue", "placeholder", "data"])) : i.value == U(he).TIME ? (n(), C(O, S({
|
|
823
823
|
key: 7,
|
|
824
824
|
modelValue: f.value,
|
|
825
825
|
"onUpdate:modelValue": o[9] || (o[9] = (m) => f.value = m),
|
|
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"])) : i.value == U(he).TIMESELECT ? (n(), C(ue, S({
|
|
830
830
|
key: 8,
|
|
831
831
|
modelValue: f.value,
|
|
832
832
|
"onUpdate:modelValue": o[10] || (o[10] = (m) => f.value = m),
|
|
@@ -834,33 +834,33 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
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"])) : B(
|
|
837
|
+
}, t.value), null, 16, ["modelValue", "placeholder"])) : B(i.value) ? (n(), C(ke, S({
|
|
838
838
|
key: 9,
|
|
839
839
|
modelValue: f.value,
|
|
840
840
|
"onUpdate:modelValue": o[11] || (o[11] = (m) => f.value = m),
|
|
841
|
-
type:
|
|
841
|
+
type: i.value,
|
|
842
842
|
placeholder: E.value[e.value].label,
|
|
843
|
-
"value-format": se(
|
|
843
|
+
"value-format": se(i.value)
|
|
844
844
|
}, t.value), me({ _: 2 }, [
|
|
845
845
|
L(z(), (m) => ({
|
|
846
846
|
name: m,
|
|
847
847
|
fn: h((W) => [
|
|
848
|
-
y(b.$slots, `${
|
|
848
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: W }, void 0, !0)
|
|
849
849
|
])
|
|
850
850
|
}))
|
|
851
|
-
]), 1040, ["modelValue", "type", "placeholder", "value-format"])) :
|
|
851
|
+
]), 1040, ["modelValue", "type", "placeholder", "value-format"])) : i.value == U(he).COLOR ? (n(), C(_e, S({
|
|
852
852
|
key: 10,
|
|
853
853
|
modelValue: f.value,
|
|
854
854
|
"onUpdate:modelValue": o[12] || (o[12] = (m) => f.value = m)
|
|
855
|
-
}, t.value), null, 16, ["modelValue"])) :
|
|
855
|
+
}, t.value), null, 16, ["modelValue"])) : i.value == U(he).RATE ? (n(), C(Te, S({
|
|
856
856
|
key: 11,
|
|
857
857
|
modelValue: f.value,
|
|
858
858
|
"onUpdate:modelValue": o[13] || (o[13] = (m) => f.value = m)
|
|
859
|
-
}, t.value), null, 16, ["modelValue"])) :
|
|
859
|
+
}, t.value), null, 16, ["modelValue"])) : i.value == U(he).SLIDER ? (n(), C(Se, S({
|
|
860
860
|
key: 12,
|
|
861
861
|
modelValue: f.value,
|
|
862
862
|
"onUpdate:modelValue": o[14] || (o[14] = (m) => f.value = m)
|
|
863
|
-
}, t.value), null, 16, ["modelValue"])) :
|
|
863
|
+
}, t.value), null, 16, ["modelValue"])) : i.value == U(he).SWITCH ? (n(), C(we, S({
|
|
864
864
|
key: 13,
|
|
865
865
|
modelValue: f.value,
|
|
866
866
|
"onUpdate:modelValue": o[15] || (o[15] = (m) => f.value = m),
|
|
@@ -869,10 +869,10 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
869
869
|
L(z(), (m) => ({
|
|
870
870
|
name: m,
|
|
871
871
|
fn: h((W) => [
|
|
872
|
-
y(b.$slots, `${
|
|
872
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: W }, void 0, !0)
|
|
873
873
|
])
|
|
874
874
|
}))
|
|
875
|
-
]), 1040, ["modelValue"])) :
|
|
875
|
+
]), 1040, ["modelValue"])) : i.value == U(he).TRANSFER ? (n(), C(xe, S({
|
|
876
876
|
key: 14,
|
|
877
877
|
modelValue: f.value,
|
|
878
878
|
"onUpdate:modelValue": o[16] || (o[16] = (m) => f.value = m)
|
|
@@ -880,10 +880,10 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
880
880
|
L(z(), (m) => ({
|
|
881
881
|
name: m,
|
|
882
882
|
fn: h((W) => [
|
|
883
|
-
y(b.$slots, `${
|
|
883
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: W }, void 0, !0)
|
|
884
884
|
])
|
|
885
885
|
}))
|
|
886
|
-
]), 1040, ["modelValue"])) :
|
|
886
|
+
]), 1040, ["modelValue"])) : i.value == U(he).CASCADER ? (n(), C(Ue, S({
|
|
887
887
|
key: 15,
|
|
888
888
|
modelValue: f.value,
|
|
889
889
|
"onUpdate:modelValue": o[17] || (o[17] = (m) => f.value = m)
|
|
@@ -891,10 +891,10 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
891
891
|
L(z(), (m) => ({
|
|
892
892
|
name: m,
|
|
893
893
|
fn: h((W) => [
|
|
894
|
-
y(b.$slots, `${
|
|
894
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: W }, void 0, !0)
|
|
895
895
|
])
|
|
896
896
|
}))
|
|
897
|
-
]), 1040, ["modelValue", "options"])) :
|
|
897
|
+
]), 1040, ["modelValue", "options"])) : i.value == U(he).IMAGE ? (n(), C(ut, S({
|
|
898
898
|
key: 16,
|
|
899
899
|
"file-list": t.value["file-list"],
|
|
900
900
|
"onUpdate:fileList": o[21] || (o[21] = (m) => t.value["file-list"] = m),
|
|
@@ -913,32 +913,32 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
913
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
|
-
X("div",
|
|
917
|
-
Z(
|
|
916
|
+
X("div", nl, [
|
|
917
|
+
Z(ot, S({
|
|
918
918
|
style: { width: "var(--up-width)", height: "var(--up-height)" },
|
|
919
919
|
src: f.value
|
|
920
920
|
}, { fit: "cover", lazy: !0, ...(m = t.value) == null ? void 0 : m.img }), me({ _: 2 }, [
|
|
921
921
|
L(z(), (W, ce) => ({
|
|
922
922
|
name: W,
|
|
923
923
|
fn: h((Be) => [
|
|
924
|
-
y(b.$slots, `${
|
|
924
|
+
y(b.$slots, `${a.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: o[18] || (o[18] = (W) =>
|
|
932
|
-
onMouseleave: o[19] || (o[19] = (W) =>
|
|
931
|
+
onMouseenter: o[18] || (o[18] = (W) => $.value = !0),
|
|
932
|
+
onMouseleave: o[19] || (o[19] = (W) => $.value = !1),
|
|
933
933
|
class: "up-view"
|
|
934
934
|
}, [
|
|
935
|
-
|
|
935
|
+
$.value ? (n(), C(tt, {
|
|
936
936
|
key: 0,
|
|
937
937
|
content: "查看大图",
|
|
938
938
|
placement: "top"
|
|
939
939
|
}, {
|
|
940
940
|
default: h(() => [
|
|
941
|
-
Z(U(
|
|
941
|
+
Z(U(Qt), {
|
|
942
942
|
style: { width: "1.5em", height: "1.5em", "margin-right": "12px" },
|
|
943
943
|
color: "white",
|
|
944
944
|
onClick: de
|
|
@@ -946,13 +946,13 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
946
946
|
]),
|
|
947
947
|
_: 1
|
|
948
948
|
})) : pe("", !0),
|
|
949
|
-
te.value.showDel &&
|
|
949
|
+
te.value.showDel && $.value ? (n(), C(tt, {
|
|
950
950
|
key: 1,
|
|
951
951
|
content: "删除",
|
|
952
952
|
placement: "top"
|
|
953
953
|
}, {
|
|
954
954
|
default: h(() => [
|
|
955
|
-
Z(U(
|
|
955
|
+
Z(U(Zt), {
|
|
956
956
|
style: { width: "1.5em", height: "1.5em" },
|
|
957
957
|
color: "white",
|
|
958
958
|
onClick: be
|
|
@@ -961,9 +961,9 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
961
961
|
_: 1
|
|
962
962
|
})) : pe("", !0)
|
|
963
963
|
], 32)
|
|
964
|
-
])) : (n(),
|
|
964
|
+
])) : (n(), C(Re, { key: 0 }, {
|
|
965
965
|
default: h(() => [
|
|
966
|
-
Z(U(
|
|
966
|
+
Z(U(Gt))
|
|
967
967
|
]),
|
|
968
968
|
_: 1
|
|
969
969
|
}))
|
|
@@ -974,10 +974,10 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
974
974
|
L(z(), (m, W) => ({
|
|
975
975
|
name: m,
|
|
976
976
|
fn: h((ce) => [
|
|
977
|
-
y(b.$slots, `${
|
|
977
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: ce }, void 0, !0)
|
|
978
978
|
])
|
|
979
979
|
}))
|
|
980
|
-
]), 1040, ["file-list"])) :
|
|
980
|
+
]), 1040, ["file-list"])) : i.value == U(he).AUTOCOMPLETE ? (n(), C(nt, S({
|
|
981
981
|
key: 17,
|
|
982
982
|
modelValue: f.value,
|
|
983
983
|
"onUpdate:modelValue": o[22] || (o[22] = (m) => f.value = m)
|
|
@@ -987,10 +987,10 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
987
987
|
L(z(), (m, W) => ({
|
|
988
988
|
name: m,
|
|
989
989
|
fn: h((ce) => [
|
|
990
|
-
y(b.$slots, `${
|
|
990
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: ce }, void 0, !0)
|
|
991
991
|
])
|
|
992
992
|
}))
|
|
993
|
-
]), 1040, ["modelValue", "placeholder"])) :
|
|
993
|
+
]), 1040, ["modelValue", "placeholder"])) : i.value == U(he).INPUTNUMBER ? (n(), C(st, S({
|
|
994
994
|
key: 18,
|
|
995
995
|
modelValue: f.value,
|
|
996
996
|
"onUpdate:modelValue": o[23] || (o[23] = (m) => f.value = m),
|
|
@@ -1001,74 +1001,74 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1001
1001
|
L(z(), (m, W) => ({
|
|
1002
1002
|
name: m,
|
|
1003
1003
|
fn: h((ce) => [
|
|
1004
|
-
y(b.$slots, `${
|
|
1004
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: ce }, void 0, !0)
|
|
1005
1005
|
])
|
|
1006
1006
|
}))
|
|
1007
|
-
]), 1040, ["modelValue", "placeholder"])) :
|
|
1007
|
+
]), 1040, ["modelValue", "placeholder"])) : i.value == U(he).MONEY ? (n(), F("div", sl, [
|
|
1008
1008
|
Z(lt, S({
|
|
1009
1009
|
modelValue: f.value,
|
|
1010
1010
|
"onUpdate:modelValue": o[24] || (o[24] = (m) => f.value = m),
|
|
1011
1011
|
placeholder: E.value[e.value].label,
|
|
1012
1012
|
type: U(he).NUMBER,
|
|
1013
1013
|
maxlength: ((N = t.value) == null ? void 0 : N.max) || 25
|
|
1014
|
-
}, { ...t.value, type:
|
|
1014
|
+
}, { ...t.value, type: i.value }), me({
|
|
1015
1015
|
suffix: h(() => [
|
|
1016
1016
|
X("div", {
|
|
1017
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(U(Et)(f.value)), 9,
|
|
1019
|
+
}, ye(U(Et)(f.value)), 9, il)
|
|
1020
1020
|
]),
|
|
1021
1021
|
_: 2
|
|
1022
1022
|
}, [
|
|
1023
1023
|
L(z(), (m, W) => ({
|
|
1024
1024
|
name: m,
|
|
1025
1025
|
fn: h((ce) => [
|
|
1026
|
-
y(b.$slots, `${
|
|
1026
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: ce }, void 0, !0)
|
|
1027
1027
|
])
|
|
1028
1028
|
}))
|
|
1029
1029
|
]), 1040, ["modelValue", "placeholder", "type", "maxlength"])
|
|
1030
|
-
])) : (Q =
|
|
1030
|
+
])) : (Q = i.value) != null && Q.startsWith("link") ? (n(), F("div", dl, [
|
|
1031
1031
|
Z(l, S(t.value, {
|
|
1032
|
-
type:
|
|
1032
|
+
type: i.value.replace("link-", ""),
|
|
1033
1033
|
innerHTML: q.value || f.value
|
|
1034
1034
|
}), null, 16, ["type", "innerHTML"])
|
|
1035
|
-
])) :
|
|
1035
|
+
])) : i.value != "textarea" && ((Ee = i.value) != null && Ee.startsWith("text")) ? (n(), F("div", fl, [
|
|
1036
1036
|
Z(u, S(t.value, {
|
|
1037
|
-
type:
|
|
1037
|
+
type: i.value.replace("text-", ""),
|
|
1038
1038
|
innerHTML: q.value || f.value
|
|
1039
1039
|
}), null, 16, ["type", "innerHTML"])
|
|
1040
|
-
])) :
|
|
1041
|
-
q.value ? (n(),
|
|
1040
|
+
])) : i.value == "avatar" ? (n(), F("div", cl, [
|
|
1041
|
+
q.value ? (n(), C(c, gt(S({ key: 0 }, t.value)), {
|
|
1042
1042
|
default: h(() => [
|
|
1043
|
-
X("div", { innerHTML: q.value }, null, 8,
|
|
1043
|
+
X("div", { innerHTML: q.value }, null, 8, ml)
|
|
1044
1044
|
]),
|
|
1045
1045
|
_: 1
|
|
1046
|
-
}, 16)) : (n(),
|
|
1047
|
-
])) : (Ce =
|
|
1046
|
+
}, 16)) : (n(), C(c, gt(S({ key: 1 }, t.value)), null, 16))
|
|
1047
|
+
])) : (Ce = i.value) != null && Ce.startsWith("tag") ? (n(), F("div", pl, [
|
|
1048
1048
|
Array.isArray(q.value) && q.value.length > 0 ? (n(!0), F(G, { key: 0 }, L(q.value, (m, W) => (n(), F(G, { key: W }, [
|
|
1049
|
-
typeof m == "object" ? (n(),
|
|
1049
|
+
typeof m == "object" ? (n(), C(M, S({
|
|
1050
1050
|
key: 0,
|
|
1051
1051
|
ref_for: !0
|
|
1052
1052
|
}, m, {
|
|
1053
1053
|
innerHTML: m == null ? void 0 : m.value,
|
|
1054
1054
|
style: { "margin-right": "3px" }
|
|
1055
|
-
}), null, 16, ["innerHTML"])) : (n(),
|
|
1055
|
+
}), null, 16, ["innerHTML"])) : (n(), C(M, S({
|
|
1056
1056
|
key: 1,
|
|
1057
1057
|
ref_for: !0
|
|
1058
1058
|
}, t.value, {
|
|
1059
|
-
type:
|
|
1059
|
+
type: i.value.replace("tag-", ""),
|
|
1060
1060
|
innerHTML: m,
|
|
1061
1061
|
style: { "margin-right": "3px" }
|
|
1062
1062
|
}), null, 16, ["type", "innerHTML"]))
|
|
1063
|
-
], 64))), 128)) : (n(),
|
|
1064
|
-
type:
|
|
1063
|
+
], 64))), 128)) : (n(), C(M, S({ key: 1 }, t.value, {
|
|
1064
|
+
type: i.value.replace("tag-", ""),
|
|
1065
1065
|
innerHTML: q.value || f.value
|
|
1066
1066
|
}), null, 16, ["type", "innerHTML"]))
|
|
1067
|
-
])) :
|
|
1067
|
+
])) : i.value == "div" ? (n(), F("div", S({ key: 24 }, t.value, {
|
|
1068
1068
|
innerHTML: q.value || f.value
|
|
1069
|
-
}), null, 16,
|
|
1069
|
+
}), null, 16, vl)) : i.value == "span" ? (n(), F("span", S({ key: 25 }, t.value, {
|
|
1070
1070
|
innerHTML: q.value || f.value
|
|
1071
|
-
}), null, 16,
|
|
1071
|
+
}), null, 16, hl)) : (n(), C(lt, S({
|
|
1072
1072
|
key: 26,
|
|
1073
1073
|
modelValue: f.value,
|
|
1074
1074
|
"onUpdate:modelValue": o[25] || (o[25] = (m) => f.value = m),
|
|
@@ -1076,13 +1076,13 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1076
1076
|
maxlength: ((Le = t.value) == null ? void 0 : Le.max) || 25,
|
|
1077
1077
|
clearable: !0,
|
|
1078
1078
|
onClear: o[26] || (o[26] = () => {
|
|
1079
|
-
|
|
1079
|
+
a.t == "q" && E.value.table.load();
|
|
1080
1080
|
})
|
|
1081
|
-
}, { ...t.value, type:
|
|
1081
|
+
}, { ...t.value, type: i.value }), me({ _: 2 }, [
|
|
1082
1082
|
L(z(), (m, W) => ({
|
|
1083
1083
|
name: m,
|
|
1084
1084
|
fn: h((ce) => [
|
|
1085
|
-
y(b.$slots, `${
|
|
1085
|
+
y(b.$slots, `${a.t}-${e.value}-${m}`, { data: ce }, void 0, !0)
|
|
1086
1086
|
])
|
|
1087
1087
|
}))
|
|
1088
1088
|
]), 1040, ["modelValue", "placeholder", "maxlength"]))
|
|
@@ -1090,7 +1090,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1090
1090
|
], 64);
|
|
1091
1091
|
};
|
|
1092
1092
|
}
|
|
1093
|
-
}),
|
|
1093
|
+
}), pt = /* @__PURE__ */ We(yl, [["__scopeId", "data-v-30ecdb1c"]]), gl = { class: "g-form-container" }, bl = /* @__PURE__ */ Object.assign({
|
|
1094
1094
|
name: "g-form",
|
|
1095
1095
|
inheritAttrs: !1
|
|
1096
1096
|
}, {
|
|
@@ -1100,9 +1100,9 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1100
1100
|
modelModifiers: {}
|
|
1101
1101
|
}),
|
|
1102
1102
|
emits: /* @__PURE__ */ Ne(["submit", "reset"], ["update:modelValue"]),
|
|
1103
|
-
setup(
|
|
1103
|
+
setup(d, { expose: f, emit: a }) {
|
|
1104
1104
|
var ae, $e, ne, b;
|
|
1105
|
-
const t = Pe(
|
|
1105
|
+
const t = Pe(d, "modelValue"), e = a, i = le(null), E = _t("options"), x = le({}), T = le(""), D = d, $ = {
|
|
1106
1106
|
inline: !0,
|
|
1107
1107
|
type: "hidden",
|
|
1108
1108
|
"scroll-to-error": !0,
|
|
@@ -1147,34 +1147,34 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1147
1147
|
}
|
|
1148
1148
|
};
|
|
1149
1149
|
t.value.form = qe(
|
|
1150
|
-
|
|
1150
|
+
$,
|
|
1151
1151
|
E == null ? void 0 : E.form,
|
|
1152
1152
|
($e = t.value) == null ? void 0 : $e.form
|
|
1153
1153
|
);
|
|
1154
|
-
const z = async (o,
|
|
1154
|
+
const z = async (o, _) => {
|
|
1155
1155
|
let p = 5;
|
|
1156
1156
|
for (; p > 0; ) {
|
|
1157
|
-
if (await et(),
|
|
1158
|
-
|
|
1159
|
-
|
|
1157
|
+
if (await et(), i.value) {
|
|
1158
|
+
i.value.validate((r, v) => {
|
|
1159
|
+
r ? e("submit", o, _) : console.error("表单验证不通过!", v);
|
|
1160
1160
|
});
|
|
1161
1161
|
return;
|
|
1162
1162
|
}
|
|
1163
|
-
p--, await new Promise((
|
|
1163
|
+
p--, await new Promise((r) => setTimeout(r, 50));
|
|
1164
1164
|
}
|
|
1165
1165
|
console.error("表单实例获取失败,请检查组件状态");
|
|
1166
1166
|
}, te = async () => {
|
|
1167
1167
|
let o = 5;
|
|
1168
1168
|
for (; o > 0; ) {
|
|
1169
|
-
if (await et(), !
|
|
1169
|
+
if (await et(), !i.value) {
|
|
1170
1170
|
o--, await new Promise((p) => setTimeout(p, 50));
|
|
1171
1171
|
continue;
|
|
1172
1172
|
}
|
|
1173
|
-
let
|
|
1173
|
+
let _ = !0;
|
|
1174
1174
|
if (e("reset", (p) => {
|
|
1175
|
-
|
|
1176
|
-
}),
|
|
1177
|
-
|
|
1175
|
+
_ = p;
|
|
1176
|
+
}), _) {
|
|
1177
|
+
i.value.resetFields();
|
|
1178
1178
|
return;
|
|
1179
1179
|
}
|
|
1180
1180
|
o--, await new Promise((p) => setTimeout(p, 50));
|
|
@@ -1204,11 +1204,11 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1204
1204
|
t.value.form.cols
|
|
1205
1205
|
);
|
|
1206
1206
|
const se = (o) => {
|
|
1207
|
-
let
|
|
1207
|
+
let _ = [];
|
|
1208
1208
|
if (o.rules)
|
|
1209
|
-
|
|
1209
|
+
_ = o.rules;
|
|
1210
1210
|
else {
|
|
1211
|
-
const
|
|
1211
|
+
const r = { ...{
|
|
1212
1212
|
required: void 0,
|
|
1213
1213
|
max: void 0,
|
|
1214
1214
|
min: void 0,
|
|
@@ -1217,92 +1217,92 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1217
1217
|
pattern: void 0,
|
|
1218
1218
|
validate: void 0
|
|
1219
1219
|
}, ...o };
|
|
1220
|
-
|
|
1220
|
+
r.required && _.push({
|
|
1221
1221
|
required: !0,
|
|
1222
|
-
message: `${
|
|
1222
|
+
message: `${r.label}不能为空!`,
|
|
1223
1223
|
trigger: "blur"
|
|
1224
|
-
}),
|
|
1224
|
+
}), r.max !== void 0 && r.max !== null && r.max !== "" && (r.min === void 0 || r.min === null || r.min === "") && _.push({
|
|
1225
1225
|
validator: (v, g, s) => {
|
|
1226
1226
|
if (g == null || g === "") return s();
|
|
1227
|
-
|
|
1228
|
-
new Error(`${
|
|
1229
|
-
) : s() : Number(g) > Number(
|
|
1227
|
+
r.type !== "number" && r.type !== "input-number" ? ((g == null ? void 0 : g.toString()) || "").length > Number(r.max) ? s(
|
|
1228
|
+
new Error(`${r.label}长度不能超过${r.max}个字符!`)
|
|
1229
|
+
) : s() : Number(g) > Number(r.max) ? s(new Error(`${r.label}不能大于${r.max}!`)) : s();
|
|
1230
1230
|
}
|
|
1231
|
-
}),
|
|
1231
|
+
}), r.min !== void 0 && r.min !== null && r.min !== "" && (r.max === void 0 || r.max === null || r.max === "") && _.push({
|
|
1232
1232
|
validator: (v, g, s) => {
|
|
1233
1233
|
if (g == null || g === "") return s();
|
|
1234
|
-
|
|
1234
|
+
r.type !== "number" && r.type !== "input-number" ? Number(r.min) < 1 ? s(
|
|
1235
1235
|
new Error(
|
|
1236
|
-
`${
|
|
1236
|
+
`${r.label}长度最小值${r.min}设置错误!`
|
|
1237
1237
|
)
|
|
1238
|
-
) : g.toString().length < Number(
|
|
1238
|
+
) : g.toString().length < Number(r.min) ? s(
|
|
1239
1239
|
new Error(
|
|
1240
|
-
`${
|
|
1240
|
+
`${r.label}长度不能少于${r.min}个字符!`
|
|
1241
1241
|
)
|
|
1242
|
-
) : s() : Number(g) < Number(
|
|
1242
|
+
) : s() : Number(g) < Number(r.min) ? s(new Error(`${r.label}不能小于${r.min}!`)) : s();
|
|
1243
1243
|
}
|
|
1244
|
-
}),
|
|
1244
|
+
}), r.min !== void 0 && r.min !== null && r.min !== "" && r.max !== void 0 && r.max !== null && r.max !== "" && _.push({
|
|
1245
1245
|
validator: (v, g, s) => {
|
|
1246
1246
|
if (g == null || g === "") return s();
|
|
1247
|
-
const
|
|
1248
|
-
|
|
1247
|
+
const k = Number(r.min), V = Number(r.max);
|
|
1248
|
+
r.type !== "number" && r.type !== "input-number" ? Number(r.min) < 1 ? s(
|
|
1249
1249
|
new Error(
|
|
1250
|
-
`${
|
|
1250
|
+
`${r.label}长度最小值${r.min}设置错误!`
|
|
1251
1251
|
)
|
|
1252
|
-
) : g.toString().length <
|
|
1252
|
+
) : g.toString().length < k || g.toString().length > V ? s(
|
|
1253
1253
|
new Error(
|
|
1254
|
-
`${
|
|
1254
|
+
`${r.label}长度必须在${k}-${V}个字符之间!`
|
|
1255
1255
|
)
|
|
1256
|
-
) : s() : Number(g) <
|
|
1256
|
+
) : s() : Number(g) < k || g > V ? s(new Error(`${r.label}必须在${k}-${V}之间!`)) : s();
|
|
1257
1257
|
}
|
|
1258
|
-
}),
|
|
1259
|
-
pattern:
|
|
1260
|
-
message: (
|
|
1261
|
-
}),
|
|
1262
|
-
validator: (v, g, s) =>
|
|
1258
|
+
}), r.type == "email" && _.push({ type: "email", message: "不是一个正确的邮箱地址!" }), r.type == "url" && _.push({ type: "url", message: "不是一个合正确的URL!" }), r.pattern && _.push({
|
|
1259
|
+
pattern: r == null ? void 0 : r.pattern,
|
|
1260
|
+
message: (r == null ? void 0 : r.message) || "格式不正确!"
|
|
1261
|
+
}), r.validate && _.push({
|
|
1262
|
+
validator: (v, g, s) => r.validate(v, g, s)
|
|
1263
1263
|
});
|
|
1264
1264
|
}
|
|
1265
|
-
return
|
|
1266
|
-
}, re = (o,
|
|
1267
|
-
var v, g, s,
|
|
1268
|
-
const p =
|
|
1265
|
+
return _;
|
|
1266
|
+
}, re = (o, _ = !1) => {
|
|
1267
|
+
var v, g, s, k, V;
|
|
1268
|
+
const p = _ ? o : o == null ? void 0 : o.item, r = 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) || {};
|
|
1269
1269
|
if (((g = t.value.form) == null ? void 0 : g.modalState) === "edit") {
|
|
1270
|
-
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" ?
|
|
1271
|
-
return { ...
|
|
1270
|
+
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" ? r == null ? void 0 : r.ep : {};
|
|
1271
|
+
return { ...r, ...j };
|
|
1272
1272
|
}
|
|
1273
|
-
if (((
|
|
1274
|
-
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" ?
|
|
1275
|
-
return { ...
|
|
1273
|
+
if (((k = t.value.form) == null ? void 0 : k.modalState) === "add") {
|
|
1274
|
+
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" ? r == null ? void 0 : r.ap : {};
|
|
1275
|
+
return { ...r, ...j };
|
|
1276
1276
|
}
|
|
1277
|
-
return
|
|
1277
|
+
return r;
|
|
1278
1278
|
}, K = (o) => {
|
|
1279
|
-
var p,
|
|
1280
|
-
const
|
|
1281
|
-
return ((
|
|
1279
|
+
var p, r, v, g, s;
|
|
1280
|
+
const _ = typeof o.editor == "function" ? o.editor(x.value, (p = t.value.form) == null ? void 0 : p.modalState) : o.editor;
|
|
1281
|
+
return ((r = t.value.form) == null ? void 0 : r.modalState) === "edit" ? ((v = _ == null ? void 0 : _.ep) == null ? void 0 : v.type) ?? (_ == null ? void 0 : _.type) ?? o.type : ((g = t.value.form) == null ? void 0 : g.modalState) === "add" ? ((s = _ == null ? void 0 : _.ap) == null ? void 0 : s.type) ?? (_ == null ? void 0 : _.type) ?? o.type : (_ == null ? void 0 : _.type) ?? o.type;
|
|
1282
1282
|
};
|
|
1283
|
-
|
|
1284
|
-
ve(),
|
|
1285
|
-
}),
|
|
1286
|
-
|
|
1283
|
+
rt(() => {
|
|
1284
|
+
ve(), D != null && D.editForm ? x.value = D.editForm : x.value = be.value;
|
|
1285
|
+
}), Rt(() => {
|
|
1286
|
+
i.value = null;
|
|
1287
1287
|
});
|
|
1288
1288
|
const ve = () => {
|
|
1289
1289
|
T.value = Math.random().toString(36).substring(2);
|
|
1290
|
-
for (const [o,
|
|
1290
|
+
for (const [o, _] of Object.entries(ge.value))
|
|
1291
1291
|
t.value[o].formItem = {
|
|
1292
1292
|
...t.value[o].formItem,
|
|
1293
|
-
...
|
|
1293
|
+
..._.formItem
|
|
1294
1294
|
}, t.value[o].formItem.style = {
|
|
1295
1295
|
...t.value[o].formItem.style,
|
|
1296
|
-
...
|
|
1296
|
+
..._.formItem.style
|
|
1297
1297
|
};
|
|
1298
1298
|
}, ge = Je(
|
|
1299
1299
|
() => Object.fromEntries(
|
|
1300
1300
|
Object.entries(t.value).filter((o) => o[1].type != "hidden").filter((o) => o[1].edit !== !1).filter(
|
|
1301
1301
|
(o) => !["table", "tableColumns", "query", "queryItems"].includes(o[0])
|
|
1302
1302
|
).filter((o) => o[1].editor !== !1).filter((o) => o[1].type !== "control").filter((o) => {
|
|
1303
|
-
var p,
|
|
1304
|
-
const
|
|
1305
|
-
return t.value.form.modalState === "edit" ? ((
|
|
1303
|
+
var p, r, v;
|
|
1304
|
+
const _ = typeof o[1].editor == "function" ? o[1].editor(x.value, (p = t.value.form) == null ? void 0 : p.modalState) : o[1].editor;
|
|
1305
|
+
return t.value.form.modalState === "edit" ? ((r = _ == null ? void 0 : _.ep) == null ? void 0 : r.editor) !== !1 : t.value.form.modalState === "add" ? ((v = _ == null ? void 0 : _.ap) == null ? void 0 : v.editor) !== !1 : !0;
|
|
1306
1306
|
}).map((o) => [o[0], o[1]])
|
|
1307
1307
|
)
|
|
1308
1308
|
), be = Je(
|
|
@@ -1311,17 +1311,17 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1311
1311
|
)
|
|
1312
1312
|
), ie = Je(() => {
|
|
1313
1313
|
const o = /* @__PURE__ */ new Map();
|
|
1314
|
-
return Object.entries(ge.value).forEach(([
|
|
1314
|
+
return Object.entries(ge.value).forEach(([_, p]) => {
|
|
1315
1315
|
if (p.groupName) {
|
|
1316
|
-
const
|
|
1317
|
-
o.has(
|
|
1318
|
-
groupName:
|
|
1316
|
+
const r = p.groupName;
|
|
1317
|
+
o.has(r) || o.set(r, {
|
|
1318
|
+
groupName: r,
|
|
1319
1319
|
items: []
|
|
1320
|
-
}), o.get(
|
|
1320
|
+
}), o.get(r).items.push({ key: _, item: p });
|
|
1321
1321
|
}
|
|
1322
|
-
}), o.forEach((
|
|
1323
|
-
|
|
1324
|
-
...
|
|
1322
|
+
}), o.forEach((_) => {
|
|
1323
|
+
_.tabPane = qe(
|
|
1324
|
+
..._.items.map(({ item: p }) => p.tabPane || {})
|
|
1325
1325
|
);
|
|
1326
1326
|
}), Array.from(o.values());
|
|
1327
1327
|
}), de = [
|
|
@@ -1347,19 +1347,19 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1347
1347
|
originalOrder: 1
|
|
1348
1348
|
// 添加原始顺序标识
|
|
1349
1349
|
}
|
|
1350
|
-
], fe = Je(() => de.filter((o) => !o.hidden).sort((o,
|
|
1350
|
+
], fe = Je(() => de.filter((o) => !o.hidden).sort((o, _) => o.sort - _.sort || o.originalOrder - _.originalOrder));
|
|
1351
1351
|
return f({
|
|
1352
1352
|
submit: z,
|
|
1353
1353
|
reset: te,
|
|
1354
1354
|
formData: x
|
|
1355
|
-
}), (o,
|
|
1355
|
+
}), (o, _) => {
|
|
1356
1356
|
var V, j, J;
|
|
1357
|
-
const p = I("el-form-item"),
|
|
1358
|
-
return n(), F("div",
|
|
1357
|
+
const p = I("el-form-item"), r = I("el-col"), v = I("el-tab-pane"), g = I("el-tabs"), s = I("el-form"), k = I("el-button");
|
|
1358
|
+
return n(), F("div", gl, [
|
|
1359
1359
|
Z(s, S(
|
|
1360
1360
|
{
|
|
1361
1361
|
ref_key: "gform",
|
|
1362
|
-
ref:
|
|
1362
|
+
ref: i,
|
|
1363
1363
|
model: x.value,
|
|
1364
1364
|
style: {
|
|
1365
1365
|
width: "98%",
|
|
@@ -1378,11 +1378,11 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1378
1378
|
Z(g, S({
|
|
1379
1379
|
class: "demo-tabs",
|
|
1380
1380
|
modelValue: ie.value[0].groupName,
|
|
1381
|
-
"onUpdate:modelValue":
|
|
1381
|
+
"onUpdate:modelValue": _[0] || (_[0] = (Y) => ie.value[0].groupName = Y),
|
|
1382
1382
|
style: { width: "100%" }
|
|
1383
1383
|
}, t.value.form.tabs), {
|
|
1384
1384
|
default: h(() => [
|
|
1385
|
-
(n(!0), F(G, null, L(ie.value, (Y) => (n(),
|
|
1385
|
+
(n(!0), F(G, null, L(ie.value, (Y) => (n(), C(v, S({
|
|
1386
1386
|
key: Y.groupName,
|
|
1387
1387
|
label: Y.groupName,
|
|
1388
1388
|
name: Y.groupName,
|
|
@@ -1390,7 +1390,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1390
1390
|
ref_for: !0
|
|
1391
1391
|
}, Y.tabPane), {
|
|
1392
1392
|
default: h(() => [
|
|
1393
|
-
(n(!0), F(G, null, L(Y.items, (O, ue) => (n(),
|
|
1393
|
+
(n(!0), F(G, null, L(Y.items, (O, ue) => (n(), C(r, S({ ref_for: !0 }, { ...t.value.form.cols, ...O == null ? void 0 : O.item.col }, {
|
|
1394
1394
|
key: O.key,
|
|
1395
1395
|
style: { width: "100%" }
|
|
1396
1396
|
}), {
|
|
@@ -1409,7 +1409,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1409
1409
|
formInfo: x.value,
|
|
1410
1410
|
model: t.value
|
|
1411
1411
|
}, () => [
|
|
1412
|
-
(n(),
|
|
1412
|
+
(n(), C(pt, {
|
|
1413
1413
|
modelValue: x.value[O.key],
|
|
1414
1414
|
"onUpdate:modelValue": (Te) => x.value[O.key] = Te,
|
|
1415
1415
|
item: re(O),
|
|
@@ -1447,7 +1447,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1447
1447
|
_: 3
|
|
1448
1448
|
}, 16, ["modelValue"])
|
|
1449
1449
|
], !0) : y(o.$slots, "default", { key: 1 }, () => [
|
|
1450
|
-
(n(!0), F(G, null, L(ge.value, (Y, O) => (n(),
|
|
1450
|
+
(n(!0), F(G, null, L(ge.value, (Y, O) => (n(), C(r, S({ ref_for: !0 }, { ...t.value.form.cols, ...Y.col }, {
|
|
1451
1451
|
key: O,
|
|
1452
1452
|
style: { width: "100%" }
|
|
1453
1453
|
}), {
|
|
@@ -1475,7 +1475,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1475
1475
|
formInfo: x.value,
|
|
1476
1476
|
model: t.value
|
|
1477
1477
|
}, () => [
|
|
1478
|
-
(n(),
|
|
1478
|
+
(n(), C(pt, {
|
|
1479
1479
|
modelValue: x.value[O],
|
|
1480
1480
|
"onUpdate:modelValue": (ke) => x.value[O] = ke,
|
|
1481
1481
|
item: re(Y, !0),
|
|
@@ -1518,8 +1518,8 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1518
1518
|
(n(!0), F(G, null, L(fe.value, (Y) => (n(), F(G, null, [
|
|
1519
1519
|
y(o.$slots, Y.name + "-left", {}, void 0, !0),
|
|
1520
1520
|
y(o.$slots, Y.name, {}, () => [
|
|
1521
|
-
Z(
|
|
1522
|
-
onClick:
|
|
1521
|
+
Z(k, S({ ref_for: !0 }, Y.info, {
|
|
1522
|
+
onClick: ct((O) => Y.click(x.value, t.value), ["stop"])
|
|
1523
1523
|
}), {
|
|
1524
1524
|
default: h(() => [
|
|
1525
1525
|
Me(ye(Y == null ? void 0 : Y.label), 1)
|
|
@@ -1535,7 +1535,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1535
1535
|
]);
|
|
1536
1536
|
};
|
|
1537
1537
|
}
|
|
1538
|
-
}), bt = /* @__PURE__ */ We(
|
|
1538
|
+
}), bt = /* @__PURE__ */ We(bl, [["__scopeId", "data-v-a6be53f9"]]), Dt = {
|
|
1539
1539
|
__name: "g-query-item",
|
|
1540
1540
|
props: /* @__PURE__ */ Ne(["more"], {
|
|
1541
1541
|
modelValue: { required: !0 },
|
|
@@ -1544,39 +1544,39 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1544
1544
|
infoModifiers: {}
|
|
1545
1545
|
}),
|
|
1546
1546
|
emits: ["update:modelValue", "update:info"],
|
|
1547
|
-
setup(
|
|
1548
|
-
const f = Pe(
|
|
1549
|
-
var
|
|
1550
|
-
return typeof T[1].search == "function" ? T[1].search && ((
|
|
1551
|
-
}).map((T) => [T[0], T[1]]))).value,
|
|
1552
|
-
const T =
|
|
1547
|
+
setup(d) {
|
|
1548
|
+
const f = Pe(d, "modelValue"), a = d, t = Pe(d, "info"), e = (x) => Je(() => Object.fromEntries(Object.entries(f.value).filter((T) => {
|
|
1549
|
+
var D;
|
|
1550
|
+
return typeof T[1].search == "function" ? T[1].search && ((D = T[1].search(t.value, f.value.table)) == null ? void 0 : D.more) === x : T[1].search && T[1].search.more === x;
|
|
1551
|
+
}).map((T) => [T[0], T[1]]))).value, i = (x) => typeof x.search == "function" ? x.search(t.value, f.value.table) : x.search || {}, E = (x) => {
|
|
1552
|
+
const T = i(x);
|
|
1553
1553
|
return (T == null ? void 0 : T.type) || x.type;
|
|
1554
1554
|
};
|
|
1555
1555
|
return (x, T) => {
|
|
1556
|
-
const
|
|
1557
|
-
return n(!0), F(G, null, L(e(
|
|
1556
|
+
const D = I("el-form-item");
|
|
1557
|
+
return n(!0), F(G, null, L(e(a.more), ($, z) => y(x.$slots, `q-${z}`, {
|
|
1558
1558
|
key: z,
|
|
1559
|
-
item:
|
|
1559
|
+
item: $,
|
|
1560
1560
|
queryModel: t.value,
|
|
1561
1561
|
model: f.value
|
|
1562
1562
|
}, () => [
|
|
1563
|
-
Z(
|
|
1564
|
-
label:
|
|
1563
|
+
Z(D, S({
|
|
1564
|
+
label: $.label,
|
|
1565
1565
|
ref_for: !0
|
|
1566
|
-
}, { ...f.value.queryItems, ...
|
|
1566
|
+
}, { ...f.value.queryItems, ...i($) }), {
|
|
1567
1567
|
label: h(() => [
|
|
1568
1568
|
y(x.$slots, `q-${z}-label`, {
|
|
1569
|
-
item:
|
|
1569
|
+
item: $,
|
|
1570
1570
|
model: f.value
|
|
1571
1571
|
})
|
|
1572
1572
|
]),
|
|
1573
1573
|
default: h(() => [
|
|
1574
|
-
Z(
|
|
1574
|
+
Z(pt, {
|
|
1575
1575
|
modelValue: t.value[z],
|
|
1576
1576
|
"onUpdate:modelValue": (te) => t.value[z] = te,
|
|
1577
|
-
item: {
|
|
1577
|
+
item: { ...$ == null ? void 0 : $.editor, ...i($) },
|
|
1578
1578
|
ctrlKey: z,
|
|
1579
|
-
ctrlType: E(
|
|
1579
|
+
ctrlType: E($),
|
|
1580
1580
|
model: f.value,
|
|
1581
1581
|
t: "q",
|
|
1582
1582
|
formInfo: t.value
|
|
@@ -1586,7 +1586,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1586
1586
|
fn: h((q) => [
|
|
1587
1587
|
y(x.$slots, te, {
|
|
1588
1588
|
data: q,
|
|
1589
|
-
item:
|
|
1589
|
+
item: $,
|
|
1590
1590
|
model: f.value
|
|
1591
1591
|
})
|
|
1592
1592
|
])
|
|
@@ -1598,10 +1598,10 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1598
1598
|
])), 128);
|
|
1599
1599
|
};
|
|
1600
1600
|
}
|
|
1601
|
-
},
|
|
1601
|
+
}, $l = {
|
|
1602
1602
|
key: 0,
|
|
1603
1603
|
class: "outer"
|
|
1604
|
-
},
|
|
1604
|
+
}, wl = { class: "inner" }, El = {
|
|
1605
1605
|
__name: "g-query",
|
|
1606
1606
|
props: {
|
|
1607
1607
|
modelValue: { required: !0 },
|
|
@@ -1610,8 +1610,8 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1610
1610
|
infoModifiers: {}
|
|
1611
1611
|
},
|
|
1612
1612
|
emits: /* @__PURE__ */ Ne(["query", "reset"], ["update:modelValue", "update:info"]),
|
|
1613
|
-
setup(
|
|
1614
|
-
const
|
|
1613
|
+
setup(d, { emit: f }) {
|
|
1614
|
+
const a = Pe(d, "modelValue"), t = f, e = _t("options"), i = le(!1), E = Pe(d, "info"), x = {
|
|
1615
1615
|
hidden: !1,
|
|
1616
1616
|
type: "hidden",
|
|
1617
1617
|
labelWidth: 100,
|
|
@@ -1628,7 +1628,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1628
1628
|
type: "primary",
|
|
1629
1629
|
label: "更多",
|
|
1630
1630
|
click: () => {
|
|
1631
|
-
|
|
1631
|
+
i.value = !i.value;
|
|
1632
1632
|
}
|
|
1633
1633
|
},
|
|
1634
1634
|
reset: {
|
|
@@ -1645,7 +1645,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1645
1645
|
type: "primary",
|
|
1646
1646
|
label: "查询",
|
|
1647
1647
|
click: () => {
|
|
1648
|
-
t("query", E.value),
|
|
1648
|
+
t("query", E.value), i.value = !1;
|
|
1649
1649
|
}
|
|
1650
1650
|
},
|
|
1651
1651
|
btns: {
|
|
@@ -1659,7 +1659,7 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1659
1659
|
}
|
|
1660
1660
|
}
|
|
1661
1661
|
};
|
|
1662
|
-
|
|
1662
|
+
a.value.query = qe(x, e == null ? void 0 : e.query, a.value.query);
|
|
1663
1663
|
const T = {
|
|
1664
1664
|
2: {
|
|
1665
1665
|
title: "更多查询",
|
|
@@ -1677,117 +1677,117 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1677
1677
|
trigger: "click"
|
|
1678
1678
|
}
|
|
1679
1679
|
};
|
|
1680
|
-
|
|
1681
|
-
T[
|
|
1682
|
-
|
|
1680
|
+
a.value.query.more.dialog = qe(
|
|
1681
|
+
T[a.value.query.more.mode] || {},
|
|
1682
|
+
a.value.query.more.dialog
|
|
1683
1683
|
);
|
|
1684
|
-
const
|
|
1684
|
+
const D = {
|
|
1685
1685
|
type: "hidden",
|
|
1686
1686
|
labelPosition: "right",
|
|
1687
1687
|
style: {
|
|
1688
1688
|
width: "280px"
|
|
1689
1689
|
}
|
|
1690
1690
|
};
|
|
1691
|
-
|
|
1692
|
-
const
|
|
1691
|
+
a.value.queryItems = qe(D, e == null ? void 0 : e.queryItems, a.value.queryItems);
|
|
1692
|
+
const $ = (q, B) => {
|
|
1693
1693
|
const se = Object.keys(q.slots).filter((re) => re !== "default").reduce((re, K) => (re[K] = (ve) => q.slots[K]({
|
|
1694
|
-
model:
|
|
1694
|
+
model: a.value
|
|
1695
1695
|
// 传递当前模型数据
|
|
1696
1696
|
}), re), {});
|
|
1697
1697
|
return Ae(Dt, {
|
|
1698
|
-
modelValue:
|
|
1699
|
-
"onUpdate:modelValue": (re) =>
|
|
1698
|
+
modelValue: a.value,
|
|
1699
|
+
"onUpdate:modelValue": (re) => a.value = re,
|
|
1700
1700
|
info: E.value,
|
|
1701
1701
|
"onUpdate:info": (re) => E.value = re,
|
|
1702
1702
|
more: B
|
|
1703
1703
|
}, se);
|
|
1704
|
-
}, z =
|
|
1704
|
+
}, z = St(), te = () => {
|
|
1705
1705
|
var se, re, K, ve, ge, be, ie, de, fe;
|
|
1706
1706
|
const q = [
|
|
1707
1707
|
{
|
|
1708
1708
|
key: "query",
|
|
1709
|
-
hidden: (K = (re = (se =
|
|
1709
|
+
hidden: (K = (re = (se = a.value) == null ? void 0 : se.query) == null ? void 0 : re.query) == null ? void 0 : K.hidden,
|
|
1710
1710
|
component: De,
|
|
1711
1711
|
props: {
|
|
1712
|
-
...
|
|
1713
|
-
onClick:
|
|
1712
|
+
...a.value.query.query,
|
|
1713
|
+
onClick: a.value.query.query.click
|
|
1714
1714
|
},
|
|
1715
|
-
label:
|
|
1716
|
-
sort:
|
|
1715
|
+
label: a.value.query.query.label,
|
|
1716
|
+
sort: a.value.query.query.sort || 0
|
|
1717
1717
|
},
|
|
1718
1718
|
{
|
|
1719
1719
|
key: "reset",
|
|
1720
|
-
hidden: (be = (ge = (ve =
|
|
1720
|
+
hidden: (be = (ge = (ve = a.value) == null ? void 0 : ve.query) == null ? void 0 : ge.reset) == null ? void 0 : be.hidden,
|
|
1721
1721
|
component: De,
|
|
1722
1722
|
props: {
|
|
1723
|
-
...
|
|
1724
|
-
onClick:
|
|
1723
|
+
...a.value.query.reset,
|
|
1724
|
+
onClick: a.value.query.reset.click
|
|
1725
1725
|
},
|
|
1726
|
-
label:
|
|
1727
|
-
sort:
|
|
1726
|
+
label: a.value.query.reset.label,
|
|
1727
|
+
sort: a.value.query.reset.sort || 0
|
|
1728
1728
|
},
|
|
1729
1729
|
{
|
|
1730
1730
|
key: "more",
|
|
1731
|
-
hidden: (fe = (de = (ie =
|
|
1732
|
-
component:
|
|
1733
|
-
props:
|
|
1734
|
-
...
|
|
1735
|
-
onClick:
|
|
1731
|
+
hidden: (fe = (de = (ie = a.value) == null ? void 0 : ie.query) == null ? void 0 : de.more) == null ? void 0 : fe.hidden,
|
|
1732
|
+
component: a.value.query.more.mode === 3 ? ht : De,
|
|
1733
|
+
props: a.value.query.more.mode === 3 ? { ...a.value.query.more.dialog } : {
|
|
1734
|
+
...a.value.query.more,
|
|
1735
|
+
onClick: a.value.query.more.click
|
|
1736
1736
|
},
|
|
1737
|
-
label:
|
|
1738
|
-
sort:
|
|
1739
|
-
content:
|
|
1737
|
+
label: a.value.query.more.label,
|
|
1738
|
+
sort: a.value.query.more.sort || 0,
|
|
1739
|
+
content: a.value.query.more.mode === 3 ? () => Ae(dt, {
|
|
1740
1740
|
class: "query-form",
|
|
1741
|
-
...Ve(
|
|
1742
|
-
}, () =>
|
|
1741
|
+
...Ve(a.value.query, (ae) => !["query", "more", "reset"].includes(ae))
|
|
1742
|
+
}, () => $({ slots: z }, !0)) : null
|
|
1743
1743
|
}
|
|
1744
1744
|
];
|
|
1745
1745
|
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, {
|
|
1746
|
-
reference: () => Ae(De,
|
|
1746
|
+
reference: () => Ae(De, a.value.query.more, () => ae.label),
|
|
1747
1747
|
default: ae.content
|
|
1748
1748
|
}) : (ae.props.slot = "query-" + ae.key, ae.label ? Ae(ae.component, ae.props, () => ae.label) : Ae(ae.component, ae.props)));
|
|
1749
1749
|
};
|
|
1750
1750
|
return (q, B) => {
|
|
1751
|
-
var K, ve, ge, be, ie, de, fe, ae, $e, ne, b, o,
|
|
1751
|
+
var K, ve, ge, be, ie, de, fe, ae, $e, ne, b, o, _, p, r, v, g;
|
|
1752
1752
|
const se = I("el-form-item"), re = I("el-drawer");
|
|
1753
1753
|
return n(), F(G, null, [
|
|
1754
1754
|
X("div", {
|
|
1755
1755
|
class: "g-query-container",
|
|
1756
|
-
style: Ie((ve = (K =
|
|
1756
|
+
style: Ie((ve = (K = a.value.query) == null ? void 0 : K.container) == null ? void 0 : ve.style)
|
|
1757
1757
|
}, [
|
|
1758
|
-
Z(U(
|
|
1759
|
-
onSubmit: B[0] || (B[0] =
|
|
1758
|
+
Z(U(dt), S({
|
|
1759
|
+
onSubmit: B[0] || (B[0] = ct(() => {
|
|
1760
1760
|
}, ["prevent"]))
|
|
1761
|
-
}, U(Ve)(
|
|
1761
|
+
}, U(Ve)(a.value.query, (s) => !["query", "more", "reset", "btns"].includes(s))), {
|
|
1762
1762
|
default: h(() => {
|
|
1763
|
-
var s,
|
|
1763
|
+
var s, k;
|
|
1764
1764
|
return [
|
|
1765
|
-
(n(),
|
|
1766
|
-
((
|
|
1765
|
+
(n(), C(Ye($({ slots: q.$slots }, void 0)))),
|
|
1766
|
+
((k = (s = a.value.query) == null ? void 0 : s.container) == null ? void 0 : k.inline) === !0 ? (n(), C(se, { key: 0 }, {
|
|
1767
1767
|
default: h(() => {
|
|
1768
1768
|
var V, j, J, Y, O;
|
|
1769
1769
|
return [
|
|
1770
1770
|
X("div", {
|
|
1771
|
-
style: Ie((j = (V =
|
|
1771
|
+
style: Ie((j = (V = a.value.query) == null ? void 0 : V.btns) == null ? void 0 : j.style)
|
|
1772
1772
|
}, [
|
|
1773
|
-
|
|
1773
|
+
a.value.query.group ? (n(), C(U(ft), { key: 0 }, {
|
|
1774
1774
|
default: h(() => [
|
|
1775
1775
|
(n(!0), F(G, null, L(te(), (ue) => y(q.$slots, ue.props.slot, {}, () => [
|
|
1776
|
-
(n(),
|
|
1776
|
+
(n(), C(Ye(ue)))
|
|
1777
1777
|
], !0)), 256)),
|
|
1778
1778
|
y(q.$slots, "q-btns", {}, void 0, !0)
|
|
1779
1779
|
]),
|
|
1780
1780
|
_: 3
|
|
1781
1781
|
})) : (n(), F(G, { key: 1 }, [
|
|
1782
|
-
(O = (Y = (J =
|
|
1782
|
+
(O = (Y = (J = a.value) == null ? void 0 : J.query) == null ? void 0 : Y.btns) != null && O.group ? (n(), C(U(ft), { key: 0 }, {
|
|
1783
1783
|
default: h(() => [
|
|
1784
1784
|
(n(!0), F(G, null, L(te(), (ue) => y(q.$slots, ue.props.slot, {}, () => [
|
|
1785
|
-
(n(),
|
|
1785
|
+
(n(), C(Ye(ue)))
|
|
1786
1786
|
], !0)), 256))
|
|
1787
1787
|
]),
|
|
1788
1788
|
_: 3
|
|
1789
1789
|
})) : (n(!0), F(G, { key: 1 }, L(te(), (ue) => y(q.$slots, ue.props.slot, {}, () => [
|
|
1790
|
-
(n(),
|
|
1790
|
+
(n(), C(Ye(ue)))
|
|
1791
1791
|
], !0)), 256)),
|
|
1792
1792
|
y(q.$slots, "q-btns", {}, void 0, !0)
|
|
1793
1793
|
], 64))
|
|
@@ -1800,57 +1800,57 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1800
1800
|
}),
|
|
1801
1801
|
_: 3
|
|
1802
1802
|
}, 16),
|
|
1803
|
-
((ie = (be = (ge =
|
|
1803
|
+
((ie = (be = (ge = a.value) == null ? void 0 : ge.query) == null ? void 0 : be.container) == null ? void 0 : ie.inline) === !1 ? (n(), F("div", {
|
|
1804
1804
|
key: 0,
|
|
1805
|
-
style: Ie((fe = (de =
|
|
1805
|
+
style: Ie((fe = (de = a.value.query) == null ? void 0 : de.btns) == null ? void 0 : fe.style)
|
|
1806
1806
|
}, [
|
|
1807
|
-
|
|
1807
|
+
a.value.query.group ? (n(), C(U(ft), { key: 0 }, {
|
|
1808
1808
|
default: h(() => [
|
|
1809
1809
|
(n(!0), F(G, null, L(te(), (s) => y(q.$slots, s.props.slot, {}, () => [
|
|
1810
|
-
(n(),
|
|
1810
|
+
(n(), C(Ye(s)))
|
|
1811
1811
|
], !0)), 256)),
|
|
1812
1812
|
y(q.$slots, "q-btns", {}, void 0, !0)
|
|
1813
1813
|
]),
|
|
1814
1814
|
_: 3
|
|
1815
1815
|
})) : (n(), F(G, { key: 1 }, [
|
|
1816
|
-
($e = (ae =
|
|
1816
|
+
($e = (ae = a.value.query) == null ? void 0 : ae.btns) != null && $e.group ? (n(), C(U(ft), { key: 0 }, {
|
|
1817
1817
|
default: h(() => [
|
|
1818
1818
|
(n(!0), F(G, null, L(te(), (s) => y(q.$slots, s.props.slot, {}, () => [
|
|
1819
|
-
(n(),
|
|
1819
|
+
(n(), C(Ye(s)))
|
|
1820
1820
|
], !0)), 256))
|
|
1821
1821
|
]),
|
|
1822
1822
|
_: 3
|
|
1823
1823
|
})) : (n(!0), F(G, { key: 1 }, L(te(), (s) => y(q.$slots, s.props.slot, {}, () => [
|
|
1824
|
-
(n(),
|
|
1824
|
+
(n(), C(Ye(s)))
|
|
1825
1825
|
], !0)), 256)),
|
|
1826
1826
|
y(q.$slots, "q-btns", {}, void 0, !0)
|
|
1827
1827
|
], 64))
|
|
1828
1828
|
], 4)) : pe("", !0)
|
|
1829
1829
|
], 4),
|
|
1830
|
-
|
|
1830
|
+
i.value && !((o = (b = (ne = a.value) == null ? void 0 : ne.query) == null ? void 0 : b.more) != null && o.hidden) && a.value.query.more.mode == 2 ? (n(), C(re, S({
|
|
1831
1831
|
key: 0,
|
|
1832
|
-
modelValue:
|
|
1833
|
-
"onUpdate:modelValue": B[6] || (B[6] = (s) =>
|
|
1832
|
+
modelValue: i.value,
|
|
1833
|
+
"onUpdate:modelValue": B[6] || (B[6] = (s) => i.value = s),
|
|
1834
1834
|
title: "更多查询",
|
|
1835
1835
|
"show-close": !1
|
|
1836
|
-
},
|
|
1836
|
+
}, a.value.query.more.dialog), me({
|
|
1837
1837
|
default: h(() => [
|
|
1838
|
-
Z(U(
|
|
1839
|
-
onSubmit: B[3] || (B[3] =
|
|
1838
|
+
Z(U(dt), S({
|
|
1839
|
+
onSubmit: B[3] || (B[3] = ct(() => {
|
|
1840
1840
|
}, ["prevent"]))
|
|
1841
|
-
}, U(Ve)(
|
|
1841
|
+
}, U(Ve)(a.value.query, (s) => !["query", "more", "reset"].includes(s)), { style: { width: "98%" } }), {
|
|
1842
1842
|
default: h(() => [
|
|
1843
1843
|
Z(Dt, {
|
|
1844
|
-
modelValue:
|
|
1845
|
-
"onUpdate:modelValue": B[1] || (B[1] = (s) =>
|
|
1844
|
+
modelValue: a.value,
|
|
1845
|
+
"onUpdate:modelValue": B[1] || (B[1] = (s) => a.value = s),
|
|
1846
1846
|
info: E.value,
|
|
1847
1847
|
"onUpdate:info": B[2] || (B[2] = (s) => E.value = s),
|
|
1848
1848
|
more: !0
|
|
1849
1849
|
}, me({ _: 2 }, [
|
|
1850
|
-
L(q.$slots, (s,
|
|
1851
|
-
name:
|
|
1850
|
+
L(q.$slots, (s, k, V) => ({
|
|
1851
|
+
name: k,
|
|
1852
1852
|
fn: h((j) => [
|
|
1853
|
-
y(q.$slots,
|
|
1853
|
+
y(q.$slots, k, { model: a.value }, void 0, !0)
|
|
1854
1854
|
])
|
|
1855
1855
|
}))
|
|
1856
1856
|
]), 1032, ["modelValue", "info"])
|
|
@@ -1860,23 +1860,23 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1860
1860
|
]),
|
|
1861
1861
|
_: 2
|
|
1862
1862
|
}, [
|
|
1863
|
-
(g = (v = (
|
|
1863
|
+
(g = (v = (r = (p = (_ = a.value) == null ? void 0 : _.query) == null ? void 0 : p.more) == null ? void 0 : r.dialog) == null ? void 0 : v.footer) != null && g.hidden ? void 0 : {
|
|
1864
1864
|
name: "footer",
|
|
1865
1865
|
fn: h(() => [
|
|
1866
|
-
X("div", gt(
|
|
1867
|
-
Z(U(De), S(
|
|
1868
|
-
onClick: B[4] || (B[4] = (s) =>
|
|
1866
|
+
X("div", gt(Lt(a.value.query.more.dialog.footer)), [
|
|
1867
|
+
Z(U(De), S(a.value.query.query, {
|
|
1868
|
+
onClick: B[4] || (B[4] = (s) => a.value.query.query.click())
|
|
1869
1869
|
}), {
|
|
1870
1870
|
default: h(() => [
|
|
1871
|
-
Me(ye(
|
|
1871
|
+
Me(ye(a.value.query.query.label), 1)
|
|
1872
1872
|
]),
|
|
1873
1873
|
_: 1
|
|
1874
1874
|
}, 16),
|
|
1875
|
-
Z(U(De), S(
|
|
1876
|
-
onClick: B[5] || (B[5] = (s) =>
|
|
1875
|
+
Z(U(De), S(a.value.query.reset, {
|
|
1876
|
+
onClick: B[5] || (B[5] = (s) => a.value.query.reset.click())
|
|
1877
1877
|
}), {
|
|
1878
1878
|
default: h(() => [
|
|
1879
|
-
Me(ye(
|
|
1879
|
+
Me(ye(a.value.query.reset.label), 1)
|
|
1880
1880
|
]),
|
|
1881
1881
|
_: 1
|
|
1882
1882
|
}, 16)
|
|
@@ -1885,27 +1885,27 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1885
1885
|
key: "0"
|
|
1886
1886
|
}
|
|
1887
1887
|
]), 1040, ["modelValue"])) : pe("", !0),
|
|
1888
|
-
Z(
|
|
1888
|
+
Z(jt, {
|
|
1889
1889
|
duration: 300,
|
|
1890
1890
|
name: "nested",
|
|
1891
1891
|
style: { padding: "10px" }
|
|
1892
1892
|
}, {
|
|
1893
1893
|
default: h(() => {
|
|
1894
|
-
var s,
|
|
1894
|
+
var s, k, V;
|
|
1895
1895
|
return [
|
|
1896
|
-
|
|
1897
|
-
X("div",
|
|
1898
|
-
|
|
1896
|
+
i.value && !((V = (k = (s = a.value) == null ? void 0 : s.query) == null ? void 0 : k.more) != null && V.hidden) && a.value.query.more.mode == 1 ? (n(), F("div", $l, [
|
|
1897
|
+
X("div", wl, [
|
|
1898
|
+
a.value.query.more.mode == 1 ? zt((n(), C(U(dt), S({
|
|
1899
1899
|
key: 0,
|
|
1900
|
-
onSubmit: B[7] || (B[7] =
|
|
1900
|
+
onSubmit: B[7] || (B[7] = ct(() => {
|
|
1901
1901
|
}, ["prevent"]))
|
|
1902
|
-
}, U(Ve)(
|
|
1902
|
+
}, U(Ve)(a.value.query, (j) => !["query", "more", "reset"].includes(j))), {
|
|
1903
1903
|
default: h(() => [
|
|
1904
|
-
(n(),
|
|
1904
|
+
(n(), C(Ye($({ slots: q.$slots }, !0))))
|
|
1905
1905
|
]),
|
|
1906
1906
|
_: 1
|
|
1907
1907
|
}, 16)), [
|
|
1908
|
-
[
|
|
1908
|
+
[Ht, i.value]
|
|
1909
1909
|
]) : pe("", !0)
|
|
1910
1910
|
])
|
|
1911
1911
|
])) : pe("", !0)
|
|
@@ -1916,18 +1916,18 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1916
1916
|
], 64);
|
|
1917
1917
|
};
|
|
1918
1918
|
}
|
|
1919
|
-
},
|
|
1919
|
+
}, _l = /* @__PURE__ */ We(El, [["__scopeId", "data-v-46ed95d5"]]), kl = { style: { padding: "0", margin: "0", "box-sizing": "border-box" } }, Cl = { style: { padding: "10px", "box-sizing": "border-box" } }, Dl = { style: { margin: "10px" } }, Ml = {
|
|
1920
1920
|
style: { display: "flex", "flex-wrap": "wrap" },
|
|
1921
1921
|
id: "excelSortEl"
|
|
1922
|
-
},
|
|
1922
|
+
}, Vl = ["textContent"], Tl = { style: { width: "100%", display: "flex", padding: "10px", "box-sizing": "border-box", "justify-content": "center", "border-top": "1px solid #dcdfe6" } }, Sl = {
|
|
1923
1923
|
__name: "check-excel-item",
|
|
1924
1924
|
props: {
|
|
1925
1925
|
items: Array,
|
|
1926
1926
|
commitText: String
|
|
1927
1927
|
},
|
|
1928
1928
|
emits: ["excel"],
|
|
1929
|
-
setup(
|
|
1930
|
-
const
|
|
1929
|
+
setup(d, { emit: f }) {
|
|
1930
|
+
const a = d, t = f, e = le(a.items), i = () => {
|
|
1931
1931
|
e.value.forEach((T) => {
|
|
1932
1932
|
T.value = !0;
|
|
1933
1933
|
});
|
|
@@ -1936,39 +1936,39 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1936
1936
|
T.value = !1;
|
|
1937
1937
|
});
|
|
1938
1938
|
}, x = () => {
|
|
1939
|
-
t("excel", e.value, (T,
|
|
1939
|
+
t("excel", e.value, (T, D = "excel.xls") => {
|
|
1940
1940
|
if (!T) {
|
|
1941
1941
|
console.error("下载链接无效");
|
|
1942
1942
|
return;
|
|
1943
1943
|
}
|
|
1944
1944
|
try {
|
|
1945
|
-
const
|
|
1946
|
-
|
|
1947
|
-
} catch (
|
|
1948
|
-
console.error("下载文件时出现错误:",
|
|
1945
|
+
const $ = document.createElement("a");
|
|
1946
|
+
$.href = T, $.download = D, $.style.display = "none", document.body.appendChild($), $.click(), document.body.removeChild($);
|
|
1947
|
+
} catch ($) {
|
|
1948
|
+
console.error("下载文件时出现错误:", $);
|
|
1949
1949
|
}
|
|
1950
1950
|
});
|
|
1951
1951
|
};
|
|
1952
|
-
return
|
|
1953
|
-
const T = new
|
|
1952
|
+
return rt(() => {
|
|
1953
|
+
const T = new Ft(document.getElementById("excelSortEl"), {
|
|
1954
1954
|
animation: 150,
|
|
1955
1955
|
onEnd: () => {
|
|
1956
1956
|
T.toArray();
|
|
1957
1957
|
}
|
|
1958
|
-
}),
|
|
1959
|
-
|
|
1960
|
-
|
|
1958
|
+
}), D = T;
|
|
1959
|
+
Nt(() => {
|
|
1960
|
+
D && D.destroy();
|
|
1961
1961
|
});
|
|
1962
|
-
}), (T,
|
|
1963
|
-
const
|
|
1964
|
-
return n(), F("div",
|
|
1965
|
-
X("div",
|
|
1966
|
-
X("div",
|
|
1962
|
+
}), (T, D) => {
|
|
1963
|
+
const $ = I("el-divider"), z = I("el-alert"), te = I("el-checkbox"), q = I("el-button");
|
|
1964
|
+
return n(), F("div", kl, [
|
|
1965
|
+
X("div", Cl, [
|
|
1966
|
+
X("div", Dl, [
|
|
1967
1967
|
X("a", {
|
|
1968
|
-
onClick:
|
|
1968
|
+
onClick: i,
|
|
1969
1969
|
style: { cursor: "pointer" }
|
|
1970
1970
|
}, "全选"),
|
|
1971
|
-
Z(
|
|
1971
|
+
Z($, { direction: "vertical" }),
|
|
1972
1972
|
X("a", {
|
|
1973
1973
|
onClick: E,
|
|
1974
1974
|
style: { cursor: "pointer" }
|
|
@@ -1981,9 +1981,9 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1981
1981
|
closable: !1,
|
|
1982
1982
|
style: { "margin-bottom": "10px" }
|
|
1983
1983
|
}),
|
|
1984
|
-
|
|
1985
|
-
X("div",
|
|
1986
|
-
(n(!0), F(G, null, L(e.value, (B) => (n(),
|
|
1984
|
+
D[0] || (D[0] = X("div", { style: { margin: "1px 0" } }, null, -1)),
|
|
1985
|
+
X("div", Ml, [
|
|
1986
|
+
(n(!0), F(G, null, L(e.value, (B) => (n(), C(te, {
|
|
1987
1987
|
class: "check-box-hover",
|
|
1988
1988
|
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" },
|
|
1989
1989
|
"data-id": B.key,
|
|
@@ -1996,20 +1996,20 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
1996
1996
|
X("span", {
|
|
1997
1997
|
textContent: ye(B.label),
|
|
1998
1998
|
style: { display: "block", "text-overflow": "ellipsis", width: "95px", overflow: "hidden" }
|
|
1999
|
-
}, null, 8,
|
|
1999
|
+
}, null, 8, Vl)
|
|
2000
2000
|
]),
|
|
2001
2001
|
_: 2
|
|
2002
2002
|
}, 1032, ["data-id", "modelValue", "onUpdate:modelValue", "title"]))), 128))
|
|
2003
2003
|
])
|
|
2004
2004
|
]),
|
|
2005
|
-
X("div",
|
|
2005
|
+
X("div", Tl, [
|
|
2006
2006
|
Z(q, {
|
|
2007
2007
|
type: "primary",
|
|
2008
2008
|
onClick: x,
|
|
2009
2009
|
disabled: e.value.filter((B) => B.value).length < 1
|
|
2010
2010
|
}, {
|
|
2011
2011
|
default: h(() => [
|
|
2012
|
-
Me(ye(
|
|
2012
|
+
Me(ye(a.commitText), 1)
|
|
2013
2013
|
]),
|
|
2014
2014
|
_: 1
|
|
2015
2015
|
}, 8, ["disabled"])
|
|
@@ -2017,44 +2017,50 @@ const yt = /* @__PURE__ */ al(rl), We = (i, f) => {
|
|
|
2017
2017
|
]);
|
|
2018
2018
|
};
|
|
2019
2019
|
}
|
|
2020
|
-
},
|
|
2020
|
+
}, xl = /* @__PURE__ */ We(Sl, [["__scopeId", "data-v-04791df1"]]), He = new tl("gyc");
|
|
2021
2021
|
He.version(1).stores({
|
|
2022
2022
|
tableInfo: "++id,[user+page+key],user,page,key,showCol,width,sort",
|
|
2023
2023
|
tableList: "++id,name"
|
|
2024
2024
|
});
|
|
2025
|
-
async function
|
|
2026
|
-
if (await He.tableInfo.where({ user:
|
|
2027
|
-
let
|
|
2028
|
-
return await He.tableInfo.put({ ...
|
|
2025
|
+
async function vt(d, f, a, t = {}) {
|
|
2026
|
+
if (await He.tableInfo.where({ user: d, page: f, key: a }).count() > 0) {
|
|
2027
|
+
let i = await He.tableInfo.where({ user: d, page: f, key: a }).first();
|
|
2028
|
+
return await He.tableInfo.put({ ...i, ...t }), "update success";
|
|
2029
2029
|
} else {
|
|
2030
|
-
let
|
|
2031
|
-
return await He.tableInfo.add({ user:
|
|
2030
|
+
let i = { showCol: !0, width: "auto", sort: 0, ...t };
|
|
2031
|
+
return await He.tableInfo.add({ user: d, page: f, key: a, ...i }), "add success";
|
|
2032
2032
|
}
|
|
2033
2033
|
}
|
|
2034
|
-
async function
|
|
2035
|
-
|
|
2034
|
+
async function Mt(d, f, a, t = {}) {
|
|
2035
|
+
const e = a.map(
|
|
2036
|
+
(i) => vt(d, f, i.value, { ...i, ...t })
|
|
2037
|
+
);
|
|
2038
|
+
return await Promise.all(e), "batch update success";
|
|
2039
|
+
}
|
|
2040
|
+
async function Fl(d, f) {
|
|
2041
|
+
return await He.tableInfo.where({ user: d, page: f }).toArray();
|
|
2036
2042
|
}
|
|
2037
|
-
async function
|
|
2043
|
+
async function ql(d, f) {
|
|
2038
2044
|
try {
|
|
2039
|
-
const
|
|
2040
|
-
return console.log("删除了" +
|
|
2041
|
-
} catch (
|
|
2042
|
-
throw console.error("删除表格项设置信息时出错:",
|
|
2045
|
+
const a = await He.tableInfo.where({ user: d, page: f }).delete();
|
|
2046
|
+
return console.log("删除了" + a + "条数据"), a;
|
|
2047
|
+
} catch (a) {
|
|
2048
|
+
throw console.error("删除表格项设置信息时出错:", a), a;
|
|
2043
2049
|
}
|
|
2044
2050
|
}
|
|
2045
|
-
async function
|
|
2046
|
-
return await He.tableList.where({ name:
|
|
2051
|
+
async function Ol(d) {
|
|
2052
|
+
return await He.tableList.where({ name: d }).first();
|
|
2047
2053
|
}
|
|
2048
|
-
async function
|
|
2049
|
-
return typeof
|
|
2054
|
+
async function Al(d) {
|
|
2055
|
+
return typeof d == "string" && (d = { name: d }), await He.tableList.add(d), "add success";
|
|
2050
2056
|
}
|
|
2051
|
-
const
|
|
2057
|
+
const Il = {
|
|
2052
2058
|
style: { margin: "10px" },
|
|
2053
2059
|
class: "allcheck"
|
|
2054
|
-
},
|
|
2060
|
+
}, Bl = {
|
|
2055
2061
|
id: "cols",
|
|
2056
2062
|
style: { display: "flex", "flex-wrap": "wrap", margin: "0 !important", padding: "0 !important" }
|
|
2057
|
-
},
|
|
2063
|
+
}, Yl = ["textContent"], Ul = {
|
|
2058
2064
|
__name: "columns-setting",
|
|
2059
2065
|
props: /* @__PURE__ */ Ne({
|
|
2060
2066
|
name: {
|
|
@@ -2066,31 +2072,31 @@ const Al = {
|
|
|
2066
2072
|
modelModifiers: {}
|
|
2067
2073
|
}),
|
|
2068
2074
|
emits: ["update:modelValue"],
|
|
2069
|
-
setup(
|
|
2070
|
-
const f =
|
|
2071
|
-
|
|
2075
|
+
setup(d) {
|
|
2076
|
+
const f = d, a = le([]), t = Pe(d, "modelValue"), e = async (D, $) => {
|
|
2077
|
+
D ? t.value[$].showCol = !0 : t.value[$].showCol = !1;
|
|
2072
2078
|
try {
|
|
2073
|
-
await
|
|
2079
|
+
await vt(t.value.table.user, f.name, $, { showCol: D });
|
|
2074
2080
|
} catch (z) {
|
|
2075
2081
|
console.error("列显示状态保存信息时出错:", z), Fe({
|
|
2076
2082
|
type: "error",
|
|
2077
2083
|
message: "列显示状态保存信息失败!"
|
|
2078
2084
|
});
|
|
2079
2085
|
}
|
|
2080
|
-
},
|
|
2081
|
-
const
|
|
2082
|
-
if (
|
|
2083
|
-
let
|
|
2086
|
+
}, i = () => {
|
|
2087
|
+
const D = document.getElementById("cols");
|
|
2088
|
+
if (D) {
|
|
2089
|
+
let $ = Ft.create(D, {
|
|
2084
2090
|
animation: 150,
|
|
2085
2091
|
filter: ".filtered",
|
|
2086
2092
|
//
|
|
2087
2093
|
sort: !0,
|
|
2088
2094
|
onEnd: () => {
|
|
2089
|
-
|
|
2095
|
+
$.toArray().forEach(async (te, q) => {
|
|
2090
2096
|
t.value[te].sort = q;
|
|
2091
2097
|
let B = t.value[te].width || "auto";
|
|
2092
2098
|
try {
|
|
2093
|
-
await
|
|
2099
|
+
await vt(t.value.table.user, f.name, te, { sort: q, width: B });
|
|
2094
2100
|
} catch (se) {
|
|
2095
2101
|
console.error("列排序和宽度保存信息时出错:", se), Fe({
|
|
2096
2102
|
type: "error",
|
|
@@ -2103,62 +2109,55 @@ const Al = {
|
|
|
2103
2109
|
}
|
|
2104
2110
|
}, E = async () => {
|
|
2105
2111
|
try {
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
sort: _.sort
|
|
2111
|
-
});
|
|
2112
|
-
} catch (_) {
|
|
2113
|
-
console.error("全选列保存信息时出错:", _), Fe({
|
|
2112
|
+
const D = a.value.map(($) => ($.showCol = !0, t.value[$.value].showCol = !0, $));
|
|
2113
|
+
await Mt(t.value.table.user, f.name, D, { showCol: !0 });
|
|
2114
|
+
} catch (D) {
|
|
2115
|
+
console.error("全选列保存信息时出错:", D), Fe({
|
|
2114
2116
|
type: "error",
|
|
2115
2117
|
message: "全选列保存信息失败!"
|
|
2116
2118
|
});
|
|
2117
2119
|
}
|
|
2118
2120
|
}, x = async () => {
|
|
2119
2121
|
try {
|
|
2120
|
-
const
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
});
|
|
2127
|
-
} catch (_) {
|
|
2128
|
-
console.error("清除列保存信息时出错:", _), Fe({
|
|
2122
|
+
const D = a.value.filter(($) => !$.alwaysShow && $.value != "control");
|
|
2123
|
+
D.forEach(($) => {
|
|
2124
|
+
$.showCol = !1, t.value[$.value].showCol = !1;
|
|
2125
|
+
}), await Mt(t.value.table.user, f.name, D, { showCol: !1 });
|
|
2126
|
+
} catch (D) {
|
|
2127
|
+
console.error("清除列保存信息时出错:", D), Fe({
|
|
2129
2128
|
type: "error",
|
|
2130
2129
|
message: "清除列保存信息失败!"
|
|
2131
2130
|
});
|
|
2132
2131
|
}
|
|
2133
2132
|
}, T = () => {
|
|
2134
|
-
|
|
2133
|
+
Tt.confirm("确定要复位吗?", "提示", {
|
|
2135
2134
|
confirmButtonText: "确定",
|
|
2136
2135
|
cancelButtonText: "取消",
|
|
2137
2136
|
type: "warning"
|
|
2138
2137
|
}).then(() => {
|
|
2139
|
-
|
|
2138
|
+
ql(t.value.table.user, f.name).then((D) => {
|
|
2140
2139
|
window.location.reload();
|
|
2141
|
-
}).catch((
|
|
2142
|
-
console.error("复位操作出错:",
|
|
2140
|
+
}).catch((D) => {
|
|
2141
|
+
console.error("复位操作出错:", D), Fe({
|
|
2143
2142
|
type: "info",
|
|
2144
2143
|
message: "复位失败!"
|
|
2145
2144
|
});
|
|
2146
2145
|
});
|
|
2147
2146
|
});
|
|
2148
2147
|
};
|
|
2149
|
-
return
|
|
2150
|
-
|
|
2151
|
-
label:
|
|
2152
|
-
value:
|
|
2153
|
-
alwaysShow:
|
|
2154
|
-
showCol:
|
|
2155
|
-
sort:
|
|
2156
|
-
width:
|
|
2157
|
-
})).sort((
|
|
2158
|
-
}), (
|
|
2148
|
+
return rt(async () => {
|
|
2149
|
+
a.value = Object.entries(t.value).filter(([, D]) => D.visible !== !1).filter(([, D]) => D.type != "hidden").map(([D, $]) => ({
|
|
2150
|
+
label: $.label,
|
|
2151
|
+
value: D,
|
|
2152
|
+
alwaysShow: $.alwaysShow,
|
|
2153
|
+
showCol: $.showCol !== !1,
|
|
2154
|
+
sort: $.sort || 0,
|
|
2155
|
+
width: $.width || "auto"
|
|
2156
|
+
})).sort((D, $) => D.sort - $.sort), i();
|
|
2157
|
+
}), (D, $) => {
|
|
2159
2158
|
const z = I("el-divider"), te = I("el-alert"), q = I("el-checkbox");
|
|
2160
2159
|
return n(), F("div", null, [
|
|
2161
|
-
X("div",
|
|
2160
|
+
X("div", Il, [
|
|
2162
2161
|
X("a", { onClick: E }, "全选"),
|
|
2163
2162
|
Z(z, { direction: "vertical" }),
|
|
2164
2163
|
X("a", { onClick: x }, "全不选"),
|
|
@@ -2173,12 +2172,12 @@ const Al = {
|
|
|
2173
2172
|
style: { "margin-bottom": "10px" }
|
|
2174
2173
|
}),
|
|
2175
2174
|
X("div", null, [
|
|
2176
|
-
X("div",
|
|
2177
|
-
(n(!0), F(G, null, L(
|
|
2175
|
+
X("div", Bl, [
|
|
2176
|
+
(n(!0), F(G, null, L(a.value, (B) => (n(), C(q, {
|
|
2178
2177
|
modelValue: B.showCol,
|
|
2179
2178
|
"onUpdate:modelValue": (se) => B.showCol = se,
|
|
2180
2179
|
"data-id": B.value,
|
|
2181
|
-
class:
|
|
2180
|
+
class: xt(["check-box-hover", B.value == "control" ? "filtered" : ""]),
|
|
2182
2181
|
onChange: (se) => e(se, B.value),
|
|
2183
2182
|
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" },
|
|
2184
2183
|
value: B.value,
|
|
@@ -2190,7 +2189,7 @@ const Al = {
|
|
|
2190
2189
|
X("span", {
|
|
2191
2190
|
textContent: ye(B.label),
|
|
2192
2191
|
style: { display: "block", "text-overflow": "ellipsis", width: "95px", overflow: "hidden" }
|
|
2193
|
-
}, null, 8,
|
|
2192
|
+
}, null, 8, Yl)
|
|
2194
2193
|
]),
|
|
2195
2194
|
_: 2
|
|
2196
2195
|
}, 1032, ["modelValue", "onUpdate:modelValue", "data-id", "class", "onChange", "value", "title", "disabled"]))), 128))
|
|
@@ -2199,7 +2198,7 @@ const Al = {
|
|
|
2199
2198
|
]);
|
|
2200
2199
|
};
|
|
2201
2200
|
}
|
|
2202
|
-
},
|
|
2201
|
+
}, Rl = /* @__PURE__ */ We(Ul, [["__scopeId", "data-v-23dc31e2"]]), Ll = { class: "title" }, jl = { class: "content" }, zl = {
|
|
2203
2202
|
__name: "g-cell-toopTip",
|
|
2204
2203
|
props: {
|
|
2205
2204
|
content: {
|
|
@@ -2211,34 +2210,34 @@ const Al = {
|
|
|
2211
2210
|
default: () => ({})
|
|
2212
2211
|
}
|
|
2213
2212
|
},
|
|
2214
|
-
setup(
|
|
2215
|
-
const f =
|
|
2213
|
+
setup(d) {
|
|
2214
|
+
const f = d, a = () => {
|
|
2216
2215
|
f.content ? (navigator.clipboard.writeText(f.content), Fe.success("复制成功")) : Fe.warning("没有内容可复制");
|
|
2217
2216
|
};
|
|
2218
2217
|
return (t, e) => (n(), F("div", {
|
|
2219
2218
|
class: "g-cell-toopTip",
|
|
2220
2219
|
style: Ie({ width: f.column.width + "px" })
|
|
2221
2220
|
}, [
|
|
2222
|
-
X("div",
|
|
2221
|
+
X("div", Ll, [
|
|
2223
2222
|
e[0] || (e[0] = X("span", { class: "title-text" }, "内容", -1)),
|
|
2224
2223
|
X("span", {
|
|
2225
2224
|
class: "copy-btn",
|
|
2226
|
-
onClick:
|
|
2225
|
+
onClick: a,
|
|
2227
2226
|
title: "复制内容"
|
|
2228
2227
|
}, [
|
|
2229
|
-
Z(U(
|
|
2228
|
+
Z(U(Jt))
|
|
2230
2229
|
])
|
|
2231
2230
|
]),
|
|
2232
|
-
X("div",
|
|
2231
|
+
X("div", jl, ye(f.content), 1)
|
|
2233
2232
|
], 4));
|
|
2234
2233
|
}
|
|
2235
|
-
},
|
|
2234
|
+
}, Hl = /* @__PURE__ */ We(zl, [["__scopeId", "data-v-f28912da"]]), Nl = { key: 0 }, Pl = { style: { display: "flex", "margin-top": "-2px" } }, Wl = { style: { display: "flex", flex: "1" } }, Xl = {
|
|
2236
2235
|
style: { display: "flex", "justify-content": "center", width: "100%", height: "100%" },
|
|
2237
2236
|
id: "table-form"
|
|
2238
|
-
},
|
|
2237
|
+
}, Gl = { key: 1 }, Ql = { style: { display: "flex" } }, Zl = { style: { display: "flex", flex: "1" } }, Jl = { class: "g-table-container" }, Kl = {
|
|
2239
2238
|
key: 0,
|
|
2240
2239
|
class: "table-query-container"
|
|
2241
|
-
},
|
|
2240
|
+
}, ea = { class: "table-container" }, ta = ["innerHTML"], la = /* @__PURE__ */ Object.assign({
|
|
2242
2241
|
name: "g-table",
|
|
2243
2242
|
inheritAttrs: !1
|
|
2244
2243
|
}, {
|
|
@@ -2259,11 +2258,11 @@ const Al = {
|
|
|
2259
2258
|
"download",
|
|
2260
2259
|
"row-save"
|
|
2261
2260
|
], ["update:modelValue"]),
|
|
2262
|
-
setup(
|
|
2263
|
-
var Re,
|
|
2264
|
-
const t =
|
|
2265
|
-
E.value = Object.fromEntries(
|
|
2266
|
-
const
|
|
2261
|
+
setup(d, { expose: f, emit: a }) {
|
|
2262
|
+
var Re, ot, tt, ut, nt, st, lt;
|
|
2263
|
+
const t = a, e = Pe(d, "modelValue"), i = _t("options"), E = le({}), x = le(null), T = le(null), D = Object.entries(e.value).filter(([l, u]) => (u == null ? void 0 : u.search) !== void 0).map(([l, u]) => [l, u.value]);
|
|
2264
|
+
E.value = Object.fromEntries(D);
|
|
2265
|
+
const $ = le(!1), z = [
|
|
2267
2266
|
"type",
|
|
2268
2267
|
"index",
|
|
2269
2268
|
"label",
|
|
@@ -2292,7 +2291,7 @@ const Al = {
|
|
|
2292
2291
|
"filter-multiple",
|
|
2293
2292
|
"filter-method",
|
|
2294
2293
|
"filtered-value"
|
|
2295
|
-
], te = le([]), q =
|
|
2294
|
+
], te = le([]), q = d, B = kt(), se = le({}), re = le([]), K = le(null), ve = le(""), ge = le({
|
|
2296
2295
|
autoWatch: !1,
|
|
2297
2296
|
data: [],
|
|
2298
2297
|
border: !0,
|
|
@@ -2326,7 +2325,7 @@ const Al = {
|
|
|
2326
2325
|
},
|
|
2327
2326
|
onHeaderDragend: (l, u, c) => {
|
|
2328
2327
|
var M;
|
|
2329
|
-
|
|
2328
|
+
vt((M = e.value.table) == null ? void 0 : M.user, q.name, c.property, {
|
|
2330
2329
|
width: l
|
|
2331
2330
|
});
|
|
2332
2331
|
},
|
|
@@ -2361,7 +2360,7 @@ const Al = {
|
|
|
2361
2360
|
});
|
|
2362
2361
|
e.value.table = qe(
|
|
2363
2362
|
ge.value,
|
|
2364
|
-
|
|
2363
|
+
i == null ? void 0 : i.table,
|
|
2365
2364
|
e.value.table,
|
|
2366
2365
|
B
|
|
2367
2366
|
// 继承父组件的属性
|
|
@@ -2372,7 +2371,7 @@ const Al = {
|
|
|
2372
2371
|
align: "center",
|
|
2373
2372
|
"min-width": 100,
|
|
2374
2373
|
fixed: "right",
|
|
2375
|
-
style: { ...(
|
|
2374
|
+
style: { ...(ot = (Re = e.value) == null ? void 0 : Re.control) == null ? void 0 : ot.style },
|
|
2376
2375
|
validate: async (l) => await !0,
|
|
2377
2376
|
add: {
|
|
2378
2377
|
label: "新增",
|
|
@@ -2453,33 +2452,33 @@ const Al = {
|
|
|
2453
2452
|
onClick: () => {
|
|
2454
2453
|
var N;
|
|
2455
2454
|
let H = (N = ie(l, u, c, M)) == null ? void 0 : N.operate;
|
|
2456
|
-
H === "edit" ? p(l, u, c, M) : H === "delete" ?
|
|
2455
|
+
H === "edit" ? p(l, u, c, M) : H === "delete" ? r(l, u, c, M) : H === "view" && v(l, u, c, M);
|
|
2457
2456
|
},
|
|
2458
2457
|
"button-props": { round: !0, plain: !0 }
|
|
2459
2458
|
})
|
|
2460
2459
|
};
|
|
2461
2460
|
e.value.control = qe(
|
|
2462
2461
|
be,
|
|
2463
|
-
|
|
2462
|
+
i == null ? void 0 : i.control,
|
|
2464
2463
|
(tt = e.value) == null ? void 0 : tt.control
|
|
2465
2464
|
);
|
|
2466
2465
|
const ie = (l, u, c, M) => {
|
|
2467
2466
|
var Ee, Ce, Le, m, W, ce;
|
|
2468
2467
|
if (!l || !u || c == null)
|
|
2469
2468
|
return console.warn("mergeDropdown: 缺少必要的参数(row, column或index)"), {};
|
|
2470
|
-
const H = ((Ee = be.dropdown) == null ? void 0 : Ee.call(be, l, u, c, M)) || {}, N = ((Le = (Ce =
|
|
2469
|
+
const H = ((Ee = be.dropdown) == null ? void 0 : Ee.call(be, l, u, c, M)) || {}, N = ((Le = (Ce = i == null ? void 0 : i.control) == null ? void 0 : Ce.dropdown) == null ? void 0 : Le.call(Ce, l, u, c, M)) || {}, Q = ((ce = (W = (m = e.value) == null ? void 0 : m.control) == null ? void 0 : W.dropdown) == null ? void 0 : ce.call(W, l, u, c, M)) || {};
|
|
2471
2470
|
return qe(H, N, Q) || {};
|
|
2472
2471
|
}, de = {
|
|
2473
2472
|
type: "hidden",
|
|
2474
2473
|
"min-width": 100,
|
|
2475
2474
|
align: "center",
|
|
2476
2475
|
formatter: (l, u, c, M) => c,
|
|
2477
|
-
"tooltip-formatter": ({ row: l, column: u, cellValue: c }) => Ae(
|
|
2476
|
+
"tooltip-formatter": ({ row: l, column: u, cellValue: c }) => Ae(Hl, { content: c, column: u })
|
|
2478
2477
|
};
|
|
2479
2478
|
e.value.tableColumns = qe(
|
|
2480
2479
|
de,
|
|
2481
|
-
|
|
2482
|
-
(
|
|
2480
|
+
i == null ? void 0 : i.tableColumns,
|
|
2481
|
+
(ut = e.value) == null ? void 0 : ut.tableColumns
|
|
2483
2482
|
);
|
|
2484
2483
|
const fe = {
|
|
2485
2484
|
type: "hidden",
|
|
@@ -2489,8 +2488,8 @@ const Al = {
|
|
|
2489
2488
|
};
|
|
2490
2489
|
e.value.form = qe(
|
|
2491
2490
|
fe,
|
|
2492
|
-
|
|
2493
|
-
(
|
|
2491
|
+
i == null ? void 0 : i.form,
|
|
2492
|
+
(nt = e.value) == null ? void 0 : nt.form
|
|
2494
2493
|
);
|
|
2495
2494
|
const ae = {
|
|
2496
2495
|
type: "hidden",
|
|
@@ -2501,8 +2500,8 @@ const Al = {
|
|
|
2501
2500
|
};
|
|
2502
2501
|
e.value.formItems = qe(
|
|
2503
2502
|
ae,
|
|
2504
|
-
|
|
2505
|
-
(
|
|
2503
|
+
i == null ? void 0 : i.formItems,
|
|
2504
|
+
(st = e == null ? void 0 : e.value) == null ? void 0 : st.formItems
|
|
2506
2505
|
);
|
|
2507
2506
|
const $e = {
|
|
2508
2507
|
title: "编辑",
|
|
@@ -2517,17 +2516,17 @@ const Al = {
|
|
|
2517
2516
|
overflow: !0,
|
|
2518
2517
|
max: {
|
|
2519
2518
|
style: {},
|
|
2520
|
-
icon: () => Ae(
|
|
2519
|
+
icon: () => Ae(Kt)
|
|
2521
2520
|
},
|
|
2522
2521
|
min: {
|
|
2523
2522
|
style: {},
|
|
2524
|
-
icon: () => Ae(
|
|
2523
|
+
icon: () => Ae(el)
|
|
2525
2524
|
// 最小化图标
|
|
2526
2525
|
}
|
|
2527
2526
|
};
|
|
2528
2527
|
e.value.dialog = qe(
|
|
2529
2528
|
$e,
|
|
2530
|
-
|
|
2529
|
+
i == null ? void 0 : i.dialog,
|
|
2531
2530
|
(lt = e.value) == null ? void 0 : lt.dialog
|
|
2532
2531
|
);
|
|
2533
2532
|
const ne = (l, u) => {
|
|
@@ -2544,12 +2543,12 @@ const Al = {
|
|
|
2544
2543
|
}
|
|
2545
2544
|
return l.type === "money" && (l.align = l.align || "right", l.width = l.width || 130, c = `<span title="${Et(
|
|
2546
2545
|
parseFloat(c)
|
|
2547
|
-
)}">${
|
|
2546
|
+
)}">${ya(parseFloat(c))}</span>`), l.prefix && c && (c = `<span>${l.prefix}${c}</span>`), l.suffix && c && (c = `${c}<span>${l.suffix}</span>`), c;
|
|
2548
2547
|
}, b = (l) => {
|
|
2549
|
-
E.value = Object.fromEntries(
|
|
2548
|
+
E.value = Object.fromEntries(D), e.value.table.load();
|
|
2550
2549
|
}, o = (l) => {
|
|
2551
2550
|
E.value = l, e.value.table.load();
|
|
2552
|
-
},
|
|
2551
|
+
}, _ = async (l) => {
|
|
2553
2552
|
var u, c;
|
|
2554
2553
|
e.value.form.modalState = "add";
|
|
2555
2554
|
try {
|
|
@@ -2560,7 +2559,7 @@ const Al = {
|
|
|
2560
2559
|
}
|
|
2561
2560
|
(c = e.value.control.add) != null && c.click ? e.value.control.add.click(l) : e.value.control.add.inline === !0 ? (e.value.table.data.unshift(K.value), t("open", "row-add", { initFormData: K.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(K.value).forEach((M) => {
|
|
2562
2561
|
e.value[M] && (e.value[M].value = K.value[M]);
|
|
2563
|
-
}),
|
|
2562
|
+
}), $.value = !0, t("open", "add", { m: l }), mt());
|
|
2564
2563
|
}, p = async (l, u, c, M) => {
|
|
2565
2564
|
var H, N;
|
|
2566
2565
|
e.value.form.modalState = "edit";
|
|
@@ -2577,8 +2576,8 @@ const Al = {
|
|
|
2577
2576
|
}
|
|
2578
2577
|
(N = e.value.control.edit) != null && N.click ? e.value.control.edit.click(l, u, c, M) : (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((Q) => {
|
|
2579
2578
|
e.value[Q] && (e.value[Q].value = l[Q]);
|
|
2580
|
-
}),
|
|
2581
|
-
},
|
|
2579
|
+
}), $.value = !0, t("open", "edit", { m: M, row: l, column: u, $index: c }), mt());
|
|
2580
|
+
}, r = async (l, u, c, M) => {
|
|
2582
2581
|
var H, N;
|
|
2583
2582
|
try {
|
|
2584
2583
|
if (!await ((H = e.value.control) == null ? void 0 : H.validate("delete", {
|
|
@@ -2595,7 +2594,7 @@ const Al = {
|
|
|
2595
2594
|
e.value.control.delete.click(l, u, c, M);
|
|
2596
2595
|
else {
|
|
2597
2596
|
let { message: Q, title: Ee, options: Ce } = e.value.control.delete.dialog;
|
|
2598
|
-
|
|
2597
|
+
Tt.confirm(Q, Ee, Ce).then(() => {
|
|
2599
2598
|
t(
|
|
2600
2599
|
"delete",
|
|
2601
2600
|
{ row: l, column: u, $index: c, m: M },
|
|
@@ -2622,7 +2621,7 @@ const Al = {
|
|
|
2622
2621
|
}
|
|
2623
2622
|
(N = e.value.control.view) != null && N.click ? e.value.control.view.click(l, u, c, M) : (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((Q) => {
|
|
2624
2623
|
e.value[Q] && (e.value[Q].value = l[Q]);
|
|
2625
|
-
}),
|
|
2624
|
+
}), $.value = !0, t("open", "view", { m: M, row: l, column: u, $index: c }), mt());
|
|
2626
2625
|
}, g = (l, u, c, M) => {
|
|
2627
2626
|
var H;
|
|
2628
2627
|
(H = e.value.control.save) != null && H.click ? e.value.control.save.click(l, u, c, M) : t(
|
|
@@ -2643,9 +2642,9 @@ const Al = {
|
|
|
2643
2642
|
);
|
|
2644
2643
|
}, s = (l, u) => {
|
|
2645
2644
|
t("submit", e.value.form.modalState, l, u, (c) => {
|
|
2646
|
-
c && (
|
|
2645
|
+
c && ($.value = !1, u.table.load());
|
|
2647
2646
|
});
|
|
2648
|
-
},
|
|
2647
|
+
}, k = (l) => {
|
|
2649
2648
|
t("reset", l);
|
|
2650
2649
|
}, V = (l, u) => {
|
|
2651
2650
|
var c;
|
|
@@ -2658,7 +2657,7 @@ const Al = {
|
|
|
2658
2657
|
size: l.control.download.size || 480,
|
|
2659
2658
|
width: l.control.download.width || 600,
|
|
2660
2659
|
slots: {
|
|
2661
|
-
default: () => Ae(
|
|
2660
|
+
default: () => Ae(xl, {
|
|
2662
2661
|
items: u,
|
|
2663
2662
|
commitText: l.control.download.excelLabel,
|
|
2664
2663
|
onExcel: (H, N) => {
|
|
@@ -2678,7 +2677,7 @@ const Al = {
|
|
|
2678
2677
|
size: l.control.setting.size || 470,
|
|
2679
2678
|
width: l.control.setting.width || 600,
|
|
2680
2679
|
slots: {
|
|
2681
|
-
default: () => Ae(
|
|
2680
|
+
default: () => Ae(Rl, {
|
|
2682
2681
|
modelValue: l,
|
|
2683
2682
|
name: q.name
|
|
2684
2683
|
})
|
|
@@ -2687,12 +2686,12 @@ const Al = {
|
|
|
2687
2686
|
l.control.setting.mode
|
|
2688
2687
|
);
|
|
2689
2688
|
}, J = e.value.control, Y = [
|
|
2690
|
-
{ type: "add", func:
|
|
2689
|
+
{ type: "add", func: _ },
|
|
2691
2690
|
{ type: "download", func: V },
|
|
2692
2691
|
{ type: "setting", func: j },
|
|
2693
2692
|
{ type: "view", func: v },
|
|
2694
2693
|
{ type: "edit", func: p },
|
|
2695
|
-
{ type: "delete", func:
|
|
2694
|
+
{ type: "delete", func: r },
|
|
2696
2695
|
{ type: "save", func: g }
|
|
2697
2696
|
], O = (l) => Y.filter((u) => l.includes(u.type)).map(({ type: u, func: c }) => {
|
|
2698
2697
|
var M, H, N;
|
|
@@ -2759,14 +2758,14 @@ const Al = {
|
|
|
2759
2758
|
try {
|
|
2760
2759
|
x.value.handleClose();
|
|
2761
2760
|
} catch {
|
|
2762
|
-
|
|
2761
|
+
$.value = !1;
|
|
2763
2762
|
}
|
|
2764
2763
|
else
|
|
2765
|
-
|
|
2764
|
+
$.value = !1;
|
|
2766
2765
|
};
|
|
2767
|
-
return
|
|
2766
|
+
return Pt(() => {
|
|
2768
2767
|
e.value.table.autoWatch && e.value.table.load();
|
|
2769
|
-
}),
|
|
2768
|
+
}), rt(async () => {
|
|
2770
2769
|
var l;
|
|
2771
2770
|
if (te.value = Object.entries(e.value).filter(
|
|
2772
2771
|
([u, c]) => c.type !== "hidden" && c.type !== "control" && c.visible !== !1
|
|
@@ -2792,19 +2791,19 @@ const Al = {
|
|
|
2792
2791
|
return;
|
|
2793
2792
|
}
|
|
2794
2793
|
try {
|
|
2795
|
-
let u = await
|
|
2794
|
+
let u = await Ol(q.name);
|
|
2796
2795
|
if (u) {
|
|
2797
2796
|
if (q.name !== u.name) {
|
|
2798
2797
|
Fe.error("此表格已经存在,请换一个名字!");
|
|
2799
2798
|
return;
|
|
2800
2799
|
}
|
|
2801
2800
|
} else
|
|
2802
|
-
await
|
|
2801
|
+
await Al({ name: q.name });
|
|
2803
2802
|
} catch (u) {
|
|
2804
2803
|
console.error("检查表格名称时出现错误:", u), Fe.error("检查表格名称时出现错误,请稍后重试。");
|
|
2805
2804
|
}
|
|
2806
2805
|
try {
|
|
2807
|
-
const u = await
|
|
2806
|
+
const u = await Fl(e.value.table.user, q.name);
|
|
2808
2807
|
u && u.forEach((c) => {
|
|
2809
2808
|
e.value[c.key] && (e.value[c.key].width = c.width, e.value[c.key].showCol = c.showCol, e.value[c.key].sort = c.sort);
|
|
2810
2809
|
});
|
|
@@ -2813,43 +2812,43 @@ const Al = {
|
|
|
2813
2812
|
}
|
|
2814
2813
|
e.value.table.autoWatch || e.value.table.load();
|
|
2815
2814
|
}), f({
|
|
2816
|
-
addRow:
|
|
2815
|
+
addRow: _,
|
|
2817
2816
|
editRow: p,
|
|
2818
|
-
deleteRow:
|
|
2817
|
+
deleteRow: r,
|
|
2819
2818
|
readForm: v,
|
|
2820
2819
|
saveRowData: g,
|
|
2821
2820
|
closeDialog: Ue
|
|
2822
2821
|
}), (l, u) => {
|
|
2823
|
-
var ce, Be, Ke, Ze,
|
|
2822
|
+
var ce, Be, Ke, Ze, it;
|
|
2824
2823
|
const c = I("el-icon"), M = I("el-dialog"), H = I("el-drawer"), N = I("el-button-group"), Q = I("el-dropdown-item"), Ee = I("el-dropdown-menu"), Ce = I("el-dropdown"), Le = I("el-table-column"), m = I("el-table"), W = I("el-pagination");
|
|
2825
2824
|
return n(), F(G, null, [
|
|
2826
|
-
e.value.dialog.mode == "dialog" &&
|
|
2825
|
+
e.value.dialog.mode == "dialog" && $.value ? (n(), F("div", Nl, [
|
|
2827
2826
|
Z(M, S(
|
|
2828
2827
|
{
|
|
2829
2828
|
ref_key: "dialogRef",
|
|
2830
2829
|
ref: x,
|
|
2831
2830
|
id: "dialogRef",
|
|
2832
|
-
modelValue:
|
|
2833
|
-
"onUpdate:modelValue": u[3] || (u[3] = (R) =>
|
|
2831
|
+
modelValue: $.value,
|
|
2832
|
+
"onUpdate:modelValue": u[3] || (u[3] = (R) => $.value = R),
|
|
2834
2833
|
fullscreen: e.value.dialog.fullScreen
|
|
2835
2834
|
},
|
|
2836
2835
|
U(Ve)(e.value.dialog, (R) => !["size", "max", "min"].includes(R)),
|
|
2837
2836
|
{
|
|
2838
|
-
width: U(
|
|
2837
|
+
width: U(At)(e.value.dialog.width) + 35
|
|
2839
2838
|
}
|
|
2840
2839
|
), {
|
|
2841
2840
|
header: h(() => {
|
|
2842
|
-
var R, oe,
|
|
2841
|
+
var R, oe, w, P, ee, Xe, Ge, je, ze, at;
|
|
2843
2842
|
return [
|
|
2844
|
-
X("div",
|
|
2845
|
-
X("div",
|
|
2843
|
+
X("div", Pl, [
|
|
2844
|
+
X("div", Wl, [
|
|
2846
2845
|
y(l.$slots, "f-header", {}, () => [
|
|
2847
2846
|
X("div", null, ye(e.value.dialog.title), 1)
|
|
2848
2847
|
], !0)
|
|
2849
2848
|
]),
|
|
2850
2849
|
((oe = (R = e.value) == null ? void 0 : R.dialog) == null ? void 0 : oe.fullScreen) === !1 ? (n(), F("div", {
|
|
2851
2850
|
key: 0,
|
|
2852
|
-
style: Ie((ee = (P = (
|
|
2851
|
+
style: Ie((ee = (P = (w = e.value) == null ? void 0 : w.dialog) == null ? void 0 : P.max) == null ? void 0 : ee.style),
|
|
2853
2852
|
onClick: u[0] || (u[0] = (A) => e.value.dialog.fullScreen = !0),
|
|
2854
2853
|
class: "max"
|
|
2855
2854
|
}, [
|
|
@@ -2857,7 +2856,7 @@ const Al = {
|
|
|
2857
2856
|
default: h(() => {
|
|
2858
2857
|
var A, Oe, Qe;
|
|
2859
2858
|
return [
|
|
2860
|
-
(n(),
|
|
2859
|
+
(n(), C(Ye((Qe = (Oe = (A = e.value) == null ? void 0 : A.dialog) == null ? void 0 : Oe.max) == null ? void 0 : Qe.icon)))
|
|
2861
2860
|
];
|
|
2862
2861
|
}),
|
|
2863
2862
|
_: 1
|
|
@@ -2873,7 +2872,7 @@ const Al = {
|
|
|
2873
2872
|
default: h(() => {
|
|
2874
2873
|
var A, Oe, Qe;
|
|
2875
2874
|
return [
|
|
2876
|
-
(n(),
|
|
2875
|
+
(n(), C(Ye((Qe = (Oe = (A = e.value) == null ? void 0 : A.dialog) == null ? void 0 : Oe.min) == null ? void 0 : Qe.icon)))
|
|
2877
2876
|
];
|
|
2878
2877
|
}),
|
|
2879
2878
|
_: 1
|
|
@@ -2883,15 +2882,15 @@ const Al = {
|
|
|
2883
2882
|
];
|
|
2884
2883
|
}),
|
|
2885
2884
|
default: h(() => [
|
|
2886
|
-
X("div",
|
|
2885
|
+
X("div", Xl, [
|
|
2887
2886
|
y(l.$slots, "table-dialog-form", { model: e.value }, () => [
|
|
2888
2887
|
Z(bt, {
|
|
2889
2888
|
modelValue: e.value,
|
|
2890
2889
|
"onUpdate:modelValue": u[2] || (u[2] = (R) => e.value = R),
|
|
2891
2890
|
onSubmit: s,
|
|
2892
|
-
onReset:
|
|
2891
|
+
onReset: k
|
|
2893
2892
|
}, me({ _: 2 }, [
|
|
2894
|
-
L(l.$slots, (R, oe,
|
|
2893
|
+
L(l.$slots, (R, oe, w) => ({
|
|
2895
2894
|
name: oe,
|
|
2896
2895
|
fn: h((P) => [
|
|
2897
2896
|
y(l.$slots, oe, { model: P }, void 0, !0)
|
|
@@ -2904,16 +2903,16 @@ const Al = {
|
|
|
2904
2903
|
_: 3
|
|
2905
2904
|
}, 16, ["modelValue", "fullscreen", "width"])
|
|
2906
2905
|
])) : pe("", !0),
|
|
2907
|
-
e.value.dialog.mode == "drawer" &&
|
|
2906
|
+
e.value.dialog.mode == "drawer" && $.value ? (n(), F("div", Gl, [
|
|
2908
2907
|
Z(H, S({
|
|
2909
2908
|
ref_key: "drawerRef",
|
|
2910
2909
|
ref: T,
|
|
2911
|
-
modelValue:
|
|
2912
|
-
"onUpdate:modelValue": u[5] || (u[5] = (R) =>
|
|
2910
|
+
modelValue: $.value,
|
|
2911
|
+
"onUpdate:modelValue": u[5] || (u[5] = (R) => $.value = R)
|
|
2913
2912
|
}, U(Ve)(e.value.dialog, (R) => !["width"].includes(R))), {
|
|
2914
2913
|
header: h(() => [
|
|
2915
|
-
X("div",
|
|
2916
|
-
X("div",
|
|
2914
|
+
X("div", Ql, [
|
|
2915
|
+
X("div", Zl, [
|
|
2917
2916
|
y(l.$slots, "f-header", {}, () => [
|
|
2918
2917
|
X("div", null, ye(e.value.dialog.title), 1)
|
|
2919
2918
|
], !0)
|
|
@@ -2926,9 +2925,9 @@ const Al = {
|
|
|
2926
2925
|
modelValue: e.value,
|
|
2927
2926
|
"onUpdate:modelValue": u[4] || (u[4] = (R) => e.value = R),
|
|
2928
2927
|
onSubmit: s,
|
|
2929
|
-
onReset:
|
|
2928
|
+
onReset: k
|
|
2930
2929
|
}, me({ _: 2 }, [
|
|
2931
|
-
L(l.$slots, (R, oe,
|
|
2930
|
+
L(l.$slots, (R, oe, w) => ({
|
|
2932
2931
|
name: oe,
|
|
2933
2932
|
fn: h((P) => [
|
|
2934
2933
|
y(l.$slots, oe, { model: P }, void 0, !0)
|
|
@@ -2940,10 +2939,10 @@ const Al = {
|
|
|
2940
2939
|
_: 3
|
|
2941
2940
|
}, 16, ["modelValue"])
|
|
2942
2941
|
])) : pe("", !0),
|
|
2943
|
-
X("div",
|
|
2944
|
-
((Be = (ce = e.value) == null ? void 0 : ce.query) == null ? void 0 : Be.hidden) != !0 ? (n(), F("div",
|
|
2942
|
+
X("div", Jl, [
|
|
2943
|
+
((Be = (ce = e.value) == null ? void 0 : ce.query) == null ? void 0 : Be.hidden) != !0 ? (n(), F("div", Kl, [
|
|
2945
2944
|
y(l.$slots, "query", {}, () => [
|
|
2946
|
-
Z(
|
|
2945
|
+
Z(_l, {
|
|
2947
2946
|
modelValue: e.value,
|
|
2948
2947
|
"onUpdate:modelValue": u[6] || (u[6] = (R) => e.value = R),
|
|
2949
2948
|
info: E.value,
|
|
@@ -2958,54 +2957,54 @@ const Al = {
|
|
|
2958
2957
|
"download",
|
|
2959
2958
|
"setting"
|
|
2960
2959
|
]), (R, oe) => (n(), F(G, null, [
|
|
2961
|
-
oe == "default" ? (n(!0), F(G, { key: 0 }, L(R, (
|
|
2962
|
-
y(l.$slots,
|
|
2963
|
-
(
|
|
2964
|
-
|
|
2960
|
+
oe == "default" ? (n(!0), F(G, { key: 0 }, L(R, (w) => (n(), F(G, null, [
|
|
2961
|
+
y(l.$slots, w.name + "-left", {}, void 0, !0),
|
|
2962
|
+
(w.name === "control-add" ? w.attr.auth(e.value) && w.attr.inline === !1 : w.attr.auth(e.value)) ? y(l.$slots, w.name, { key: 0 }, () => [
|
|
2963
|
+
w.label ? (n(), C(U(De), S({
|
|
2965
2964
|
key: 0,
|
|
2966
|
-
title:
|
|
2965
|
+
title: w.label,
|
|
2967
2966
|
ref_for: !0
|
|
2968
|
-
},
|
|
2969
|
-
onClick: (P) =>
|
|
2967
|
+
}, w.attr, {
|
|
2968
|
+
onClick: (P) => w.func(e.value, te.value)
|
|
2970
2969
|
}), {
|
|
2971
2970
|
default: h(() => [
|
|
2972
|
-
Me(ye(
|
|
2971
|
+
Me(ye(w.label), 1)
|
|
2973
2972
|
]),
|
|
2974
2973
|
_: 2
|
|
2975
|
-
}, 1040, ["title", "onClick"])) : (n(),
|
|
2974
|
+
}, 1040, ["title", "onClick"])) : (n(), C(U(De), S({
|
|
2976
2975
|
key: 1,
|
|
2977
|
-
title:
|
|
2976
|
+
title: w.label,
|
|
2978
2977
|
ref_for: !0
|
|
2979
|
-
},
|
|
2980
|
-
onClick: (P) =>
|
|
2978
|
+
}, w.attr, {
|
|
2979
|
+
onClick: (P) => w.func(e.value, te.value)
|
|
2981
2980
|
}), null, 16, ["title", "onClick"]))
|
|
2982
2981
|
], !0) : pe("", !0),
|
|
2983
|
-
y(l.$slots,
|
|
2984
|
-
], 64))), 256)) : (n(),
|
|
2982
|
+
y(l.$slots, w.name + "-right", {}, void 0, !0)
|
|
2983
|
+
], 64))), 256)) : (n(), C(N, { key: 1 }, {
|
|
2985
2984
|
default: h(() => [
|
|
2986
|
-
(n(!0), F(G, null, L(R, (
|
|
2987
|
-
y(l.$slots,
|
|
2988
|
-
(
|
|
2989
|
-
|
|
2985
|
+
(n(!0), F(G, null, L(R, (w) => (n(), F(G, null, [
|
|
2986
|
+
y(l.$slots, w.name + "-left", {}, void 0, !0),
|
|
2987
|
+
(w.name === "control-add" ? w.attr.auth(e.value) && w.attr.inline === !1 : w.attr.auth(e.value)) ? y(l.$slots, w.name, { key: 0 }, () => [
|
|
2988
|
+
w.label ? (n(), C(U(De), S({
|
|
2990
2989
|
key: 0,
|
|
2991
|
-
title:
|
|
2990
|
+
title: w.label,
|
|
2992
2991
|
ref_for: !0
|
|
2993
|
-
},
|
|
2994
|
-
onClick: (P) =>
|
|
2992
|
+
}, w.attr, {
|
|
2993
|
+
onClick: (P) => w.func(e.value, te.value)
|
|
2995
2994
|
}), {
|
|
2996
2995
|
default: h(() => [
|
|
2997
|
-
Me(ye(
|
|
2996
|
+
Me(ye(w.label), 1)
|
|
2998
2997
|
]),
|
|
2999
2998
|
_: 2
|
|
3000
|
-
}, 1040, ["title", "onClick"])) : (n(),
|
|
2999
|
+
}, 1040, ["title", "onClick"])) : (n(), C(U(De), S({
|
|
3001
3000
|
key: 1,
|
|
3002
|
-
title:
|
|
3001
|
+
title: w.label,
|
|
3003
3002
|
ref_for: !0
|
|
3004
|
-
},
|
|
3005
|
-
onClick: (P) =>
|
|
3003
|
+
}, w.attr, {
|
|
3004
|
+
onClick: (P) => w.func(e.value, te.value)
|
|
3006
3005
|
}), null, 16, ["title", "onClick"]))
|
|
3007
3006
|
], !0) : pe("", !0),
|
|
3008
|
-
y(l.$slots,
|
|
3007
|
+
y(l.$slots, w.name + "-right", {}, void 0, !0)
|
|
3009
3008
|
], 64))), 256))
|
|
3010
3009
|
]),
|
|
3011
3010
|
_: 2
|
|
@@ -3015,7 +3014,7 @@ const Al = {
|
|
|
3015
3014
|
]),
|
|
3016
3015
|
_: 2
|
|
3017
3016
|
}, [
|
|
3018
|
-
L(l.$slots, (R, oe,
|
|
3017
|
+
L(l.$slots, (R, oe, w) => ({
|
|
3019
3018
|
name: oe,
|
|
3020
3019
|
fn: h((P) => [
|
|
3021
3020
|
y(l.$slots, oe, { model: e.value }, void 0, !0)
|
|
@@ -3024,7 +3023,7 @@ const Al = {
|
|
|
3024
3023
|
]), 1032, ["modelValue", "info"])
|
|
3025
3024
|
], !0)
|
|
3026
3025
|
])) : pe("", !0),
|
|
3027
|
-
X("div",
|
|
3026
|
+
X("div", ea, [
|
|
3028
3027
|
Z(m, S({
|
|
3029
3028
|
...l.$attrs,
|
|
3030
3029
|
...U(Ve)(
|
|
@@ -3034,8 +3033,8 @@ const Al = {
|
|
|
3034
3033
|
}, {
|
|
3035
3034
|
"summary-method": (R) => e.value.table["summary-method"](R, { fields: re.value, sums: se.value }),
|
|
3036
3035
|
onSortChange: u[8] || (u[8] = (R) => {
|
|
3037
|
-
var oe,
|
|
3038
|
-
e.value.table.onSortChange(R, E.value), ((oe = R == null ? void 0 : R.column) == null ? void 0 : oe.sortable) === "custom" && ((
|
|
3036
|
+
var oe, w;
|
|
3037
|
+
e.value.table.onSortChange(R, E.value), ((oe = R == null ? void 0 : R.column) == null ? void 0 : oe.sortable) === "custom" && ((w = e.value.table) == null || w.load());
|
|
3039
3038
|
})
|
|
3040
3039
|
}), {
|
|
3041
3040
|
append: h(() => [
|
|
@@ -3046,37 +3045,37 @@ const Al = {
|
|
|
3046
3045
|
]),
|
|
3047
3046
|
default: h(() => [
|
|
3048
3047
|
y(l.$slots, "default", {}, () => [
|
|
3049
|
-
(n(!0), F(G, null, L(ke.value, (R, oe) => (n(),
|
|
3048
|
+
(n(!0), F(G, null, L(ke.value, (R, oe) => (n(), C(Le, S({
|
|
3050
3049
|
prop: oe,
|
|
3051
3050
|
key: oe,
|
|
3052
3051
|
ref_for: !0
|
|
3053
3052
|
}, {
|
|
3054
3053
|
...e.value.tableColumns,
|
|
3055
|
-
...U(Ve)(R, (
|
|
3054
|
+
...U(Ve)(R, (w) => z.includes(w))
|
|
3056
3055
|
}), me({
|
|
3057
|
-
header: h(({ column:
|
|
3056
|
+
header: h(({ column: w, $index: P }) => [
|
|
3058
3057
|
oe == "control" ? y(l.$slots, `${oe}-header`, {
|
|
3059
3058
|
key: 0,
|
|
3060
|
-
column:
|
|
3059
|
+
column: w,
|
|
3061
3060
|
$index: P
|
|
3062
3061
|
}, () => [
|
|
3063
|
-
X("span", null, ye(
|
|
3062
|
+
X("span", null, ye(w.label), 1)
|
|
3064
3063
|
], !0) : y(l.$slots, `${oe}-header`, {
|
|
3065
3064
|
key: 1,
|
|
3066
|
-
column:
|
|
3065
|
+
column: w,
|
|
3067
3066
|
$index: P
|
|
3068
3067
|
}, void 0, !0)
|
|
3069
3068
|
]),
|
|
3070
|
-
"filter-icon": h((
|
|
3071
|
-
y(l.$slots, `${oe}-filter-icon`, { data:
|
|
3069
|
+
"filter-icon": h((w) => [
|
|
3070
|
+
y(l.$slots, `${oe}-filter-icon`, { data: w }, void 0, !0)
|
|
3072
3071
|
]),
|
|
3073
3072
|
_: 2
|
|
3074
3073
|
}, [
|
|
3075
3074
|
R.type === "expand" ? {
|
|
3076
3075
|
name: "default",
|
|
3077
|
-
fn: h(({ row:
|
|
3076
|
+
fn: h(({ row: w, column: P, $index: ee }) => [
|
|
3078
3077
|
y(l.$slots, `${oe}`, {
|
|
3079
|
-
row:
|
|
3078
|
+
row: w,
|
|
3080
3079
|
column: P,
|
|
3081
3080
|
$index: ee
|
|
3082
3081
|
}, void 0, !0)
|
|
@@ -3084,16 +3083,16 @@ const Al = {
|
|
|
3084
3083
|
key: "0"
|
|
3085
3084
|
} : R.type == "control" ? {
|
|
3086
3085
|
name: "default",
|
|
3087
|
-
fn: h(({ row:
|
|
3086
|
+
fn: h(({ row: w, column: P, $index: ee }) => {
|
|
3088
3087
|
var Xe, Ge;
|
|
3089
3088
|
return [
|
|
3090
3089
|
X("div", {
|
|
3091
|
-
class:
|
|
3090
|
+
class: xt(["control", (Xe = e.value.control) == null ? void 0 : Xe.class]),
|
|
3092
3091
|
style: Ie((Ge = e.value.control) == null ? void 0 : Ge.style)
|
|
3093
3092
|
}, [
|
|
3094
3093
|
y(l.$slots, "control", {}, () => [
|
|
3095
3094
|
y(l.$slots, "control-left", {
|
|
3096
|
-
row:
|
|
3095
|
+
row: w,
|
|
3097
3096
|
column: P,
|
|
3098
3097
|
$index: ee
|
|
3099
3098
|
}, void 0, !0),
|
|
@@ -3107,44 +3106,44 @@ const Al = {
|
|
|
3107
3106
|
return n(), F(G, null, [
|
|
3108
3107
|
ze == "default" ? (n(!0), F(G, { key: 0 }, L(je, (A) => (n(), F(G, null, [
|
|
3109
3108
|
y(l.$slots, A.name + "-left", {
|
|
3110
|
-
row:
|
|
3109
|
+
row: w,
|
|
3111
3110
|
column: P,
|
|
3112
3111
|
$index: ee
|
|
3113
3112
|
}, void 0, !0),
|
|
3114
|
-
A.attr.auth(
|
|
3113
|
+
A.attr.auth(w, P, ee, e.value) ? y(l.$slots, A.name, {
|
|
3115
3114
|
key: 0,
|
|
3116
|
-
row:
|
|
3115
|
+
row: w,
|
|
3117
3116
|
column: P,
|
|
3118
3117
|
$index: ee
|
|
3119
3118
|
}, () => [
|
|
3120
|
-
A.label ? (n(),
|
|
3119
|
+
A.label ? (n(), C(U(De), S({
|
|
3121
3120
|
key: 0,
|
|
3122
3121
|
title: A.label,
|
|
3123
3122
|
ref_for: !0
|
|
3124
3123
|
}, A.attr, {
|
|
3125
|
-
onClick: (Oe) => A.func(
|
|
3124
|
+
onClick: (Oe) => A.func(w, P, ee, e.value)
|
|
3126
3125
|
}), {
|
|
3127
3126
|
default: h(() => [
|
|
3128
3127
|
Me(ye(xe(A, ee)), 1)
|
|
3129
3128
|
]),
|
|
3130
3129
|
_: 2
|
|
3131
|
-
}, 1040, ["title", "onClick"])) : (n(),
|
|
3130
|
+
}, 1040, ["title", "onClick"])) : (n(), C(U(De), S({
|
|
3132
3131
|
key: 1,
|
|
3133
3132
|
title: A.label,
|
|
3134
3133
|
ref_for: !0
|
|
3135
3134
|
}, A.attr, {
|
|
3136
|
-
onClick: (Oe) => A.func(
|
|
3135
|
+
onClick: (Oe) => A.func(w, P, ee, e.value)
|
|
3137
3136
|
}), null, 16, ["title", "onClick"]))
|
|
3138
3137
|
], !0) : pe("", !0),
|
|
3139
3138
|
y(l.$slots, A.name + "-right", {
|
|
3140
|
-
row:
|
|
3139
|
+
row: w,
|
|
3141
3140
|
column: P,
|
|
3142
3141
|
$index: ee
|
|
3143
3142
|
}, void 0, !0)
|
|
3144
|
-
], 64))), 256)) : ze != null && ze.startsWith("dropdown") && ((at = ie(
|
|
3143
|
+
], 64))), 256)) : ze != null && ze.startsWith("dropdown") && ((at = ie(w, P, ee, e.value)) != null && at.auth()) ? (n(), C(Ce, S({
|
|
3145
3144
|
key: 1,
|
|
3146
3145
|
ref_for: !0
|
|
3147
|
-
}, ie(
|
|
3146
|
+
}, ie(w, P, ee, e.value)), {
|
|
3148
3147
|
dropdown: h(() => [
|
|
3149
3148
|
Z(Ee, null, {
|
|
3150
3149
|
default: h(() => [
|
|
@@ -3153,11 +3152,11 @@ const Al = {
|
|
|
3153
3152
|
return n(), F(G, null, [
|
|
3154
3153
|
l.$slots[A.name + "-left"] ? y(l.$slots, A.name + "-left", {
|
|
3155
3154
|
key: 0,
|
|
3156
|
-
row:
|
|
3155
|
+
row: w,
|
|
3157
3156
|
column: P,
|
|
3158
3157
|
$index: ee
|
|
3159
3158
|
}, void 0, !0) : pe("", !0),
|
|
3160
|
-
A.attr.auth(
|
|
3159
|
+
A.attr.auth(w, P, ee, e.value) ? (n(), C(Q, S({
|
|
3161
3160
|
key: 1,
|
|
3162
3161
|
ref_for: !0
|
|
3163
3162
|
}, {
|
|
@@ -3167,27 +3166,27 @@ const Al = {
|
|
|
3167
3166
|
}), {
|
|
3168
3167
|
default: h(() => [
|
|
3169
3168
|
y(l.$slots, A.name, {
|
|
3170
|
-
row:
|
|
3169
|
+
row: w,
|
|
3171
3170
|
column: P,
|
|
3172
3171
|
$index: ee
|
|
3173
3172
|
}, () => [
|
|
3174
|
-
A.label ? (n(),
|
|
3173
|
+
A.label ? (n(), C(U(De), S({
|
|
3175
3174
|
key: 0,
|
|
3176
3175
|
title: A.label,
|
|
3177
3176
|
ref_for: !0
|
|
3178
3177
|
}, A.attr, {
|
|
3179
|
-
onClick: (
|
|
3178
|
+
onClick: (It) => A.func(w, P, ee, e.value)
|
|
3180
3179
|
}), {
|
|
3181
3180
|
default: h(() => [
|
|
3182
3181
|
Me(ye(xe(A, ee)), 1)
|
|
3183
3182
|
]),
|
|
3184
3183
|
_: 2
|
|
3185
|
-
}, 1040, ["title", "onClick"])) : (n(),
|
|
3184
|
+
}, 1040, ["title", "onClick"])) : (n(), C(U(De), S({
|
|
3186
3185
|
key: 1,
|
|
3187
3186
|
title: A.label,
|
|
3188
3187
|
ref_for: !0
|
|
3189
3188
|
}, A.attr, {
|
|
3190
|
-
onClick: (
|
|
3189
|
+
onClick: (It) => A.func(w, P, ee, e.value)
|
|
3191
3190
|
}), null, 16, ["title", "onClick"]))
|
|
3192
3191
|
], !0)
|
|
3193
3192
|
]),
|
|
@@ -3195,7 +3194,7 @@ const Al = {
|
|
|
3195
3194
|
}, 1040)) : pe("", !0),
|
|
3196
3195
|
l.$slots[A.name + "-right"] ? y(l.$slots, A.name + "-right", {
|
|
3197
3196
|
key: 2,
|
|
3198
|
-
row:
|
|
3197
|
+
row: w,
|
|
3199
3198
|
column: P,
|
|
3200
3199
|
$index: ee
|
|
3201
3200
|
}, void 0, !0) : pe("", !0)
|
|
@@ -3208,45 +3207,45 @@ const Al = {
|
|
|
3208
3207
|
default: h(() => {
|
|
3209
3208
|
var A;
|
|
3210
3209
|
return [
|
|
3211
|
-
Me(ye((A = ie(
|
|
3210
|
+
Me(ye((A = ie(w, P, ee, e.value)) == null ? void 0 : A.label) + " ", 1)
|
|
3212
3211
|
];
|
|
3213
3212
|
}),
|
|
3214
3213
|
_: 2
|
|
3215
|
-
}, 1040)) : (n(),
|
|
3214
|
+
}, 1040)) : (n(), C(N, { key: 2 }, {
|
|
3216
3215
|
default: h(() => [
|
|
3217
3216
|
(n(!0), F(G, null, L(je, (A) => (n(), F(G, null, [
|
|
3218
3217
|
y(l.$slots, A.name + "-left", {
|
|
3219
|
-
row:
|
|
3218
|
+
row: w,
|
|
3220
3219
|
column: P,
|
|
3221
3220
|
$index: ee
|
|
3222
3221
|
}, void 0, !0),
|
|
3223
|
-
A.attr.auth(
|
|
3222
|
+
A.attr.auth(w, P, ee, e.value) ? y(l.$slots, A.name, {
|
|
3224
3223
|
key: 0,
|
|
3225
|
-
row:
|
|
3224
|
+
row: w,
|
|
3226
3225
|
column: P,
|
|
3227
3226
|
$index: ee
|
|
3228
3227
|
}, () => [
|
|
3229
|
-
A.label ? (n(),
|
|
3228
|
+
A.label ? (n(), C(U(De), S({
|
|
3230
3229
|
key: 0,
|
|
3231
3230
|
title: A.label,
|
|
3232
3231
|
ref_for: !0
|
|
3233
3232
|
}, A.attr, {
|
|
3234
|
-
onClick: (Oe) => A.func(
|
|
3233
|
+
onClick: (Oe) => A.func(w, P, ee, e.value)
|
|
3235
3234
|
}), {
|
|
3236
3235
|
default: h(() => [
|
|
3237
3236
|
Me(ye(xe(A, ee)), 1)
|
|
3238
3237
|
]),
|
|
3239
3238
|
_: 2
|
|
3240
|
-
}, 1040, ["title", "onClick"])) : (n(),
|
|
3239
|
+
}, 1040, ["title", "onClick"])) : (n(), C(U(De), S({
|
|
3241
3240
|
key: 1,
|
|
3242
3241
|
title: A.label,
|
|
3243
3242
|
ref_for: !0
|
|
3244
3243
|
}, A.attr, {
|
|
3245
|
-
onClick: (Oe) => A.func(
|
|
3244
|
+
onClick: (Oe) => A.func(w, P, ee, e.value)
|
|
3246
3245
|
}), null, 16, ["title", "onClick"]))
|
|
3247
3246
|
], !0) : pe("", !0),
|
|
3248
3247
|
y(l.$slots, A.name + "-right", {
|
|
3249
|
-
row:
|
|
3248
|
+
row: w,
|
|
3250
3249
|
column: P,
|
|
3251
3250
|
$index: ee
|
|
3252
3251
|
}, void 0, !0)
|
|
@@ -3257,7 +3256,7 @@ const Al = {
|
|
|
3257
3256
|
], 64);
|
|
3258
3257
|
}), 256)),
|
|
3259
3258
|
y(l.$slots, "control-right", {
|
|
3260
|
-
row:
|
|
3259
|
+
row: w,
|
|
3261
3260
|
column: P,
|
|
3262
3261
|
$index: ee
|
|
3263
3262
|
}, void 0, !0)
|
|
@@ -3268,26 +3267,26 @@ const Al = {
|
|
|
3268
3267
|
key: "1"
|
|
3269
3268
|
} : R.type != "selection" && R.type != "index" ? {
|
|
3270
3269
|
name: "default",
|
|
3271
|
-
fn: h(({ row:
|
|
3272
|
-
we(R,
|
|
3270
|
+
fn: h(({ row: w, column: P, $index: ee }) => [
|
|
3271
|
+
we(R, w, P, ee) && ee != -1 ? y(l.$slots, `${oe}`, {
|
|
3273
3272
|
key: 0,
|
|
3274
|
-
row:
|
|
3273
|
+
row: w,
|
|
3275
3274
|
column: P,
|
|
3276
3275
|
$index: ee
|
|
3277
3276
|
}, () => {
|
|
3278
3277
|
var Xe;
|
|
3279
3278
|
return [
|
|
3280
|
-
(n(),
|
|
3281
|
-
modelValue:
|
|
3282
|
-
"onUpdate:modelValue": (Ge) =>
|
|
3283
|
-
item: R == null ? void 0 : R.table(
|
|
3279
|
+
(n(), C(pt, {
|
|
3280
|
+
modelValue: w[oe],
|
|
3281
|
+
"onUpdate:modelValue": (Ge) => w[oe] = Ge,
|
|
3282
|
+
item: R == null ? void 0 : R.table(w, P, ee),
|
|
3284
3283
|
ctrlKey: oe,
|
|
3285
3284
|
key: `${oe}-${ee} -${ve.value}`,
|
|
3286
|
-
ctrlType: (Xe = R.table(
|
|
3285
|
+
ctrlType: (Xe = R.table(w, P, ee)) != null && Xe.type ? R.table(w, P, ee).type : R.type,
|
|
3287
3286
|
model: e.value,
|
|
3288
3287
|
class: "g-ctrl-container",
|
|
3289
3288
|
t: "t",
|
|
3290
|
-
formInfo:
|
|
3289
|
+
formInfo: w
|
|
3291
3290
|
}, me({ _: 2 }, [
|
|
3292
3291
|
L(l.$slots, (Ge, je) => ({
|
|
3293
3292
|
name: je,
|
|
@@ -3303,7 +3302,7 @@ const Al = {
|
|
|
3303
3302
|
];
|
|
3304
3303
|
}, !0) : y(l.$slots, `${oe}`, {
|
|
3305
3304
|
key: 1,
|
|
3306
|
-
row:
|
|
3305
|
+
row: w,
|
|
3307
3306
|
column: P,
|
|
3308
3307
|
$index: ee
|
|
3309
3308
|
}, () => [
|
|
@@ -3311,9 +3310,9 @@ const Al = {
|
|
|
3311
3310
|
style: Ie([{ width: "100%", "text-overflow": "ellipsis", overflow: "hidden" }, R == null ? void 0 : R.style]),
|
|
3312
3311
|
innerHTML: ne(
|
|
3313
3312
|
R,
|
|
3314
|
-
P.formatter(
|
|
3313
|
+
P.formatter(w, P, w[oe], ee)
|
|
3315
3314
|
)
|
|
3316
|
-
}, null, 12,
|
|
3315
|
+
}, null, 12, ta)
|
|
3317
3316
|
], !0)
|
|
3318
3317
|
]),
|
|
3319
3318
|
key: "2"
|
|
@@ -3323,7 +3322,7 @@ const Al = {
|
|
|
3323
3322
|
]),
|
|
3324
3323
|
_: 3
|
|
3325
3324
|
}, 16, ["summary-method"]),
|
|
3326
|
-
(
|
|
3325
|
+
(it = (Ze = (Ke = e.value) == null ? void 0 : Ke.table) == null ? void 0 : Ze.page) != null && it.hidden ? pe("", !0) : y(l.$slots, "page", { key: 0 }, () => [
|
|
3327
3326
|
Z(W, S({
|
|
3328
3327
|
"page-size": e.value.table.page.pageSize,
|
|
3329
3328
|
"onUpdate:pageSize": u[9] || (u[9] = (R) => e.value.table.page.pageSize = R),
|
|
@@ -3341,7 +3340,7 @@ const Al = {
|
|
|
3341
3340
|
], 64);
|
|
3342
3341
|
};
|
|
3343
3342
|
}
|
|
3344
|
-
}),
|
|
3343
|
+
}), aa = /* @__PURE__ */ We(la, [["__scopeId", "data-v-62a9a1b9"]]), ra = { class: "g-tree-table" }, oa = { class: "g-tree-container" }, ua = { class: "g-tree-table-container" }, na = /* @__PURE__ */ Object.assign({
|
|
3345
3344
|
name: "g-tree-table",
|
|
3346
3345
|
inheritAttrs: !1
|
|
3347
3346
|
}, {
|
|
@@ -3351,30 +3350,30 @@ const Al = {
|
|
|
3351
3350
|
modelModifiers: {}
|
|
3352
3351
|
},
|
|
3353
3352
|
emits: /* @__PURE__ */ Ne(["load"], ["update:modelValue"]),
|
|
3354
|
-
setup(
|
|
3353
|
+
setup(d, { emit: f }) {
|
|
3355
3354
|
var q, B, se, re;
|
|
3356
|
-
const
|
|
3355
|
+
const a = f, t = Pe(d, "modelValue"), e = kt(), i = le(
|
|
3357
3356
|
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"
|
|
3358
|
-
), 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(""),
|
|
3357
|
+
), 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(""), D = le(null), $ = (K, ve) => {
|
|
3359
3358
|
var be, ie;
|
|
3360
3359
|
if (!K) return !0;
|
|
3361
3360
|
const ge = ((ie = (be = e.tree) == null ? void 0 : be.props) == null ? void 0 : ie.label) || "label";
|
|
3362
3361
|
return ve[ge].includes(K);
|
|
3363
3362
|
}, z = (K, ve) => {
|
|
3364
|
-
|
|
3363
|
+
a("load", x.value, K, ve);
|
|
3365
3364
|
}, te = (K) => {
|
|
3366
3365
|
x.value = K, t.value.table.load();
|
|
3367
3366
|
};
|
|
3368
|
-
return
|
|
3369
|
-
|
|
3367
|
+
return Wt(T, (K) => {
|
|
3368
|
+
D.value.filter(K);
|
|
3370
3369
|
}), (K, ve) => {
|
|
3371
3370
|
const ge = I("el-input"), be = I("el-tree"), ie = I("g-table");
|
|
3372
|
-
return n(), F("div",
|
|
3371
|
+
return n(), F("div", ra, [
|
|
3373
3372
|
X("div", {
|
|
3374
3373
|
class: "g-tree-left",
|
|
3375
|
-
style: Ie({ width:
|
|
3374
|
+
style: Ie({ width: i.value })
|
|
3376
3375
|
}, [
|
|
3377
|
-
E.value ? (n(),
|
|
3376
|
+
E.value ? (n(), C(ge, {
|
|
3378
3377
|
key: 0,
|
|
3379
3378
|
modelValue: T.value,
|
|
3380
3379
|
"onUpdate:modelValue": ve[0] || (ve[0] = (de) => T.value = de),
|
|
@@ -3382,13 +3381,13 @@ const Al = {
|
|
|
3382
3381
|
placeholder: "输入节点查询",
|
|
3383
3382
|
clearable: ""
|
|
3384
3383
|
}, null, 8, ["modelValue"])) : pe("", !0),
|
|
3385
|
-
X("div",
|
|
3384
|
+
X("div", oa, [
|
|
3386
3385
|
Z(be, S({
|
|
3387
|
-
style: { width:
|
|
3388
|
-
"filter-node-method":
|
|
3386
|
+
style: { width: i.value },
|
|
3387
|
+
"filter-node-method": $,
|
|
3389
3388
|
"expand-on-click-node": !1,
|
|
3390
3389
|
ref_key: "treeRef",
|
|
3391
|
-
ref:
|
|
3390
|
+
ref: D,
|
|
3392
3391
|
onNodeClick: te
|
|
3393
3392
|
}, K.$attrs.tree), me({
|
|
3394
3393
|
default: h(({ node: de, data: fe }) => [
|
|
@@ -3410,7 +3409,7 @@ const Al = {
|
|
|
3410
3409
|
]), 1040, ["style"])
|
|
3411
3410
|
])
|
|
3412
3411
|
], 4),
|
|
3413
|
-
X("div",
|
|
3412
|
+
X("div", ua, [
|
|
3414
3413
|
Z(ie, S({
|
|
3415
3414
|
modelValue: t.value,
|
|
3416
3415
|
"onUpdate:modelValue": ve[1] || (ve[1] = (de) => t.value = de)
|
|
@@ -3426,14 +3425,14 @@ const Al = {
|
|
|
3426
3425
|
]);
|
|
3427
3426
|
};
|
|
3428
3427
|
}
|
|
3429
|
-
}),
|
|
3428
|
+
}), sa = /* @__PURE__ */ We(na, [["__scopeId", "data-v-2d8b16ed"]]), ia = {
|
|
3430
3429
|
key: 0,
|
|
3431
3430
|
class: "op-group"
|
|
3432
|
-
},
|
|
3431
|
+
}, da = {
|
|
3433
3432
|
key: 1,
|
|
3434
3433
|
class: "op-items",
|
|
3435
3434
|
style: { width: "100%", height: "100%" }
|
|
3436
|
-
},
|
|
3435
|
+
}, fa = ["title"], Vt = "100px", ca = /* @__PURE__ */ Object.assign({ name: "g-select-option" }, {
|
|
3437
3436
|
__name: "g-select-option",
|
|
3438
3437
|
props: {
|
|
3439
3438
|
columns: {
|
|
@@ -3453,153 +3452,153 @@ const Al = {
|
|
|
3453
3452
|
default: ""
|
|
3454
3453
|
}
|
|
3455
3454
|
},
|
|
3456
|
-
setup(
|
|
3457
|
-
const f =
|
|
3458
|
-
return (
|
|
3455
|
+
setup(d) {
|
|
3456
|
+
const f = d;
|
|
3457
|
+
return (a, t) => f.title ? (n(), F("div", ia, [
|
|
3459
3458
|
(n(!0), F(G, null, L(f.columns, (e) => (n(), F("span", {
|
|
3460
|
-
style: Ie({ width: (e == null ? void 0 : e.width) ||
|
|
3459
|
+
style: Ie({ width: (e == null ? void 0 : e.width) || Vt, ...e == null ? void 0 : e.titleStyle, textAlign: (e == null ? void 0 : e.align) || "center" }),
|
|
3461
3460
|
key: e.key
|
|
3462
3461
|
}, [
|
|
3463
|
-
y(
|
|
3462
|
+
y(a.$slots, `${d.t}-title-${e.key}`, { col: e }, () => [
|
|
3464
3463
|
Me(ye(e.label), 1)
|
|
3465
3464
|
], !0)
|
|
3466
3465
|
], 4))), 128))
|
|
3467
|
-
])) : (n(), F("div",
|
|
3466
|
+
])) : (n(), F("div", da, [
|
|
3468
3467
|
(n(!0), F(G, null, L(f.columns, (e) => (n(), F("span", {
|
|
3469
|
-
style: Ie({ width: (e == null ? void 0 : e.width) ||
|
|
3468
|
+
style: Ie({ width: (e == null ? void 0 : e.width) || Vt, textAlign: (e == null ? void 0 : e.align) || "center", ...e == null ? void 0 : e.style }),
|
|
3470
3469
|
key: e.key,
|
|
3471
|
-
title:
|
|
3470
|
+
title: d.data[e.key]
|
|
3472
3471
|
}, [
|
|
3473
|
-
y(
|
|
3474
|
-
Me(ye(
|
|
3472
|
+
y(a.$slots, `${d.t}-option-${e.key}`, { col: e }, () => [
|
|
3473
|
+
Me(ye(d.data[e.key] ?? "-"), 1)
|
|
3475
3474
|
], !0)
|
|
3476
|
-
], 12,
|
|
3475
|
+
], 12, fa))), 128))
|
|
3477
3476
|
]));
|
|
3478
3477
|
}
|
|
3479
|
-
}),
|
|
3478
|
+
}), ma = /* @__PURE__ */ We(ca, [["__scopeId", "data-v-c0ac6b77"]]), pa = Object.freeze({}), Ot = [aa, bt, sa, ma];
|
|
3480
3479
|
let $t = {};
|
|
3481
|
-
const
|
|
3482
|
-
install: (
|
|
3483
|
-
$t = Object.freeze({ ...
|
|
3484
|
-
|
|
3485
|
-
}),
|
|
3480
|
+
const Da = {
|
|
3481
|
+
install: (d, f = {}) => {
|
|
3482
|
+
$t = Object.freeze({ ...pa, ...f }), Ot.forEach((a) => {
|
|
3483
|
+
d.component(a.name, a);
|
|
3484
|
+
}), d.provide("options", $t), d.config.globalProperties.$openModal = wt;
|
|
3486
3485
|
}
|
|
3487
|
-
},
|
|
3486
|
+
}, va = (d) => ({ dialog: Yt, drawer: Ut })[d] || null, wt = (d = {}, f = "dialog") => {
|
|
3488
3487
|
if (typeof document > "u") return () => {
|
|
3489
3488
|
};
|
|
3490
|
-
const
|
|
3489
|
+
const a = document.createElement("div");
|
|
3491
3490
|
let t = () => {
|
|
3492
3491
|
};
|
|
3493
|
-
const e =
|
|
3492
|
+
const e = va(f);
|
|
3494
3493
|
if (!e) return () => {
|
|
3495
3494
|
};
|
|
3496
|
-
const
|
|
3495
|
+
const i = le(!0), E = Xt({
|
|
3497
3496
|
setup() {
|
|
3498
3497
|
return t = () => {
|
|
3499
|
-
|
|
3500
|
-
E.unmount(),
|
|
3498
|
+
i.value = !1, setTimeout(() => {
|
|
3499
|
+
E.unmount(), a.remove();
|
|
3501
3500
|
}, 300);
|
|
3502
3501
|
}, () => {
|
|
3503
|
-
var x, T,
|
|
3502
|
+
var x, T, D;
|
|
3504
3503
|
return Ae(e, {
|
|
3505
|
-
modelValue:
|
|
3506
|
-
"onUpdate:modelValue": (
|
|
3504
|
+
modelValue: i.value,
|
|
3505
|
+
"onUpdate:modelValue": ($) => i.value = $,
|
|
3507
3506
|
appendToBody: !0,
|
|
3508
3507
|
draggable: !0,
|
|
3509
3508
|
"align-center": !0,
|
|
3510
3509
|
overflow: !0,
|
|
3511
3510
|
destroyOnClose: !0,
|
|
3512
3511
|
"close-on-click-modal": !1,
|
|
3513
|
-
...
|
|
3512
|
+
...d
|
|
3514
3513
|
}, {
|
|
3515
|
-
default: (x =
|
|
3516
|
-
header: (T =
|
|
3517
|
-
footer: (
|
|
3514
|
+
default: (x = d.slots) == null ? void 0 : x.default,
|
|
3515
|
+
header: (T = d.slots) == null ? void 0 : T.header,
|
|
3516
|
+
footer: (D = d.slots) == null ? void 0 : D.footer
|
|
3518
3517
|
});
|
|
3519
3518
|
};
|
|
3520
3519
|
},
|
|
3521
3520
|
mounted: () => {
|
|
3522
|
-
|
|
3521
|
+
mt();
|
|
3523
3522
|
}
|
|
3524
3523
|
});
|
|
3525
|
-
return
|
|
3524
|
+
return Ot.forEach((x) => {
|
|
3526
3525
|
E.component(x.name, x);
|
|
3527
|
-
}), E.provide("options", $t), E.use(
|
|
3526
|
+
}), E.provide("options", $t), E.use(Bt, { locale: ll }), document.body.appendChild(a), E.mount(a), t;
|
|
3528
3527
|
};
|
|
3529
|
-
function
|
|
3530
|
-
if (typeof
|
|
3531
|
-
return
|
|
3532
|
-
if (
|
|
3533
|
-
return parseFloat(
|
|
3534
|
-
const
|
|
3535
|
-
if (
|
|
3536
|
-
return
|
|
3537
|
-
if (
|
|
3538
|
-
return t * parseFloat(
|
|
3539
|
-
if (
|
|
3528
|
+
function At(d, f = window.innerWidth) {
|
|
3529
|
+
if (typeof d == "number")
|
|
3530
|
+
return d;
|
|
3531
|
+
if (d.endsWith("px"))
|
|
3532
|
+
return parseFloat(d);
|
|
3533
|
+
const a = window.innerHeight, t = window.innerWidth;
|
|
3534
|
+
if (d.endsWith("vh"))
|
|
3535
|
+
return a * parseFloat(d) / 100;
|
|
3536
|
+
if (d.endsWith("vw"))
|
|
3537
|
+
return t * parseFloat(d) / 100;
|
|
3538
|
+
if (d.endsWith("%")) {
|
|
3540
3539
|
if (typeof f != "number")
|
|
3541
3540
|
throw new Error("Reference size is required to convert % to px");
|
|
3542
|
-
return f * parseFloat(
|
|
3541
|
+
return f * parseFloat(d) / 100;
|
|
3543
3542
|
}
|
|
3544
|
-
if (
|
|
3545
|
-
let
|
|
3543
|
+
if (d.startsWith("calc(") && d.endsWith(")")) {
|
|
3544
|
+
let i = function(x) {
|
|
3546
3545
|
if (/[0-9+\-*/().\s]+$/.test(x))
|
|
3547
3546
|
return new Function("return " + x)();
|
|
3548
3547
|
throw new Error("Invalid calc expression");
|
|
3549
3548
|
};
|
|
3550
|
-
const e =
|
|
3551
|
-
return
|
|
3549
|
+
const e = d.slice(5, -1).trim();
|
|
3550
|
+
return i(e.replace(/([0-9.]+)([a-z%]+)/g, (x, T, D) => At(T + D, f)));
|
|
3552
3551
|
}
|
|
3553
|
-
throw new Error("Unsupported unit in value: " +
|
|
3552
|
+
throw new Error("Unsupported unit in value: " + d);
|
|
3554
3553
|
}
|
|
3555
|
-
const qe = (...
|
|
3556
|
-
const f = {},
|
|
3557
|
-
t[
|
|
3554
|
+
const qe = (...d) => {
|
|
3555
|
+
const f = {}, a = (t, e) => (Object.keys(e).forEach((i) => {
|
|
3556
|
+
t[i] = typeof e[i] == "object" && !Array.isArray(e[i]) ? a(t[i] || {}, e[i]) : e[i];
|
|
3558
3557
|
}), t);
|
|
3559
|
-
return
|
|
3558
|
+
return d.forEach((t = {}) => a(f, t)), f;
|
|
3560
3559
|
};
|
|
3561
|
-
function Ve(
|
|
3562
|
-
const
|
|
3563
|
-
for (const t in
|
|
3564
|
-
|
|
3565
|
-
return
|
|
3560
|
+
function Ve(d, f = (a, t) => f(a, t)) {
|
|
3561
|
+
const a = {};
|
|
3562
|
+
for (const t in d)
|
|
3563
|
+
d.hasOwnProperty(t) && f(t, d[t]) && (a[t] = d[t]);
|
|
3564
|
+
return a;
|
|
3566
3565
|
}
|
|
3567
|
-
function
|
|
3568
|
-
for (const
|
|
3569
|
-
if (
|
|
3570
|
-
return
|
|
3571
|
-
if (
|
|
3572
|
-
const E =
|
|
3566
|
+
function ha(d, f, a = "value", t = "label", e = "children") {
|
|
3567
|
+
for (const i of d) {
|
|
3568
|
+
if (i[a] === f)
|
|
3569
|
+
return i[t];
|
|
3570
|
+
if (i[e] && i[e].length > 0) {
|
|
3571
|
+
const E = ha(i[e], f, a, t, e);
|
|
3573
3572
|
if (E)
|
|
3574
3573
|
return E;
|
|
3575
3574
|
}
|
|
3576
3575
|
}
|
|
3577
3576
|
return null;
|
|
3578
3577
|
}
|
|
3579
|
-
function Et(
|
|
3580
|
-
if (!
|
|
3581
|
-
const f = ["角", "分"],
|
|
3578
|
+
function Et(d) {
|
|
3579
|
+
if (!d || isNaN(d)) return "零";
|
|
3580
|
+
const f = ["角", "分"], a = ["零", "壹", "贰", "叁", "肆", "伍", "陆", "柒", "捌", "玖"], t = [
|
|
3582
3581
|
["元", "万", "亿"],
|
|
3583
3582
|
["", "拾", "佰", "仟"]
|
|
3584
|
-
], e =
|
|
3585
|
-
|
|
3586
|
-
let
|
|
3583
|
+
], e = d < 0 ? "欠" : "";
|
|
3584
|
+
d = Math.abs(d);
|
|
3585
|
+
let i = "";
|
|
3587
3586
|
for (let E = 0; E < f.length; E++)
|
|
3588
|
-
|
|
3589
|
-
|
|
3590
|
-
for (let E = 0; E < t[0].length &&
|
|
3587
|
+
i += (a[Math.floor(d * 10 * Math.pow(10, E)) % 10] + f[E]).replace(/零./, "");
|
|
3588
|
+
i = i || "整", d = Math.floor(d);
|
|
3589
|
+
for (let E = 0; E < t[0].length && d > 0; E++) {
|
|
3591
3590
|
let x = "";
|
|
3592
|
-
for (let T = 0; T < t[1].length &&
|
|
3593
|
-
x =
|
|
3594
|
-
|
|
3591
|
+
for (let T = 0; T < t[1].length && d > 0; T++)
|
|
3592
|
+
x = a[d % 10] + t[1][T] + x, d = Math.floor(d / 10);
|
|
3593
|
+
i = x.replace(/(零.)*零$/, "").replace(/^$/, "零") + t[0][E] + i;
|
|
3595
3594
|
}
|
|
3596
|
-
return e +
|
|
3595
|
+
return e + i.replace(/(零.)*零元/, "元").replace(/(零.)+/g, "零").replace(/^整$/, "零元整");
|
|
3597
3596
|
}
|
|
3598
|
-
function
|
|
3599
|
-
if (typeof
|
|
3597
|
+
function ya(d) {
|
|
3598
|
+
if (typeof d != "number" || isNaN(d) || !isFinite(d))
|
|
3600
3599
|
return "0.00";
|
|
3601
|
-
const f =
|
|
3602
|
-
return `${
|
|
3600
|
+
const f = d.toFixed(2), [a, t] = f.split(".");
|
|
3601
|
+
return `${a.replace(/\B(?=(\d{3})+(?!\d))/g, ",")}.${t}`;
|
|
3603
3602
|
}
|
|
3604
3603
|
const he = {
|
|
3605
3604
|
RADIO: "radio",
|
|
@@ -3629,21 +3628,21 @@ const he = {
|
|
|
3629
3628
|
PASSWORD: "password",
|
|
3630
3629
|
TEXTAREA: "textarea",
|
|
3631
3630
|
TEL: "tel"
|
|
3632
|
-
},
|
|
3631
|
+
}, mt = () => {
|
|
3633
3632
|
et(() => {
|
|
3634
|
-
const
|
|
3635
|
-
if (!
|
|
3633
|
+
const d = document.querySelector(".el-dialog");
|
|
3634
|
+
if (!d) {
|
|
3636
3635
|
console.warn("未找到对话框元素");
|
|
3637
3636
|
return;
|
|
3638
3637
|
}
|
|
3639
|
-
if (
|
|
3638
|
+
if (d.querySelector(".dialog-resize-handle"))
|
|
3640
3639
|
return;
|
|
3641
|
-
const f =
|
|
3642
|
-
|
|
3640
|
+
const f = ga();
|
|
3641
|
+
d.appendChild(f), ba(d), $a(d, f);
|
|
3643
3642
|
});
|
|
3644
|
-
},
|
|
3645
|
-
const
|
|
3646
|
-
return Object.assign(
|
|
3643
|
+
}, ga = () => {
|
|
3644
|
+
const d = document.createElement("div");
|
|
3645
|
+
return Object.assign(d.style, {
|
|
3647
3646
|
position: "absolute",
|
|
3648
3647
|
right: "0",
|
|
3649
3648
|
bottom: "0",
|
|
@@ -3652,36 +3651,36 @@ const he = {
|
|
|
3652
3651
|
background: "transparent",
|
|
3653
3652
|
cursor: "nwse-resize",
|
|
3654
3653
|
zIndex: "999999999999"
|
|
3655
|
-
}),
|
|
3656
|
-
},
|
|
3657
|
-
Object.assign(
|
|
3654
|
+
}), d.className = "dialog-resize-handle", d;
|
|
3655
|
+
}, ba = (d) => {
|
|
3656
|
+
Object.assign(d.style, {
|
|
3658
3657
|
transition: "none",
|
|
3659
3658
|
minWidth: "300px",
|
|
3660
3659
|
minHeight: "200px",
|
|
3661
3660
|
resize: "none"
|
|
3662
3661
|
// 防止与原生resize冲突
|
|
3663
3662
|
});
|
|
3664
|
-
},
|
|
3665
|
-
let
|
|
3666
|
-
const x = (
|
|
3667
|
-
|
|
3668
|
-
}, T = (
|
|
3669
|
-
if (!
|
|
3670
|
-
const z = Math.max(300,
|
|
3671
|
-
|
|
3672
|
-
},
|
|
3673
|
-
|
|
3663
|
+
}, $a = (d, f) => {
|
|
3664
|
+
let a = !1, t, e, i, E;
|
|
3665
|
+
const x = ($) => {
|
|
3666
|
+
$.preventDefault(), a = !0, t = $.clientX, e = $.clientY, i = parseInt(document.defaultView.getComputedStyle(d).width), E = parseInt(document.defaultView.getComputedStyle(d).height), document.addEventListener("mousemove", T), document.addEventListener("mouseup", D);
|
|
3667
|
+
}, T = ($) => {
|
|
3668
|
+
if (!a) return;
|
|
3669
|
+
const z = Math.max(300, i + $.clientX - t), te = Math.max(200, E + $.clientY - e);
|
|
3670
|
+
d.style.width = `${z}px`, d.style.height = `${te}px`;
|
|
3671
|
+
}, D = () => {
|
|
3672
|
+
a = !1, document.removeEventListener("mousemove", T), document.removeEventListener("mouseup", D);
|
|
3674
3673
|
};
|
|
3675
3674
|
f.addEventListener("mousedown", x);
|
|
3676
3675
|
};
|
|
3677
3676
|
export {
|
|
3678
3677
|
he as CT,
|
|
3679
|
-
|
|
3680
|
-
|
|
3681
|
-
|
|
3678
|
+
mt as bindResize,
|
|
3679
|
+
At as convertToPx,
|
|
3680
|
+
Da as default,
|
|
3682
3681
|
Ve as filterObject,
|
|
3683
|
-
|
|
3684
|
-
|
|
3682
|
+
ha as findTreeLabelByValue,
|
|
3683
|
+
ya as formatAmount,
|
|
3685
3684
|
qe as mergeObjects,
|
|
3686
3685
|
Et as moneyToChinese,
|
|
3687
3686
|
wt as openModal
|