vue-2024-ui 0.0.87 → 0.0.89

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