@jt-home/mfe-components 1.0.39 → 1.0.40
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.cjs +2 -2
- package/dist/index.mjs +966 -942
- package/dist/style.css +1 -1
- package/dist/types/components/form/item/JtDatePicker/index.vue.d.ts +4 -1
- package/dist/types/components/form/item/JtInput/index.vue.d.ts +5 -2
- package/dist/types/components/form/item/JtSelect/types.d.ts +1 -0
- package/package.json +98 -99
- package/readme.md +694 -694
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import './style.css';
|
|
2
2
|
import { t as Z, J as Dt, i as Un } from "./index-C6AyqKhk.js";
|
|
3
3
|
import { a as ms, g as vs, n as hs, r as gs, s as ys, b as bs } from "./index-C6AyqKhk.js";
|
|
4
|
-
import { defineComponent as pe, useAttrs as Hn, computed as O, openBlock as
|
|
4
|
+
import { defineComponent as pe, useAttrs as Hn, computed as O, openBlock as $, createBlock as H, mergeProps as ae, toHandlers as et, withCtx as U, renderSlot as te, resolveDynamicComponent as Kt, createCommentVNode as fe, ref as ge, watch as Ee, mergeDefaults as Jn, withKeys as Wn, createElementBlock as G, Fragment as Se, renderList as ye, normalizeStyle as Yt, nextTick as Zn, useSlots as Le, normalizeClass as We, createVNode as Ie, withModifiers as Ut, unref as J, createSlots as Re, createElementVNode as ne, toDisplayString as oe, normalizeProps as Oe, guardReactiveProps as Be, useModel as vt, withDirectives as Qn, mergeModels as Ft, shallowRef as je, onMounted as Ht, onBeforeUnmount as Xn, createTextVNode as He, resolveComponent as eo, onErrorCaptured as to } from "vue";
|
|
5
5
|
import { ElButton as $t, ElIcon as Jt, ElCascader as no, ElDatePicker as Wt, ElInput as Zt, ElSelect as Qt, ElOption as Xt, ElFormItem as en, ElForm as tn, ElTable as nn, ElTableColumn as on, ElPagination as oo, ElLoadingDirective as ro, ElInputNumber as ao, ElSwitch as so, ElRow as lo, ElCol as io, ElPopconfirm as co } from "element-plus/es";
|
|
6
6
|
import { cascaderEmits as uo, inputEmits as Bt, selectEmits as Et } from "element-plus";
|
|
7
7
|
const bt = 2, fo = 3;
|
|
@@ -61,12 +61,12 @@ const vo = /* @__PURE__ */ pe({
|
|
|
61
61
|
...sn(n),
|
|
62
62
|
...a
|
|
63
63
|
};
|
|
64
|
-
}),
|
|
64
|
+
}), l = O(() => an(n));
|
|
65
65
|
return (c, a) => {
|
|
66
|
-
const
|
|
67
|
-
return
|
|
66
|
+
const r = Jt, s = $t;
|
|
67
|
+
return $(), H(s, ae({ class: "jt-button" }, o.value, et(l.value)), {
|
|
68
68
|
default: U(() => [
|
|
69
|
-
c.$slots.icon ? (
|
|
69
|
+
c.$slots.icon ? ($(), H(r, {
|
|
70
70
|
key: 0,
|
|
71
71
|
class: "jt-button__icon"
|
|
72
72
|
}, {
|
|
@@ -74,12 +74,12 @@ const vo = /* @__PURE__ */ pe({
|
|
|
74
74
|
te(c.$slots, "icon", {}, void 0, !0)
|
|
75
75
|
]),
|
|
76
76
|
_: 3
|
|
77
|
-
})) : t.icon ? (
|
|
77
|
+
})) : t.icon ? ($(), H(r, {
|
|
78
78
|
key: 1,
|
|
79
79
|
class: "jt-button__icon"
|
|
80
80
|
}, {
|
|
81
81
|
default: U(() => [
|
|
82
|
-
(
|
|
82
|
+
($(), H(Kt(t.icon)))
|
|
83
83
|
]),
|
|
84
84
|
_: 1
|
|
85
85
|
})) : fe("", !0),
|
|
@@ -91,10 +91,10 @@ const vo = /* @__PURE__ */ pe({
|
|
|
91
91
|
}
|
|
92
92
|
}), be = (e, t) => {
|
|
93
93
|
const n = e.__vccOpts || e;
|
|
94
|
-
for (const [o,
|
|
95
|
-
n[o] =
|
|
94
|
+
for (const [o, l] of t)
|
|
95
|
+
n[o] = l;
|
|
96
96
|
return n;
|
|
97
|
-
}, rt = /* @__PURE__ */ be(vo, [["__scopeId", "data-v-
|
|
97
|
+
}, rt = /* @__PURE__ */ be(vo, [["__scopeId", "data-v-fde6491e"]]), ho = {
|
|
98
98
|
// 默认值只补组件缺省体验,显式传入的 false、null 和空字符串仍由归一化逻辑保留。
|
|
99
99
|
options: () => [],
|
|
100
100
|
placeholder: Z("common.请选择"),
|
|
@@ -159,22 +159,22 @@ const yo = /* @__PURE__ */ pe({
|
|
|
159
159
|
const n = e, o = O(() => {
|
|
160
160
|
const f = go(n);
|
|
161
161
|
if (!f.disabled) return f;
|
|
162
|
-
const { placeholder:
|
|
163
|
-
return
|
|
164
|
-
}),
|
|
162
|
+
const { placeholder: _, ...M } = f;
|
|
163
|
+
return M;
|
|
164
|
+
}), l = ge(n.modelValue);
|
|
165
165
|
Ee(
|
|
166
166
|
() => n.modelValue,
|
|
167
167
|
(f) => {
|
|
168
|
-
|
|
168
|
+
l.value = f;
|
|
169
169
|
},
|
|
170
170
|
{ deep: !0 }
|
|
171
171
|
);
|
|
172
172
|
const c = t;
|
|
173
|
-
function a(f, ...
|
|
174
|
-
c(f, ...
|
|
173
|
+
function a(f, ..._) {
|
|
174
|
+
c(f, ..._);
|
|
175
175
|
}
|
|
176
|
-
function
|
|
177
|
-
|
|
176
|
+
function r(f) {
|
|
177
|
+
l.value = f, a("update:modelValue", f);
|
|
178
178
|
}
|
|
179
179
|
function s(f) {
|
|
180
180
|
a("change", f);
|
|
@@ -182,13 +182,13 @@ const yo = /* @__PURE__ */ pe({
|
|
|
182
182
|
function i(f) {
|
|
183
183
|
a("focus", f);
|
|
184
184
|
}
|
|
185
|
-
function
|
|
185
|
+
function h(f) {
|
|
186
186
|
a("blur", f);
|
|
187
187
|
}
|
|
188
|
-
function
|
|
188
|
+
function S() {
|
|
189
189
|
a("clear");
|
|
190
190
|
}
|
|
191
|
-
function
|
|
191
|
+
function I(f) {
|
|
192
192
|
a("visibleChange", f);
|
|
193
193
|
}
|
|
194
194
|
function L(f) {
|
|
@@ -197,16 +197,16 @@ const yo = /* @__PURE__ */ pe({
|
|
|
197
197
|
function V(f) {
|
|
198
198
|
a("removeTag", f);
|
|
199
199
|
}
|
|
200
|
-
return (f,
|
|
201
|
-
const
|
|
202
|
-
return
|
|
203
|
-
"model-value":
|
|
204
|
-
"onUpdate:modelValue":
|
|
200
|
+
return (f, _) => {
|
|
201
|
+
const M = no;
|
|
202
|
+
return $(), H(M, ae({ class: "jt-cascader" }, o.value, {
|
|
203
|
+
"model-value": l.value,
|
|
204
|
+
"onUpdate:modelValue": r,
|
|
205
205
|
onChange: s,
|
|
206
206
|
onFocus: i,
|
|
207
|
-
onBlur:
|
|
208
|
-
onClear:
|
|
209
|
-
onVisibleChange:
|
|
207
|
+
onBlur: h,
|
|
208
|
+
onClear: S,
|
|
209
|
+
onVisibleChange: I,
|
|
210
210
|
onExpandChange: L,
|
|
211
211
|
onRemoveTag: V
|
|
212
212
|
}), null, 16, ["model-value"]);
|
|
@@ -262,36 +262,49 @@ const yo = /* @__PURE__ */ pe({
|
|
|
262
262
|
endPlaceholder: {},
|
|
263
263
|
defaultValue: {},
|
|
264
264
|
defaultTime: {},
|
|
265
|
-
isRange: { type: Boolean }
|
|
265
|
+
isRange: { type: Boolean },
|
|
266
|
+
preservePlaceholderWhenDisabled: { type: Boolean }
|
|
266
267
|
},
|
|
267
268
|
setup(e) {
|
|
268
269
|
const t = e, n = O(() => {
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
} = t;
|
|
276
|
-
return l;
|
|
277
|
-
}
|
|
278
|
-
return {
|
|
279
|
-
...t,
|
|
270
|
+
const { preservePlaceholderWhenDisabled: a, ...r } = t, s = l(
|
|
271
|
+
"jt-date-picker-popper",
|
|
272
|
+
r.popperClass
|
|
273
|
+
), i = {
|
|
274
|
+
...r,
|
|
275
|
+
popperClass: s,
|
|
280
276
|
startPlaceholder: t.startPlaceholder ?? (o(t.type) ? Z("common.开始日期") : void 0),
|
|
281
277
|
endPlaceholder: t.endPlaceholder ?? (o(t.type) ? Z("common.结束日期") : void 0)
|
|
282
278
|
};
|
|
279
|
+
if (t.disabled && !a) {
|
|
280
|
+
const {
|
|
281
|
+
placeholder: h,
|
|
282
|
+
startPlaceholder: S,
|
|
283
|
+
endPlaceholder: I,
|
|
284
|
+
...L
|
|
285
|
+
} = i;
|
|
286
|
+
return L;
|
|
287
|
+
}
|
|
288
|
+
return i;
|
|
283
289
|
});
|
|
284
|
-
function o(
|
|
285
|
-
return
|
|
290
|
+
function o(a) {
|
|
291
|
+
return a?.includes("range") ?? !1;
|
|
286
292
|
}
|
|
287
|
-
|
|
288
|
-
const
|
|
289
|
-
return
|
|
290
|
-
|
|
293
|
+
function l(a, r) {
|
|
294
|
+
const s = Array.isArray(r) ? r.flatMap((i) => c(i)) : c(r);
|
|
295
|
+
return [a, ...s].filter(Boolean).join(" ");
|
|
296
|
+
}
|
|
297
|
+
function c(a) {
|
|
298
|
+
return a ? typeof a == "string" ? [a] : Array.isArray(a) ? a.flatMap((r) => c(r)) : typeof a == "object" ? Object.entries(a).filter(([, r]) => !!r).map(([r]) => r) : [] : [];
|
|
299
|
+
}
|
|
300
|
+
return (a, r) => {
|
|
301
|
+
const s = Wt;
|
|
302
|
+
return $(), H(s, ae({ class: "jt-date-picker" }, n.value, {
|
|
303
|
+
"onUpdate:modelValue": r[0] || (r[0] = (i) => a.$emit("update:modelValue", i))
|
|
291
304
|
}), null, 16);
|
|
292
305
|
};
|
|
293
306
|
}
|
|
294
|
-
}), So = /* @__PURE__ */ be(bo, [["__scopeId", "data-v-
|
|
307
|
+
}), So = /* @__PURE__ */ be(bo, [["__scopeId", "data-v-dcb1a539"]]), _o = /* @__PURE__ */ pe({
|
|
295
308
|
name: "JtInput",
|
|
296
309
|
__name: "index",
|
|
297
310
|
props: {
|
|
@@ -327,7 +340,8 @@ const yo = /* @__PURE__ */ pe({
|
|
|
327
340
|
ariaLabel: {},
|
|
328
341
|
inputmode: {},
|
|
329
342
|
name: {},
|
|
330
|
-
countGraphemes: {}
|
|
343
|
+
countGraphemes: {},
|
|
344
|
+
preservePlaceholderWhenDisabled: { type: Boolean }
|
|
331
345
|
},
|
|
332
346
|
emits: {
|
|
333
347
|
...Bt,
|
|
@@ -335,27 +349,29 @@ const yo = /* @__PURE__ */ pe({
|
|
|
335
349
|
},
|
|
336
350
|
setup(e, { emit: t }) {
|
|
337
351
|
const n = e, o = O(() => {
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
352
|
+
const { preservePlaceholderWhenDisabled: a, ...r } = n;
|
|
353
|
+
if (!n.disabled || a) return r;
|
|
354
|
+
const { placeholder: s, ...i } = r;
|
|
355
|
+
return i;
|
|
356
|
+
}), l = t, c = O(() => Object.fromEntries(
|
|
342
357
|
Object.keys(Bt).map((a) => [
|
|
343
358
|
a,
|
|
344
|
-
(...
|
|
359
|
+
(...r) => l(a, ...r)
|
|
345
360
|
])
|
|
346
361
|
));
|
|
347
|
-
return (a,
|
|
362
|
+
return (a, r) => {
|
|
348
363
|
const s = Zt;
|
|
349
|
-
return
|
|
350
|
-
onKeyup:
|
|
364
|
+
return $(), H(s, ae({ class: "jt-input" }, o.value, et(c.value), {
|
|
365
|
+
onKeyup: r[0] || (r[0] = Wn((i) => l("enter"), ["enter"]))
|
|
351
366
|
}), null, 16);
|
|
352
367
|
};
|
|
353
368
|
}
|
|
354
|
-
}), ht = /* @__PURE__ */ be(_o, [["__scopeId", "data-v-
|
|
369
|
+
}), ht = /* @__PURE__ */ be(_o, [["__scopeId", "data-v-9467a9b9"]]), wo = /* @__PURE__ */ pe({
|
|
355
370
|
name: "JtSelect",
|
|
356
371
|
__name: "index",
|
|
357
372
|
props: {
|
|
358
373
|
options: {},
|
|
374
|
+
preservePlaceholderWhenDisabled: { type: Boolean },
|
|
359
375
|
ariaLabel: {},
|
|
360
376
|
emptyValues: {},
|
|
361
377
|
valueOnClear: {},
|
|
@@ -411,31 +427,38 @@ const yo = /* @__PURE__ */ pe({
|
|
|
411
427
|
emits: Et,
|
|
412
428
|
setup(e, { emit: t }) {
|
|
413
429
|
const n = e, o = O(() => {
|
|
414
|
-
const { options:
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
placeholder: l
|
|
430
|
+
const { options: r, placeholder: s, preservePlaceholderWhenDisabled: i, ...h } = n, S = l("jt-select-popper", h.popperClass), I = {
|
|
431
|
+
...h,
|
|
432
|
+
popperClass: S
|
|
418
433
|
};
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
434
|
+
return n.disabled && !i ? I : {
|
|
435
|
+
...I,
|
|
436
|
+
placeholder: s
|
|
437
|
+
};
|
|
438
|
+
});
|
|
439
|
+
function l(r, s) {
|
|
440
|
+
return [r, s].flat().filter(Boolean).join(" ");
|
|
441
|
+
}
|
|
442
|
+
const c = t, a = O(() => Object.fromEntries(
|
|
443
|
+
Object.keys(Et).map((r) => [
|
|
444
|
+
r,
|
|
445
|
+
(...s) => c(r, ...s)
|
|
423
446
|
])
|
|
424
447
|
));
|
|
425
|
-
return (
|
|
426
|
-
const
|
|
427
|
-
return
|
|
448
|
+
return (r, s) => {
|
|
449
|
+
const i = Xt, h = Qt;
|
|
450
|
+
return $(), H(h, ae({ class: "jt-select" }, o.value, et(a.value)), {
|
|
428
451
|
default: U(() => [
|
|
429
|
-
(
|
|
430
|
-
key:
|
|
452
|
+
($(!0), G(Se, null, ye(r.options ?? [], (S) => ($(), H(i, ae({
|
|
453
|
+
key: S.value,
|
|
431
454
|
ref_for: !0
|
|
432
|
-
},
|
|
455
|
+
}, S), null, 16))), 128))
|
|
433
456
|
]),
|
|
434
457
|
_: 1
|
|
435
458
|
}, 16);
|
|
436
459
|
};
|
|
437
460
|
}
|
|
438
|
-
}), Io = /* @__PURE__ */ be(wo, [["__scopeId", "data-v-
|
|
461
|
+
}), Io = /* @__PURE__ */ be(wo, [["__scopeId", "data-v-6cfa7fbd"]]), $o = { class: "jt-form-items" }, gt = 4, Co = /* @__PURE__ */ pe({
|
|
439
462
|
name: "JTFormItems",
|
|
440
463
|
__name: "JtFormItems",
|
|
441
464
|
props: {
|
|
@@ -455,46 +478,46 @@ const yo = /* @__PURE__ */ pe({
|
|
|
455
478
|
daterange: "date-picker",
|
|
456
479
|
"date-range": "date-picker",
|
|
457
480
|
dateRange: "date-picker"
|
|
458
|
-
},
|
|
459
|
-
const { itemType: v } =
|
|
481
|
+
}, l = /* @__PURE__ */ new Set(["prop", "label", "itemType", "span", "options", "rules", "formItemProps", "showSlot", "show"]), c = Object.keys(n), a = /* @__PURE__ */ new Map(), r = O(() => t.configs.filter((g) => g.show !== !1)), s = (g) => {
|
|
482
|
+
const { itemType: v } = g;
|
|
460
483
|
if (!v) return ht;
|
|
461
484
|
if (typeof v != "string") return v;
|
|
462
485
|
const F = o[v] ?? v;
|
|
463
486
|
return c.includes(F) ? n[F] : (console.error(
|
|
464
487
|
`[JtFormItems] 不支持的 itemType: "${v}",支持的类型: ${c.join(", ")}`
|
|
465
488
|
), ht);
|
|
466
|
-
}, i = (
|
|
467
|
-
const v = sn(
|
|
468
|
-
return
|
|
489
|
+
}, i = (g) => {
|
|
490
|
+
const v = sn(g, l);
|
|
491
|
+
return g.itemType === "select" || g.itemType === "remote-select" || g.itemType === "cascader" ? {
|
|
469
492
|
...v,
|
|
470
|
-
options:
|
|
471
|
-
} : z(
|
|
493
|
+
options: g.options
|
|
494
|
+
} : z(g.itemType) ? {
|
|
472
495
|
...v,
|
|
473
496
|
type: "daterange"
|
|
474
497
|
} : v;
|
|
475
|
-
},
|
|
476
|
-
rules:
|
|
477
|
-
...
|
|
478
|
-
}),
|
|
479
|
-
t.formData[
|
|
498
|
+
}, h = (g) => an(g, l), S = (g) => ({
|
|
499
|
+
rules: g.rules,
|
|
500
|
+
...g.formItemProps
|
|
501
|
+
}), I = (g, v) => {
|
|
502
|
+
t.formData[g] = v;
|
|
480
503
|
};
|
|
481
|
-
function L(
|
|
504
|
+
function L(g) {
|
|
482
505
|
return (v) => {
|
|
483
506
|
if (v) {
|
|
484
|
-
a.set(
|
|
507
|
+
a.set(g, v);
|
|
485
508
|
return;
|
|
486
509
|
}
|
|
487
|
-
a.delete(
|
|
510
|
+
a.delete(g);
|
|
488
511
|
};
|
|
489
512
|
}
|
|
490
|
-
function V(
|
|
513
|
+
function V(g, v) {
|
|
491
514
|
Zn(() => {
|
|
492
|
-
a.get(
|
|
515
|
+
a.get(g)?.validate(v).catch(() => {
|
|
493
516
|
});
|
|
494
517
|
});
|
|
495
518
|
}
|
|
496
|
-
const f = (
|
|
497
|
-
const v =
|
|
519
|
+
const f = (g) => Math.min(Math.max(Math.trunc(g || 1), 1), 4), _ = O(() => {
|
|
520
|
+
const v = r.value.reduce(
|
|
498
521
|
(F, y) => F + f(t.span || y.span),
|
|
499
522
|
0
|
|
500
523
|
) % gt;
|
|
@@ -503,52 +526,52 @@ const yo = /* @__PURE__ */ pe({
|
|
|
503
526
|
} : {
|
|
504
527
|
gridColumn: `${v + 1} / span ${gt - v}`
|
|
505
528
|
};
|
|
506
|
-
}),
|
|
507
|
-
gridColumn: `span ${f(t.span ||
|
|
529
|
+
}), M = (g) => ({
|
|
530
|
+
gridColumn: `span ${f(t.span || g.span)}`
|
|
508
531
|
});
|
|
509
|
-
function z(
|
|
510
|
-
return
|
|
532
|
+
function z(g) {
|
|
533
|
+
return g === "daterange" || g === "date-range" || g === "dateRange";
|
|
511
534
|
}
|
|
512
|
-
return (
|
|
535
|
+
return (g, v) => {
|
|
513
536
|
const F = en;
|
|
514
|
-
return
|
|
515
|
-
(
|
|
537
|
+
return $(), G("div", $o, [
|
|
538
|
+
($(!0), G(Se, null, ye(r.value, (y) => ($(), H(F, ae({
|
|
516
539
|
key: y.prop,
|
|
517
540
|
ref_for: !0,
|
|
518
541
|
ref: L(y.prop),
|
|
519
542
|
class: "jt-form-items__item",
|
|
520
|
-
style:
|
|
543
|
+
style: M(y),
|
|
521
544
|
label: y.label,
|
|
522
545
|
prop: y.prop
|
|
523
|
-
},
|
|
546
|
+
}, S(y)), {
|
|
524
547
|
default: U(() => [
|
|
525
|
-
y.showSlot ? te(
|
|
548
|
+
y.showSlot ? te(g.$slots, y.prop, { key: 0 }, void 0, !0) : ($(), H(Kt(s(y)), ae({
|
|
526
549
|
key: 1,
|
|
527
|
-
"model-value":
|
|
550
|
+
"model-value": g.formData[y.prop],
|
|
528
551
|
ref_for: !0
|
|
529
|
-
}, i(y), et(
|
|
530
|
-
"onUpdate:modelValue": (A) =>
|
|
552
|
+
}, i(y), et(h(y)), {
|
|
553
|
+
"onUpdate:modelValue": (A) => I(y.prop, A),
|
|
531
554
|
onChange: () => V(y.prop, "change"),
|
|
532
555
|
onBlur: () => V(y.prop, "blur")
|
|
533
556
|
}), null, 16, ["model-value", "onUpdate:modelValue", "onChange", "onBlur"]))
|
|
534
557
|
]),
|
|
535
558
|
_: 2
|
|
536
559
|
}, 1040, ["style", "label", "prop"]))), 128)),
|
|
537
|
-
|
|
560
|
+
g.$slots.actions ? ($(), H(F, {
|
|
538
561
|
key: 0,
|
|
539
562
|
class: "jt-form-items__actions",
|
|
540
|
-
style: Yt(
|
|
563
|
+
style: Yt(_.value)
|
|
541
564
|
}, {
|
|
542
565
|
default: U(() => [
|
|
543
|
-
te(
|
|
566
|
+
te(g.$slots, "actions", {}, void 0, !0)
|
|
544
567
|
]),
|
|
545
568
|
_: 3
|
|
546
569
|
}, 8, ["style"])) : fe("", !0)
|
|
547
570
|
]);
|
|
548
571
|
};
|
|
549
572
|
}
|
|
550
|
-
}), ko = /* @__PURE__ */ be(Co, [["__scopeId", "data-v-
|
|
551
|
-
function
|
|
573
|
+
}), ko = /* @__PURE__ */ be(Co, [["__scopeId", "data-v-f16cba07"]]);
|
|
574
|
+
function Mo() {
|
|
552
575
|
const e = ge(!1);
|
|
553
576
|
function t() {
|
|
554
577
|
e.value = !0;
|
|
@@ -562,7 +585,7 @@ function To() {
|
|
|
562
585
|
searchDone: n
|
|
563
586
|
};
|
|
564
587
|
}
|
|
565
|
-
const
|
|
588
|
+
const To = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%200%2014%2014'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3crect%20x='0.5'%20y='-0.5'%20width='11'%20height='11'%20rx='5.5'%20transform='matrix(1%200%200%20-1%201%2012)'%20stroke='%23999999'/%3e%3cpath%20d='M10%208.16064L7%205.16064L4%208.16064'%20stroke='%23999999'/%3e%3c/svg%3e", Oo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%200%2014%2014'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M2.375%207.00017C2.375%207.27631%202.59886%207.50017%202.875%207.50017C3.15114%207.50017%203.375%207.27631%203.375%207.00017H2.875H2.375ZM2.875%207.00017H3.375C3.375%204.46334%205.41801%202.41406%207.93713%202.41406V1.91406V1.41406C4.86127%201.41406%202.375%203.91551%202.375%207.00017H2.875ZM7.93713%201.91406V2.41406C10.4563%202.41406%2012.4993%204.46334%2012.4993%207.00017H12.9993H13.4993C13.4993%203.91551%2011.013%201.41406%207.93713%201.41406V1.91406ZM12.9993%207.00017H12.4993C12.4993%209.537%2010.4563%2011.5863%207.93713%2011.5863V12.0863V12.5863C11.013%2012.5863%2013.4993%2010.0848%2013.4993%207.00017H12.9993ZM7.93713%2012.0863V11.5863C6.68975%2011.5863%205.55663%2011.0806%204.72892%2010.2635L4.37765%2010.6193L4.02638%2010.9752C5.0317%2011.9676%206.41366%2012.5863%207.93713%2012.5863V12.0863Z'%20fill='%23999999'/%3e%3cpath%20d='M4.75131%206.0102L2.88631%207.88403L1%205.99414'%20stroke='%23999999'%20stroke-miterlimit='10'/%3e%3c/svg%3e", Do = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%200%2014%2014'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M6.60938%2012.1099C9.64694%2012.1099%2012.1094%209.64743%2012.1094%206.60986C12.1094%203.5723%209.64694%201.10986%206.60938%201.10986C3.57181%201.10986%201.10938%203.5723%201.10938%206.60986C1.10938%209.64743%203.57181%2012.1099%206.60938%2012.1099Z'%20stroke='white'%20stroke-miterlimit='10'/%3e%3cpath%20d='M12.4993%2012.5002L10.2832%2010.3301'%20stroke='white'%20stroke-miterlimit='10'/%3e%3c/svg%3e", Fo = { class: "jt-filter-bar__btns" }, Bo = ["src"], Eo = ["src"], Lo = ["src"], Po = /* @__PURE__ */ pe({
|
|
566
589
|
name: "JtFilterBar",
|
|
567
590
|
__name: "JtFilterBar",
|
|
568
591
|
props: {
|
|
@@ -572,78 +595,79 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
572
595
|
},
|
|
573
596
|
emits: ["update:modelValue", "search", "reset"],
|
|
574
597
|
setup(e, { expose: t, emit: n }) {
|
|
575
|
-
const o = e,
|
|
576
|
-
() => o.columns.filter((
|
|
598
|
+
const o = e, l = n, c = ge(), a = Le(), r = ge({}), { searchDisabled: s, searchLoading: i, searchDone: h } = Mo(), S = O(() => o.option), I = ge(S.value.searchCollapsed ?? !0), L = O(
|
|
599
|
+
() => o.columns.filter((T) => T.search === !0)
|
|
577
600
|
), V = O(
|
|
578
|
-
() => Math.max(1,
|
|
601
|
+
() => Math.max(1, S.value.searchSpan ?? 4)
|
|
579
602
|
), f = O(
|
|
580
|
-
() => Math.max(1,
|
|
581
|
-
),
|
|
582
|
-
() => Math.max(1,
|
|
583
|
-
), z = O(() => V.value),
|
|
603
|
+
() => Math.max(1, S.value.searchCollapsedRows ?? 1)
|
|
604
|
+
), _ = O(() => V.value), M = O(
|
|
605
|
+
() => Math.max(1, _.value * f.value)
|
|
606
|
+
), z = O(() => V.value), g = O(
|
|
584
607
|
() => j.value ? "264px" : "174px"
|
|
585
608
|
), v = O(
|
|
586
|
-
() => K(
|
|
609
|
+
() => K(S.value.searchLabelWidth ?? 84)
|
|
587
610
|
), F = O(
|
|
588
|
-
() =>
|
|
611
|
+
() => S.value.searchLabelPosition ?? "top"
|
|
589
612
|
), y = O(
|
|
590
|
-
() => q(
|
|
613
|
+
() => q(S.value.searchGutter, 16)
|
|
591
614
|
), A = O(
|
|
592
|
-
() => q(
|
|
615
|
+
() => q(S.value.searchRowGap, 10)
|
|
593
616
|
), b = O(
|
|
594
|
-
() => Q(
|
|
595
|
-
), j = O(() =>
|
|
596
|
-
if (!j.value ||
|
|
597
|
-
let
|
|
617
|
+
() => Q(S.value.searchPadding ?? "18px 4px 0")
|
|
618
|
+
), j = O(() => S.value.searchCollapse === !1 ? !1 : x(L.value) > M.value), C = O(() => {
|
|
619
|
+
if (!j.value || !I.value) return L.value;
|
|
620
|
+
let T = 0;
|
|
598
621
|
return L.value.filter((X) => {
|
|
599
622
|
const ue = P(X);
|
|
600
|
-
return
|
|
623
|
+
return T + ue > M.value ? !1 : (T += ue, !0);
|
|
601
624
|
});
|
|
602
625
|
}), N = O(
|
|
603
|
-
() => C.value.filter((
|
|
626
|
+
() => C.value.filter((T) => !!a[`${T.prop}-search`])
|
|
604
627
|
), re = O(() => {
|
|
605
|
-
const
|
|
606
|
-
return C.value.length > 0 && C.value.length <= 2 &&
|
|
628
|
+
const T = x(C.value);
|
|
629
|
+
return C.value.length > 0 && C.value.length <= 2 && T < V.value;
|
|
607
630
|
}), le = O(() => {
|
|
608
|
-
const
|
|
609
|
-
return `${Math.min(V.value,
|
|
631
|
+
const T = x(C.value);
|
|
632
|
+
return `${Math.min(V.value, T + 1)}`;
|
|
610
633
|
}), R = O(
|
|
611
|
-
() => C.value.map((
|
|
634
|
+
() => C.value.map((T) => E(T))
|
|
612
635
|
);
|
|
613
636
|
Ee(
|
|
614
|
-
() =>
|
|
615
|
-
(
|
|
616
|
-
typeof
|
|
637
|
+
() => S.value.searchCollapsed,
|
|
638
|
+
(T) => {
|
|
639
|
+
typeof T == "boolean" && (I.value = T);
|
|
617
640
|
}
|
|
618
641
|
), Ee(
|
|
619
642
|
() => o.modelValue,
|
|
620
|
-
(
|
|
621
|
-
|
|
643
|
+
(T) => {
|
|
644
|
+
r.value = { ...T };
|
|
622
645
|
},
|
|
623
646
|
{ deep: !0, immediate: !0 }
|
|
624
647
|
);
|
|
625
|
-
function B(
|
|
648
|
+
function B(T, X) {
|
|
626
649
|
if (s.value) return;
|
|
627
|
-
const ue = { ...
|
|
628
|
-
|
|
650
|
+
const ue = { ...r.value, [T]: X };
|
|
651
|
+
r.value = ue, l("update:modelValue", ue);
|
|
629
652
|
}
|
|
630
|
-
function E(
|
|
631
|
-
const X =
|
|
653
|
+
function E(T) {
|
|
654
|
+
const X = T.searchProps ?? {}, ue = T.searchType ?? "input";
|
|
632
655
|
return {
|
|
633
656
|
...X,
|
|
634
|
-
prop:
|
|
635
|
-
label:
|
|
636
|
-
span: P(
|
|
657
|
+
prop: T.prop,
|
|
658
|
+
label: T.searchLabel ?? T.label,
|
|
659
|
+
span: P(T),
|
|
637
660
|
itemType: ue,
|
|
638
661
|
// 外部提供 `${prop}-search` 时交给插槽渲染,保持旧版 JtFilterBar 的自定义能力。
|
|
639
|
-
showSlot: !!a[`${
|
|
640
|
-
options: X.options ??
|
|
641
|
-
placeholder: X.placeholder ??
|
|
642
|
-
valueFormat: X.valueFormat ??
|
|
662
|
+
showSlot: !!a[`${T.prop}-search`],
|
|
663
|
+
options: X.options ?? T.searchOptions ?? T.dicData,
|
|
664
|
+
placeholder: X.placeholder ?? T.searchPlaceholder,
|
|
665
|
+
valueFormat: X.valueFormat ?? T.searchValueFormat,
|
|
643
666
|
disabled: s.value || X.disabled === !0,
|
|
667
|
+
preservePlaceholderWhenDisabled: s.value,
|
|
644
668
|
formItemProps: {
|
|
645
|
-
required:
|
|
646
|
-
class: ["jt-filter-bar__item", { "is-required":
|
|
669
|
+
required: T.searchRequired,
|
|
670
|
+
class: ["jt-filter-bar__item", { "is-required": T.searchRequired }]
|
|
647
671
|
},
|
|
648
672
|
// 保留原来输入框回车触发查询的行为,同时不吞掉使用方在 searchProps 中传入的 onEnter。
|
|
649
673
|
onEnter: (...de) => {
|
|
@@ -651,16 +675,16 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
651
675
|
},
|
|
652
676
|
// JtFormItems 内部会修改 filterModel,这里继续按旧接口向外 emit update:modelValue。
|
|
653
677
|
"onUpdate:modelValue": (de) => {
|
|
654
|
-
d(X["onUpdate:modelValue"], de), B(
|
|
678
|
+
d(X["onUpdate:modelValue"], de), B(T.prop, de);
|
|
655
679
|
}
|
|
656
680
|
};
|
|
657
681
|
}
|
|
658
|
-
function d(
|
|
659
|
-
if (Array.isArray(
|
|
660
|
-
|
|
682
|
+
function d(T, ...X) {
|
|
683
|
+
if (Array.isArray(T)) {
|
|
684
|
+
T.forEach((ue) => d(ue, ...X));
|
|
661
685
|
return;
|
|
662
686
|
}
|
|
663
|
-
typeof
|
|
687
|
+
typeof T == "function" && T(...X);
|
|
664
688
|
}
|
|
665
689
|
async function u() {
|
|
666
690
|
if (!s.value) {
|
|
@@ -670,29 +694,29 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
670
694
|
} catch {
|
|
671
695
|
return;
|
|
672
696
|
}
|
|
673
|
-
|
|
697
|
+
l("search");
|
|
674
698
|
}
|
|
675
699
|
}
|
|
676
|
-
function
|
|
677
|
-
s.value ||
|
|
700
|
+
function w() {
|
|
701
|
+
s.value || l("reset");
|
|
678
702
|
}
|
|
679
703
|
function D() {
|
|
680
|
-
|
|
704
|
+
I.value = !I.value;
|
|
681
705
|
}
|
|
682
|
-
function P(
|
|
683
|
-
return Math.min(V.value, Math.max(1,
|
|
706
|
+
function P(T) {
|
|
707
|
+
return Math.min(V.value, Math.max(1, T.searchSpan ?? 1));
|
|
684
708
|
}
|
|
685
|
-
function x(
|
|
686
|
-
return
|
|
709
|
+
function x(T) {
|
|
710
|
+
return T.reduce((X, ue) => X + P(ue), 0);
|
|
687
711
|
}
|
|
688
|
-
function K(
|
|
689
|
-
return typeof
|
|
712
|
+
function K(T) {
|
|
713
|
+
return typeof T == "number" ? `${T}px` : T;
|
|
690
714
|
}
|
|
691
|
-
function q(
|
|
692
|
-
return typeof
|
|
715
|
+
function q(T, X) {
|
|
716
|
+
return typeof T == "number" ? T : X;
|
|
693
717
|
}
|
|
694
|
-
function Q(
|
|
695
|
-
return typeof
|
|
718
|
+
function Q(T) {
|
|
719
|
+
return typeof T == "number" ? `${T}px` : T;
|
|
696
720
|
}
|
|
697
721
|
return t({
|
|
698
722
|
/** 内部 Element Plus Form 实例,保留给业务侧做校验、重置等原生表单操作。 */
|
|
@@ -702,10 +726,10 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
702
726
|
/** 开启筛选表单禁用。 */
|
|
703
727
|
searchLoading: i,
|
|
704
728
|
/** 关闭筛选表单禁用。 */
|
|
705
|
-
searchDone:
|
|
706
|
-
}), (
|
|
729
|
+
searchDone: h
|
|
730
|
+
}), (T, X) => {
|
|
707
731
|
const ue = tn;
|
|
708
|
-
return
|
|
732
|
+
return $(), G("div", {
|
|
709
733
|
class: We(["jt-filter-bar", [
|
|
710
734
|
`is-label-${F.value}`,
|
|
711
735
|
{ "is-single-filter": re.value }
|
|
@@ -713,7 +737,7 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
713
737
|
style: Yt({
|
|
714
738
|
"--jt-filter-columns": V.value,
|
|
715
739
|
"--jt-filter-field-columns": z.value,
|
|
716
|
-
"--jt-filter-btns-width":
|
|
740
|
+
"--jt-filter-btns-width": g.value,
|
|
717
741
|
"--jt-filter-actions-start": le.value,
|
|
718
742
|
"--jt-filter-label-width": v.value,
|
|
719
743
|
"--jt-filter-column-gap": `${y.value}px`,
|
|
@@ -725,7 +749,7 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
725
749
|
ref_key: "formRef",
|
|
726
750
|
ref: c,
|
|
727
751
|
class: "jt-filter-bar__form",
|
|
728
|
-
model:
|
|
752
|
+
model: r.value,
|
|
729
753
|
"label-position": F.value,
|
|
730
754
|
"label-width": v.value,
|
|
731
755
|
disabled: J(s),
|
|
@@ -735,19 +759,19 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
735
759
|
default: U(() => [
|
|
736
760
|
Ie(J(ko), {
|
|
737
761
|
configs: R.value,
|
|
738
|
-
"form-data":
|
|
762
|
+
"form-data": r.value,
|
|
739
763
|
style: { "--jt-form-label-gap": "6px", "--jt-form-column-gap": "16px", "--jt-form-row-gap": "10px" }
|
|
740
764
|
}, Re({
|
|
741
765
|
actions: U(() => [
|
|
742
766
|
ne("div", Fo, [
|
|
743
|
-
te(
|
|
767
|
+
te(T.$slots, "search-menu", {
|
|
744
768
|
search: u,
|
|
745
|
-
reset:
|
|
769
|
+
reset: w,
|
|
746
770
|
disabled: J(s),
|
|
747
|
-
collapsed:
|
|
771
|
+
collapsed: I.value,
|
|
748
772
|
toggleCollapse: D
|
|
749
773
|
}, () => [
|
|
750
|
-
j.value ? (
|
|
774
|
+
j.value ? ($(), H(J(rt), {
|
|
751
775
|
key: 0,
|
|
752
776
|
class: "jt-filter-bar__btn-collapse",
|
|
753
777
|
size: "small",
|
|
@@ -755,13 +779,13 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
755
779
|
}, {
|
|
756
780
|
icon: U(() => [
|
|
757
781
|
ne("img", {
|
|
758
|
-
class: We(["jt-filter-bar__icon-arrow", { "is-collapsed":
|
|
759
|
-
src: J(
|
|
782
|
+
class: We(["jt-filter-bar__icon-arrow", { "is-collapsed": I.value }]),
|
|
783
|
+
src: J(To),
|
|
760
784
|
alt: ""
|
|
761
785
|
}, null, 10, Bo)
|
|
762
786
|
]),
|
|
763
787
|
default: U(() => [
|
|
764
|
-
ne("span", null, oe(
|
|
788
|
+
ne("span", null, oe(I.value ? J(Z)("common.展开") : J(Z)("common.收起")), 1)
|
|
765
789
|
]),
|
|
766
790
|
_: 1
|
|
767
791
|
})) : fe("", !0),
|
|
@@ -769,7 +793,7 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
769
793
|
class: "jt-filter-bar__btn-reset",
|
|
770
794
|
size: "small",
|
|
771
795
|
disabled: J(s),
|
|
772
|
-
onClick:
|
|
796
|
+
onClick: w
|
|
773
797
|
}, {
|
|
774
798
|
icon: U(() => [
|
|
775
799
|
ne("img", {
|
|
@@ -778,7 +802,7 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
778
802
|
}, null, 8, Eo)
|
|
779
803
|
]),
|
|
780
804
|
default: U(() => [
|
|
781
|
-
ne("span", null, oe(
|
|
805
|
+
ne("span", null, oe(S.value.resetBtnText ?? J(Z)("common.重置")), 1)
|
|
782
806
|
]),
|
|
783
807
|
_: 1
|
|
784
808
|
}, 8, ["disabled"]),
|
|
@@ -796,7 +820,7 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
796
820
|
}, null, 8, Lo)
|
|
797
821
|
]),
|
|
798
822
|
default: U(() => [
|
|
799
|
-
ne("span", null, oe(
|
|
823
|
+
ne("span", null, oe(S.value.searchBtnText ?? J(Z)("common.查询")), 1)
|
|
800
824
|
]),
|
|
801
825
|
_: 1
|
|
802
826
|
}, 8, ["disabled"])
|
|
@@ -808,12 +832,12 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
808
832
|
ye(N.value, (de) => ({
|
|
809
833
|
name: de.prop,
|
|
810
834
|
fn: U(() => [
|
|
811
|
-
te(
|
|
812
|
-
value:
|
|
835
|
+
te(T.$slots, `${de.prop}-search`, {
|
|
836
|
+
value: r.value[de.prop],
|
|
813
837
|
column: de,
|
|
814
838
|
setValue: (me) => B(de.prop, me),
|
|
815
839
|
search: u,
|
|
816
|
-
reset:
|
|
840
|
+
reset: w,
|
|
817
841
|
disabled: J(s)
|
|
818
842
|
}, void 0, !0)
|
|
819
843
|
])
|
|
@@ -825,7 +849,7 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
825
849
|
], 6);
|
|
826
850
|
};
|
|
827
851
|
}
|
|
828
|
-
}), Vo = /* @__PURE__ */ be(Po, [["__scopeId", "data-v-
|
|
852
|
+
}), Vo = /* @__PURE__ */ be(Po, [["__scopeId", "data-v-233ce306"]]), jo = { key: 1 }, Ao = { key: 2 }, Ro = { key: 3 }, zo = /* @__PURE__ */ pe({
|
|
829
853
|
name: "JtTable",
|
|
830
854
|
__name: "JtTable",
|
|
831
855
|
props: {
|
|
@@ -835,100 +859,100 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
835
859
|
tableEvents: {}
|
|
836
860
|
},
|
|
837
861
|
setup(e, { expose: t }) {
|
|
838
|
-
const n = e, o = Le(),
|
|
862
|
+
const n = e, o = Le(), l = ge(), c = O(() => n.option ?? {}), a = O(() => n.columns.filter((f) => !f.hide)), r = O(() => c.value.menuFixed ?? "right");
|
|
839
863
|
function s(f) {
|
|
840
864
|
return !!o[`${f}-header`];
|
|
841
865
|
}
|
|
842
866
|
function i(f) {
|
|
843
867
|
return !!o[`${f}-data`];
|
|
844
868
|
}
|
|
845
|
-
function
|
|
869
|
+
function h(f) {
|
|
846
870
|
return {
|
|
847
871
|
width: f.width,
|
|
848
872
|
minWidth: f.minWidth,
|
|
849
873
|
align: f.align || "center",
|
|
850
874
|
fixed: f.fixed,
|
|
851
875
|
sortable: f.sortable,
|
|
852
|
-
showOverflowTooltip: f.showOverflowTooltip ??
|
|
876
|
+
showOverflowTooltip: f.showOverflowTooltip ?? S(f),
|
|
853
877
|
...f.columnOptions
|
|
854
878
|
};
|
|
855
879
|
}
|
|
856
|
-
function
|
|
880
|
+
function S(f) {
|
|
857
881
|
return !i(f.prop) && !L(f.columnOptions?.type);
|
|
858
882
|
}
|
|
859
|
-
function
|
|
883
|
+
function I(f) {
|
|
860
884
|
return !L(f.columnOptions?.type);
|
|
861
885
|
}
|
|
862
886
|
function L(f) {
|
|
863
887
|
return f === "selection" || f === "index" || f === "expand";
|
|
864
888
|
}
|
|
865
|
-
function V(f,
|
|
866
|
-
return f.find((
|
|
889
|
+
function V(f, _) {
|
|
890
|
+
return f.find((M) => M.value === _)?.label ?? String(_ ?? "");
|
|
867
891
|
}
|
|
868
|
-
return t({ tableRef:
|
|
869
|
-
const
|
|
870
|
-
return
|
|
892
|
+
return t({ tableRef: l }), (f, _) => {
|
|
893
|
+
const M = on, z = nn;
|
|
894
|
+
return $(), H(z, ae({
|
|
871
895
|
ref_key: "tableRef",
|
|
872
|
-
ref:
|
|
896
|
+
ref: l,
|
|
873
897
|
data: f.data,
|
|
874
898
|
"row-key": c.value.rowKey ?? "id",
|
|
875
899
|
"empty-text": c.value.emptyText,
|
|
876
900
|
class: "jt-table"
|
|
877
901
|
}, c.value.tableProps, et(f.tableEvents)), {
|
|
878
902
|
default: U(() => [
|
|
879
|
-
c.value.selection ? (
|
|
903
|
+
c.value.selection ? ($(), H(M, {
|
|
880
904
|
key: 0,
|
|
881
905
|
type: "selection",
|
|
882
906
|
width: "55",
|
|
883
907
|
align: "center"
|
|
884
908
|
})) : fe("", !0),
|
|
885
|
-
c.value.index ? (
|
|
909
|
+
c.value.index ? ($(), H(M, {
|
|
886
910
|
key: 1,
|
|
887
911
|
type: "index",
|
|
888
912
|
label: c.value.indexLabel ?? J(Z)("common.序号"),
|
|
889
913
|
width: "60",
|
|
890
914
|
align: "center"
|
|
891
915
|
}, null, 8, ["label"])) : fe("", !0),
|
|
892
|
-
(
|
|
893
|
-
key:
|
|
894
|
-
prop:
|
|
895
|
-
label:
|
|
896
|
-
formatter: !i(
|
|
916
|
+
($(!0), G(Se, null, ye(a.value, (g) => ($(), H(M, ae({
|
|
917
|
+
key: g.prop,
|
|
918
|
+
prop: g.prop,
|
|
919
|
+
label: g.label,
|
|
920
|
+
formatter: !i(g.prop) && !g.dicData ? g.formatter : void 0,
|
|
897
921
|
ref_for: !0
|
|
898
|
-
}, g
|
|
899
|
-
s(
|
|
922
|
+
}, h(g)), Re({ _: 2 }, [
|
|
923
|
+
s(g.prop) ? {
|
|
900
924
|
name: "header",
|
|
901
925
|
fn: U((v) => [
|
|
902
|
-
te(f.$slots, `${
|
|
926
|
+
te(f.$slots, `${g.prop}-header`, ae({ ref_for: !0 }, v), void 0, !0)
|
|
903
927
|
]),
|
|
904
928
|
key: "0"
|
|
905
929
|
} : void 0,
|
|
906
|
-
|
|
930
|
+
I(g) ? {
|
|
907
931
|
name: "default",
|
|
908
932
|
fn: U((v) => [
|
|
909
|
-
i(
|
|
933
|
+
i(g.prop) ? te(f.$slots, `${g.prop}-data`, ae({
|
|
910
934
|
key: 0,
|
|
911
935
|
ref_for: !0
|
|
912
|
-
}, v), void 0, !0) :
|
|
936
|
+
}, v), void 0, !0) : g.dicData ? ($(), G("span", jo, oe(V(g.dicData, v.row[g.prop])), 1)) : g.formatter ? ($(), G("span", Ao, oe(g.formatter(
|
|
913
937
|
v.row,
|
|
914
938
|
v.column,
|
|
915
|
-
v.row[
|
|
939
|
+
v.row[g.prop],
|
|
916
940
|
v.$index
|
|
917
|
-
)), 1)) : (
|
|
941
|
+
)), 1)) : ($(), G("span", Ro, oe(v.row[g.prop]), 1))
|
|
918
942
|
]),
|
|
919
943
|
key: "1"
|
|
920
944
|
} : void 0
|
|
921
945
|
]), 1040, ["prop", "label", "formatter"]))), 128)),
|
|
922
|
-
c.value.menu ? (
|
|
946
|
+
c.value.menu ? ($(), H(M, {
|
|
923
947
|
key: 2,
|
|
924
948
|
label: c.value.menuLabel ?? J(Z)("common.操作"),
|
|
925
949
|
width: c.value.menuWidth,
|
|
926
950
|
"min-width": c.value.menuMinWidth,
|
|
927
951
|
align: c.value.menuAlign ?? "center",
|
|
928
|
-
fixed:
|
|
952
|
+
fixed: r.value
|
|
929
953
|
}, {
|
|
930
|
-
default: U((
|
|
931
|
-
te(f.$slots, "menu", Oe(Be(
|
|
954
|
+
default: U((g) => [
|
|
955
|
+
te(f.$slots, "menu", Oe(Be(g)), void 0, !0)
|
|
932
956
|
]),
|
|
933
957
|
_: 3
|
|
934
958
|
}, 8, ["label", "width", "min-width", "align", "fixed"])) : fe("", !0)
|
|
@@ -937,7 +961,7 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
937
961
|
}, 16, ["data", "row-key", "empty-text"]);
|
|
938
962
|
};
|
|
939
963
|
}
|
|
940
|
-
}), No = /* @__PURE__ */ be(zo, [["__scopeId", "data-v-
|
|
964
|
+
}), No = /* @__PURE__ */ be(zo, [["__scopeId", "data-v-ca9bbaae"]]), xo = { class: "jt-pagination" }, qo = { class: "jt-pagination__count" }, Go = /* @__PURE__ */ pe({
|
|
941
965
|
name: "JtPagination",
|
|
942
966
|
__name: "JtPagination",
|
|
943
967
|
props: {
|
|
@@ -948,29 +972,29 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
948
972
|
},
|
|
949
973
|
emits: ["update:currentPage", "update:pageSize", "current-change", "page-change", "size-change"],
|
|
950
974
|
setup(e, { emit: t }) {
|
|
951
|
-
const n = e, o = O(() => n.option ?? {}),
|
|
975
|
+
const n = e, o = O(() => n.option ?? {}), l = t;
|
|
952
976
|
function c(a) {
|
|
953
|
-
|
|
977
|
+
l("current-change", a), l("page-change", a);
|
|
954
978
|
}
|
|
955
|
-
return (a,
|
|
979
|
+
return (a, r) => {
|
|
956
980
|
const s = oo;
|
|
957
|
-
return
|
|
981
|
+
return $(), G("div", xo, [
|
|
958
982
|
Ie(s, {
|
|
959
983
|
"current-page": a.currentPage,
|
|
960
984
|
"page-size": a.pageSize,
|
|
961
985
|
"page-sizes": o.value.pageSizes ?? [10, 20, 50, 100],
|
|
962
986
|
total: a.total,
|
|
963
987
|
layout: o.value.paginationLayout ?? "sizes, prev, pager, next, jumper",
|
|
964
|
-
"onUpdate:currentPage":
|
|
965
|
-
"onUpdate:pageSize":
|
|
988
|
+
"onUpdate:currentPage": r[0] || (r[0] = (i) => a.$emit("update:currentPage", i)),
|
|
989
|
+
"onUpdate:pageSize": r[1] || (r[1] = (i) => a.$emit("update:pageSize", i)),
|
|
966
990
|
onCurrentChange: c,
|
|
967
|
-
onSizeChange:
|
|
991
|
+
onSizeChange: r[2] || (r[2] = (i) => a.$emit("size-change", i))
|
|
968
992
|
}, null, 8, ["current-page", "page-size", "page-sizes", "total", "layout"]),
|
|
969
993
|
ne("span", qo, oe(J(Z)("common.共")) + oe(a.total) + oe(J(Z)("common.条记录")), 1)
|
|
970
994
|
]);
|
|
971
995
|
};
|
|
972
996
|
}
|
|
973
|
-
}), Ko = /* @__PURE__ */ be(Go, [["__scopeId", "data-v-
|
|
997
|
+
}), Ko = /* @__PURE__ */ be(Go, [["__scopeId", "data-v-37c16fce"]]), Yo = { class: "jt-crud-table" }, Uo = { class: "filter-bar-box" }, Ho = { class: "jt-crud-table__result" }, Jo = { class: "jt-crud-table__table-group" }, Wo = {
|
|
974
998
|
key: 0,
|
|
975
999
|
class: "jt-crud-table__toolbar"
|
|
976
1000
|
}, Zo = /* @__PURE__ */ pe({
|
|
@@ -994,57 +1018,57 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
994
1018
|
}),
|
|
995
1019
|
emits: /* @__PURE__ */ Ft(["search", "reset", "page-change", "size-change"], ["update:currentPage", "update:pageSize", "update:searchModel"]),
|
|
996
1020
|
setup(e, { expose: t, emit: n }) {
|
|
997
|
-
const o = e,
|
|
998
|
-
() =>
|
|
1021
|
+
const o = e, l = n, c = vt(e, "currentPage"), a = vt(e, "pageSize"), r = vt(e, "searchModel"), s = Le(), i = ge(), h = ge(), S = O(() => o.option), I = O(() => S.value.searchShow !== !1), L = O(
|
|
1022
|
+
() => S.value.paginationShow !== !1
|
|
999
1023
|
), V = O(
|
|
1000
1024
|
() => o.columns.filter((y) => y.search && !!s[`${y.prop}-search`])
|
|
1001
1025
|
), f = O(
|
|
1002
1026
|
() => o.columns.filter((y) => !y.hide && !!s[`${y.prop}-header`])
|
|
1003
|
-
),
|
|
1027
|
+
), _ = O(
|
|
1004
1028
|
() => o.columns.filter((y) => !y.hide && !!s[`${y.prop}-data`])
|
|
1005
1029
|
);
|
|
1006
|
-
function
|
|
1030
|
+
function M() {
|
|
1007
1031
|
const y = {};
|
|
1008
1032
|
return o.columns.forEach((A) => {
|
|
1009
1033
|
A.search && (y[A.prop] = void 0);
|
|
1010
1034
|
}), y;
|
|
1011
1035
|
}
|
|
1012
1036
|
function z() {
|
|
1013
|
-
|
|
1037
|
+
l("search", { ...r.value });
|
|
1014
1038
|
}
|
|
1015
|
-
function
|
|
1016
|
-
|
|
1039
|
+
function g() {
|
|
1040
|
+
r.value = M(), l("reset");
|
|
1017
1041
|
}
|
|
1018
1042
|
function v() {
|
|
1019
|
-
|
|
1043
|
+
h.value?.searchLoading();
|
|
1020
1044
|
}
|
|
1021
1045
|
function F() {
|
|
1022
|
-
|
|
1046
|
+
h.value?.searchDone();
|
|
1023
1047
|
}
|
|
1024
1048
|
return t({
|
|
1025
1049
|
/** 获取内部 el-table 实例 */
|
|
1026
1050
|
tableRef: O(() => i.value?.tableRef),
|
|
1027
1051
|
/** 获取内部筛选条实例 */
|
|
1028
|
-
filterBarRef:
|
|
1052
|
+
filterBarRef: h,
|
|
1029
1053
|
/** 开启筛选表单禁用。 */
|
|
1030
1054
|
searchLoading: v,
|
|
1031
1055
|
/** 关闭筛选表单禁用。 */
|
|
1032
1056
|
searchDone: F
|
|
1033
1057
|
}), (y, A) => {
|
|
1034
1058
|
const b = ro;
|
|
1035
|
-
return
|
|
1059
|
+
return $(), G("div", Yo, [
|
|
1036
1060
|
te(y.$slots, "header", {}, void 0, !0),
|
|
1037
1061
|
ne("div", Uo, [
|
|
1038
|
-
|
|
1062
|
+
I.value ? ($(), H(Vo, {
|
|
1039
1063
|
key: 0,
|
|
1040
1064
|
ref_key: "filterBarRef",
|
|
1041
|
-
ref:
|
|
1042
|
-
modelValue:
|
|
1043
|
-
"onUpdate:modelValue": A[0] || (A[0] = (j) =>
|
|
1065
|
+
ref: h,
|
|
1066
|
+
modelValue: r.value,
|
|
1067
|
+
"onUpdate:modelValue": A[0] || (A[0] = (j) => r.value = j),
|
|
1044
1068
|
columns: y.columns,
|
|
1045
|
-
option:
|
|
1069
|
+
option: S.value,
|
|
1046
1070
|
onSearch: z,
|
|
1047
|
-
onReset:
|
|
1071
|
+
onReset: g
|
|
1048
1072
|
}, Re({ _: 2 }, [
|
|
1049
1073
|
ye(V.value, (j) => ({
|
|
1050
1074
|
name: `${j.prop}-search`,
|
|
@@ -1056,15 +1080,15 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
1056
1080
|
]),
|
|
1057
1081
|
ne("div", Ho, [
|
|
1058
1082
|
ne("div", Jo, [
|
|
1059
|
-
J(s).toolbar ? (
|
|
1083
|
+
J(s).toolbar ? ($(), G("div", Wo, [
|
|
1060
1084
|
te(y.$slots, "toolbar", {}, void 0, !0)
|
|
1061
1085
|
])) : fe("", !0),
|
|
1062
|
-
Qn((
|
|
1086
|
+
Qn(($(), H(No, {
|
|
1063
1087
|
ref_key: "jtTableRef",
|
|
1064
1088
|
ref: i,
|
|
1065
1089
|
data: y.data,
|
|
1066
1090
|
columns: y.columns,
|
|
1067
|
-
option:
|
|
1091
|
+
option: S.value,
|
|
1068
1092
|
"table-events": y.tableEvents
|
|
1069
1093
|
}, Re({ _: 2 }, [
|
|
1070
1094
|
ye(f.value, (j) => ({
|
|
@@ -1073,13 +1097,13 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
1073
1097
|
te(y.$slots, `${j.prop}-header`, Oe(Be(C)), void 0, !0)
|
|
1074
1098
|
])
|
|
1075
1099
|
})),
|
|
1076
|
-
ye(
|
|
1100
|
+
ye(_.value, (j) => ({
|
|
1077
1101
|
name: `${j.prop}-data`,
|
|
1078
1102
|
fn: U((C) => [
|
|
1079
1103
|
te(y.$slots, `${j.prop}-data`, Oe(Be(C)), void 0, !0)
|
|
1080
1104
|
])
|
|
1081
1105
|
})),
|
|
1082
|
-
|
|
1106
|
+
S.value.menu ? {
|
|
1083
1107
|
name: "menu",
|
|
1084
1108
|
fn: U((j) => [
|
|
1085
1109
|
te(y.$slots, "menu", Oe(Be(j)), void 0, !0)
|
|
@@ -1087,17 +1111,17 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
1087
1111
|
key: "0"
|
|
1088
1112
|
} : void 0
|
|
1089
1113
|
]), 1032, ["data", "columns", "option", "table-events"])), [
|
|
1090
|
-
[b,
|
|
1114
|
+
[b, S.value.loading]
|
|
1091
1115
|
])
|
|
1092
1116
|
]),
|
|
1093
|
-
L.value ? (
|
|
1117
|
+
L.value ? ($(), H(Ko, {
|
|
1094
1118
|
key: 0,
|
|
1095
1119
|
"current-page": c.value,
|
|
1096
1120
|
"onUpdate:currentPage": A[1] || (A[1] = (j) => c.value = j),
|
|
1097
1121
|
"page-size": a.value,
|
|
1098
1122
|
"onUpdate:pageSize": A[2] || (A[2] = (j) => a.value = j),
|
|
1099
1123
|
total: y.total,
|
|
1100
|
-
option:
|
|
1124
|
+
option: S.value,
|
|
1101
1125
|
onPageChange: A[3] || (A[3] = (j) => y.$emit("page-change", j)),
|
|
1102
1126
|
onSizeChange: A[4] || (A[4] = (j) => y.$emit("size-change", j))
|
|
1103
1127
|
}, null, 8, ["current-page", "page-size", "total", "option"])) : fe("", !0)
|
|
@@ -1105,7 +1129,7 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
1105
1129
|
]);
|
|
1106
1130
|
};
|
|
1107
1131
|
}
|
|
1108
|
-
}), ss = /* @__PURE__ */ be(Zo, [["__scopeId", "data-v-
|
|
1132
|
+
}), ss = /* @__PURE__ */ be(Zo, [["__scopeId", "data-v-335c2682"]]), Qo = { class: "jt-page-header__title" }, Xo = { key: 0 }, er = {
|
|
1109
1133
|
key: 0,
|
|
1110
1134
|
class: "jt-page-header__operates"
|
|
1111
1135
|
}, tr = /* @__PURE__ */ pe({
|
|
@@ -1118,21 +1142,21 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
1118
1142
|
},
|
|
1119
1143
|
emits: ["operate-click"],
|
|
1120
1144
|
setup(e, { emit: t }) {
|
|
1121
|
-
const n = e, o = t,
|
|
1122
|
-
function a(
|
|
1123
|
-
|
|
1145
|
+
const n = e, o = t, l = Le(), c = O(() => n.operates.length > 0 || !!l.operates);
|
|
1146
|
+
function a(r, s) {
|
|
1147
|
+
r.onClick?.(r, s), o("operate-click", r, s);
|
|
1124
1148
|
}
|
|
1125
|
-
return (
|
|
1126
|
-
class: ["jt-page-header", `jt-page-header--${
|
|
1127
|
-
},
|
|
1149
|
+
return (r, s) => ($(), G("div", ae({
|
|
1150
|
+
class: ["jt-page-header", `jt-page-header--${r.type}`]
|
|
1151
|
+
}, r.$attrs), [
|
|
1128
1152
|
ne("div", Qo, [
|
|
1129
|
-
te(
|
|
1130
|
-
|
|
1153
|
+
te(r.$slots, "title", {}, () => [
|
|
1154
|
+
r.title ? ($(), G("span", Xo, oe(r.title), 1)) : fe("", !0)
|
|
1131
1155
|
], !0)
|
|
1132
1156
|
]),
|
|
1133
|
-
c.value ? (
|
|
1134
|
-
te(
|
|
1135
|
-
(
|
|
1157
|
+
c.value ? ($(), G("div", er, [
|
|
1158
|
+
te(r.$slots, "operates", { operates: r.operates }, () => [
|
|
1159
|
+
($(!0), G(Se, null, ye(r.operates, (i) => ($(), H(J(rt), ae({
|
|
1136
1160
|
key: i.key ?? i.label,
|
|
1137
1161
|
ref_for: !0
|
|
1138
1162
|
}, i.buttonProps, {
|
|
@@ -1143,7 +1167,7 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
1143
1167
|
text: i.text,
|
|
1144
1168
|
link: i.link,
|
|
1145
1169
|
icon: i.icon,
|
|
1146
|
-
onClick: (
|
|
1170
|
+
onClick: (h) => a(i, h)
|
|
1147
1171
|
}), {
|
|
1148
1172
|
default: U(() => [
|
|
1149
1173
|
ne("span", null, oe(i.label), 1)
|
|
@@ -1154,17 +1178,17 @@ const Mo = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
1154
1178
|
])) : fe("", !0)
|
|
1155
1179
|
], 16));
|
|
1156
1180
|
}
|
|
1157
|
-
}), ls = /* @__PURE__ */ be(tr, [["__scopeId", "data-v-
|
|
1181
|
+
}), ls = /* @__PURE__ */ be(tr, [["__scopeId", "data-v-0926ebf1"]]);
|
|
1158
1182
|
function nr(e, t) {
|
|
1159
1183
|
t = t || (() => "default-use-once-sync");
|
|
1160
1184
|
const n = /* @__PURE__ */ new Map();
|
|
1161
|
-
async function o(...
|
|
1162
|
-
const c = t(...
|
|
1185
|
+
async function o(...l) {
|
|
1186
|
+
const c = t(...l);
|
|
1163
1187
|
if (n.get(c))
|
|
1164
1188
|
return n.get(c);
|
|
1165
1189
|
try {
|
|
1166
|
-
const a = e(...
|
|
1167
|
-
throw
|
|
1190
|
+
const a = e(...l).then((r) => r).catch((r) => {
|
|
1191
|
+
throw r;
|
|
1168
1192
|
});
|
|
1169
1193
|
return n.set(c, a), a;
|
|
1170
1194
|
} catch (a) {
|
|
@@ -1176,11 +1200,11 @@ function nr(e, t) {
|
|
|
1176
1200
|
function ln(e, t) {
|
|
1177
1201
|
t = t || (() => "default-use-queue-sync");
|
|
1178
1202
|
const n = /* @__PURE__ */ new Map();
|
|
1179
|
-
async function o(...
|
|
1180
|
-
const c = t(...
|
|
1181
|
-
return n.set(c, a), new Promise((
|
|
1182
|
-
e(...
|
|
1183
|
-
n.get(c) === a &&
|
|
1203
|
+
async function o(...l) {
|
|
1204
|
+
const c = t(...l), a = Symbol("single");
|
|
1205
|
+
return n.set(c, a), new Promise((r, s) => {
|
|
1206
|
+
e(...l).then((i) => {
|
|
1207
|
+
n.get(c) === a && r(i);
|
|
1184
1208
|
}).catch((i) => {
|
|
1185
1209
|
n.get(c) === a && s(i);
|
|
1186
1210
|
});
|
|
@@ -1197,23 +1221,23 @@ var cn = { exports: {} };
|
|
|
1197
1221
|
(function(n, o) {
|
|
1198
1222
|
e.exports = o();
|
|
1199
1223
|
})(it, function() {
|
|
1200
|
-
var n = 1e3, o = 6e4,
|
|
1224
|
+
var n = 1e3, o = 6e4, l = 36e5, c = "millisecond", a = "second", r = "minute", s = "hour", i = "day", h = "week", S = "month", I = "quarter", L = "year", V = "date", f = "Invalid Date", _ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, M = /\[([^\]]+)]|YYYY|YY|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, z = { 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(R) {
|
|
1201
1225
|
var B = ["th", "st", "nd", "rd"], E = R % 100;
|
|
1202
1226
|
return "[" + R + (B[(E - 20) % 10] || B[E] || B[0]) + "]";
|
|
1203
|
-
} },
|
|
1227
|
+
} }, g = function(R, B, E) {
|
|
1204
1228
|
var d = String(R);
|
|
1205
1229
|
return !d || d.length >= B ? R : "" + Array(B + 1 - d.length).join(E) + R;
|
|
1206
|
-
}, v = { s:
|
|
1230
|
+
}, v = { s: g, z: function(R) {
|
|
1207
1231
|
var B = -R.utcOffset(), E = Math.abs(B), d = Math.floor(E / 60), u = E % 60;
|
|
1208
|
-
return (B <= 0 ? "+" : "-") +
|
|
1232
|
+
return (B <= 0 ? "+" : "-") + g(d, 2, "0") + ":" + g(u, 2, "0");
|
|
1209
1233
|
}, m: function R(B, E) {
|
|
1210
1234
|
if (B.date() < E.date()) return -R(E, B);
|
|
1211
|
-
var d = 12 * (E.year() - B.year()) + (E.month() - B.month()), u = B.clone().add(d,
|
|
1212
|
-
return +(-(d + (E - u) / (
|
|
1235
|
+
var d = 12 * (E.year() - B.year()) + (E.month() - B.month()), u = B.clone().add(d, S), w = E - u < 0, D = B.clone().add(d + (w ? -1 : 1), S);
|
|
1236
|
+
return +(-(d + (E - u) / (w ? u - D : D - u)) || 0);
|
|
1213
1237
|
}, a: function(R) {
|
|
1214
1238
|
return R < 0 ? Math.ceil(R) || 0 : Math.floor(R);
|
|
1215
1239
|
}, p: function(R) {
|
|
1216
|
-
return { M:
|
|
1240
|
+
return { M: S, y: L, w: h, d: i, D: V, h: s, m: r, s: a, ms: c, Q: I }[R] || String(R || "").toLowerCase().replace(/s$/, "");
|
|
1217
1241
|
}, u: function(R) {
|
|
1218
1242
|
return R === void 0;
|
|
1219
1243
|
} }, F = "en", y = {};
|
|
@@ -1224,8 +1248,8 @@ var cn = { exports: {} };
|
|
|
1224
1248
|
var u;
|
|
1225
1249
|
if (!B) return F;
|
|
1226
1250
|
if (typeof B == "string") {
|
|
1227
|
-
var
|
|
1228
|
-
y[
|
|
1251
|
+
var w = B.toLowerCase();
|
|
1252
|
+
y[w] && (u = w), E && (y[w] = E, u = w);
|
|
1229
1253
|
var D = B.split("-");
|
|
1230
1254
|
if (!u && D.length > 1) return R(D[0]);
|
|
1231
1255
|
} else {
|
|
@@ -1248,15 +1272,15 @@ var cn = { exports: {} };
|
|
|
1248
1272
|
var B = R.prototype;
|
|
1249
1273
|
return B.parse = function(E) {
|
|
1250
1274
|
this.$d = function(d) {
|
|
1251
|
-
var u = d.date,
|
|
1275
|
+
var u = d.date, w = d.utc;
|
|
1252
1276
|
if (u === null) return /* @__PURE__ */ new Date(NaN);
|
|
1253
1277
|
if (N.u(u)) return /* @__PURE__ */ new Date();
|
|
1254
1278
|
if (u instanceof Date) return new Date(u);
|
|
1255
1279
|
if (typeof u == "string" && !/Z$/i.test(u)) {
|
|
1256
|
-
var D = u.match(
|
|
1280
|
+
var D = u.match(_);
|
|
1257
1281
|
if (D) {
|
|
1258
1282
|
var P = D[2] - 1 || 0, x = (D[7] || "0").substring(0, 3);
|
|
1259
|
-
return
|
|
1283
|
+
return w ? new Date(Date.UTC(D[1], P, D[3] || 1, D[4] || 0, D[5] || 0, D[6] || 0, x)) : new Date(D[1], P, D[3] || 1, D[4] || 0, D[5] || 0, D[6] || 0, x);
|
|
1260
1284
|
}
|
|
1261
1285
|
}
|
|
1262
1286
|
return new Date(u);
|
|
@@ -1282,37 +1306,37 @@ var cn = { exports: {} };
|
|
|
1282
1306
|
}, B.valueOf = function() {
|
|
1283
1307
|
return this.$d.getTime();
|
|
1284
1308
|
}, B.startOf = function(E, d) {
|
|
1285
|
-
var u = this,
|
|
1309
|
+
var u = this, w = !!N.u(d) || d, D = N.p(E), P = function(de, me) {
|
|
1286
1310
|
var we = N.w(u.$u ? Date.UTC(u.$y, me, de) : new Date(u.$y, me, de), u);
|
|
1287
|
-
return
|
|
1311
|
+
return w ? we : we.endOf(i);
|
|
1288
1312
|
}, x = function(de, me) {
|
|
1289
|
-
return N.w(u.toDate()[de].apply(u.toDate("s"), (
|
|
1290
|
-
}, K = this.$W, q = this.$M, Q = this.$D,
|
|
1313
|
+
return N.w(u.toDate()[de].apply(u.toDate("s"), (w ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(me)), u);
|
|
1314
|
+
}, K = this.$W, q = this.$M, Q = this.$D, T = "set" + (this.$u ? "UTC" : "");
|
|
1291
1315
|
switch (D) {
|
|
1292
1316
|
case L:
|
|
1293
|
-
return
|
|
1294
|
-
case
|
|
1295
|
-
return
|
|
1296
|
-
case
|
|
1317
|
+
return w ? P(1, 0) : P(31, 11);
|
|
1318
|
+
case S:
|
|
1319
|
+
return w ? P(1, q) : P(0, q + 1);
|
|
1320
|
+
case h:
|
|
1297
1321
|
var X = this.$locale().weekStart || 0, ue = (K < X ? K + 7 : K) - X;
|
|
1298
|
-
return P(
|
|
1322
|
+
return P(w ? Q - ue : Q + (6 - ue), q);
|
|
1299
1323
|
case i:
|
|
1300
1324
|
case V:
|
|
1301
|
-
return x(
|
|
1325
|
+
return x(T + "Hours", 0);
|
|
1302
1326
|
case s:
|
|
1303
|
-
return x(
|
|
1304
|
-
case
|
|
1305
|
-
return x(
|
|
1327
|
+
return x(T + "Minutes", 1);
|
|
1328
|
+
case r:
|
|
1329
|
+
return x(T + "Seconds", 2);
|
|
1306
1330
|
case a:
|
|
1307
|
-
return x(
|
|
1331
|
+
return x(T + "Milliseconds", 3);
|
|
1308
1332
|
default:
|
|
1309
1333
|
return this.clone();
|
|
1310
1334
|
}
|
|
1311
1335
|
}, B.endOf = function(E) {
|
|
1312
1336
|
return this.startOf(E, !1);
|
|
1313
1337
|
}, B.$set = function(E, d) {
|
|
1314
|
-
var u,
|
|
1315
|
-
if (
|
|
1338
|
+
var u, w = N.p(E), D = "set" + (this.$u ? "UTC" : ""), P = (u = {}, u[i] = D + "Date", u[V] = D + "Date", u[S] = D + "Month", u[L] = D + "FullYear", u[s] = D + "Hours", u[r] = D + "Minutes", u[a] = D + "Seconds", u[c] = D + "Milliseconds", u)[w], x = w === i ? this.$D + (d - this.$W) : d;
|
|
1339
|
+
if (w === S || w === L) {
|
|
1316
1340
|
var K = this.clone().set(V, 1);
|
|
1317
1341
|
K.$d[P](x), K.init(), this.$d = K.set(V, Math.min(this.$D, K.daysInMonth())).$d;
|
|
1318
1342
|
} else P && this.$d[P](x);
|
|
@@ -1322,32 +1346,32 @@ var cn = { exports: {} };
|
|
|
1322
1346
|
}, B.get = function(E) {
|
|
1323
1347
|
return this[N.p(E)]();
|
|
1324
1348
|
}, B.add = function(E, d) {
|
|
1325
|
-
var u,
|
|
1349
|
+
var u, w = this;
|
|
1326
1350
|
E = Number(E);
|
|
1327
1351
|
var D = N.p(d), P = function(q) {
|
|
1328
|
-
var Q = C(
|
|
1329
|
-
return N.w(Q.date(Q.date() + Math.round(q * E)),
|
|
1352
|
+
var Q = C(w);
|
|
1353
|
+
return N.w(Q.date(Q.date() + Math.round(q * E)), w);
|
|
1330
1354
|
};
|
|
1331
|
-
if (D ===
|
|
1355
|
+
if (D === S) return this.set(S, this.$M + E);
|
|
1332
1356
|
if (D === L) return this.set(L, this.$y + E);
|
|
1333
1357
|
if (D === i) return P(1);
|
|
1334
|
-
if (D ===
|
|
1335
|
-
var x = (u = {}, u[
|
|
1358
|
+
if (D === h) return P(7);
|
|
1359
|
+
var x = (u = {}, u[r] = o, u[s] = l, u[a] = n, u)[D] || 1, K = this.$d.getTime() + E * x;
|
|
1336
1360
|
return N.w(K, this);
|
|
1337
1361
|
}, B.subtract = function(E, d) {
|
|
1338
1362
|
return this.add(-1 * E, d);
|
|
1339
1363
|
}, B.format = function(E) {
|
|
1340
1364
|
var d = this, u = this.$locale();
|
|
1341
1365
|
if (!this.isValid()) return u.invalidDate || f;
|
|
1342
|
-
var
|
|
1343
|
-
return me && (me[we] || me(d,
|
|
1366
|
+
var w = E || "YYYY-MM-DDTHH:mm:ssZ", D = N.z(this), P = this.$H, x = this.$m, K = this.$M, q = u.weekdays, Q = u.months, T = u.meridiem, X = function(me, we, De, $e) {
|
|
1367
|
+
return me && (me[we] || me(d, w)) || De[we].slice(0, $e);
|
|
1344
1368
|
}, ue = function(me) {
|
|
1345
1369
|
return N.s(P % 12 || 12, me, "0");
|
|
1346
|
-
}, de =
|
|
1370
|
+
}, de = T || function(me, we, De) {
|
|
1347
1371
|
var $e = me < 12 ? "AM" : "PM";
|
|
1348
1372
|
return De ? $e.toLowerCase() : $e;
|
|
1349
1373
|
};
|
|
1350
|
-
return
|
|
1374
|
+
return w.replace(M, function(me, we) {
|
|
1351
1375
|
return we || function(De) {
|
|
1352
1376
|
switch (De) {
|
|
1353
1377
|
case "YY":
|
|
@@ -1405,46 +1429,46 @@ var cn = { exports: {} };
|
|
|
1405
1429
|
}, B.utcOffset = function() {
|
|
1406
1430
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
1407
1431
|
}, B.diff = function(E, d, u) {
|
|
1408
|
-
var
|
|
1432
|
+
var w, D = this, P = N.p(d), x = C(E), K = (x.utcOffset() - this.utcOffset()) * o, q = this - x, Q = function() {
|
|
1409
1433
|
return N.m(D, x);
|
|
1410
1434
|
};
|
|
1411
1435
|
switch (P) {
|
|
1412
1436
|
case L:
|
|
1413
|
-
|
|
1437
|
+
w = Q() / 12;
|
|
1414
1438
|
break;
|
|
1415
|
-
case
|
|
1416
|
-
|
|
1439
|
+
case S:
|
|
1440
|
+
w = Q();
|
|
1417
1441
|
break;
|
|
1418
|
-
case
|
|
1419
|
-
|
|
1442
|
+
case I:
|
|
1443
|
+
w = Q() / 3;
|
|
1420
1444
|
break;
|
|
1421
|
-
case
|
|
1422
|
-
|
|
1445
|
+
case h:
|
|
1446
|
+
w = (q - K) / 6048e5;
|
|
1423
1447
|
break;
|
|
1424
1448
|
case i:
|
|
1425
|
-
|
|
1449
|
+
w = (q - K) / 864e5;
|
|
1426
1450
|
break;
|
|
1427
1451
|
case s:
|
|
1428
|
-
|
|
1452
|
+
w = q / l;
|
|
1429
1453
|
break;
|
|
1430
|
-
case
|
|
1431
|
-
|
|
1454
|
+
case r:
|
|
1455
|
+
w = q / o;
|
|
1432
1456
|
break;
|
|
1433
1457
|
case a:
|
|
1434
|
-
|
|
1458
|
+
w = q / n;
|
|
1435
1459
|
break;
|
|
1436
1460
|
default:
|
|
1437
|
-
|
|
1461
|
+
w = q;
|
|
1438
1462
|
}
|
|
1439
|
-
return u ?
|
|
1463
|
+
return u ? w : N.a(w);
|
|
1440
1464
|
}, B.daysInMonth = function() {
|
|
1441
|
-
return this.endOf(
|
|
1465
|
+
return this.endOf(S).$D;
|
|
1442
1466
|
}, B.$locale = function() {
|
|
1443
1467
|
return y[this.$L];
|
|
1444
1468
|
}, B.locale = function(E, d) {
|
|
1445
1469
|
if (!E) return this.$L;
|
|
1446
|
-
var u = this.clone(),
|
|
1447
|
-
return
|
|
1470
|
+
var u = this.clone(), w = j(E, d, !0);
|
|
1471
|
+
return w && (u.$L = w), u;
|
|
1448
1472
|
}, B.clone = function() {
|
|
1449
1473
|
return N.w(this.$d, this);
|
|
1450
1474
|
}, B.toDate = function() {
|
|
@@ -1457,7 +1481,7 @@ var cn = { exports: {} };
|
|
|
1457
1481
|
return this.$d.toUTCString();
|
|
1458
1482
|
}, R;
|
|
1459
1483
|
}(), le = re.prototype;
|
|
1460
|
-
return C.prototype = le, [["$ms", c], ["$s", a], ["$m",
|
|
1484
|
+
return C.prototype = le, [["$ms", c], ["$s", a], ["$m", r], ["$H", s], ["$W", i], ["$M", S], ["$y", L], ["$D", V]].forEach(function(R) {
|
|
1461
1485
|
le[R[1]] = function(B) {
|
|
1462
1486
|
return this.$g(B, R[0], R[1]);
|
|
1463
1487
|
};
|
|
@@ -1475,104 +1499,104 @@ var un = { exports: {} };
|
|
|
1475
1499
|
(function(n, o) {
|
|
1476
1500
|
e.exports = o();
|
|
1477
1501
|
})(it, function() {
|
|
1478
|
-
var n = { LTS: "h:mm:ss A", LT: "h:mm A", L: "MM/DD/YYYY", LL: "MMMM D, YYYY", LLL: "MMMM D, YYYY h:mm A", LLLL: "dddd, MMMM D, YYYY h:mm A" }, o = /(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,
|
|
1479
|
-
return (
|
|
1480
|
-
},
|
|
1481
|
-
return function(
|
|
1482
|
-
this[
|
|
1502
|
+
var n = { LTS: "h:mm:ss A", LT: "h:mm A", L: "MM/DD/YYYY", LL: "MMMM D, YYYY", LLL: "MMMM D, YYYY h:mm A", LLLL: "dddd, MMMM D, YYYY h:mm A" }, o = /(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g, l = /\d/, c = /\d\d/, a = /\d\d?/, r = /\d*[^-_:/,()\s\d]+/, s = {}, i = function(_) {
|
|
1503
|
+
return (_ = +_) + (_ > 68 ? 1900 : 2e3);
|
|
1504
|
+
}, h = function(_) {
|
|
1505
|
+
return function(M) {
|
|
1506
|
+
this[_] = +M;
|
|
1483
1507
|
};
|
|
1484
|
-
},
|
|
1485
|
-
(this.zone || (this.zone = {})).offset = function(
|
|
1486
|
-
if (!
|
|
1487
|
-
var z =
|
|
1488
|
-
return
|
|
1489
|
-
}(
|
|
1490
|
-
}],
|
|
1491
|
-
var
|
|
1492
|
-
return
|
|
1493
|
-
}, L = function(
|
|
1494
|
-
var z,
|
|
1495
|
-
if (
|
|
1496
|
-
for (var v = 1; v <= 24; v += 1) if (
|
|
1508
|
+
}, S = [/[+-]\d\d:?(\d\d)?|Z/, function(_) {
|
|
1509
|
+
(this.zone || (this.zone = {})).offset = function(M) {
|
|
1510
|
+
if (!M || M === "Z") return 0;
|
|
1511
|
+
var z = M.match(/([+-]|\d\d)/g), g = 60 * z[1] + (+z[2] || 0);
|
|
1512
|
+
return g === 0 ? 0 : z[0] === "+" ? -g : g;
|
|
1513
|
+
}(_);
|
|
1514
|
+
}], I = function(_) {
|
|
1515
|
+
var M = s[_];
|
|
1516
|
+
return M && (M.indexOf ? M : M.s.concat(M.f));
|
|
1517
|
+
}, L = function(_, M) {
|
|
1518
|
+
var z, g = s.meridiem;
|
|
1519
|
+
if (g) {
|
|
1520
|
+
for (var v = 1; v <= 24; v += 1) if (_.indexOf(g(v, 0, M)) > -1) {
|
|
1497
1521
|
z = v > 12;
|
|
1498
1522
|
break;
|
|
1499
1523
|
}
|
|
1500
|
-
} else z =
|
|
1524
|
+
} else z = _ === (M ? "pm" : "PM");
|
|
1501
1525
|
return z;
|
|
1502
|
-
}, V = { A: [
|
|
1503
|
-
this.afternoon = L(
|
|
1504
|
-
}], a: [
|
|
1505
|
-
this.afternoon = L(
|
|
1506
|
-
}], Q: [
|
|
1507
|
-
this.month = 3 * (
|
|
1508
|
-
}], S: [
|
|
1509
|
-
this.milliseconds = 100 * +
|
|
1510
|
-
}], SS: [c, function(
|
|
1511
|
-
this.milliseconds = 10 * +
|
|
1512
|
-
}], SSS: [/\d{3}/, function(
|
|
1513
|
-
this.milliseconds = +
|
|
1514
|
-
}], s: [a,
|
|
1515
|
-
var
|
|
1516
|
-
if (this.day = z[0],
|
|
1517
|
-
}], w: [a,
|
|
1518
|
-
var
|
|
1519
|
-
return
|
|
1520
|
-
})).indexOf(
|
|
1526
|
+
}, V = { A: [r, function(_) {
|
|
1527
|
+
this.afternoon = L(_, !1);
|
|
1528
|
+
}], a: [r, function(_) {
|
|
1529
|
+
this.afternoon = L(_, !0);
|
|
1530
|
+
}], Q: [l, function(_) {
|
|
1531
|
+
this.month = 3 * (_ - 1) + 1;
|
|
1532
|
+
}], S: [l, function(_) {
|
|
1533
|
+
this.milliseconds = 100 * +_;
|
|
1534
|
+
}], SS: [c, function(_) {
|
|
1535
|
+
this.milliseconds = 10 * +_;
|
|
1536
|
+
}], SSS: [/\d{3}/, function(_) {
|
|
1537
|
+
this.milliseconds = +_;
|
|
1538
|
+
}], s: [a, h("seconds")], ss: [a, h("seconds")], m: [a, h("minutes")], mm: [a, h("minutes")], H: [a, h("hours")], h: [a, h("hours")], HH: [a, h("hours")], hh: [a, h("hours")], D: [a, h("day")], DD: [c, h("day")], Do: [r, function(_) {
|
|
1539
|
+
var M = s.ordinal, z = _.match(/\d+/);
|
|
1540
|
+
if (this.day = z[0], M) for (var g = 1; g <= 31; g += 1) M(g).replace(/\[|\]/g, "") === _ && (this.day = g);
|
|
1541
|
+
}], w: [a, h("week")], ww: [c, h("week")], M: [a, h("month")], MM: [c, h("month")], MMM: [r, function(_) {
|
|
1542
|
+
var M = I("months"), z = (I("monthsShort") || M.map(function(g) {
|
|
1543
|
+
return g.slice(0, 3);
|
|
1544
|
+
})).indexOf(_) + 1;
|
|
1521
1545
|
if (z < 1) throw new Error();
|
|
1522
1546
|
this.month = z % 12 || z;
|
|
1523
|
-
}], MMMM: [
|
|
1524
|
-
var
|
|
1525
|
-
if (
|
|
1526
|
-
this.month =
|
|
1527
|
-
}], Y: [/[+-]?\d+/,
|
|
1528
|
-
this.year = i(
|
|
1529
|
-
}], YYYY: [/\d{4}/,
|
|
1530
|
-
function f(
|
|
1531
|
-
var
|
|
1532
|
-
|
|
1533
|
-
for (var
|
|
1547
|
+
}], MMMM: [r, function(_) {
|
|
1548
|
+
var M = I("months").indexOf(_) + 1;
|
|
1549
|
+
if (M < 1) throw new Error();
|
|
1550
|
+
this.month = M % 12 || M;
|
|
1551
|
+
}], Y: [/[+-]?\d+/, h("year")], YY: [c, function(_) {
|
|
1552
|
+
this.year = i(_);
|
|
1553
|
+
}], YYYY: [/\d{4}/, h("year")], Z: S, ZZ: S };
|
|
1554
|
+
function f(_) {
|
|
1555
|
+
var M, z;
|
|
1556
|
+
M = _, z = s && s.formats;
|
|
1557
|
+
for (var g = (_ = M.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g, function(C, N, re) {
|
|
1534
1558
|
var le = re && re.toUpperCase();
|
|
1535
1559
|
return N || z[re] || n[re] || z[le].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, function(R, B, E) {
|
|
1536
1560
|
return B || E.slice(1);
|
|
1537
1561
|
});
|
|
1538
|
-
})).match(o), v =
|
|
1539
|
-
var y =
|
|
1540
|
-
|
|
1562
|
+
})).match(o), v = g.length, F = 0; F < v; F += 1) {
|
|
1563
|
+
var y = g[F], A = V[y], b = A && A[0], j = A && A[1];
|
|
1564
|
+
g[F] = j ? { regex: b, parser: j } : y.replace(/^\[|\]$/g, "");
|
|
1541
1565
|
}
|
|
1542
1566
|
return function(C) {
|
|
1543
1567
|
for (var N = {}, re = 0, le = 0; re < v; re += 1) {
|
|
1544
|
-
var R =
|
|
1568
|
+
var R = g[re];
|
|
1545
1569
|
if (typeof R == "string") le += R.length;
|
|
1546
1570
|
else {
|
|
1547
1571
|
var B = R.regex, E = R.parser, d = C.slice(le), u = B.exec(d)[0];
|
|
1548
1572
|
E.call(N, u), C = C.replace(u, "");
|
|
1549
1573
|
}
|
|
1550
1574
|
}
|
|
1551
|
-
return function(
|
|
1552
|
-
var D =
|
|
1575
|
+
return function(w) {
|
|
1576
|
+
var D = w.afternoon;
|
|
1553
1577
|
if (D !== void 0) {
|
|
1554
|
-
var P =
|
|
1555
|
-
D ? P < 12 && (
|
|
1578
|
+
var P = w.hours;
|
|
1579
|
+
D ? P < 12 && (w.hours += 12) : P === 12 && (w.hours = 0), delete w.afternoon;
|
|
1556
1580
|
}
|
|
1557
1581
|
}(N), N;
|
|
1558
1582
|
};
|
|
1559
1583
|
}
|
|
1560
|
-
return function(
|
|
1561
|
-
z.p.customParseFormat = !0,
|
|
1562
|
-
var
|
|
1563
|
-
|
|
1584
|
+
return function(_, M, z) {
|
|
1585
|
+
z.p.customParseFormat = !0, _ && _.parseTwoDigitYear && (i = _.parseTwoDigitYear);
|
|
1586
|
+
var g = M.prototype, v = g.parse;
|
|
1587
|
+
g.parse = function(F) {
|
|
1564
1588
|
var y = F.date, A = F.utc, b = F.args;
|
|
1565
1589
|
this.$u = A;
|
|
1566
1590
|
var j = b[1];
|
|
1567
1591
|
if (typeof j == "string") {
|
|
1568
1592
|
var C = b[2] === !0, N = b[3] === !0, re = C || N, le = b[2];
|
|
1569
|
-
N && (le = b[2]), s = this.$locale(), !C && le && (s = z.Ls[le]), this.$d = function(d, u,
|
|
1593
|
+
N && (le = b[2]), s = this.$locale(), !C && le && (s = z.Ls[le]), this.$d = function(d, u, w, D) {
|
|
1570
1594
|
try {
|
|
1571
1595
|
if (["x", "X"].indexOf(u) > -1) return new Date((u === "X" ? 1e3 : 1) * d);
|
|
1572
|
-
var P = f(u)(d), x = P.year, K = P.month, q = P.day, Q = P.hours,
|
|
1596
|
+
var P = f(u)(d), x = P.year, K = P.month, q = P.day, Q = P.hours, T = P.minutes, X = P.seconds, ue = P.milliseconds, de = P.zone, me = P.week, we = /* @__PURE__ */ new Date(), De = q || (x || K ? 1 : we.getDate()), $e = x || we.getFullYear(), xe = 0;
|
|
1573
1597
|
x && !K || (xe = K > 0 ? K - 1 : we.getMonth());
|
|
1574
|
-
var qe, nt = Q || 0, Ge =
|
|
1575
|
-
return de ? new Date(Date.UTC($e, xe, De, nt, Ge, m, p + 60 * de.offset * 1e3)) :
|
|
1598
|
+
var qe, nt = Q || 0, Ge = T || 0, m = X || 0, p = ue || 0;
|
|
1599
|
+
return de ? new Date(Date.UTC($e, xe, De, nt, Ge, m, p + 60 * de.offset * 1e3)) : w ? new Date(Date.UTC($e, xe, De, nt, Ge, m, p)) : (qe = new Date($e, xe, De, nt, Ge, m, p), me && (qe = D(qe).week(me).toDate()), qe);
|
|
1576
1600
|
} catch {
|
|
1577
1601
|
return /* @__PURE__ */ new Date("");
|
|
1578
1602
|
}
|
|
@@ -1599,57 +1623,57 @@ var dn = { exports: {} };
|
|
|
1599
1623
|
e.exports = o();
|
|
1600
1624
|
})(it, function() {
|
|
1601
1625
|
var n = { year: 0, month: 1, day: 2, hour: 3, minute: 4, second: 5 }, o = {};
|
|
1602
|
-
return function(
|
|
1603
|
-
var
|
|
1626
|
+
return function(l, c, a) {
|
|
1627
|
+
var r, s = function(I, L, V) {
|
|
1604
1628
|
V === void 0 && (V = {});
|
|
1605
|
-
var f = new Date(
|
|
1629
|
+
var f = new Date(I), _ = function(M, z) {
|
|
1606
1630
|
z === void 0 && (z = {});
|
|
1607
|
-
var
|
|
1608
|
-
return F || (F = new Intl.DateTimeFormat("en-US", { hour12: !1, timeZone:
|
|
1631
|
+
var g = z.timeZoneName || "short", v = M + "|" + g, F = o[v];
|
|
1632
|
+
return F || (F = new Intl.DateTimeFormat("en-US", { hour12: !1, timeZone: M, year: "numeric", month: "2-digit", day: "2-digit", hour: "2-digit", minute: "2-digit", second: "2-digit", timeZoneName: g }), o[v] = F), F;
|
|
1609
1633
|
}(L, V);
|
|
1610
|
-
return
|
|
1611
|
-
}, i = function(
|
|
1612
|
-
for (var V = s(
|
|
1613
|
-
var
|
|
1614
|
-
v >= 0 && (f[v] = parseInt(
|
|
1634
|
+
return _.formatToParts(f);
|
|
1635
|
+
}, i = function(I, L) {
|
|
1636
|
+
for (var V = s(I, L), f = [], _ = 0; _ < V.length; _ += 1) {
|
|
1637
|
+
var M = V[_], z = M.type, g = M.value, v = n[z];
|
|
1638
|
+
v >= 0 && (f[v] = parseInt(g, 10));
|
|
1615
1639
|
}
|
|
1616
|
-
var F = f[3], y = F === 24 ? 0 : F, A = f[0] + "-" + f[1] + "-" + f[2] + " " + y + ":" + f[4] + ":" + f[5] + ":000", b =
|
|
1640
|
+
var F = f[3], y = F === 24 ? 0 : F, A = f[0] + "-" + f[1] + "-" + f[2] + " " + y + ":" + f[4] + ":" + f[5] + ":000", b = +I;
|
|
1617
1641
|
return (a.utc(A).valueOf() - (b -= b % 1e3)) / 6e4;
|
|
1618
|
-
},
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
var V, f = this.utcOffset(),
|
|
1622
|
-
if (!Number(
|
|
1623
|
-
else if (V = a(
|
|
1642
|
+
}, h = c.prototype;
|
|
1643
|
+
h.tz = function(I, L) {
|
|
1644
|
+
I === void 0 && (I = r);
|
|
1645
|
+
var V, f = this.utcOffset(), _ = this.toDate(), M = _.toLocaleString("en-US", { timeZone: I }), z = Math.round((_ - new Date(M)) / 1e3 / 60), g = 15 * -Math.round(_.getTimezoneOffset() / 15) - z;
|
|
1646
|
+
if (!Number(g)) V = this.utcOffset(0, L);
|
|
1647
|
+
else if (V = a(M, { locale: this.$L }).$set("millisecond", this.$ms).utcOffset(g, !0), L) {
|
|
1624
1648
|
var v = V.utcOffset();
|
|
1625
1649
|
V = V.add(f - v, "minute");
|
|
1626
1650
|
}
|
|
1627
|
-
return V.$x.$timezone =
|
|
1628
|
-
},
|
|
1629
|
-
var L = this.$x.$timezone || a.tz.guess(), V = s(this.valueOf(), L, { timeZoneName:
|
|
1651
|
+
return V.$x.$timezone = I, V;
|
|
1652
|
+
}, h.offsetName = function(I) {
|
|
1653
|
+
var L = this.$x.$timezone || a.tz.guess(), V = s(this.valueOf(), L, { timeZoneName: I }).find(function(f) {
|
|
1630
1654
|
return f.type.toLowerCase() === "timezonename";
|
|
1631
1655
|
});
|
|
1632
1656
|
return V && V.value;
|
|
1633
1657
|
};
|
|
1634
|
-
var
|
|
1635
|
-
|
|
1636
|
-
if (!this.$x || !this.$x.$timezone) return
|
|
1658
|
+
var S = h.startOf;
|
|
1659
|
+
h.startOf = function(I, L) {
|
|
1660
|
+
if (!this.$x || !this.$x.$timezone) return S.call(this, I, L);
|
|
1637
1661
|
var V = a(this.format("YYYY-MM-DD HH:mm:ss:SSS"), { locale: this.$L });
|
|
1638
|
-
return
|
|
1639
|
-
}, a.tz = function(
|
|
1640
|
-
var f = V && L,
|
|
1641
|
-
if (typeof
|
|
1662
|
+
return S.call(V, I, L).tz(this.$x.$timezone, !0);
|
|
1663
|
+
}, a.tz = function(I, L, V) {
|
|
1664
|
+
var f = V && L, _ = V || L || r, M = i(+a(), _);
|
|
1665
|
+
if (typeof I != "string") return a(I).tz(_);
|
|
1642
1666
|
var z = function(y, A, b) {
|
|
1643
1667
|
var j = y - 60 * A * 1e3, C = i(j, b);
|
|
1644
1668
|
if (A === C) return [j, A];
|
|
1645
1669
|
var N = i(j -= 60 * (C - A) * 1e3, b);
|
|
1646
1670
|
return C === N ? [j, C] : [y - 60 * Math.min(C, N) * 1e3, Math.max(C, N)];
|
|
1647
|
-
}(a.utc(
|
|
1648
|
-
return F.$x.$timezone =
|
|
1671
|
+
}(a.utc(I, f).valueOf(), M, _), g = z[0], v = z[1], F = a(g).utcOffset(v);
|
|
1672
|
+
return F.$x.$timezone = _, F;
|
|
1649
1673
|
}, a.tz.guess = function() {
|
|
1650
1674
|
return Intl.DateTimeFormat().resolvedOptions().timeZone;
|
|
1651
|
-
}, a.tz.setDefault = function(
|
|
1652
|
-
|
|
1675
|
+
}, a.tz.setDefault = function(I) {
|
|
1676
|
+
r = I;
|
|
1653
1677
|
};
|
|
1654
1678
|
};
|
|
1655
1679
|
});
|
|
@@ -1661,51 +1685,51 @@ var fn = { exports: {} };
|
|
|
1661
1685
|
(function(n, o) {
|
|
1662
1686
|
e.exports = o();
|
|
1663
1687
|
})(it, function() {
|
|
1664
|
-
var n = "minute", o = /[+-]\d\d(?::?\d\d)?/g,
|
|
1665
|
-
return function(c, a,
|
|
1688
|
+
var n = "minute", o = /[+-]\d\d(?::?\d\d)?/g, l = /([+-]|\d\d)/g;
|
|
1689
|
+
return function(c, a, r) {
|
|
1666
1690
|
var s = a.prototype;
|
|
1667
|
-
|
|
1668
|
-
var
|
|
1669
|
-
return new a(
|
|
1691
|
+
r.utc = function(f) {
|
|
1692
|
+
var _ = { date: f, utc: !0, args: arguments };
|
|
1693
|
+
return new a(_);
|
|
1670
1694
|
}, s.utc = function(f) {
|
|
1671
|
-
var
|
|
1672
|
-
return f ?
|
|
1695
|
+
var _ = r(this.toDate(), { locale: this.$L, utc: !0 });
|
|
1696
|
+
return f ? _.add(this.utcOffset(), n) : _;
|
|
1673
1697
|
}, s.local = function() {
|
|
1674
|
-
return
|
|
1698
|
+
return r(this.toDate(), { locale: this.$L, utc: !1 });
|
|
1675
1699
|
};
|
|
1676
1700
|
var i = s.parse;
|
|
1677
1701
|
s.parse = function(f) {
|
|
1678
1702
|
f.utc && (this.$u = !0), this.$utils().u(f.$offset) || (this.$offset = f.$offset), i.call(this, f);
|
|
1679
1703
|
};
|
|
1680
|
-
var
|
|
1704
|
+
var h = s.init;
|
|
1681
1705
|
s.init = function() {
|
|
1682
1706
|
if (this.$u) {
|
|
1683
1707
|
var f = this.$d;
|
|
1684
1708
|
this.$y = f.getUTCFullYear(), this.$M = f.getUTCMonth(), this.$D = f.getUTCDate(), this.$W = f.getUTCDay(), this.$H = f.getUTCHours(), this.$m = f.getUTCMinutes(), this.$s = f.getUTCSeconds(), this.$ms = f.getUTCMilliseconds();
|
|
1685
|
-
} else
|
|
1709
|
+
} else h.call(this);
|
|
1686
1710
|
};
|
|
1687
|
-
var
|
|
1688
|
-
s.utcOffset = function(f,
|
|
1689
|
-
var
|
|
1690
|
-
if (
|
|
1711
|
+
var S = s.utcOffset;
|
|
1712
|
+
s.utcOffset = function(f, _) {
|
|
1713
|
+
var M = this.$utils().u;
|
|
1714
|
+
if (M(f)) return this.$u ? 0 : M(this.$offset) ? S.call(this) : this.$offset;
|
|
1691
1715
|
if (typeof f == "string" && (f = function(F) {
|
|
1692
1716
|
F === void 0 && (F = "");
|
|
1693
1717
|
var y = F.match(o);
|
|
1694
1718
|
if (!y) return null;
|
|
1695
|
-
var A = ("" + y[0]).match(
|
|
1719
|
+
var A = ("" + y[0]).match(l) || ["-", 0, 0], b = A[0], j = 60 * +A[1] + +A[2];
|
|
1696
1720
|
return j === 0 ? 0 : b === "+" ? j : -j;
|
|
1697
1721
|
}(f), f === null)) return this;
|
|
1698
1722
|
var z = Math.abs(f) <= 16 ? 60 * f : f;
|
|
1699
|
-
if (z === 0) return this.utc(
|
|
1700
|
-
var
|
|
1701
|
-
if (
|
|
1723
|
+
if (z === 0) return this.utc(_);
|
|
1724
|
+
var g = this.clone();
|
|
1725
|
+
if (_) return g.$offset = z, g.$u = !1, g;
|
|
1702
1726
|
var v = this.$u ? this.toDate().getTimezoneOffset() : -1 * this.utcOffset();
|
|
1703
|
-
return (
|
|
1727
|
+
return (g = this.local().add(z + v, n)).$offset = z, g.$x.$localOffset = v, g;
|
|
1704
1728
|
};
|
|
1705
|
-
var
|
|
1729
|
+
var I = s.format;
|
|
1706
1730
|
s.format = function(f) {
|
|
1707
|
-
var
|
|
1708
|
-
return
|
|
1731
|
+
var _ = f || (this.$u ? "YYYY-MM-DDTHH:mm:ss[Z]" : "");
|
|
1732
|
+
return I.call(this, _);
|
|
1709
1733
|
}, s.valueOf = function() {
|
|
1710
1734
|
var f = this.$utils().u(this.$offset) ? 0 : this.$offset + (this.$x.$localOffset || this.$d.getTimezoneOffset());
|
|
1711
1735
|
return this.$d.valueOf() - 6e4 * f;
|
|
@@ -1718,13 +1742,13 @@ var fn = { exports: {} };
|
|
|
1718
1742
|
};
|
|
1719
1743
|
var L = s.toDate;
|
|
1720
1744
|
s.toDate = function(f) {
|
|
1721
|
-
return f === "s" && this.$offset ?
|
|
1745
|
+
return f === "s" && this.$offset ? r(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate() : L.call(this);
|
|
1722
1746
|
};
|
|
1723
1747
|
var V = s.diff;
|
|
1724
|
-
s.diff = function(f,
|
|
1725
|
-
if (f && this.$u === f.$u) return V.call(this, f,
|
|
1726
|
-
var z = this.local(),
|
|
1727
|
-
return V.call(z,
|
|
1748
|
+
s.diff = function(f, _, M) {
|
|
1749
|
+
if (f && this.$u === f.$u) return V.call(this, f, _, M);
|
|
1750
|
+
var z = this.local(), g = r(f).local();
|
|
1751
|
+
return V.call(z, g, _, M);
|
|
1728
1752
|
};
|
|
1729
1753
|
};
|
|
1730
1754
|
});
|
|
@@ -1778,7 +1802,7 @@ function kt(e) {
|
|
|
1778
1802
|
e.type || e.fieldType || e.frontInputType
|
|
1779
1803
|
) || jt(e.renderType) || "text";
|
|
1780
1804
|
}
|
|
1781
|
-
function
|
|
1805
|
+
function Mt(e) {
|
|
1782
1806
|
return At(
|
|
1783
1807
|
e.type || e.fieldType || e.frontInputType
|
|
1784
1808
|
) || At(e.renderType) || "text";
|
|
@@ -1816,7 +1840,7 @@ function pn(e) {
|
|
|
1816
1840
|
return typeof t.message == "string" && (typeof t.stack == "string" || t.name === "Error");
|
|
1817
1841
|
}
|
|
1818
1842
|
function mn(e, t, n = "-") {
|
|
1819
|
-
const o =
|
|
1843
|
+
const o = Mt(e);
|
|
1820
1844
|
return o === "empty" || _e(t) ? n : pn(t) ? (console.error("[globalInfo] field value render failed", t), n) : o === "select" ? Sr(e, t, n) : o === "switch" ? vn(t) ? Z("common.是") : Z("common.否") : o === "file" ? _r(t, n) : o === "multi-row" ? wr(t, n) : String(t);
|
|
1821
1845
|
}
|
|
1822
1846
|
function dt(e, t) {
|
|
@@ -1849,12 +1873,12 @@ function Ze(e, t) {
|
|
|
1849
1873
|
);
|
|
1850
1874
|
}
|
|
1851
1875
|
function ft(e, t, n, o = {}) {
|
|
1852
|
-
const
|
|
1876
|
+
const l = gr(o);
|
|
1853
1877
|
return e.filter((c) => c.visible ? !yr(
|
|
1854
1878
|
c,
|
|
1855
1879
|
t,
|
|
1856
1880
|
n,
|
|
1857
|
-
|
|
1881
|
+
l,
|
|
1858
1882
|
o.rows
|
|
1859
1883
|
) : !1);
|
|
1860
1884
|
}
|
|
@@ -1888,8 +1912,8 @@ function mr(e) {
|
|
|
1888
1912
|
}
|
|
1889
1913
|
function hn(e, t, n = "-") {
|
|
1890
1914
|
return !mr(e) || _e(t) ? [] : (Array.isArray(t) ? t : [t]).map(
|
|
1891
|
-
(
|
|
1892
|
-
).filter((
|
|
1915
|
+
(l, c) => vr(l, c, n)
|
|
1916
|
+
).filter((l) => !!l);
|
|
1893
1917
|
}
|
|
1894
1918
|
function vr(e, t, n) {
|
|
1895
1919
|
if (_e(e)) return null;
|
|
@@ -1910,22 +1934,22 @@ function vr(e, t, n) {
|
|
|
1910
1934
|
text: e.name || n
|
|
1911
1935
|
};
|
|
1912
1936
|
if (e && typeof e == "object") {
|
|
1913
|
-
const o = e,
|
|
1937
|
+
const o = e, l = hr(o, n), c = Fe(o.url);
|
|
1914
1938
|
if (c) {
|
|
1915
|
-
const
|
|
1916
|
-
return s && (
|
|
1939
|
+
const r = { url: c }, s = Fe(o.name), i = Fe(o.mimeType), h = Fe(o.extension);
|
|
1940
|
+
return s && (r.name = s), i && (r.mimeType = i), h && (r.extension = h), {
|
|
1917
1941
|
key: String(t),
|
|
1918
|
-
text:
|
|
1942
|
+
text: l,
|
|
1919
1943
|
action: {
|
|
1920
1944
|
type: "direct",
|
|
1921
|
-
options:
|
|
1945
|
+
options: r
|
|
1922
1946
|
}
|
|
1923
1947
|
};
|
|
1924
1948
|
}
|
|
1925
1949
|
const a = Fe(o.fileId);
|
|
1926
1950
|
return a ? {
|
|
1927
1951
|
key: String(t),
|
|
1928
|
-
text:
|
|
1952
|
+
text: l,
|
|
1929
1953
|
action: {
|
|
1930
1954
|
type: "params",
|
|
1931
1955
|
params: {
|
|
@@ -1934,7 +1958,7 @@ function vr(e, t, n) {
|
|
|
1934
1958
|
}
|
|
1935
1959
|
} : {
|
|
1936
1960
|
key: String(t),
|
|
1937
|
-
text:
|
|
1961
|
+
text: l
|
|
1938
1962
|
};
|
|
1939
1963
|
}
|
|
1940
1964
|
return {
|
|
@@ -1959,22 +1983,22 @@ function At(e) {
|
|
|
1959
1983
|
function gr(e) {
|
|
1960
1984
|
return e.rows?.length ? e.rows : [e.values ?? {}];
|
|
1961
1985
|
}
|
|
1962
|
-
function yr(e, t, n, o,
|
|
1986
|
+
function yr(e, t, n, o, l) {
|
|
1963
1987
|
const c = n?.hiddenRule;
|
|
1964
1988
|
return c ? o.some((a) => {
|
|
1965
1989
|
try {
|
|
1966
|
-
const
|
|
1990
|
+
const r = a[e.code];
|
|
1967
1991
|
return c({
|
|
1968
1992
|
field: e,
|
|
1969
1993
|
section: t,
|
|
1970
1994
|
values: a,
|
|
1971
1995
|
allValues: a,
|
|
1972
|
-
value:
|
|
1973
|
-
currentValue:
|
|
1974
|
-
rows:
|
|
1996
|
+
value: r,
|
|
1997
|
+
currentValue: r,
|
|
1998
|
+
rows: l
|
|
1975
1999
|
});
|
|
1976
|
-
} catch (
|
|
1977
|
-
return console.error("[globalInfo] hidden rule failed",
|
|
2000
|
+
} catch (r) {
|
|
2001
|
+
return console.error("[globalInfo] hidden rule failed", r), !1;
|
|
1978
2002
|
}
|
|
1979
2003
|
}) : !1;
|
|
1980
2004
|
}
|
|
@@ -1999,13 +2023,13 @@ function yn(e) {
|
|
|
1999
2023
|
function Sr(e, t, n) {
|
|
2000
2024
|
const o = pt(e);
|
|
2001
2025
|
if (Array.isArray(t) || o) {
|
|
2002
|
-
const
|
|
2003
|
-
return
|
|
2026
|
+
const l = dt(e, t).map((a) => Rt(e, a) || String(a ?? "").trim()).filter(Boolean), c = o ? "," : "、";
|
|
2027
|
+
return l.length > 0 ? l.join(c) : n;
|
|
2004
2028
|
}
|
|
2005
2029
|
return Rt(e, t) || String(t).trim() || n;
|
|
2006
2030
|
}
|
|
2007
2031
|
function pt(e) {
|
|
2008
|
-
return !!e.props?.multiple && (kt(e) === "select" ||
|
|
2032
|
+
return !!e.props?.multiple && (kt(e) === "select" || Mt(e) === "select");
|
|
2009
2033
|
}
|
|
2010
2034
|
function Rt(e, t) {
|
|
2011
2035
|
return e.options?.find(
|
|
@@ -2061,7 +2085,7 @@ function Ir(e = null) {
|
|
|
2061
2085
|
}
|
|
2062
2086
|
function Nt(e) {
|
|
2063
2087
|
const t = kn(e), n = Cn(t), o = Lr(t).flatMap(
|
|
2064
|
-
(
|
|
2088
|
+
(l) => $n(l, n)
|
|
2065
2089
|
);
|
|
2066
2090
|
return {
|
|
2067
2091
|
...Ir(e),
|
|
@@ -2077,11 +2101,11 @@ function Sn(e, t, n) {
|
|
|
2077
2101
|
});
|
|
2078
2102
|
}
|
|
2079
2103
|
function $r(e, t = {}, n = null) {
|
|
2080
|
-
const o = kn(e),
|
|
2081
|
-
c.map((
|
|
2104
|
+
const o = kn(e), l = Cn(o, t), c = Mr(o, t, n), a = Object.fromEntries(
|
|
2105
|
+
c.map((r) => [r.key, r])
|
|
2082
2106
|
);
|
|
2083
2107
|
return {
|
|
2084
|
-
scheme:
|
|
2108
|
+
scheme: l,
|
|
2085
2109
|
node: n,
|
|
2086
2110
|
topNodes: [],
|
|
2087
2111
|
treeNodes: [],
|
|
@@ -2098,14 +2122,14 @@ function Cr(e) {
|
|
|
2098
2122
|
function kr(e, t = {}) {
|
|
2099
2123
|
const n = e.renderType === "table" ? e.rows.map(
|
|
2100
2124
|
(s) => _t(wt(s))
|
|
2101
|
-
) : [_t(wt(e.model))], o = ce(e.operationInfo),
|
|
2125
|
+
) : [_t(wt(e.model))], o = ce(e.operationInfo), l = ce(o.editInfoSet), c = ce(l.params), a = ce(o.queryInfoSet), r = ce(a.params);
|
|
2102
2126
|
return {
|
|
2103
2127
|
...t,
|
|
2104
2128
|
infSchmId: t.infSchmId ?? se(e.raw.infSchmId),
|
|
2105
2129
|
emplid: t.emplid ?? se(e.raw.emplid),
|
|
2106
2130
|
// 保存优先使用接口出参里的信息集挂载 tagId,其次才回退到请求节点 tagId。
|
|
2107
2131
|
tagId: ee(
|
|
2108
|
-
e.tagId || c.tagId ||
|
|
2132
|
+
e.tagId || c.tagId || r.tagId || t.tagId || e.requestTagId
|
|
2109
2133
|
),
|
|
2110
2134
|
infSetId: t.infSetId ?? e.infSetId,
|
|
2111
2135
|
setId: t.setId ?? e.setId,
|
|
@@ -2130,59 +2154,59 @@ function is(e) {
|
|
|
2130
2154
|
return !!(t && typeof t == "object" && typeof t.key == "string" && typeof t.tagId == "string");
|
|
2131
2155
|
}
|
|
2132
2156
|
function wn(e) {
|
|
2133
|
-
const t =
|
|
2157
|
+
const t = Mn(e);
|
|
2134
2158
|
return (Array.isArray(t) ? t : Qe(ce(t), ["options", "list", "records", "data"])).map((o) => {
|
|
2135
|
-
const
|
|
2159
|
+
const l = ce(o), c = l.fieldvalue, a = c ?? l.value ?? l.code ?? l.emplid;
|
|
2136
2160
|
return {
|
|
2137
|
-
id:
|
|
2138
|
-
code: c ??
|
|
2161
|
+
id: l.id,
|
|
2162
|
+
code: c ?? l.value ?? l.code ?? l.emplid,
|
|
2139
2163
|
// fieldname 在 md-options 中是字段标识,不是用户可读文案;展示文案只接受明确的 label/descr/name。
|
|
2140
2164
|
label: ee(
|
|
2141
|
-
|
|
2165
|
+
l.label ?? l.descr ?? l.name
|
|
2142
2166
|
),
|
|
2143
|
-
labelDescr: se(
|
|
2144
|
-
name: se(
|
|
2167
|
+
labelDescr: se(l.labelDescr),
|
|
2168
|
+
name: se(l.name),
|
|
2145
2169
|
value: a,
|
|
2146
2170
|
raw: o
|
|
2147
2171
|
};
|
|
2148
2172
|
});
|
|
2149
2173
|
}
|
|
2150
|
-
function
|
|
2174
|
+
function Mr(e, t, n) {
|
|
2151
2175
|
const o = Qe(e, ["sections", "sets", "list"]);
|
|
2152
2176
|
return o.length > 0 ? o.map(
|
|
2153
|
-
(
|
|
2177
|
+
(l) => xt(l, t, n, o.length === 1)
|
|
2154
2178
|
) : e.infSetMark || e.infSetFields || e.fields ? [xt(e, t, n, !0)] : [];
|
|
2155
2179
|
}
|
|
2156
2180
|
function xt(e, t, n, o) {
|
|
2157
|
-
const
|
|
2158
|
-
|
|
2181
|
+
const l = ce(e), c = Tr(l.infSetMark ?? l), a = Or(l.infSetFields ?? l.fields ?? []), r = Cr(c), s = Fr(
|
|
2182
|
+
l.infSetValues ?? l.rows ?? l.data,
|
|
2159
2183
|
a,
|
|
2160
|
-
|
|
2161
|
-
), i = s[0] ? wt(s[0]) : In(a),
|
|
2162
|
-
|
|
2163
|
-
),
|
|
2184
|
+
r
|
|
2185
|
+
), i = s[0] ? wt(s[0]) : In(a), h = ce(l.tag), S = ee(
|
|
2186
|
+
l.tagId ?? l.infTagId ?? h.tagId ?? h.infTagId ?? c.raw.tagId ?? c.raw.infTagId
|
|
2187
|
+
), I = ee(t.tagId ?? n?.tagId), L = ee(n?.key), V = o ? t.infSetId ?? n?.infSetId : void 0, f = o ? t.setId : void 0, _ = o ? n?.code : void 0, M = c.setId || ee(l.setId), z = ee(l.infSetId) || M || ee(V), g = M || ee(f ?? z), v = c.code || ee(l.code ?? _ ?? g), F = g || v || z || S, y = {
|
|
2164
2188
|
key: F,
|
|
2165
2189
|
id: F,
|
|
2166
|
-
setId:
|
|
2190
|
+
setId: g,
|
|
2167
2191
|
code: v,
|
|
2168
|
-
tagId:
|
|
2169
|
-
requestTagId:
|
|
2192
|
+
tagId: S,
|
|
2193
|
+
requestTagId: I || void 0,
|
|
2170
2194
|
ownerNodeKey: L || void 0,
|
|
2171
2195
|
infSetId: z,
|
|
2172
|
-
title: c.name || ee(
|
|
2173
|
-
renderType:
|
|
2196
|
+
title: c.name || ee(l.name ?? n?.tagName ?? F),
|
|
2197
|
+
renderType: r,
|
|
2174
2198
|
mark: c,
|
|
2175
2199
|
fields: a,
|
|
2176
2200
|
model: i,
|
|
2177
2201
|
rows: s,
|
|
2178
2202
|
operationInfo: mt(
|
|
2179
|
-
t.operationInfo ??
|
|
2203
|
+
t.operationInfo ?? l.operationInfo
|
|
2180
2204
|
),
|
|
2181
|
-
raw:
|
|
2205
|
+
raw: l
|
|
2182
2206
|
};
|
|
2183
2207
|
return y.renderType === "form" && s.length === 0 && (y.rows = [{ ...i, __rowKey: `${F}-0` }]), y;
|
|
2184
2208
|
}
|
|
2185
|
-
function
|
|
2209
|
+
function Tr(e) {
|
|
2186
2210
|
const t = ce(e), n = ee(t.htmlDisplay || "F");
|
|
2187
2211
|
return {
|
|
2188
2212
|
name: ee(t.name ?? t.title),
|
|
@@ -2203,14 +2227,14 @@ function Or(e) {
|
|
|
2203
2227
|
function Dr(e, t) {
|
|
2204
2228
|
const n = ce(e), o = ee(
|
|
2205
2229
|
n.code ?? n.fieldCode ?? n.prop ?? n.key ?? `field_${t}`
|
|
2206
|
-
),
|
|
2230
|
+
), l = ee(n.label ?? n.name ?? n.tagName ?? o), c = Tn(
|
|
2207
2231
|
n.interface ?? n.interfaceField
|
|
2208
2232
|
), a = qt(n.cascadeDependFields);
|
|
2209
2233
|
return {
|
|
2210
2234
|
id: ee(n.id ?? n.key ?? n.prop ?? o),
|
|
2211
2235
|
key: ee(n.key ?? n.prop ?? o),
|
|
2212
2236
|
code: o,
|
|
2213
|
-
label:
|
|
2237
|
+
label: l,
|
|
2214
2238
|
value: n.value ?? n.defaultValue ?? "",
|
|
2215
2239
|
type: jr(n),
|
|
2216
2240
|
fieldType: se(n.fieldType),
|
|
@@ -2243,7 +2267,7 @@ function Fr(e, t, n) {
|
|
|
2243
2267
|
if (Array.isArray(e) && e.some((c) => {
|
|
2244
2268
|
const a = ce(c);
|
|
2245
2269
|
return t.some(
|
|
2246
|
-
(
|
|
2270
|
+
(r) => a[r.code] !== void 0 || a[r.key] !== void 0
|
|
2247
2271
|
);
|
|
2248
2272
|
}))
|
|
2249
2273
|
return e.map((c, a) => ({
|
|
@@ -2259,23 +2283,23 @@ function In(e) {
|
|
|
2259
2283
|
return e.reduce((t, n) => (t[n.code || n.key] = n.value, t), {});
|
|
2260
2284
|
}
|
|
2261
2285
|
function $n(e, t, n = "") {
|
|
2262
|
-
const o = ce(e),
|
|
2286
|
+
const o = ce(e), l = Qe(o, ["children", "list", "tags"]).flatMap(
|
|
2263
2287
|
(a) => $n(
|
|
2264
2288
|
a,
|
|
2265
2289
|
t,
|
|
2266
2290
|
ee(o.tagId ?? o.id ?? o.key)
|
|
2267
2291
|
)
|
|
2268
2292
|
), c = Pr(o.infSetList);
|
|
2269
|
-
return
|
|
2270
|
-
(a,
|
|
2271
|
-
) : [Br(o, t, n,
|
|
2293
|
+
return l.length === 0 && c.length > 0 ? c.map(
|
|
2294
|
+
(a, r) => Er(o, a, t, n, r)
|
|
2295
|
+
) : [Br(o, t, n, l)];
|
|
2272
2296
|
}
|
|
2273
2297
|
function Br(e, t, n, o) {
|
|
2274
|
-
const
|
|
2298
|
+
const l = ee(e.tagId ?? e.id ?? e.key), c = ee(e.tagName ?? e.name ?? e.label ?? l);
|
|
2275
2299
|
return {
|
|
2276
|
-
key: ee(e.key ??
|
|
2277
|
-
id:
|
|
2278
|
-
tagId:
|
|
2300
|
+
key: ee(e.key ?? l),
|
|
2301
|
+
id: l,
|
|
2302
|
+
tagId: l,
|
|
2279
2303
|
tagName: c,
|
|
2280
2304
|
label: c,
|
|
2281
2305
|
tagLevel: se(e.tagLevel ?? e.level) ?? null,
|
|
@@ -2296,8 +2320,8 @@ function Br(e, t, n, o) {
|
|
|
2296
2320
|
raw: e
|
|
2297
2321
|
};
|
|
2298
2322
|
}
|
|
2299
|
-
function Er(e, t, n, o,
|
|
2300
|
-
const c = ee(e.tagId ?? e.id ?? e.key), a = ee(e.tagName ?? e.name ?? e.label ?? c),
|
|
2323
|
+
function Er(e, t, n, o, l) {
|
|
2324
|
+
const c = ee(e.tagId ?? e.id ?? e.key), a = ee(e.tagName ?? e.name ?? e.label ?? c), r = t.infSetId || ee(t.setId), s = t.setId || r, i = r || `${c}-${l}`, h = t.code || se(e.code ?? r);
|
|
2301
2325
|
return {
|
|
2302
2326
|
key: i,
|
|
2303
2327
|
id: i,
|
|
@@ -2312,16 +2336,16 @@ function Er(e, t, n, o, r) {
|
|
|
2312
2336
|
parentId: se(e.parentTagId ?? e.parentId ?? o) ?? null,
|
|
2313
2337
|
infSchmId: se(e.infSchmId ?? n?.infSchmId),
|
|
2314
2338
|
schemeId: ee(e.infSchmId ?? n?.infSchmId),
|
|
2315
|
-
infSetId:
|
|
2339
|
+
infSetId: r,
|
|
2316
2340
|
setId: s,
|
|
2317
|
-
code:
|
|
2341
|
+
code: h,
|
|
2318
2342
|
children: [],
|
|
2319
2343
|
infSetList: [t],
|
|
2320
2344
|
operationInfo: mt(e.operationInfo),
|
|
2321
2345
|
loaded: !0,
|
|
2322
2346
|
raw: {
|
|
2323
2347
|
...e,
|
|
2324
|
-
infSetId:
|
|
2348
|
+
infSetId: r,
|
|
2325
2349
|
setId: s,
|
|
2326
2350
|
infSetList: [t.raw]
|
|
2327
2351
|
}
|
|
@@ -2330,10 +2354,10 @@ function Er(e, t, n, o, r) {
|
|
|
2330
2354
|
function Cn(e, t = {}) {
|
|
2331
2355
|
const n = ce(
|
|
2332
2356
|
e.globalInfoSchmMark ?? e.scheme ?? e
|
|
2333
|
-
), o = ee(n.infSchmId ?? t.infSchmId),
|
|
2334
|
-
return !o && !
|
|
2357
|
+
), o = ee(n.infSchmId ?? t.infSchmId), l = ee(n.emplid ?? t.emplid);
|
|
2358
|
+
return !o && !l && Object.keys(n).length === 0 ? null : {
|
|
2335
2359
|
infSchmId: o,
|
|
2336
|
-
emplid:
|
|
2360
|
+
emplid: l,
|
|
2337
2361
|
id: o,
|
|
2338
2362
|
mark: ee(n.globalInfoSchmMark ?? e.globalInfoSchmMark),
|
|
2339
2363
|
config: Array.isArray(e.globalInfoSchmConfig) ? "" : ee(n.globalInfoSchmConfig ?? e.globalInfoSchmConfig),
|
|
@@ -2362,9 +2386,9 @@ function Pr(e) {
|
|
|
2362
2386
|
}) : [];
|
|
2363
2387
|
}
|
|
2364
2388
|
function kn(e) {
|
|
2365
|
-
return ce(
|
|
2389
|
+
return ce(Mn(e));
|
|
2366
2390
|
}
|
|
2367
|
-
function
|
|
2391
|
+
function Mn(e) {
|
|
2368
2392
|
const t = ce(e);
|
|
2369
2393
|
return t.data ?? t.result ?? e;
|
|
2370
2394
|
}
|
|
@@ -2380,7 +2404,7 @@ function wt(e) {
|
|
|
2380
2404
|
const t = { ...e };
|
|
2381
2405
|
return delete t.__rowKey, delete t.fields, t;
|
|
2382
2406
|
}
|
|
2383
|
-
function
|
|
2407
|
+
function Tn(e) {
|
|
2384
2408
|
const t = ce(e);
|
|
2385
2409
|
if (!(!t.method && !t.url && !t.params))
|
|
2386
2410
|
return {
|
|
@@ -2396,7 +2420,7 @@ function mt(e) {
|
|
|
2396
2420
|
return Object.fromEntries(
|
|
2397
2421
|
Object.entries(t).map(([n, o]) => [
|
|
2398
2422
|
n,
|
|
2399
|
-
|
|
2423
|
+
Tn(o) ?? o
|
|
2400
2424
|
])
|
|
2401
2425
|
);
|
|
2402
2426
|
}
|
|
@@ -2454,7 +2478,7 @@ function ke(e) {
|
|
|
2454
2478
|
e.toLowerCase()
|
|
2455
2479
|
) : !!e;
|
|
2456
2480
|
}
|
|
2457
|
-
const Ve = (e) => e.key || e.code,
|
|
2481
|
+
const Ve = (e) => e.key || e.code, Te = (e) => e.key || e.setId, Rr = (e) => String(e ?? "").trim(), tt = (e) => Array.from(new Set(e.map(Rr).filter(Boolean))), Ue = (e) => !!(e && typeof e == "object" && "children" in e), Xe = (e) => tt([
|
|
2458
2482
|
e?.key,
|
|
2459
2483
|
e?.id,
|
|
2460
2484
|
e?.setId,
|
|
@@ -2472,25 +2496,25 @@ const Ve = (e) => e.key || e.code, Me = (e) => e.key || e.setId, Rr = (e) => Str
|
|
|
2472
2496
|
e.code
|
|
2473
2497
|
]);
|
|
2474
2498
|
function Bn(e, t, n) {
|
|
2475
|
-
const o = zr(e),
|
|
2476
|
-
return
|
|
2499
|
+
const o = zr(e), l = tt([n, ...Xe(t)]);
|
|
2500
|
+
return l.length === 0 ? !1 : l.some((c) => o.includes(c));
|
|
2477
2501
|
}
|
|
2478
2502
|
function Nr(e, t, n) {
|
|
2479
|
-
return tt([n, ...Xe(t)]).length === 0 ? e : e.filter((
|
|
2503
|
+
return tt([n, ...Xe(t)]).length === 0 ? e : e.filter((l) => Bn(l, t, n));
|
|
2480
2504
|
}
|
|
2481
2505
|
function xr(e, t, n = {}) {
|
|
2482
|
-
const o = Object.keys(n).length > 0 ? n : e.model,
|
|
2506
|
+
const o = Object.keys(n).length > 0 ? n : e.model, l = typeof t == "string" ? t : Ve(t), c = typeof t == "string" ? e.fields.find((s) => Ve(s) === l || s.code === l) : t, r = Ne(c).some((s) => {
|
|
2483
2507
|
if (s === "searchText" && Object.prototype.hasOwnProperty.call(o, s) || s !== "searchText" && !Gr(e, s))
|
|
2484
2508
|
return !1;
|
|
2485
2509
|
const i = o[s];
|
|
2486
2510
|
return i == null || i === "";
|
|
2487
2511
|
});
|
|
2488
2512
|
return {
|
|
2489
|
-
fieldKey:
|
|
2513
|
+
fieldKey: l,
|
|
2490
2514
|
currentField: c,
|
|
2491
2515
|
sourceModel: o,
|
|
2492
2516
|
sourceRow: e.renderType === "table" ? o : void 0,
|
|
2493
|
-
missingDependField:
|
|
2517
|
+
missingDependField: r
|
|
2494
2518
|
};
|
|
2495
2519
|
}
|
|
2496
2520
|
function qr(e) {
|
|
@@ -2502,27 +2526,27 @@ function Gr(e, t) {
|
|
|
2502
2526
|
function Kr(e) {
|
|
2503
2527
|
return wn(e);
|
|
2504
2528
|
}
|
|
2505
|
-
const
|
|
2506
|
-
const t =
|
|
2529
|
+
const Me = (e) => e && typeof e == "object" && !Array.isArray(e) ? e : {}, at = (e) => {
|
|
2530
|
+
const t = Me(e);
|
|
2507
2531
|
return !!(t.url || t.method || t.params);
|
|
2508
2532
|
};
|
|
2509
2533
|
function Yr(e) {
|
|
2510
|
-
const t =
|
|
2534
|
+
const t = Me(e.operationInfo).openTag;
|
|
2511
2535
|
return at(t) ? t : void 0;
|
|
2512
2536
|
}
|
|
2513
2537
|
function Ur(e, t, n) {
|
|
2514
|
-
const o =
|
|
2538
|
+
const o = Me(e?.operationInfo).queryInfoSet;
|
|
2515
2539
|
if (at(o))
|
|
2516
2540
|
return o;
|
|
2517
|
-
const
|
|
2541
|
+
const l = t?.infSetList.find((a) => a.infSetId === n), c = Me(l?.operationInfo).queryInfoSet;
|
|
2518
2542
|
return at(c) ? c : void 0;
|
|
2519
2543
|
}
|
|
2520
2544
|
function Hr(e) {
|
|
2521
|
-
const t =
|
|
2545
|
+
const t = Me(e.operationInfo).editInfoSet;
|
|
2522
2546
|
return at(t) ? t : void 0;
|
|
2523
2547
|
}
|
|
2524
2548
|
async function En(e) {
|
|
2525
|
-
const t = e.params === void 0 ? void 0 :
|
|
2549
|
+
const t = e.params === void 0 ? void 0 : Me(e.params);
|
|
2526
2550
|
return !e.formatter || !Jr(e) ? t : e.formatter({
|
|
2527
2551
|
operation: e.operation,
|
|
2528
2552
|
interfaceOperation: e.field?.interface,
|
|
@@ -2530,8 +2554,8 @@ async function En(e) {
|
|
|
2530
2554
|
requestSource: e.requestSource,
|
|
2531
2555
|
tagId: e.tagId,
|
|
2532
2556
|
model: {
|
|
2533
|
-
...
|
|
2534
|
-
...
|
|
2557
|
+
...Me(e.section?.model),
|
|
2558
|
+
...Me(e.model)
|
|
2535
2559
|
},
|
|
2536
2560
|
row: e.row,
|
|
2537
2561
|
section: e.section,
|
|
@@ -2551,7 +2575,7 @@ function Jr(e) {
|
|
|
2551
2575
|
async function Wr(e) {
|
|
2552
2576
|
if (!e.service.requestOperation)
|
|
2553
2577
|
throw new Error("[GlobalInfo] service.requestOperation is required for operationInfo");
|
|
2554
|
-
const t = e.operation.params === void 0 ? void 0 :
|
|
2578
|
+
const t = e.operation.params === void 0 ? void 0 : Me(e.operation.params), n = Zr(t, e.context), o = await En({
|
|
2555
2579
|
formatter: e.formatter,
|
|
2556
2580
|
params: n,
|
|
2557
2581
|
operation: e.operation,
|
|
@@ -2577,10 +2601,10 @@ async function Wr(e) {
|
|
|
2577
2601
|
function Zr(e, t) {
|
|
2578
2602
|
if (t?.params === void 0)
|
|
2579
2603
|
return e;
|
|
2580
|
-
const n =
|
|
2604
|
+
const n = Me(t.params);
|
|
2581
2605
|
return t.type === "openTag" && t.requestSource === "sidebar" ? {
|
|
2582
2606
|
...n,
|
|
2583
|
-
...
|
|
2607
|
+
...Me(e)
|
|
2584
2608
|
} : n;
|
|
2585
2609
|
}
|
|
2586
2610
|
function Je(e = {}) {
|
|
@@ -2600,28 +2624,28 @@ function Je(e = {}) {
|
|
|
2600
2624
|
};
|
|
2601
2625
|
}
|
|
2602
2626
|
function Qr(e) {
|
|
2603
|
-
const t = { ...e.currentMap }, n = { ...e.currentAliasMap }, o = [...e.currentOrder],
|
|
2627
|
+
const t = { ...e.currentMap }, n = { ...e.currentAliasMap }, o = [...e.currentOrder], l = { ...e.currentStatusMap }, c = Nr(e.nextViewModel.sections, e.node, e.targetKey), a = tt([e.targetKey, ...Xe(e.node)]).length > 0, r = c.find((s) => Bn(s, e.node, e.targetKey)) ?? (a ? null : e.nextViewModel.activeSection ?? c[0] ?? e.activeSection ?? null);
|
|
2604
2628
|
return c.forEach((s) => {
|
|
2605
|
-
const i =
|
|
2606
|
-
t[i] = s, o.includes(i) || o.push(i),
|
|
2607
|
-
...
|
|
2629
|
+
const i = Te(s);
|
|
2630
|
+
t[i] = s, o.includes(i) || o.push(i), l[i] = Je({
|
|
2631
|
+
...l[i],
|
|
2608
2632
|
loaded: !0,
|
|
2609
2633
|
loading: !1,
|
|
2610
2634
|
error: null,
|
|
2611
2635
|
editing: e.editingSectionKeys.includes(i)
|
|
2612
2636
|
});
|
|
2613
|
-
}), e.targetKey &&
|
|
2614
|
-
...
|
|
2637
|
+
}), e.targetKey && r ? n[e.targetKey] = Te(r) : e.targetKey && (n[e.targetKey] = ""), e.targetKey && (l[e.targetKey] = Je({
|
|
2638
|
+
...l[e.targetKey],
|
|
2615
2639
|
loaded: !0,
|
|
2616
2640
|
loading: !1,
|
|
2617
2641
|
error: null,
|
|
2618
|
-
editing: !!(
|
|
2642
|
+
editing: !!(r && e.editingSectionKeys.includes(Te(r)))
|
|
2619
2643
|
})), {
|
|
2620
2644
|
sectionMap: t,
|
|
2621
2645
|
sectionAliasMap: n,
|
|
2622
2646
|
sectionOrder: o,
|
|
2623
|
-
sectionStatusMap:
|
|
2624
|
-
matchedSection:
|
|
2647
|
+
sectionStatusMap: l,
|
|
2648
|
+
matchedSection: r,
|
|
2625
2649
|
targetSections: c
|
|
2626
2650
|
};
|
|
2627
2651
|
}
|
|
@@ -2640,15 +2664,15 @@ function ea(e, t) {
|
|
|
2640
2664
|
const ze = (e) => new Error(`[GlobalInfo] ${e}`), ta = (e) => [
|
|
2641
2665
|
String(e.method ?? "").toLowerCase(),
|
|
2642
2666
|
String(e.url ?? ""),
|
|
2643
|
-
It(
|
|
2667
|
+
It(Me(e.params))
|
|
2644
2668
|
].join("::");
|
|
2645
2669
|
function It(e) {
|
|
2646
2670
|
return Array.isArray(e) ? `[${e.map((t) => It(t)).join(",")}]` : e && typeof e == "object" ? `{${Object.entries(e).sort(([n], [o]) => n.localeCompare(o)).map(([n, o]) => `${JSON.stringify(n)}:${It(o)}`).join(",")}}` : JSON.stringify(e);
|
|
2647
2671
|
}
|
|
2648
2672
|
const na = (e) => {
|
|
2649
|
-
const t = ge(!1), n = ge(!1), o = ge(!1),
|
|
2673
|
+
const t = ge(!1), n = ge(!1), o = ge(!1), l = je(null), c = je([]), a = je(null), r = je(null), s = je(null), i = je({}), h = je({}), S = ge([]), I = je({}), L = ge([]), V = O(
|
|
2650
2674
|
() => {
|
|
2651
|
-
const m =
|
|
2675
|
+
const m = S.value.map((k) => i.value[k]).filter((k) => !!k), p = Object.entries(i.value).filter(([k]) => !S.value.includes(k)).map(([, k]) => k);
|
|
2652
2676
|
return [...m, ...p];
|
|
2653
2677
|
}
|
|
2654
2678
|
), f = O(() => ({
|
|
@@ -2664,28 +2688,28 @@ const na = (e) => {
|
|
|
2664
2688
|
sectionMap: i.value,
|
|
2665
2689
|
// section 状态映射;这里把 alias 后的编辑态也同步进去。
|
|
2666
2690
|
sectionStatusMap: Object.fromEntries(
|
|
2667
|
-
Object.entries(
|
|
2691
|
+
Object.entries(I.value).map(([m, p]) => [
|
|
2668
2692
|
m,
|
|
2669
2693
|
{
|
|
2670
2694
|
// 保留原状态字段。
|
|
2671
2695
|
...p,
|
|
2672
2696
|
// 编辑态以 editingSectionKeys 为准,避免状态对象里 editing 值残留。
|
|
2673
2697
|
editing: L.value.includes(
|
|
2674
|
-
|
|
2698
|
+
h.value[m] ?? m
|
|
2675
2699
|
)
|
|
2676
2700
|
}
|
|
2677
2701
|
])
|
|
2678
2702
|
),
|
|
2679
2703
|
// 最近一次全局错误。
|
|
2680
|
-
error:
|
|
2681
|
-
})),
|
|
2704
|
+
error: l.value
|
|
2705
|
+
})), _ = () => ({
|
|
2682
2706
|
// adaptScene 透传给新接口形态。
|
|
2683
2707
|
adaptScene: e.adaptScene,
|
|
2684
2708
|
// emplid 是当前人员标识,树和详情接口都需要它。
|
|
2685
2709
|
emplid: e.emplid
|
|
2686
|
-
}),
|
|
2710
|
+
}), M = (m) => ({
|
|
2687
2711
|
// 复用基础参数,保证人员和场景一致。
|
|
2688
|
-
...
|
|
2712
|
+
..._(),
|
|
2689
2713
|
// infSchmId 指定当前模板方案。
|
|
2690
2714
|
infSchmId: m.infSchmId,
|
|
2691
2715
|
// tagId 指定要展开的树节点。
|
|
@@ -2694,9 +2718,9 @@ const na = (e) => {
|
|
|
2694
2718
|
tagLevel: m.tagLevel,
|
|
2695
2719
|
// parentTagId 保留父子关系上下文。
|
|
2696
2720
|
parentTagId: m.parentTagId
|
|
2697
|
-
}), z = (m =
|
|
2721
|
+
}), z = (m = r.value, p = s.value) => ({
|
|
2698
2722
|
// 详情接口同样需要基础人员和场景参数。
|
|
2699
|
-
...
|
|
2723
|
+
..._(),
|
|
2700
2724
|
// 当前节点所属模板方案。
|
|
2701
2725
|
infSchmId: m?.infSchmId,
|
|
2702
2726
|
// 当前点击或加载的树节点 id。
|
|
@@ -2705,14 +2729,14 @@ const na = (e) => {
|
|
|
2705
2729
|
infSetId: p?.infSetId ?? m?.infSetId,
|
|
2706
2730
|
// setId 同样优先取 section,避免保存时拿错节点 setId。
|
|
2707
2731
|
setId: p?.setId ?? m?.setId
|
|
2708
|
-
}),
|
|
2732
|
+
}), g = async (m, p) => Wr({
|
|
2709
2733
|
service: e.service,
|
|
2710
2734
|
formatter: e.formatOperationParams,
|
|
2711
2735
|
operation: m,
|
|
2712
2736
|
context: p,
|
|
2713
2737
|
viewModel: a.value,
|
|
2714
2738
|
sections: V.value,
|
|
2715
|
-
activeNode:
|
|
2739
|
+
activeNode: r.value,
|
|
2716
2740
|
activeSection: s.value
|
|
2717
2741
|
}), v = nr(
|
|
2718
2742
|
async (m, p) => {
|
|
@@ -2736,7 +2760,7 @@ const na = (e) => {
|
|
|
2736
2760
|
node: p?.node,
|
|
2737
2761
|
viewModel: a.value,
|
|
2738
2762
|
sections: V.value,
|
|
2739
|
-
activeNode:
|
|
2763
|
+
activeNode: r.value,
|
|
2740
2764
|
activeSection: s.value,
|
|
2741
2765
|
searchText: p?.searchText
|
|
2742
2766
|
}), Y = { ...m, params: k }, W = p && { ...p, params: k };
|
|
@@ -2754,20 +2778,20 @@ const na = (e) => {
|
|
|
2754
2778
|
return null;
|
|
2755
2779
|
}, A = (m = s.value) => {
|
|
2756
2780
|
if (m)
|
|
2757
|
-
return typeof m == "string" ? m : Ue(m) ? C(m) :
|
|
2781
|
+
return typeof m == "string" ? m : Ue(m) ? C(m) : Te(m);
|
|
2758
2782
|
}, b = (m = s.value) => {
|
|
2759
2783
|
const p = A(m);
|
|
2760
2784
|
if (!p)
|
|
2761
2785
|
return null;
|
|
2762
|
-
const k =
|
|
2786
|
+
const k = h.value[p] ?? p;
|
|
2763
2787
|
return i.value[k] ?? null;
|
|
2764
2788
|
}, j = (m = s.value) => {
|
|
2765
2789
|
const p = A(m);
|
|
2766
2790
|
if (p)
|
|
2767
|
-
return
|
|
2791
|
+
return h.value[p] ?? p;
|
|
2768
2792
|
}, C = (m = s.value) => {
|
|
2769
2793
|
if (m)
|
|
2770
|
-
return typeof m == "string" ? m : Ue(m) ? m.setId ?? m.infSetId ?? m.key :
|
|
2794
|
+
return typeof m == "string" ? m : Ue(m) ? m.setId ?? m.infSetId ?? m.key : Te(m);
|
|
2771
2795
|
}, N = (m = s.value) => {
|
|
2772
2796
|
if (Ue(m))
|
|
2773
2797
|
return m;
|
|
@@ -2776,17 +2800,17 @@ const na = (e) => {
|
|
|
2776
2800
|
if (p)
|
|
2777
2801
|
return p;
|
|
2778
2802
|
const k = b(m);
|
|
2779
|
-
return k?.ownerNodeKey ? y(c.value, k.ownerNodeKey) ??
|
|
2803
|
+
return k?.ownerNodeKey ? y(c.value, k.ownerNodeKey) ?? r.value : k || r.value && Xe(r.value).includes(m) ? r.value : null;
|
|
2780
2804
|
}
|
|
2781
|
-
return m?.ownerNodeKey ? y(c.value, m.ownerNodeKey) ??
|
|
2805
|
+
return m?.ownerNodeKey ? y(c.value, m.ownerNodeKey) ?? r.value : r.value;
|
|
2782
2806
|
}, re = (m = s.value) => !m || Ue(m) ? null : b(m), le = (m = s.value) => {
|
|
2783
2807
|
const p = C(m);
|
|
2784
2808
|
if (!p)
|
|
2785
2809
|
return Je();
|
|
2786
|
-
const k =
|
|
2810
|
+
const k = h.value[p] ?? p;
|
|
2787
2811
|
return Je({
|
|
2788
|
-
|
|
2789
|
-
|
|
2812
|
+
...I.value[p],
|
|
2813
|
+
...I.value[k],
|
|
2790
2814
|
// 编辑态始终从 editingSectionKeys 计算,避免状态对象过期。
|
|
2791
2815
|
editing: L.value.includes(
|
|
2792
2816
|
k
|
|
@@ -2794,20 +2818,20 @@ const na = (e) => {
|
|
|
2794
2818
|
});
|
|
2795
2819
|
}, R = (m, p) => {
|
|
2796
2820
|
const k = C(m);
|
|
2797
|
-
k && (
|
|
2798
|
-
|
|
2821
|
+
k && (I.value = {
|
|
2822
|
+
...I.value,
|
|
2799
2823
|
[k]: Je({
|
|
2800
2824
|
// 保留已有状态。
|
|
2801
|
-
|
|
2825
|
+
...I.value[k],
|
|
2802
2826
|
// 合并本次状态补丁。
|
|
2803
2827
|
...p,
|
|
2804
2828
|
// 编辑态仍以 editingSectionKeys 为准。
|
|
2805
2829
|
editing: L.value.includes(k)
|
|
2806
2830
|
})
|
|
2807
2831
|
});
|
|
2808
|
-
}, B = (m = a.value?.raw ?? null, p =
|
|
2832
|
+
}, B = (m = a.value?.raw ?? null, p = r.value) => {
|
|
2809
2833
|
const k = V.value, Y = s.value && k.find(
|
|
2810
|
-
(W) =>
|
|
2834
|
+
(W) => Te(W) === Te(s.value)
|
|
2811
2835
|
) ? s.value : null;
|
|
2812
2836
|
a.value = {
|
|
2813
2837
|
// 保留原 scheme。
|
|
@@ -2828,19 +2852,19 @@ const na = (e) => {
|
|
|
2828
2852
|
// 保留原始接口数据。
|
|
2829
2853
|
raw: m
|
|
2830
2854
|
}, s.value = Y;
|
|
2831
|
-
}, E = (m, p =
|
|
2855
|
+
}, E = (m, p = r.value, k) => {
|
|
2832
2856
|
const Y = Qr({
|
|
2833
2857
|
currentMap: i.value,
|
|
2834
|
-
currentAliasMap:
|
|
2835
|
-
currentOrder:
|
|
2836
|
-
currentStatusMap:
|
|
2858
|
+
currentAliasMap: h.value,
|
|
2859
|
+
currentOrder: S.value,
|
|
2860
|
+
currentStatusMap: I.value,
|
|
2837
2861
|
editingSectionKeys: L.value,
|
|
2838
2862
|
nextViewModel: m,
|
|
2839
2863
|
node: p,
|
|
2840
2864
|
targetKey: k,
|
|
2841
2865
|
activeSection: s.value
|
|
2842
2866
|
});
|
|
2843
|
-
return i.value = Y.sectionMap,
|
|
2867
|
+
return i.value = Y.sectionMap, h.value = Y.sectionAliasMap, S.value = Y.sectionOrder, I.value = Y.sectionStatusMap, a.value = {
|
|
2844
2868
|
...m,
|
|
2845
2869
|
scheme: m.scheme ?? a.value?.scheme ?? null,
|
|
2846
2870
|
topNodes: c.value,
|
|
@@ -2858,14 +2882,14 @@ const na = (e) => {
|
|
|
2858
2882
|
i.value = {
|
|
2859
2883
|
...i.value,
|
|
2860
2884
|
[k]: W
|
|
2861
|
-
}, s.value =
|
|
2862
|
-
}, u = async (m = s.value ??
|
|
2863
|
-
const p = re(m), k = N(m) ??
|
|
2885
|
+
}, s.value = Te(s.value ?? W) === k ? W : s.value, B();
|
|
2886
|
+
}, u = async (m = s.value ?? r.value) => {
|
|
2887
|
+
const p = re(m), k = N(m) ?? r.value, Y = C(m);
|
|
2864
2888
|
if (!k)
|
|
2865
2889
|
return null;
|
|
2866
2890
|
if (!e.service.requestOperation)
|
|
2867
2891
|
throw ze("service.requestOperation is required");
|
|
2868
|
-
n.value = !0,
|
|
2892
|
+
n.value = !0, l.value = null, R(Y ?? k, { loading: !0, error: null });
|
|
2869
2893
|
try {
|
|
2870
2894
|
const W = p ? [{ infSetId: p.infSetId, setId: p.setId, operationInfo: p.operationInfo, raw: p.raw }] : k.infSetList;
|
|
2871
2895
|
if (W.length === 0)
|
|
@@ -2879,7 +2903,7 @@ const na = (e) => {
|
|
|
2879
2903
|
operationInfo: ie.operationInfo
|
|
2880
2904
|
};
|
|
2881
2905
|
if (he) {
|
|
2882
|
-
const Ke = await
|
|
2906
|
+
const Ke = await g(he, {
|
|
2883
2907
|
type: "queryInfoSet",
|
|
2884
2908
|
requestSource: "inner",
|
|
2885
2909
|
tagId: Ae,
|
|
@@ -2897,22 +2921,22 @@ const na = (e) => {
|
|
|
2897
2921
|
};
|
|
2898
2922
|
return E(ve, k, Y);
|
|
2899
2923
|
} catch (W) {
|
|
2900
|
-
throw
|
|
2924
|
+
throw l.value = W, R(Y ?? k, { loading: !1, error: W }), W;
|
|
2901
2925
|
} finally {
|
|
2902
2926
|
n.value = !1, R(Y ?? k, { loading: !1 });
|
|
2903
2927
|
}
|
|
2904
|
-
},
|
|
2928
|
+
}, w = (m = s.value) => u(m), D = (m = s.value) => {
|
|
2905
2929
|
if (!m)
|
|
2906
2930
|
return null;
|
|
2907
2931
|
if (!Ue(m) && typeof m != "string")
|
|
2908
2932
|
return b(m);
|
|
2909
2933
|
const p = C(m);
|
|
2910
|
-
return p ? i.value[
|
|
2911
|
-
}, P = async (m =
|
|
2934
|
+
return p ? i.value[h.value[p] ?? p] ?? null : null;
|
|
2935
|
+
}, P = async (m = r.value) => m ? (await u(m), a.value) : (a.value = null, s.value = null, i.value = {}, h.value = {}, S.value = [], I.value = {}, null), x = async (m) => {
|
|
2912
2936
|
const p = Yr(m);
|
|
2913
2937
|
if (!p)
|
|
2914
2938
|
return m.children;
|
|
2915
|
-
const k =
|
|
2939
|
+
const k = M(m), Y = await g(p, {
|
|
2916
2940
|
type: "openTag",
|
|
2917
2941
|
requestSource: "sidebar",
|
|
2918
2942
|
tagId: m.tagId,
|
|
@@ -2927,14 +2951,14 @@ const na = (e) => {
|
|
|
2927
2951
|
return p.length > 0 && (c.value = Sn(c.value, m.key, p)), p;
|
|
2928
2952
|
}, q = async (m) => {
|
|
2929
2953
|
const p = typeof m == "string" ? y(c.value, m) : m;
|
|
2930
|
-
return p ? (
|
|
2954
|
+
return p ? (r.value = p, s.value = null, L.value = [], await K(p), B(a.value?.raw, p), p) : null;
|
|
2931
2955
|
}, Q = async () => {
|
|
2932
2956
|
const m = e.service.templateTree;
|
|
2933
2957
|
if (!m)
|
|
2934
2958
|
throw ze("service.templateTree is required");
|
|
2935
|
-
t.value = !0,
|
|
2959
|
+
t.value = !0, l.value = null;
|
|
2936
2960
|
try {
|
|
2937
|
-
const p = await m(
|
|
2961
|
+
const p = await m(_()), k = Nt(p), Y = await Promise.all(
|
|
2938
2962
|
k.treeNodes.map(async (Ce) => {
|
|
2939
2963
|
const ve = await x(Ce);
|
|
2940
2964
|
return {
|
|
@@ -2944,9 +2968,9 @@ const na = (e) => {
|
|
|
2944
2968
|
};
|
|
2945
2969
|
})
|
|
2946
2970
|
);
|
|
2947
|
-
c.value = Y, s.value = null, i.value = {},
|
|
2971
|
+
c.value = Y, s.value = null, i.value = {}, h.value = {}, S.value = [], I.value = {}, L.value = [];
|
|
2948
2972
|
const W = y(Y, e.initialActiveNodeKey) ?? y(Y);
|
|
2949
|
-
return
|
|
2973
|
+
return r.value = W, a.value = {
|
|
2950
2974
|
...k,
|
|
2951
2975
|
treeNodes: Y,
|
|
2952
2976
|
activeNode: W,
|
|
@@ -2954,15 +2978,15 @@ const na = (e) => {
|
|
|
2954
2978
|
sections: V.value
|
|
2955
2979
|
}, c.value;
|
|
2956
2980
|
} catch (p) {
|
|
2957
|
-
throw
|
|
2981
|
+
throw l.value = p, p;
|
|
2958
2982
|
} finally {
|
|
2959
2983
|
t.value = !1;
|
|
2960
2984
|
}
|
|
2961
|
-
},
|
|
2985
|
+
}, T = async () => {
|
|
2962
2986
|
const m = A();
|
|
2963
|
-
await
|
|
2987
|
+
await w(s.value ?? r.value);
|
|
2964
2988
|
const p = V.value.find(
|
|
2965
|
-
(k) =>
|
|
2989
|
+
(k) => Te(k) === m
|
|
2966
2990
|
);
|
|
2967
2991
|
return p && (s.value = p), B(), a.value;
|
|
2968
2992
|
}, X = (m = s.value) => {
|
|
@@ -3035,7 +3059,7 @@ const na = (e) => {
|
|
|
3035
3059
|
node: N(W),
|
|
3036
3060
|
section: W,
|
|
3037
3061
|
field: ie,
|
|
3038
|
-
params:
|
|
3062
|
+
params: Me(Ke.params),
|
|
3039
3063
|
// searchText 参与本次查询时,需要一并透传到 model 上,避免被依赖检查视为缺失并提前截断请求。
|
|
3040
3064
|
model: he,
|
|
3041
3065
|
row: Ae,
|
|
@@ -3079,11 +3103,11 @@ const na = (e) => {
|
|
|
3079
3103
|
// 加载当前节点详情。
|
|
3080
3104
|
loadDetail: P,
|
|
3081
3105
|
// 刷新当前详情。
|
|
3082
|
-
reloadActiveSection:
|
|
3106
|
+
reloadActiveSection: T,
|
|
3083
3107
|
// 加载指定节点或 section。
|
|
3084
3108
|
loadSection: u,
|
|
3085
3109
|
// 重新加载指定节点或 section。
|
|
3086
|
-
reloadSection:
|
|
3110
|
+
reloadSection: w,
|
|
3087
3111
|
// 获取指定节点或 section 的缓存数据。
|
|
3088
3112
|
getSection: D,
|
|
3089
3113
|
// 获取指定节点或 section 的状态。
|
|
@@ -3120,12 +3144,12 @@ const na = (e) => {
|
|
|
3120
3144
|
const Y = Hr(k);
|
|
3121
3145
|
if (!Y)
|
|
3122
3146
|
throw ze("section.operationInfo.editInfoSet is required");
|
|
3123
|
-
o.value = !0,
|
|
3147
|
+
o.value = !0, l.value = null, p && p !== Te(k) && R(p, { saving: !0, error: null }), R(k, { saving: !0, error: null });
|
|
3124
3148
|
try {
|
|
3125
3149
|
const {
|
|
3126
3150
|
tagId: W,
|
|
3127
3151
|
...Ce
|
|
3128
|
-
} = z(
|
|
3152
|
+
} = z(r.value, k), ve = kr(k, Ce), ie = Xr(
|
|
3129
3153
|
k,
|
|
3130
3154
|
ve.infSetValues ?? [],
|
|
3131
3155
|
{
|
|
@@ -3134,24 +3158,24 @@ const na = (e) => {
|
|
|
3134
3158
|
);
|
|
3135
3159
|
if (ie)
|
|
3136
3160
|
throw new Error(ie);
|
|
3137
|
-
const he = await
|
|
3161
|
+
const he = await g(
|
|
3138
3162
|
// 保存时保留后端给的 method/url,但不再把 editOperation.params 混入实际提交数据。
|
|
3139
3163
|
Y,
|
|
3140
3164
|
{
|
|
3141
3165
|
type: "editInfoSet",
|
|
3142
3166
|
requestSource: "inner",
|
|
3143
3167
|
tagId: k.requestTagId ?? k.tagId,
|
|
3144
|
-
node:
|
|
3168
|
+
node: r.value,
|
|
3145
3169
|
section: k,
|
|
3146
3170
|
params: ve,
|
|
3147
3171
|
model: k.model
|
|
3148
3172
|
}
|
|
3149
3173
|
);
|
|
3150
|
-
return de(k), await
|
|
3174
|
+
return de(k), await w(k), he;
|
|
3151
3175
|
} catch (W) {
|
|
3152
|
-
throw
|
|
3176
|
+
throw l.value = W, p && p !== Te(k) && R(p, { saving: !1, error: W }), R(k, { saving: !1, error: W }), W;
|
|
3153
3177
|
} finally {
|
|
3154
|
-
o.value = !1, p && p !==
|
|
3178
|
+
o.value = !1, p && p !== Te(k) && R(p, { saving: !1 }), R(k, { saving: !1 });
|
|
3155
3179
|
}
|
|
3156
3180
|
},
|
|
3157
3181
|
// 判断编辑态。
|
|
@@ -3175,9 +3199,9 @@ const na = (e) => {
|
|
|
3175
3199
|
// 当前 section 缓存。
|
|
3176
3200
|
sectionMap: i,
|
|
3177
3201
|
// 当前 section 状态缓存。
|
|
3178
|
-
sectionStatusMap:
|
|
3202
|
+
sectionStatusMap: I,
|
|
3179
3203
|
// 当前激活节点。
|
|
3180
|
-
activeNode:
|
|
3204
|
+
activeNode: r,
|
|
3181
3205
|
// 当前激活 section。
|
|
3182
3206
|
activeSection: s,
|
|
3183
3207
|
// 给页面消费的状态快照。
|
|
@@ -3198,13 +3222,13 @@ const na = (e) => {
|
|
|
3198
3222
|
formatOperationParams: {}
|
|
3199
3223
|
},
|
|
3200
3224
|
setup(e) {
|
|
3201
|
-
const t = e, n = na(t), { viewModel: o, nodes:
|
|
3202
|
-
return (
|
|
3225
|
+
const t = e, n = na(t), { viewModel: o, nodes: l, sections: c, activeNode: a, activeSection: r, state: s, actions: i } = n;
|
|
3226
|
+
return (h, S) => te(h.$slots, "default", Oe(Be({
|
|
3203
3227
|
viewModel: J(o),
|
|
3204
|
-
nodes: J(
|
|
3228
|
+
nodes: J(l),
|
|
3205
3229
|
sections: J(c),
|
|
3206
3230
|
activeNode: J(a),
|
|
3207
|
-
activeSection: J(
|
|
3231
|
+
activeSection: J(r),
|
|
3208
3232
|
state: J(s),
|
|
3209
3233
|
actions: J(i),
|
|
3210
3234
|
renderConfig: t.renderConfig
|
|
@@ -3251,23 +3275,23 @@ const oa = {
|
|
|
3251
3275
|
},
|
|
3252
3276
|
emits: ["update:modelValue", "change", "loadOptions"],
|
|
3253
3277
|
setup(e, { emit: t }) {
|
|
3254
|
-
const n = e, o = t,
|
|
3278
|
+
const n = e, o = t, l = [
|
|
3255
3279
|
"textarea",
|
|
3256
3280
|
"html",
|
|
3257
3281
|
"code",
|
|
3258
3282
|
"multi-row"
|
|
3259
3283
|
], c = ge(null), a = O(
|
|
3260
3284
|
() => kt(n.field)
|
|
3261
|
-
),
|
|
3285
|
+
), r = O(
|
|
3262
3286
|
() => ut(n.field)
|
|
3263
3287
|
), s = O(
|
|
3264
3288
|
() => dr(n.field)
|
|
3265
3289
|
), i = O(
|
|
3266
3290
|
() => n.disabled || n.field.disabled || n.field.readonly
|
|
3267
|
-
),
|
|
3291
|
+
), h = O(() => !!n.field.props?.multiple), S = O(
|
|
3268
3292
|
() => n.modelValue === void 0 || n.modelValue === null ? "" : String(n.modelValue)
|
|
3269
|
-
),
|
|
3270
|
-
() =>
|
|
3293
|
+
), I = O(
|
|
3294
|
+
() => l.includes(a.value) ? n.field.props?.resize ?? "vertical" : void 0
|
|
3271
3295
|
), L = O(() => {
|
|
3272
3296
|
if (n.modelValue === void 0 || n.modelValue === null || n.modelValue === "")
|
|
3273
3297
|
return;
|
|
@@ -3280,18 +3304,18 @@ const oa = {
|
|
|
3280
3304
|
...u,
|
|
3281
3305
|
value: j(u)
|
|
3282
3306
|
}))
|
|
3283
|
-
),
|
|
3307
|
+
), _ = O(() => {
|
|
3284
3308
|
const u = n.field.props?.popperClass ?? n.field.props?.["popper-class"];
|
|
3285
3309
|
return s.value ? [u, "global-info-field-control__descr-popper"].filter(Boolean).join(" ") : u;
|
|
3286
|
-
}),
|
|
3310
|
+
}), M = O(
|
|
3287
3311
|
() => (
|
|
3288
3312
|
// select_remote_descr 的浮层样式受业务沙箱前缀约束,默认留在当前应用容器内,避免 teleport 到 body 后样式失效。
|
|
3289
3313
|
s.value ? !1 : n.field.props?.teleported
|
|
3290
3314
|
)
|
|
3291
3315
|
), z = O(() => {
|
|
3292
|
-
const u = n.field.props?.activeValue ?? n.field.props?.["active-value"],
|
|
3293
|
-
return u !== void 0 ||
|
|
3294
|
-
}),
|
|
3316
|
+
const u = n.field.props?.activeValue ?? n.field.props?.["active-value"], w = n.field.props?.inactiveValue ?? n.field.props?.["inactive-value"];
|
|
3317
|
+
return u !== void 0 || w !== void 0 ? n.modelValue ?? w ?? !1 : vn(n.modelValue);
|
|
3318
|
+
}), g = O(() => a.value === "code" ? 5 : 1), v = O(
|
|
3295
3319
|
() => a.value === "file" && !_e(n.modelValue)
|
|
3296
3320
|
), F = O(
|
|
3297
3321
|
() => mn(
|
|
@@ -3305,14 +3329,14 @@ const oa = {
|
|
|
3305
3329
|
n.modelValue,
|
|
3306
3330
|
Z("common.请选择文件")
|
|
3307
3331
|
)
|
|
3308
|
-
), A = O(() => n.field.placeholder ? n.field.placeholder :
|
|
3332
|
+
), A = O(() => n.field.placeholder ? n.field.placeholder : r.value ? Z("common.请输入关键词") : a.value === "select" ? Z("common.请选择") : a.value === "date" ? Z("common.请选择日期") : a.value === "file" ? Z("common.请选择文件") : Z("common.请输入"));
|
|
3309
3333
|
let b;
|
|
3310
3334
|
function j(u) {
|
|
3311
3335
|
if (Array.isArray(V.value)) {
|
|
3312
|
-
const
|
|
3336
|
+
const w = V.value.find(
|
|
3313
3337
|
(D) => Ze(u, D)
|
|
3314
3338
|
);
|
|
3315
|
-
if (
|
|
3339
|
+
if (w !== void 0) return w;
|
|
3316
3340
|
}
|
|
3317
3341
|
return Ze(u, V.value) ? V.value : u.value;
|
|
3318
3342
|
}
|
|
@@ -3326,10 +3350,10 @@ const oa = {
|
|
|
3326
3350
|
return a.value === "select" || a.value === "select_remote" ? pr(n.field, u) : u;
|
|
3327
3351
|
}
|
|
3328
3352
|
function le(u) {
|
|
3329
|
-
u && o("loadOptions",
|
|
3353
|
+
u && o("loadOptions", r.value ? { searchText: "" } : void 0);
|
|
3330
3354
|
}
|
|
3331
3355
|
function R(u) {
|
|
3332
|
-
|
|
3356
|
+
r.value && (b && clearTimeout(b), b = setTimeout(() => {
|
|
3333
3357
|
o("loadOptions", { searchText: u });
|
|
3334
3358
|
}, 300));
|
|
3335
3359
|
}
|
|
@@ -3343,48 +3367,48 @@ const oa = {
|
|
|
3343
3367
|
b && clearTimeout(b);
|
|
3344
3368
|
});
|
|
3345
3369
|
function d(u) {
|
|
3346
|
-
const
|
|
3370
|
+
const w = u.target, D = Array.from(w.files ?? []), P = n.field.props?.multiple ? D : D[0] ?? null;
|
|
3347
3371
|
C(P), N(P);
|
|
3348
3372
|
}
|
|
3349
|
-
return (u,
|
|
3373
|
+
return (u, w) => {
|
|
3350
3374
|
const D = Xt, P = Qt, x = Wt, K = ao, q = so, Q = Zt;
|
|
3351
|
-
return a.value === "select" || a.value === "select_remote" ? (
|
|
3375
|
+
return a.value === "select" || a.value === "select_remote" ? ($(), H(P, ae({
|
|
3352
3376
|
key: 0,
|
|
3353
3377
|
class: "global-info-field-control"
|
|
3354
3378
|
}, u.field.props, {
|
|
3355
|
-
"popper-class":
|
|
3356
|
-
teleported:
|
|
3379
|
+
"popper-class": _.value,
|
|
3380
|
+
teleported: M.value,
|
|
3357
3381
|
"model-value": V.value,
|
|
3358
3382
|
placeholder: A.value,
|
|
3359
3383
|
disabled: i.value,
|
|
3360
|
-
"collapse-tags":
|
|
3361
|
-
"collapse-tags-tooltip":
|
|
3384
|
+
"collapse-tags": h.value,
|
|
3385
|
+
"collapse-tags-tooltip": h.value,
|
|
3362
3386
|
"max-collapse-tags": 1,
|
|
3363
|
-
filterable:
|
|
3364
|
-
remote:
|
|
3365
|
-
"remote-method":
|
|
3387
|
+
filterable: r.value || !!u.field.props?.filterable,
|
|
3388
|
+
remote: r.value || !!u.field.props?.remote,
|
|
3389
|
+
"remote-method": r.value ? R : u.field.props?.remoteMethod,
|
|
3366
3390
|
clearable: "",
|
|
3367
3391
|
onVisibleChange: le,
|
|
3368
3392
|
"onUpdate:modelValue": C,
|
|
3369
3393
|
onChange: N
|
|
3370
3394
|
}), {
|
|
3371
3395
|
default: U(() => [
|
|
3372
|
-
(
|
|
3373
|
-
key: String(
|
|
3374
|
-
label:
|
|
3375
|
-
value:
|
|
3396
|
+
($(!0), G(Se, null, ye(f.value, (T) => ($(), H(D, {
|
|
3397
|
+
key: String(T.value),
|
|
3398
|
+
label: T.label,
|
|
3399
|
+
value: T.value
|
|
3376
3400
|
}, {
|
|
3377
3401
|
default: U(() => [
|
|
3378
|
-
s.value ? (
|
|
3379
|
-
ne("div", ra, oe(
|
|
3380
|
-
|
|
3402
|
+
s.value ? ($(), G("div", oa, [
|
|
3403
|
+
ne("div", ra, oe(T.label), 1),
|
|
3404
|
+
T.labelDescr ? ($(), G("div", aa, oe(T.labelDescr), 1)) : fe("", !0)
|
|
3381
3405
|
])) : fe("", !0)
|
|
3382
3406
|
]),
|
|
3383
3407
|
_: 2
|
|
3384
3408
|
}, 1032, ["label", "value"]))), 128))
|
|
3385
3409
|
]),
|
|
3386
3410
|
_: 1
|
|
3387
|
-
}, 16, ["popper-class", "teleported", "model-value", "placeholder", "disabled", "collapse-tags", "collapse-tags-tooltip", "filterable", "remote", "remote-method"])) : a.value === "date" ? (
|
|
3411
|
+
}, 16, ["popper-class", "teleported", "model-value", "placeholder", "disabled", "collapse-tags", "collapse-tags-tooltip", "filterable", "remote", "remote-method"])) : a.value === "date" ? ($(), H(x, ae({
|
|
3388
3412
|
key: 1,
|
|
3389
3413
|
class: "global-info-field-control"
|
|
3390
3414
|
}, u.field.props, {
|
|
@@ -3395,7 +3419,7 @@ const oa = {
|
|
|
3395
3419
|
"value-format": "YYYY-MM-DD",
|
|
3396
3420
|
"onUpdate:modelValue": C,
|
|
3397
3421
|
onChange: N
|
|
3398
|
-
}), null, 16, ["model-value", "placeholder", "disabled"])) : a.value === "number" ? (
|
|
3422
|
+
}), null, 16, ["model-value", "placeholder", "disabled"])) : a.value === "number" ? ($(), H(K, ae({
|
|
3399
3423
|
key: 2,
|
|
3400
3424
|
class: "global-info-field-control"
|
|
3401
3425
|
}, u.field.props, {
|
|
@@ -3405,7 +3429,7 @@ const oa = {
|
|
|
3405
3429
|
"controls-position": "right",
|
|
3406
3430
|
"onUpdate:modelValue": C,
|
|
3407
3431
|
onChange: N
|
|
3408
|
-
}), null, 16, ["model-value", "placeholder", "disabled"])) : a.value === "switch" ? (
|
|
3432
|
+
}), null, 16, ["model-value", "placeholder", "disabled"])) : a.value === "switch" ? ($(), H(q, ae({
|
|
3409
3433
|
key: 3,
|
|
3410
3434
|
class: "global-info-field-control global-info-field-control--switch"
|
|
3411
3435
|
}, u.field.props, {
|
|
@@ -3413,7 +3437,7 @@ const oa = {
|
|
|
3413
3437
|
disabled: i.value,
|
|
3414
3438
|
"onUpdate:modelValue": C,
|
|
3415
3439
|
onChange: N
|
|
3416
|
-
}), null, 16, ["model-value", "disabled"])) : a.value === "file" ? (
|
|
3440
|
+
}), null, 16, ["model-value", "disabled"])) : a.value === "file" ? ($(), G("div", {
|
|
3417
3441
|
key: 4,
|
|
3418
3442
|
class: We(["global-info-field-control global-info-field-control--file", {
|
|
3419
3443
|
"is-disabled": i.value,
|
|
@@ -3432,44 +3456,44 @@ const oa = {
|
|
|
3432
3456
|
multiple: !!u.field.props?.multiple,
|
|
3433
3457
|
onChange: d
|
|
3434
3458
|
}, null, 40, sa),
|
|
3435
|
-
y.value.length ? (
|
|
3436
|
-
(
|
|
3437
|
-
key:
|
|
3459
|
+
y.value.length ? ($(), G("span", la, [
|
|
3460
|
+
($(!0), G(Se, null, ye(y.value, (T, X) => ($(), G(Se, {
|
|
3461
|
+
key: T.key
|
|
3438
3462
|
}, [
|
|
3439
|
-
|
|
3463
|
+
T.action ? ($(), G("button", {
|
|
3440
3464
|
key: 0,
|
|
3441
3465
|
class: "global-info-field-control__file-preview",
|
|
3442
3466
|
type: "button",
|
|
3443
|
-
onClick: Ut((ue) => E(
|
|
3444
|
-
}, oe(
|
|
3445
|
-
X < y.value.length - 1 ? (
|
|
3467
|
+
onClick: Ut((ue) => E(T), ["stop", "prevent"])
|
|
3468
|
+
}, oe(T.text), 9, ia)) : ($(), G("span", ca, oe(T.text), 1)),
|
|
3469
|
+
X < y.value.length - 1 ? ($(), G("span", ua, "、")) : fe("", !0)
|
|
3446
3470
|
], 64))), 128))
|
|
3447
|
-
])) : v.value ? (
|
|
3448
|
-
], 2)) : a.value === "empty" ? (
|
|
3471
|
+
])) : v.value ? ($(), G("span", da, oe(F.value), 1)) : ($(), G("span", fa, oe(J(Z)("common.上传")), 1))
|
|
3472
|
+
], 2)) : a.value === "empty" ? ($(), H(Q, {
|
|
3449
3473
|
key: 5,
|
|
3450
3474
|
class: "global-info-field-control",
|
|
3451
3475
|
"model-value": "",
|
|
3452
3476
|
disabled: "",
|
|
3453
3477
|
placeholder: "-"
|
|
3454
|
-
})) : (
|
|
3478
|
+
})) : ($(), H(Q, ae({
|
|
3455
3479
|
key: 6,
|
|
3456
3480
|
class: ["global-info-field-control", {
|
|
3457
|
-
"global-info-field-control--textarea":
|
|
3481
|
+
"global-info-field-control--textarea": l.includes(a.value),
|
|
3458
3482
|
"global-info-field-control--code": a.value === "code"
|
|
3459
3483
|
}]
|
|
3460
3484
|
}, u.field.props, {
|
|
3461
|
-
"model-value":
|
|
3485
|
+
"model-value": S.value,
|
|
3462
3486
|
placeholder: A.value,
|
|
3463
3487
|
disabled: i.value,
|
|
3464
|
-
type:
|
|
3465
|
-
rows:
|
|
3466
|
-
resize:
|
|
3488
|
+
type: l.includes(a.value) ? "textarea" : "text",
|
|
3489
|
+
rows: l.includes(a.value) ? g.value : void 0,
|
|
3490
|
+
resize: I.value,
|
|
3467
3491
|
"onUpdate:modelValue": C,
|
|
3468
3492
|
onChange: N
|
|
3469
3493
|
}), null, 16, ["class", "model-value", "placeholder", "disabled", "type", "rows", "resize"]));
|
|
3470
3494
|
};
|
|
3471
3495
|
}
|
|
3472
|
-
}), Vn = /* @__PURE__ */ be(pa, [["__scopeId", "data-v-
|
|
3496
|
+
}), Vn = /* @__PURE__ */ be(pa, [["__scopeId", "data-v-fb0f2f9b"]]), ma = ["innerHTML"], va = {
|
|
3473
3497
|
key: 1,
|
|
3474
3498
|
class: "global-info-field-value global-info-field-value--code"
|
|
3475
3499
|
}, ha = {
|
|
@@ -3484,42 +3508,42 @@ const oa = {
|
|
|
3484
3508
|
emptyText: { default: "-" }
|
|
3485
3509
|
},
|
|
3486
3510
|
setup(e) {
|
|
3487
|
-
const t = e, n = O(() =>
|
|
3488
|
-
function a(
|
|
3489
|
-
Pn(
|
|
3511
|
+
const t = e, n = O(() => Mt(t.field)), o = O(() => n.value === "empty" || _e(t.value)), l = O(() => mn(t.field, t.value, t.emptyText)), c = O(() => hn(t.field, t.value, t.emptyText));
|
|
3512
|
+
function a(r) {
|
|
3513
|
+
Pn(r);
|
|
3490
3514
|
}
|
|
3491
|
-
return (
|
|
3515
|
+
return (r, s) => n.value === "html" && !o.value ? ($(), G("span", {
|
|
3492
3516
|
key: 0,
|
|
3493
3517
|
class: "global-info-field-value global-info-field-value--html",
|
|
3494
|
-
innerHTML:
|
|
3495
|
-
}, null, 8, ma)) : n.value === "code" && !o.value ? (
|
|
3496
|
-
(
|
|
3518
|
+
innerHTML: l.value
|
|
3519
|
+
}, null, 8, ma)) : n.value === "code" && !o.value ? ($(), G("pre", va, oe(l.value), 1)) : c.value.length ? ($(), G("span", ha, [
|
|
3520
|
+
($(!0), G(Se, null, ye(c.value, (i, h) => ($(), G(Se, {
|
|
3497
3521
|
key: i.key
|
|
3498
3522
|
}, [
|
|
3499
|
-
i.action ? (
|
|
3523
|
+
i.action ? ($(), G("button", {
|
|
3500
3524
|
key: 0,
|
|
3501
3525
|
class: "global-info-field-value__attachment-preview",
|
|
3502
3526
|
type: "button",
|
|
3503
|
-
onClick: (
|
|
3504
|
-
}, oe(i.text), 9, ga)) : (
|
|
3505
|
-
|
|
3527
|
+
onClick: (S) => a(i)
|
|
3528
|
+
}, oe(i.text), 9, ga)) : ($(), G("span", ya, oe(i.text), 1)),
|
|
3529
|
+
h < c.value.length - 1 ? ($(), G("span", ba, "、")) : fe("", !0)
|
|
3506
3530
|
], 64))), 128))
|
|
3507
|
-
])) : (
|
|
3531
|
+
])) : ($(), G("span", {
|
|
3508
3532
|
key: 3,
|
|
3509
3533
|
class: We(["global-info-field-value", {
|
|
3510
3534
|
"global-info-field-value--multi-row": n.value === "multi-row",
|
|
3511
3535
|
"global-info-field-value--file": n.value === "file" && !o.value
|
|
3512
3536
|
}])
|
|
3513
|
-
}, oe(
|
|
3537
|
+
}, oe(l.value), 3));
|
|
3514
3538
|
}
|
|
3515
|
-
}), jn = /* @__PURE__ */ be(Sa, [["__scopeId", "data-v-
|
|
3539
|
+
}), jn = /* @__PURE__ */ be(Sa, [["__scopeId", "data-v-671a4fb5"]]);
|
|
3516
3540
|
function _a(e) {
|
|
3517
3541
|
const t = kt(e);
|
|
3518
3542
|
return (t === "select" || t === "select_remote") && !!e.interface;
|
|
3519
3543
|
}
|
|
3520
3544
|
function st(e, t, n = {}, o = "") {
|
|
3521
|
-
const
|
|
3522
|
-
return [e, o,
|
|
3545
|
+
const l = t.key || t.id || t.code, a = Ne(t).map((r) => `${r}:${String(n[r] ?? "")}`).join("|");
|
|
3546
|
+
return [e, o, l, a].join("::");
|
|
3523
3547
|
}
|
|
3524
3548
|
function lt(e, t, n) {
|
|
3525
3549
|
return Array.isArray(e.options) && e.options.length > 0 ? t === n ? !0 : !t && Ne(e).length === 0 : !1;
|
|
@@ -3561,16 +3585,16 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3561
3585
|
renderConfig: {}
|
|
3562
3586
|
},
|
|
3563
3587
|
setup(e) {
|
|
3564
|
-
const t = e, n = Le(), o = O(() => t.model ?? t.section.model),
|
|
3588
|
+
const t = e, n = Le(), o = O(() => t.model ?? t.section.model), l = /* @__PURE__ */ new Map(), c = O(() => ft(
|
|
3565
3589
|
t.section.fields,
|
|
3566
3590
|
t.section,
|
|
3567
3591
|
t.renderConfig,
|
|
3568
3592
|
{ values: o.value }
|
|
3569
3593
|
)), a = ln(
|
|
3570
3594
|
async (v, F, y) => t.actions.loadFieldOptions(t.section, v, F, y),
|
|
3571
|
-
(v) => `${t.section.key}:${
|
|
3595
|
+
(v) => `${t.section.key}:${M(v)}`
|
|
3572
3596
|
);
|
|
3573
|
-
function
|
|
3597
|
+
function r(v, F) {
|
|
3574
3598
|
const y = { ...o.value, [v.code]: F };
|
|
3575
3599
|
(v.cascadeClearFields ?? []).forEach((A) => {
|
|
3576
3600
|
y[A] = "";
|
|
@@ -3588,8 +3612,8 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3588
3612
|
values: y,
|
|
3589
3613
|
node: t.node,
|
|
3590
3614
|
activeNode: t.node,
|
|
3591
|
-
sections:
|
|
3592
|
-
sectionValues:
|
|
3615
|
+
sections: h(),
|
|
3616
|
+
sectionValues: S(t.section, y),
|
|
3593
3617
|
actions: t.actions,
|
|
3594
3618
|
selectedOption: b[0],
|
|
3595
3619
|
selectedOptions: b
|
|
@@ -3605,20 +3629,20 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3605
3629
|
const y = dt(v, F);
|
|
3606
3630
|
return (v.options ?? []).filter((A) => y.some((b) => Ze(A, b)));
|
|
3607
3631
|
}
|
|
3608
|
-
function
|
|
3632
|
+
function h() {
|
|
3609
3633
|
return Object.values(t.state.sectionMap);
|
|
3610
3634
|
}
|
|
3611
|
-
function
|
|
3612
|
-
const A =
|
|
3635
|
+
function S(v, F) {
|
|
3636
|
+
const A = h().flatMap((b) => {
|
|
3613
3637
|
const j = b.key === v.key ? F : b.renderType === "table" ? b.rows : b.model;
|
|
3614
3638
|
return [b.key, b.id, b.setId, b.infSetId, b.code].filter(Boolean).map((C) => [String(C), j]);
|
|
3615
3639
|
});
|
|
3616
3640
|
return Object.fromEntries(A);
|
|
3617
3641
|
}
|
|
3618
|
-
async function
|
|
3619
|
-
const A = y, b =
|
|
3642
|
+
async function I(v, F = {}, y = o.value) {
|
|
3643
|
+
const A = y, b = M(v), j = st(t.section.key, v, A), C = l.get(b);
|
|
3620
3644
|
if (!An(F) && lt(v, C, j)) {
|
|
3621
|
-
|
|
3645
|
+
l.set(b, j);
|
|
3622
3646
|
return;
|
|
3623
3647
|
}
|
|
3624
3648
|
try {
|
|
@@ -3626,7 +3650,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3626
3650
|
await a(v, A, F);
|
|
3627
3651
|
return;
|
|
3628
3652
|
}
|
|
3629
|
-
await t.actions.loadFieldOptions(t.section, v, A, F),
|
|
3653
|
+
await t.actions.loadFieldOptions(t.section, v, A, F), l.set(b, j);
|
|
3630
3654
|
} catch (re) {
|
|
3631
3655
|
console.error("[GlobalInfoFormRenderer] load field options failed", re);
|
|
3632
3656
|
}
|
|
@@ -3636,18 +3660,18 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3636
3660
|
if (F && !Rn(y, F)) continue;
|
|
3637
3661
|
const A = Nn(y, v);
|
|
3638
3662
|
if (!z(y, A)) continue;
|
|
3639
|
-
const b = st(t.section.key, y, v), j =
|
|
3663
|
+
const b = st(t.section.key, y, v), j = M(y), C = l.get(j);
|
|
3640
3664
|
if (lt(y, C, b)) {
|
|
3641
|
-
|
|
3665
|
+
l.set(j, b);
|
|
3642
3666
|
continue;
|
|
3643
3667
|
}
|
|
3644
|
-
C !== b && await
|
|
3668
|
+
C !== b && await I(y, xn(y, A), v);
|
|
3645
3669
|
}
|
|
3646
3670
|
}
|
|
3647
3671
|
Ee(
|
|
3648
3672
|
() => t.section.key,
|
|
3649
3673
|
() => {
|
|
3650
|
-
|
|
3674
|
+
l.clear();
|
|
3651
3675
|
}
|
|
3652
3676
|
), Ee(
|
|
3653
3677
|
() => t.editing,
|
|
@@ -3668,7 +3692,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3668
3692
|
value: F,
|
|
3669
3693
|
state: t.state,
|
|
3670
3694
|
actions: t.actions,
|
|
3671
|
-
updateModelValue: (y) =>
|
|
3695
|
+
updateModelValue: (y) => r(v, y)
|
|
3672
3696
|
};
|
|
3673
3697
|
}
|
|
3674
3698
|
function f(v) {
|
|
@@ -3677,21 +3701,21 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3677
3701
|
const A = y.toLowerCase();
|
|
3678
3702
|
return A !== y && n[A] ? A : "";
|
|
3679
3703
|
}
|
|
3680
|
-
function
|
|
3704
|
+
function _(v) {
|
|
3681
3705
|
return v.span ? Math.min(Math.max(v.span, 1), 24) : 6;
|
|
3682
3706
|
}
|
|
3683
|
-
function
|
|
3707
|
+
function M(v) {
|
|
3684
3708
|
return v.key || v.id || v.code;
|
|
3685
3709
|
}
|
|
3686
3710
|
function z(v, F) {
|
|
3687
3711
|
return zn(v, F, t.editing);
|
|
3688
3712
|
}
|
|
3689
|
-
function
|
|
3713
|
+
function g(v) {
|
|
3690
3714
|
return v.required || v.isRequired;
|
|
3691
3715
|
}
|
|
3692
3716
|
return (v, F) => {
|
|
3693
3717
|
const y = en, A = io, b = lo, j = tn;
|
|
3694
|
-
return
|
|
3718
|
+
return $(), H(j, {
|
|
3695
3719
|
class: "global-info-form-renderer",
|
|
3696
3720
|
model: o.value,
|
|
3697
3721
|
"label-position": "top"
|
|
@@ -3699,9 +3723,9 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3699
3723
|
default: U(() => [
|
|
3700
3724
|
Ie(b, { gutter: 24 }, {
|
|
3701
3725
|
default: U(() => [
|
|
3702
|
-
(
|
|
3703
|
-
key:
|
|
3704
|
-
span:
|
|
3726
|
+
($(!0), G(Se, null, ye(c.value, (C) => ($(), H(A, {
|
|
3727
|
+
key: M(C),
|
|
3728
|
+
span: _(C)
|
|
3705
3729
|
}, {
|
|
3706
3730
|
default: U(() => [
|
|
3707
3731
|
Ie(y, ae({
|
|
@@ -3710,7 +3734,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3710
3734
|
}, C.formItemProps), {
|
|
3711
3735
|
label: U(() => [
|
|
3712
3736
|
ne("span", wa, [
|
|
3713
|
-
|
|
3737
|
+
g(C) ? ($(), G("span", Ia, "*")) : fe("", !0),
|
|
3714
3738
|
He(" " + oe(C.label), 1)
|
|
3715
3739
|
])
|
|
3716
3740
|
]),
|
|
@@ -3718,14 +3742,14 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3718
3742
|
f(C) ? te(v.$slots, f(C), ae({
|
|
3719
3743
|
key: 0,
|
|
3720
3744
|
ref_for: !0
|
|
3721
|
-
}, V(C)), void 0, !0) : v.editing && !C.readonly ? (
|
|
3745
|
+
}, V(C)), void 0, !0) : v.editing && !C.readonly ? ($(), H(Vn, {
|
|
3722
3746
|
key: 1,
|
|
3723
3747
|
field: C,
|
|
3724
3748
|
"model-value": o.value[C.code],
|
|
3725
3749
|
section: v.section,
|
|
3726
|
-
onLoadOptions: (N) =>
|
|
3727
|
-
"onUpdate:modelValue": (N) =>
|
|
3728
|
-
}, null, 8, ["field", "model-value", "section", "onLoadOptions", "onUpdate:modelValue"])) : (
|
|
3750
|
+
onLoadOptions: (N) => I(C, N),
|
|
3751
|
+
"onUpdate:modelValue": (N) => r(C, N)
|
|
3752
|
+
}, null, 8, ["field", "model-value", "section", "onLoadOptions", "onUpdate:modelValue"])) : ($(), H(jn, {
|
|
3729
3753
|
key: 2,
|
|
3730
3754
|
field: C,
|
|
3731
3755
|
value: o.value[C.code],
|
|
@@ -3745,7 +3769,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3745
3769
|
}, 8, ["model"]);
|
|
3746
3770
|
};
|
|
3747
3771
|
}
|
|
3748
|
-
}), Ca = /* @__PURE__ */ be($a, [["__scopeId", "data-v-
|
|
3772
|
+
}), Ca = /* @__PURE__ */ be($a, [["__scopeId", "data-v-45009469"]]), ka = /* @__PURE__ */ pe({
|
|
3749
3773
|
name: "GlobalInfoDeleteConfirm",
|
|
3750
3774
|
__name: "GlobalInfoDeleteConfirm",
|
|
3751
3775
|
props: {
|
|
@@ -3757,14 +3781,14 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3757
3781
|
setup(e) {
|
|
3758
3782
|
return (t, n) => {
|
|
3759
3783
|
const o = co;
|
|
3760
|
-
return
|
|
3784
|
+
return $(), H(o, {
|
|
3761
3785
|
title: t.title,
|
|
3762
3786
|
"confirm-button-text": t.confirmText,
|
|
3763
3787
|
"cancel-button-text": t.cancelText,
|
|
3764
3788
|
width: "240",
|
|
3765
3789
|
"popper-class": "global-info-delete-confirm",
|
|
3766
|
-
onConfirm: n[0] || (n[0] = (
|
|
3767
|
-
onCancel: n[1] || (n[1] = (
|
|
3790
|
+
onConfirm: n[0] || (n[0] = (l) => t.$emit("confirm")),
|
|
3791
|
+
onCancel: n[1] || (n[1] = (l) => t.$emit("cancel"))
|
|
3768
3792
|
}, {
|
|
3769
3793
|
reference: U(() => [
|
|
3770
3794
|
te(t.$slots, "default")
|
|
@@ -3773,7 +3797,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3773
3797
|
}, 8, ["title", "confirm-button-text", "cancel-button-text"]);
|
|
3774
3798
|
};
|
|
3775
3799
|
}
|
|
3776
|
-
}),
|
|
3800
|
+
}), Ma = { class: "global-info-table-renderer__table-scroll" }, Ta = { class: "global-info-table-renderer__header" }, Oa = {
|
|
3777
3801
|
key: 0,
|
|
3778
3802
|
class: "global-info-table-renderer__required"
|
|
3779
3803
|
}, Da = /* @__PURE__ */ pe({
|
|
@@ -3792,11 +3816,11 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3792
3816
|
setup(e) {
|
|
3793
3817
|
const t = e, n = Le(), o = O(
|
|
3794
3818
|
() => t.section.fields.some((d) => Vt(d))
|
|
3795
|
-
),
|
|
3819
|
+
), l = O(() => o.value), c = O(
|
|
3796
3820
|
() => t.renderConfig?.sequenceLabel ?? Z("common.序号")
|
|
3797
3821
|
), a = O(
|
|
3798
3822
|
() => t.renderConfig?.sequenceWidth ?? 56
|
|
3799
|
-
),
|
|
3823
|
+
), r = O(() => {
|
|
3800
3824
|
const d = t.renderConfig?.sequenceStart;
|
|
3801
3825
|
return typeof d == "number" && Number.isFinite(d) ? d : 1;
|
|
3802
3826
|
}), s = O(() => {
|
|
@@ -3806,17 +3830,17 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3806
3830
|
t.renderConfig,
|
|
3807
3831
|
{ rows: t.section.rows, values: t.section.model }
|
|
3808
3832
|
);
|
|
3809
|
-
return
|
|
3810
|
-
}), i = /* @__PURE__ */ new Map(),
|
|
3811
|
-
async (d, u,
|
|
3833
|
+
return l.value ? d.filter((u) => !re(u)) : d;
|
|
3834
|
+
}), i = /* @__PURE__ */ new Map(), h = ln(
|
|
3835
|
+
async (d, u, w) => t.actions.loadFieldOptions(t.section, d, u, w),
|
|
3812
3836
|
(d, u) => `${t.section.key}:${B(u)}:${C(d)}`
|
|
3813
3837
|
);
|
|
3814
|
-
function
|
|
3838
|
+
function S(d) {
|
|
3815
3839
|
t.actions.deleteRow(t.section, d);
|
|
3816
3840
|
}
|
|
3817
|
-
function
|
|
3818
|
-
const
|
|
3819
|
-
return t.showDelete && (typeof
|
|
3841
|
+
function I(d, u) {
|
|
3842
|
+
const w = t.renderConfig?.rowDeleteVisibleRule;
|
|
3843
|
+
return t.showDelete && (typeof w == "function" ? w({
|
|
3820
3844
|
section: t.section,
|
|
3821
3845
|
row: d,
|
|
3822
3846
|
rowIndex: u,
|
|
@@ -3825,43 +3849,43 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3825
3849
|
actions: t.actions
|
|
3826
3850
|
}) : d.allowDelete !== !1);
|
|
3827
3851
|
}
|
|
3828
|
-
function L(d, u,
|
|
3829
|
-
const P = t.section.rows.slice(), x =
|
|
3852
|
+
function L(d, u, w, D) {
|
|
3853
|
+
const P = t.section.rows.slice(), x = w.cascadeClearFields ?? [], K = {
|
|
3830
3854
|
...d,
|
|
3831
3855
|
__rowKey: B(d),
|
|
3832
|
-
[
|
|
3856
|
+
[w.code]: D
|
|
3833
3857
|
};
|
|
3834
3858
|
x.forEach((q) => {
|
|
3835
3859
|
K[q] = "";
|
|
3836
3860
|
}), P[u] = {
|
|
3837
3861
|
...K
|
|
3838
|
-
}, t.actions.updateTableRows(t.section, P), V(
|
|
3862
|
+
}, t.actions.updateTableRows(t.section, P), V(w, D, K, u, P), g(w, K);
|
|
3839
3863
|
}
|
|
3840
|
-
function V(d, u,
|
|
3864
|
+
function V(d, u, w, D, P) {
|
|
3841
3865
|
const x = t.renderConfig?.onFieldBusinessChange;
|
|
3842
3866
|
if (x)
|
|
3843
3867
|
try {
|
|
3844
|
-
const K = f(d, u), q = { ...t.section.model, ...
|
|
3868
|
+
const K = f(d, u), q = { ...t.section.model, ...w }, Q = {
|
|
3845
3869
|
field: d,
|
|
3846
3870
|
value: u,
|
|
3847
3871
|
section: t.section,
|
|
3848
3872
|
model: q,
|
|
3849
3873
|
values: q,
|
|
3850
|
-
row:
|
|
3874
|
+
row: w,
|
|
3851
3875
|
rowIndex: D,
|
|
3852
3876
|
rows: P,
|
|
3853
3877
|
node: t.node,
|
|
3854
3878
|
activeNode: t.node,
|
|
3855
|
-
sections:
|
|
3856
|
-
sectionValues:
|
|
3879
|
+
sections: _(),
|
|
3880
|
+
sectionValues: M(t.section, P),
|
|
3857
3881
|
actions: t.actions,
|
|
3858
3882
|
selectedOption: K[0],
|
|
3859
3883
|
selectedOptions: K
|
|
3860
3884
|
};
|
|
3861
|
-
Promise.resolve(x(Q)).catch((
|
|
3885
|
+
Promise.resolve(x(Q)).catch((T) => {
|
|
3862
3886
|
console.error(
|
|
3863
3887
|
"[GlobalInfoTableRenderer] field business change failed",
|
|
3864
|
-
|
|
3888
|
+
T
|
|
3865
3889
|
);
|
|
3866
3890
|
});
|
|
3867
3891
|
} catch (K) {
|
|
@@ -3872,16 +3896,16 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3872
3896
|
}
|
|
3873
3897
|
}
|
|
3874
3898
|
function f(d, u) {
|
|
3875
|
-
const
|
|
3899
|
+
const w = dt(d, u);
|
|
3876
3900
|
return (d.options ?? []).filter(
|
|
3877
|
-
(D) =>
|
|
3901
|
+
(D) => w.some((P) => Ze(D, P))
|
|
3878
3902
|
);
|
|
3879
3903
|
}
|
|
3880
|
-
function
|
|
3904
|
+
function _() {
|
|
3881
3905
|
return Object.values(t.state.sectionMap);
|
|
3882
3906
|
}
|
|
3883
|
-
function
|
|
3884
|
-
const D =
|
|
3907
|
+
function M(d, u) {
|
|
3908
|
+
const D = _().flatMap((P) => {
|
|
3885
3909
|
const x = P.key === d.key ? u : P.renderType === "table" ? P.rows : P.model;
|
|
3886
3910
|
return [
|
|
3887
3911
|
P.key,
|
|
@@ -3893,35 +3917,35 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3893
3917
|
});
|
|
3894
3918
|
return Object.fromEntries(D);
|
|
3895
3919
|
}
|
|
3896
|
-
async function z(d, u,
|
|
3920
|
+
async function z(d, u, w = {}, D = u) {
|
|
3897
3921
|
const P = B(D), x = `${P}:${C(d)}`, K = st(
|
|
3898
3922
|
t.section.key,
|
|
3899
3923
|
d,
|
|
3900
3924
|
D,
|
|
3901
3925
|
P
|
|
3902
3926
|
), q = i.get(x);
|
|
3903
|
-
if (!An(
|
|
3927
|
+
if (!An(w) && lt(d, q, K)) {
|
|
3904
3928
|
i.set(x, K);
|
|
3905
3929
|
return;
|
|
3906
3930
|
}
|
|
3907
3931
|
try {
|
|
3908
|
-
if (
|
|
3909
|
-
await
|
|
3932
|
+
if (w.searchText !== void 0) {
|
|
3933
|
+
await h(d, D, w);
|
|
3910
3934
|
return;
|
|
3911
3935
|
}
|
|
3912
3936
|
await t.actions.loadFieldOptions(
|
|
3913
3937
|
t.section,
|
|
3914
3938
|
d,
|
|
3915
3939
|
D,
|
|
3916
|
-
|
|
3940
|
+
w
|
|
3917
3941
|
), i.set(x, K);
|
|
3918
|
-
} catch (
|
|
3919
|
-
console.error("[GlobalInfoTableRenderer] load field options failed",
|
|
3942
|
+
} catch (T) {
|
|
3943
|
+
console.error("[GlobalInfoTableRenderer] load field options failed", T);
|
|
3920
3944
|
}
|
|
3921
3945
|
}
|
|
3922
|
-
async function
|
|
3923
|
-
const
|
|
3924
|
-
for (const D of
|
|
3946
|
+
async function g(d, u) {
|
|
3947
|
+
const w = u ? [u] : t.section.rows;
|
|
3948
|
+
for (const D of w) {
|
|
3925
3949
|
const P = B(D);
|
|
3926
3950
|
for (const x of s.value) {
|
|
3927
3951
|
if (d && !Rn(x, d))
|
|
@@ -3933,12 +3957,12 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3933
3957
|
x,
|
|
3934
3958
|
D,
|
|
3935
3959
|
P
|
|
3936
|
-
), Q = `${P}:${C(x)}`,
|
|
3937
|
-
if (lt(x,
|
|
3960
|
+
), Q = `${P}:${C(x)}`, T = i.get(Q);
|
|
3961
|
+
if (lt(x, T, q)) {
|
|
3938
3962
|
i.set(Q, q);
|
|
3939
3963
|
continue;
|
|
3940
3964
|
}
|
|
3941
|
-
|
|
3965
|
+
T !== q && await z(
|
|
3942
3966
|
x,
|
|
3943
3967
|
D,
|
|
3944
3968
|
xn(x, K)
|
|
@@ -3946,7 +3970,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3946
3970
|
}
|
|
3947
3971
|
}
|
|
3948
3972
|
}
|
|
3949
|
-
function v(d, u,
|
|
3973
|
+
function v(d, u, w) {
|
|
3950
3974
|
const D = u[d.code];
|
|
3951
3975
|
return {
|
|
3952
3976
|
field: d,
|
|
@@ -3954,20 +3978,20 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3954
3978
|
sectionView: t.section,
|
|
3955
3979
|
node: t.node,
|
|
3956
3980
|
row: u,
|
|
3957
|
-
rowIndex:
|
|
3981
|
+
rowIndex: w,
|
|
3958
3982
|
editing: t.editing,
|
|
3959
3983
|
modelValue: D,
|
|
3960
3984
|
value: D,
|
|
3961
3985
|
state: t.state,
|
|
3962
3986
|
actions: t.actions,
|
|
3963
|
-
updateModelValue: (P) => L(u,
|
|
3987
|
+
updateModelValue: (P) => L(u, w, d, P)
|
|
3964
3988
|
};
|
|
3965
3989
|
}
|
|
3966
3990
|
function F(d) {
|
|
3967
|
-
const u = String(d.code || "").trim(),
|
|
3968
|
-
if (
|
|
3969
|
-
const D =
|
|
3970
|
-
return D !==
|
|
3991
|
+
const u = String(d.code || "").trim(), w = u ? `field-${u}` : "";
|
|
3992
|
+
if (w && n[w]) return w;
|
|
3993
|
+
const D = w.toLowerCase();
|
|
3994
|
+
return D !== w && n[D] ? D : "";
|
|
3971
3995
|
}
|
|
3972
3996
|
function y(d) {
|
|
3973
3997
|
return !d.readonly && !d.disabled;
|
|
@@ -3986,7 +4010,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3986
4010
|
return d.key || d.id || d.code;
|
|
3987
4011
|
}
|
|
3988
4012
|
function N(d) {
|
|
3989
|
-
return
|
|
4013
|
+
return r.value + d;
|
|
3990
4014
|
}
|
|
3991
4015
|
function re(d) {
|
|
3992
4016
|
return Vt(d);
|
|
@@ -3997,11 +4021,11 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
3997
4021
|
const u = d.__rowKey ?? d.key ?? d.id ?? d.setId ?? d.infSetId;
|
|
3998
4022
|
if (u != null && u !== "")
|
|
3999
4023
|
return String(u);
|
|
4000
|
-
const
|
|
4024
|
+
const w = d, D = R.get(w);
|
|
4001
4025
|
if (D) return D;
|
|
4002
4026
|
le += 1;
|
|
4003
4027
|
const P = `local-${le}`;
|
|
4004
|
-
return R.set(
|
|
4028
|
+
return R.set(w, P), P;
|
|
4005
4029
|
}
|
|
4006
4030
|
function E(d) {
|
|
4007
4031
|
return d.required || d.isRequired;
|
|
@@ -4014,15 +4038,15 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
4014
4038
|
), Ee(
|
|
4015
4039
|
() => t.editing,
|
|
4016
4040
|
() => {
|
|
4017
|
-
|
|
4041
|
+
g();
|
|
4018
4042
|
},
|
|
4019
4043
|
{ immediate: !0 }
|
|
4020
4044
|
), (d, u) => {
|
|
4021
|
-
const
|
|
4022
|
-
return
|
|
4045
|
+
const w = on, D = eo("Delete"), P = Jt, x = $t, K = nn;
|
|
4046
|
+
return $(), G("div", {
|
|
4023
4047
|
class: We(["global-info-table-renderer", { "global-info-table-renderer--editing": d.editing }])
|
|
4024
4048
|
}, [
|
|
4025
|
-
ne("div",
|
|
4049
|
+
ne("div", Ma, [
|
|
4026
4050
|
Ie(K, {
|
|
4027
4051
|
class: "global-info-table-renderer__table",
|
|
4028
4052
|
data: d.section.rows,
|
|
@@ -4031,14 +4055,14 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
4031
4055
|
"row-key": B
|
|
4032
4056
|
}, {
|
|
4033
4057
|
default: U(() => [
|
|
4034
|
-
|
|
4058
|
+
l.value ? ($(), H(w, {
|
|
4035
4059
|
key: 0,
|
|
4036
4060
|
type: "index",
|
|
4037
4061
|
label: c.value,
|
|
4038
4062
|
width: a.value,
|
|
4039
4063
|
index: N
|
|
4040
4064
|
}, null, 8, ["label", "width"])) : fe("", !0),
|
|
4041
|
-
(
|
|
4065
|
+
($(!0), G(Se, null, ye(s.value, (q) => ($(), H(w, {
|
|
4042
4066
|
key: C(q),
|
|
4043
4067
|
prop: q.code,
|
|
4044
4068
|
label: q.label,
|
|
@@ -4046,45 +4070,45 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
4046
4070
|
"min-width": j(q)
|
|
4047
4071
|
}, {
|
|
4048
4072
|
header: U(() => [
|
|
4049
|
-
ne("span",
|
|
4050
|
-
E(q) ? (
|
|
4073
|
+
ne("span", Ta, [
|
|
4074
|
+
E(q) ? ($(), G("span", Oa, "*")) : fe("", !0),
|
|
4051
4075
|
ne("span", null, oe(q.label), 1)
|
|
4052
4076
|
])
|
|
4053
4077
|
]),
|
|
4054
|
-
default: U(({ row: Q, $index:
|
|
4078
|
+
default: U(({ row: Q, $index: T }) => [
|
|
4055
4079
|
F(q) ? te(d.$slots, F(q), ae({
|
|
4056
4080
|
key: 0,
|
|
4057
4081
|
ref_for: !0
|
|
4058
|
-
}, v(q, Q,
|
|
4082
|
+
}, v(q, Q, T)), void 0, !0) : d.editing && y(q) ? ($(), H(Vn, {
|
|
4059
4083
|
key: 1,
|
|
4060
4084
|
field: q,
|
|
4061
4085
|
"model-value": Q[q.code],
|
|
4062
4086
|
section: d.section,
|
|
4063
4087
|
row: Q,
|
|
4064
|
-
"row-index":
|
|
4088
|
+
"row-index": T,
|
|
4065
4089
|
onLoadOptions: (X) => z(q, Q, X),
|
|
4066
|
-
"onUpdate:modelValue": (X) => L(Q,
|
|
4067
|
-
}, null, 8, ["field", "model-value", "section", "row", "row-index", "onLoadOptions", "onUpdate:modelValue"])) : (
|
|
4090
|
+
"onUpdate:modelValue": (X) => L(Q, T, q, X)
|
|
4091
|
+
}, null, 8, ["field", "model-value", "section", "row", "row-index", "onLoadOptions", "onUpdate:modelValue"])) : ($(), H(jn, {
|
|
4068
4092
|
key: 2,
|
|
4069
4093
|
field: q,
|
|
4070
4094
|
value: Q[q.code],
|
|
4071
4095
|
section: d.section,
|
|
4072
4096
|
row: Q,
|
|
4073
|
-
"row-index":
|
|
4097
|
+
"row-index": T
|
|
4074
4098
|
}, null, 8, ["field", "value", "section", "row", "row-index"]))
|
|
4075
4099
|
]),
|
|
4076
4100
|
_: 2
|
|
4077
4101
|
}, 1032, ["prop", "label", "width", "min-width"]))), 128)),
|
|
4078
|
-
d.editing ? (
|
|
4102
|
+
d.editing ? ($(), H(w, {
|
|
4079
4103
|
key: 1,
|
|
4080
4104
|
label: J(Z)("common.操作"),
|
|
4081
4105
|
width: "104",
|
|
4082
4106
|
fixed: "right"
|
|
4083
4107
|
}, {
|
|
4084
4108
|
default: U(({ row: q, $index: Q }) => [
|
|
4085
|
-
|
|
4109
|
+
I(q, Q) ? ($(), H(ka, {
|
|
4086
4110
|
key: 0,
|
|
4087
|
-
onConfirm: (
|
|
4111
|
+
onConfirm: (T) => S(Q)
|
|
4088
4112
|
}, {
|
|
4089
4113
|
default: U(() => [
|
|
4090
4114
|
Ie(x, {
|
|
@@ -4116,7 +4140,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
4116
4140
|
], 2);
|
|
4117
4141
|
};
|
|
4118
4142
|
}
|
|
4119
|
-
}), Fa = /* @__PURE__ */ be(Da, [["__scopeId", "data-v-
|
|
4143
|
+
}), Fa = /* @__PURE__ */ be(Da, [["__scopeId", "data-v-47a32889"]]), Ba = /* @__PURE__ */ pe({
|
|
4120
4144
|
name: "GlobalInfoAutoRenderer",
|
|
4121
4145
|
__name: "GlobalInfoAutoRenderer",
|
|
4122
4146
|
props: {
|
|
@@ -4128,7 +4152,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
4128
4152
|
renderConfig: {}
|
|
4129
4153
|
},
|
|
4130
4154
|
setup(e) {
|
|
4131
|
-
return (t, n) => t.section.renderType === "table" ? (
|
|
4155
|
+
return (t, n) => t.section.renderType === "table" ? ($(), H(Fa, {
|
|
4132
4156
|
key: 0,
|
|
4133
4157
|
section: t.section,
|
|
4134
4158
|
node: t.node,
|
|
@@ -4136,7 +4160,7 @@ const wa = { class: "global-info-form-renderer__label" }, Ia = {
|
|
|
4136
4160
|
state: t.state,
|
|
4137
4161
|
actions: t.actions,
|
|
4138
4162
|
"render-config": t.renderConfig
|
|
4139
|
-
}, null, 8, ["section", "node", "editing", "state", "actions", "render-config"])) : (
|
|
4163
|
+
}, null, 8, ["section", "node", "editing", "state", "actions", "render-config"])) : ($(), H(Ca, {
|
|
4140
4164
|
key: 1,
|
|
4141
4165
|
section: t.section,
|
|
4142
4166
|
node: t.node,
|
|
@@ -4153,12 +4177,12 @@ function qn(e) {
|
|
|
4153
4177
|
function Gn(e, t) {
|
|
4154
4178
|
return qn(e) || Kn(t?.code);
|
|
4155
4179
|
}
|
|
4156
|
-
function
|
|
4180
|
+
function Tt(e, t, n) {
|
|
4157
4181
|
if (!n) return "";
|
|
4158
4182
|
const o = `${t}-${n}`;
|
|
4159
4183
|
if (e[o]) return o;
|
|
4160
|
-
const
|
|
4161
|
-
return
|
|
4184
|
+
const l = o.toLowerCase();
|
|
4185
|
+
return l !== o && e[l] ? l : "";
|
|
4162
4186
|
}
|
|
4163
4187
|
function Kn(e) {
|
|
4164
4188
|
return typeof e == "string" ? e.trim() : "";
|
|
@@ -4183,19 +4207,19 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4183
4207
|
values: t.section.model,
|
|
4184
4208
|
rows: t.section.renderType === "table" ? t.section.rows : void 0
|
|
4185
4209
|
}
|
|
4186
|
-
)),
|
|
4187
|
-
const s =
|
|
4210
|
+
)), l = O(() => t.editing ?? t.actions.isEditing(t.section)), c = O(() => t.section.renderType === "table" && t.section.rows.length === 0 || o.value.length === 0), a = O(() => {
|
|
4211
|
+
const s = Tt(
|
|
4188
4212
|
n,
|
|
4189
4213
|
"section",
|
|
4190
4214
|
Gn(t.node ?? {}, t.section)
|
|
4191
|
-
), i =
|
|
4215
|
+
), i = r(t.section.renderType);
|
|
4192
4216
|
return [
|
|
4193
4217
|
s,
|
|
4194
4218
|
i,
|
|
4195
4219
|
"default"
|
|
4196
|
-
].find((
|
|
4220
|
+
].find((h) => !!(h && n[h])) ?? "";
|
|
4197
4221
|
});
|
|
4198
|
-
function
|
|
4222
|
+
function r(s) {
|
|
4199
4223
|
return s === "form" || s === "table" ? s : "";
|
|
4200
4224
|
}
|
|
4201
4225
|
return (s, i) => a.value ? te(s.$slots, a.value, {
|
|
@@ -4203,18 +4227,18 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4203
4227
|
section: s.section,
|
|
4204
4228
|
sectionView: s.section,
|
|
4205
4229
|
node: s.node,
|
|
4206
|
-
editing:
|
|
4230
|
+
editing: l.value,
|
|
4207
4231
|
isEmpty: c.value,
|
|
4208
4232
|
empty: c.value,
|
|
4209
4233
|
fields: o.value,
|
|
4210
4234
|
renderConfig: s.renderConfig,
|
|
4211
4235
|
state: s.state,
|
|
4212
4236
|
actions: s.actions
|
|
4213
|
-
}) : (
|
|
4237
|
+
}) : ($(), H(Ba, {
|
|
4214
4238
|
key: 1,
|
|
4215
4239
|
section: s.section,
|
|
4216
4240
|
node: s.node,
|
|
4217
|
-
editing:
|
|
4241
|
+
editing: l.value,
|
|
4218
4242
|
state: s.state,
|
|
4219
4243
|
actions: s.actions,
|
|
4220
4244
|
"render-config": s.renderConfig
|
|
@@ -4242,8 +4266,8 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4242
4266
|
() => {
|
|
4243
4267
|
o.value = !1;
|
|
4244
4268
|
}
|
|
4245
|
-
), to((c) => (
|
|
4246
|
-
function
|
|
4269
|
+
), to((c) => (l(c), !1));
|
|
4270
|
+
function l(c) {
|
|
4247
4271
|
o.value = !0, console.error(`[GlobalInfoSlotErrorBoundary] ${e.label || "section"} slot render failed`, c), t("error", c);
|
|
4248
4272
|
}
|
|
4249
4273
|
return () => {
|
|
@@ -4252,7 +4276,7 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4252
4276
|
try {
|
|
4253
4277
|
return n.default?.() ?? null;
|
|
4254
4278
|
} catch (c) {
|
|
4255
|
-
return
|
|
4279
|
+
return l(c), n.fallback?.() ?? null;
|
|
4256
4280
|
}
|
|
4257
4281
|
};
|
|
4258
4282
|
}
|
|
@@ -4276,7 +4300,7 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4276
4300
|
onSave: { type: Function }
|
|
4277
4301
|
},
|
|
4278
4302
|
setup(e) {
|
|
4279
|
-
const t = e, n = Le(), o = ge(!1),
|
|
4303
|
+
const t = e, n = Le(), o = ge(!1), l = ge(null), c = ge(null), a = O(() => !!t.hideHeader), r = O(() => t.actions.getSectionStatus(t.node)), s = O(
|
|
4280
4304
|
() => t.actions.getSection(t.node) ?? c.value
|
|
4281
4305
|
), i = O(() => {
|
|
4282
4306
|
const b = s.value;
|
|
@@ -4289,47 +4313,47 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4289
4313
|
rows: b.renderType === "table" ? b.rows : void 0
|
|
4290
4314
|
}
|
|
4291
4315
|
) : [];
|
|
4292
|
-
}),
|
|
4316
|
+
}), h = O(
|
|
4293
4317
|
() => s.value?.title || t.node.tagName || t.node.label || "-"
|
|
4294
|
-
),
|
|
4318
|
+
), S = O(
|
|
4295
4319
|
() => !!(s.value && t.actions.isEditing(s.value))
|
|
4296
|
-
),
|
|
4320
|
+
), I = O(
|
|
4297
4321
|
() => s.value?.renderType === "table"
|
|
4298
|
-
), L = O(() => o.value ||
|
|
4299
|
-
() =>
|
|
4322
|
+
), L = O(() => o.value || r.value.loading), V = O(
|
|
4323
|
+
() => M(l.value || r.value.error)
|
|
4300
4324
|
), f = O(() => {
|
|
4301
4325
|
const b = s.value;
|
|
4302
4326
|
return b ? b.renderType === "table" && b.rows.length === 0 || i.value.length === 0 : !0;
|
|
4303
|
-
}),
|
|
4327
|
+
}), _ = O(() => ({
|
|
4304
4328
|
node: t.node,
|
|
4305
4329
|
section: s.value,
|
|
4306
4330
|
sectionView: s.value,
|
|
4307
4331
|
fields: i.value,
|
|
4308
4332
|
renderConfig: t.renderConfig,
|
|
4309
|
-
title:
|
|
4310
|
-
editing:
|
|
4333
|
+
title: h.value,
|
|
4334
|
+
editing: S.value,
|
|
4311
4335
|
loading: L.value,
|
|
4312
|
-
error:
|
|
4336
|
+
error: l.value || r.value.error,
|
|
4313
4337
|
errorMessage: V.value,
|
|
4314
4338
|
isEmpty: f.value,
|
|
4315
4339
|
empty: f.value,
|
|
4316
|
-
sectionStatus:
|
|
4340
|
+
sectionStatus: r.value,
|
|
4317
4341
|
state: t.state,
|
|
4318
4342
|
actions: t.actions,
|
|
4319
4343
|
reload: A,
|
|
4320
4344
|
handleEdit: z,
|
|
4321
|
-
handleCancel:
|
|
4345
|
+
handleCancel: g,
|
|
4322
4346
|
handleAddTableRow: v,
|
|
4323
4347
|
handleSave: F
|
|
4324
4348
|
}));
|
|
4325
|
-
function
|
|
4349
|
+
function M(b) {
|
|
4326
4350
|
return b ? b instanceof Error ? b.message : String(b) : "";
|
|
4327
4351
|
}
|
|
4328
4352
|
async function z() {
|
|
4329
4353
|
const b = s.value;
|
|
4330
4354
|
b && (await t.onEdit?.(b, t.node), t.onEdit || t.actions.startEdit(b));
|
|
4331
4355
|
}
|
|
4332
|
-
async function
|
|
4356
|
+
async function g() {
|
|
4333
4357
|
const b = s.value;
|
|
4334
4358
|
b && (await t.onCancel?.(b, t.node), t.onCancel || t.actions.cancelEdit(b));
|
|
4335
4359
|
}
|
|
@@ -4352,18 +4376,18 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4352
4376
|
}
|
|
4353
4377
|
await t.actions.saveSection(b);
|
|
4354
4378
|
} catch (j) {
|
|
4355
|
-
|
|
4379
|
+
l.value = j, console.error("[GlobalInfoSectionBlock] save section failed", j);
|
|
4356
4380
|
}
|
|
4357
4381
|
}
|
|
4358
4382
|
function y(b) {
|
|
4359
|
-
|
|
4383
|
+
l.value = b;
|
|
4360
4384
|
}
|
|
4361
4385
|
async function A() {
|
|
4362
|
-
o.value = !0,
|
|
4386
|
+
o.value = !0, l.value = null, c.value = null;
|
|
4363
4387
|
try {
|
|
4364
4388
|
c.value = await t.actions.loadSection(t.node);
|
|
4365
4389
|
} catch (b) {
|
|
4366
|
-
|
|
4390
|
+
l.value = b, console.error("[GlobalInfoSectionBlock] load section failed", b);
|
|
4367
4391
|
} finally {
|
|
4368
4392
|
o.value = !1;
|
|
4369
4393
|
}
|
|
@@ -4377,30 +4401,30 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4377
4401
|
}
|
|
4378
4402
|
), (b, j) => {
|
|
4379
4403
|
const C = $t;
|
|
4380
|
-
return
|
|
4381
|
-
a.value ? fe("", !0) : (
|
|
4382
|
-
te(b.$slots, "header", Oe(Be(
|
|
4404
|
+
return $(), G("section", Pa, [
|
|
4405
|
+
a.value ? fe("", !0) : ($(), G("header", Va, [
|
|
4406
|
+
te(b.$slots, "header", Oe(Be(_.value)), () => [
|
|
4383
4407
|
ne("div", ja, [
|
|
4384
4408
|
j[0] || (j[0] = ne("span", { class: "global-info-section-block__marker" }, null, -1)),
|
|
4385
|
-
ne("h3", Aa, oe(
|
|
4409
|
+
ne("h3", Aa, oe(h.value), 1)
|
|
4386
4410
|
]),
|
|
4387
|
-
te(b.$slots, "actions", Oe(Be(
|
|
4388
|
-
s.value ? (
|
|
4389
|
-
|
|
4411
|
+
te(b.$slots, "actions", Oe(Be(_.value)), () => [
|
|
4412
|
+
s.value ? ($(), G("div", Ra, [
|
|
4413
|
+
S.value ? ($(), G(Se, { key: 1 }, [
|
|
4390
4414
|
Ie(C, {
|
|
4391
4415
|
class: "global-info-section-block__cancel",
|
|
4392
|
-
disabled:
|
|
4393
|
-
onClick:
|
|
4416
|
+
disabled: r.value.saving,
|
|
4417
|
+
onClick: g
|
|
4394
4418
|
}, {
|
|
4395
4419
|
default: U(() => [
|
|
4396
4420
|
He(oe(J(Z)("common.取消")), 1)
|
|
4397
4421
|
]),
|
|
4398
4422
|
_: 1
|
|
4399
4423
|
}, 8, ["disabled"]),
|
|
4400
|
-
|
|
4424
|
+
I.value ? ($(), H(C, {
|
|
4401
4425
|
key: 0,
|
|
4402
4426
|
class: "global-info-section-block__add",
|
|
4403
|
-
disabled:
|
|
4427
|
+
disabled: r.value.saving,
|
|
4404
4428
|
onClick: v
|
|
4405
4429
|
}, {
|
|
4406
4430
|
default: U(() => [
|
|
@@ -4410,18 +4434,18 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4410
4434
|
}, 8, ["disabled"])) : fe("", !0),
|
|
4411
4435
|
Ie(C, {
|
|
4412
4436
|
class: "global-info-section-block__confirm",
|
|
4413
|
-
loading:
|
|
4437
|
+
loading: r.value.saving,
|
|
4414
4438
|
onClick: F
|
|
4415
4439
|
}, {
|
|
4416
4440
|
default: U(() => [
|
|
4417
|
-
He(oe(
|
|
4441
|
+
He(oe(I.value ? J(Z)("common.确认") : J(Z)("common.保存")), 1)
|
|
4418
4442
|
]),
|
|
4419
4443
|
_: 1
|
|
4420
4444
|
}, 8, ["loading"])
|
|
4421
|
-
], 64)) : (
|
|
4445
|
+
], 64)) : ($(), H(C, {
|
|
4422
4446
|
key: 0,
|
|
4423
4447
|
class: "global-info-section-block__edit",
|
|
4424
|
-
disabled:
|
|
4448
|
+
disabled: r.value.saving || L.value,
|
|
4425
4449
|
onClick: z
|
|
4426
4450
|
}, {
|
|
4427
4451
|
default: U(() => [
|
|
@@ -4445,18 +4469,18 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4445
4469
|
], !0)
|
|
4446
4470
|
])),
|
|
4447
4471
|
ne("div", za, [
|
|
4448
|
-
L.value ? te(b.$slots, "loading", Oe(ae({ key: 0 },
|
|
4472
|
+
L.value ? te(b.$slots, "loading", Oe(ae({ key: 0 }, _.value)), () => [
|
|
4449
4473
|
ne("div", Na, oe(J(Z)("common.加载中___")), 1)
|
|
4450
|
-
], !0) : !s.value || f.value ? te(b.$slots, "empty", Oe(ae({ key: 1 },
|
|
4474
|
+
], !0) : !s.value || f.value ? te(b.$slots, "empty", Oe(ae({ key: 1 }, _.value)), () => [
|
|
4451
4475
|
ne("div", xa, oe(J(Z)("common.暂无数据")), 1)
|
|
4452
|
-
], !0) : (
|
|
4476
|
+
], !0) : ($(), H(La, {
|
|
4453
4477
|
key: 2,
|
|
4454
4478
|
"boundary-key": b.node.key,
|
|
4455
|
-
label:
|
|
4479
|
+
label: h.value,
|
|
4456
4480
|
onError: y
|
|
4457
4481
|
}, {
|
|
4458
4482
|
fallback: U(() => [
|
|
4459
|
-
te(b.$slots, "empty", Oe(Be(
|
|
4483
|
+
te(b.$slots, "empty", Oe(Be(_.value)), () => [
|
|
4460
4484
|
ne("div", qa, oe(J(Z)("common.暂无数据")), 1)
|
|
4461
4485
|
], !0)
|
|
4462
4486
|
]),
|
|
@@ -4464,7 +4488,7 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4464
4488
|
Ie(Ea, {
|
|
4465
4489
|
section: s.value,
|
|
4466
4490
|
node: b.node,
|
|
4467
|
-
editing:
|
|
4491
|
+
editing: S.value,
|
|
4468
4492
|
state: b.state,
|
|
4469
4493
|
actions: b.actions,
|
|
4470
4494
|
"render-config": b.renderConfig
|
|
@@ -4472,7 +4496,7 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4472
4496
|
ye(J(n), (N, re) => ({
|
|
4473
4497
|
name: re,
|
|
4474
4498
|
fn: U((le) => [
|
|
4475
|
-
te(b.$slots, re, Oe(Be({ ...
|
|
4499
|
+
te(b.$slots, re, Oe(Be({ ..._.value, ...le })), void 0, !0)
|
|
4476
4500
|
])
|
|
4477
4501
|
}))
|
|
4478
4502
|
]), 1032, ["section", "node", "editing", "state", "actions", "render-config"])
|
|
@@ -4483,7 +4507,7 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4483
4507
|
]);
|
|
4484
4508
|
};
|
|
4485
4509
|
}
|
|
4486
|
-
}), Ka = /* @__PURE__ */ be(Ga, [["__scopeId", "data-v-
|
|
4510
|
+
}), Ka = /* @__PURE__ */ be(Ga, [["__scopeId", "data-v-d1ce154e"]]), Ya = { class: "global-info-group" }, Ua = { class: "global-info-group__header" }, Ha = { class: "global-info-group__title" }, Ja = { class: "global-info-group__body" }, Wa = ["id"], Za = { class: "global-info-group__empty" }, Qa = /* @__PURE__ */ pe({
|
|
4487
4511
|
name: "GlobalInfoGroup",
|
|
4488
4512
|
__name: "GlobalInfoGroup",
|
|
4489
4513
|
props: {
|
|
@@ -4497,42 +4521,42 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4497
4521
|
setup(e) {
|
|
4498
4522
|
const t = e, n = Le(), o = O(
|
|
4499
4523
|
() => t.group.tagName || t.group.label || "-"
|
|
4500
|
-
),
|
|
4501
|
-
function c(i,
|
|
4502
|
-
const
|
|
4524
|
+
), l = O(() => t.children.length <= 1);
|
|
4525
|
+
function c(i, h) {
|
|
4526
|
+
const S = t.actions.getSection(i);
|
|
4503
4527
|
return {
|
|
4504
4528
|
node: i,
|
|
4505
4529
|
group: t.group,
|
|
4506
4530
|
sectionNode: i,
|
|
4507
|
-
section:
|
|
4508
|
-
sectionView:
|
|
4531
|
+
section: S,
|
|
4532
|
+
sectionView: S,
|
|
4509
4533
|
state: t.state,
|
|
4510
4534
|
actions: t.actions,
|
|
4511
4535
|
renderConfig: t.renderConfig,
|
|
4512
|
-
index:
|
|
4513
|
-
editing: !!(
|
|
4536
|
+
index: h,
|
|
4537
|
+
editing: !!(S && t.actions.isEditing(S)),
|
|
4514
4538
|
sectionStatus: t.actions.getSectionStatus(i),
|
|
4515
|
-
isSelfSection:
|
|
4539
|
+
isSelfSection: r(i, 0) === r(t.group, 0),
|
|
4516
4540
|
handleEdit: () => t.actions.startEdit(i),
|
|
4517
4541
|
handleCancel: () => t.actions.cancelEdit(i),
|
|
4518
4542
|
handleSave: () => t.actions.saveSection(i.key)
|
|
4519
4543
|
};
|
|
4520
4544
|
}
|
|
4521
4545
|
function a(i) {
|
|
4522
|
-
const
|
|
4523
|
-
return
|
|
4546
|
+
const h = t.actions.getSection(i);
|
|
4547
|
+
return Tt(
|
|
4524
4548
|
n,
|
|
4525
4549
|
"section",
|
|
4526
|
-
Gn(i,
|
|
4550
|
+
Gn(i, h)
|
|
4527
4551
|
);
|
|
4528
4552
|
}
|
|
4529
|
-
function
|
|
4530
|
-
return i.key || i.id || i.infSetId || i.tagId || `${
|
|
4553
|
+
function r(i, h) {
|
|
4554
|
+
return i.key || i.id || i.infSetId || i.tagId || `${h}`;
|
|
4531
4555
|
}
|
|
4532
4556
|
function s(i) {
|
|
4533
|
-
return `global-info-section-${
|
|
4557
|
+
return `global-info-section-${r(i, 0)}`;
|
|
4534
4558
|
}
|
|
4535
|
-
return (i,
|
|
4559
|
+
return (i, h) => ($(), G("section", Ya, [
|
|
4536
4560
|
te(i.$slots, "header", {
|
|
4537
4561
|
group: i.group,
|
|
4538
4562
|
children: i.children,
|
|
@@ -4544,7 +4568,7 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4544
4568
|
isEmpty: i.children.length === 0
|
|
4545
4569
|
}, () => [
|
|
4546
4570
|
ne("header", Ua, [
|
|
4547
|
-
|
|
4571
|
+
h[0] || (h[0] = ne("span", { class: "global-info-group__marker" }, null, -1)),
|
|
4548
4572
|
ne("h2", Ha, oe(o.value), 1)
|
|
4549
4573
|
])
|
|
4550
4574
|
], !0),
|
|
@@ -4558,24 +4582,24 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4558
4582
|
renderConfig: i.renderConfig,
|
|
4559
4583
|
index: i.index,
|
|
4560
4584
|
isEmpty: i.children.length === 0
|
|
4561
|
-
}, void 0, !0) : (
|
|
4562
|
-
(
|
|
4563
|
-
id: s(
|
|
4564
|
-
key:
|
|
4585
|
+
}, void 0, !0) : ($(), G(Se, { key: 1 }, [
|
|
4586
|
+
($(!0), G(Se, null, ye(i.children, (S, I) => ($(), G("div", {
|
|
4587
|
+
id: s(S),
|
|
4588
|
+
key: r(S, I),
|
|
4565
4589
|
class: "global-info-group__section"
|
|
4566
4590
|
}, [
|
|
4567
|
-
a(
|
|
4591
|
+
a(S) ? te(i.$slots, a(S), ae({
|
|
4568
4592
|
key: 0,
|
|
4569
4593
|
ref_for: !0
|
|
4570
|
-
}, c(
|
|
4594
|
+
}, c(S, I)), void 0, !0) : J(n).section ? te(i.$slots, "section", ae({
|
|
4571
4595
|
key: 1,
|
|
4572
4596
|
ref_for: !0
|
|
4573
|
-
}, c(
|
|
4597
|
+
}, c(S, I)), void 0, !0) : ($(), H(Ka, {
|
|
4574
4598
|
key: 2,
|
|
4575
|
-
node:
|
|
4599
|
+
node: S,
|
|
4576
4600
|
state: i.state,
|
|
4577
4601
|
actions: i.actions,
|
|
4578
|
-
"hide-header":
|
|
4602
|
+
"hide-header": l.value,
|
|
4579
4603
|
"render-config": i.renderConfig
|
|
4580
4604
|
}, Re({ _: 2 }, [
|
|
4581
4605
|
ye(J(n), (L, V) => ({
|
|
@@ -4602,7 +4626,7 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4602
4626
|
])
|
|
4603
4627
|
]));
|
|
4604
4628
|
}
|
|
4605
|
-
}), Xa = /* @__PURE__ */ be(Qa, [["__scopeId", "data-v-
|
|
4629
|
+
}), Xa = /* @__PURE__ */ be(Qa, [["__scopeId", "data-v-91c91b25"]]), es = { class: "global-info-sections" }, ts = /* @__PURE__ */ pe({
|
|
4606
4630
|
name: "GlobalInfoSections",
|
|
4607
4631
|
__name: "GlobalInfoSections",
|
|
4608
4632
|
props: {
|
|
@@ -4613,104 +4637,104 @@ const Ea = /* @__PURE__ */ pe({
|
|
|
4613
4637
|
},
|
|
4614
4638
|
setup(e) {
|
|
4615
4639
|
const t = e, n = Le(), o = O(() => {
|
|
4616
|
-
const
|
|
4617
|
-
(
|
|
4618
|
-
),
|
|
4619
|
-
group:
|
|
4620
|
-
children:
|
|
4621
|
-
})), f =
|
|
4622
|
-
group:
|
|
4623
|
-
children: [
|
|
4640
|
+
const h = t.nodes.filter(
|
|
4641
|
+
(M) => l(M).length > 0
|
|
4642
|
+
), S = t.nodes.filter((M) => l(M).length === 0), I = S.filter((M) => c(M)), L = S.filter((M) => !c(M)), V = h.map((M) => ({
|
|
4643
|
+
group: M,
|
|
4644
|
+
children: l(M)
|
|
4645
|
+
})), f = I.map((M) => ({
|
|
4646
|
+
group: M,
|
|
4647
|
+
children: [M]
|
|
4624
4648
|
}));
|
|
4625
4649
|
if (V.length === 0)
|
|
4626
|
-
return
|
|
4627
|
-
const
|
|
4628
|
-
return [...V, ...f, ...
|
|
4650
|
+
return I.length > 0 ? f : i(L);
|
|
4651
|
+
const _ = i(L);
|
|
4652
|
+
return [...V, ...f, ..._];
|
|
4629
4653
|
});
|
|
4630
|
-
function
|
|
4631
|
-
return
|
|
4654
|
+
function l(h) {
|
|
4655
|
+
return h.children ?? [];
|
|
4632
4656
|
}
|
|
4633
|
-
function c(
|
|
4634
|
-
return !String(
|
|
4657
|
+
function c(h) {
|
|
4658
|
+
return !String(h.parentId || h.parentTagId || "").trim();
|
|
4635
4659
|
}
|
|
4636
|
-
function a(
|
|
4637
|
-
return
|
|
4660
|
+
function a(h) {
|
|
4661
|
+
return Tt(n, "group", qn(h));
|
|
4638
4662
|
}
|
|
4639
|
-
function
|
|
4640
|
-
return
|
|
4663
|
+
function r(h, S) {
|
|
4664
|
+
return h.key || h.id || h.tagId || `${S}`;
|
|
4641
4665
|
}
|
|
4642
|
-
function s(
|
|
4643
|
-
const
|
|
4644
|
-
|
|
4666
|
+
function s(h) {
|
|
4667
|
+
const S = h[0], I = S?.raw ?? {}, L = String(
|
|
4668
|
+
I.parentTagName || I.parentName || I.parentLabel || S?.parentId || Z("common.信息")
|
|
4645
4669
|
);
|
|
4646
4670
|
return {
|
|
4647
|
-
...
|
|
4648
|
-
key: `${
|
|
4671
|
+
...S,
|
|
4672
|
+
key: `${S?.parentId || S?.parentTagId || S?.key || "global-info"}-group`,
|
|
4649
4673
|
id: String(
|
|
4650
|
-
|
|
4674
|
+
S?.parentId || S?.parentTagId || S?.id || "global-info-group"
|
|
4651
4675
|
),
|
|
4652
4676
|
tagId: String(
|
|
4653
|
-
|
|
4677
|
+
S?.parentTagId || S?.parentId || S?.tagId || "global-info-group"
|
|
4654
4678
|
),
|
|
4655
4679
|
tagName: L,
|
|
4656
4680
|
label: L,
|
|
4657
|
-
children:
|
|
4681
|
+
children: h
|
|
4658
4682
|
};
|
|
4659
4683
|
}
|
|
4660
|
-
function i(
|
|
4661
|
-
const
|
|
4662
|
-
return
|
|
4684
|
+
function i(h) {
|
|
4685
|
+
const S = /* @__PURE__ */ new Map();
|
|
4686
|
+
return h.forEach((I) => {
|
|
4663
4687
|
const L = String(
|
|
4664
|
-
|
|
4665
|
-
), V =
|
|
4666
|
-
V.push(
|
|
4667
|
-
}), Array.from(
|
|
4668
|
-
group: s(
|
|
4669
|
-
children:
|
|
4688
|
+
I.parentId || I.parentTagId || "global-info-flat"
|
|
4689
|
+
), V = S.get(L) ?? [];
|
|
4690
|
+
V.push(I), S.set(L, V);
|
|
4691
|
+
}), Array.from(S.values()).map((I) => ({
|
|
4692
|
+
group: s(I),
|
|
4693
|
+
children: I
|
|
4670
4694
|
}));
|
|
4671
4695
|
}
|
|
4672
|
-
return (
|
|
4673
|
-
(
|
|
4674
|
-
key:
|
|
4696
|
+
return (h, S) => ($(), G("div", es, [
|
|
4697
|
+
($(!0), G(Se, null, ye(o.value, (I, L) => ($(), G(Se, {
|
|
4698
|
+
key: r(I.group, L)
|
|
4675
4699
|
}, [
|
|
4676
|
-
a(
|
|
4700
|
+
a(I.group) ? te(h.$slots, a(I.group), {
|
|
4677
4701
|
key: 0,
|
|
4678
|
-
group:
|
|
4679
|
-
children:
|
|
4680
|
-
state:
|
|
4681
|
-
actions:
|
|
4682
|
-
renderConfig:
|
|
4702
|
+
group: I.group,
|
|
4703
|
+
children: I.children,
|
|
4704
|
+
state: h.state,
|
|
4705
|
+
actions: h.actions,
|
|
4706
|
+
renderConfig: h.renderConfig,
|
|
4683
4707
|
index: L,
|
|
4684
|
-
isEmpty:
|
|
4685
|
-
}, void 0, !0) : J(n).group ? te(
|
|
4708
|
+
isEmpty: I.children.length === 0
|
|
4709
|
+
}, void 0, !0) : J(n).group ? te(h.$slots, "group", {
|
|
4686
4710
|
key: 1,
|
|
4687
|
-
group:
|
|
4688
|
-
children:
|
|
4689
|
-
state:
|
|
4690
|
-
actions:
|
|
4691
|
-
renderConfig:
|
|
4711
|
+
group: I.group,
|
|
4712
|
+
children: I.children,
|
|
4713
|
+
state: h.state,
|
|
4714
|
+
actions: h.actions,
|
|
4715
|
+
renderConfig: h.renderConfig,
|
|
4692
4716
|
index: L,
|
|
4693
|
-
isEmpty:
|
|
4694
|
-
}, void 0, !0) : (
|
|
4717
|
+
isEmpty: I.children.length === 0
|
|
4718
|
+
}, void 0, !0) : ($(), H(Xa, {
|
|
4695
4719
|
key: 2,
|
|
4696
|
-
group:
|
|
4697
|
-
children:
|
|
4698
|
-
state:
|
|
4699
|
-
actions:
|
|
4700
|
-
"render-config":
|
|
4720
|
+
group: I.group,
|
|
4721
|
+
children: I.children,
|
|
4722
|
+
state: h.state,
|
|
4723
|
+
actions: h.actions,
|
|
4724
|
+
"render-config": h.renderConfig,
|
|
4701
4725
|
index: L
|
|
4702
4726
|
}, Re({ _: 2 }, [
|
|
4703
4727
|
ye(J(n), (V, f) => ({
|
|
4704
4728
|
name: f,
|
|
4705
|
-
fn: U((
|
|
4706
|
-
te(
|
|
4729
|
+
fn: U((_) => [
|
|
4730
|
+
te(h.$slots, f, ae({ ref_for: !0 }, _), void 0, !0)
|
|
4707
4731
|
])
|
|
4708
4732
|
}))
|
|
4709
4733
|
]), 1032, ["group", "children", "state", "actions", "render-config", "index"]))
|
|
4710
4734
|
], 64))), 128))
|
|
4711
4735
|
]));
|
|
4712
4736
|
}
|
|
4713
|
-
}), us = /* @__PURE__ */ be(ts, [["__scopeId", "data-v-
|
|
4737
|
+
}), us = /* @__PURE__ */ be(ts, [["__scopeId", "data-v-86c94f9f"]]);
|
|
4714
4738
|
function ds(e, t = {}) {
|
|
4715
4739
|
Un(e, t);
|
|
4716
4740
|
}
|