vue-2024-ui 0.0.37 → 0.0.39

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