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