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