@gx-design-vue/pro-table 0.2.0-beta.94 → 0.2.0-beta.95
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/pro-table.js +584 -584
- package/dist/pro-table.umd.cjs +1 -1
- package/package.json +1 -1
package/dist/pro-table.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { cloneDeep as
|
|
2
|
-
import { isObject as
|
|
3
|
-
import { reactive as
|
|
1
|
+
import { cloneDeep as ue, omit as Ge, pick as xt } from "lodash-es";
|
|
2
|
+
import { isObject as U, isBoolean as ie, getSlot as Bt, isFunction as Ee, arrayRepeat as tl, runFunction as ll, convertValueBoolean as Re, isArray as ne, getSortIndex as al, isDeepEqualReact as He, handleCurrentPage as nl, genColumnKey as Ft, compareArray as ul, isNumber as Qe, isString as Rt, classNames as Se, filterEmpty as It, getPrefixCls as ut, getRandomNumber as at, handleShowIndex as il, hanndleEmptyField as sl, getTextWidth as ol, getSlotVNode as Fe } from "@gx-design-vue/pro-utils";
|
|
3
|
+
import { reactive as we, isReactive as rl, watch as q, computed as w, ref as E, toRaw as Te, createVNode as c, mergeProps as _, isVNode as ce, watchEffect as Ae, unref as b, onUnmounted as cl, onDeactivated as dl, onMounted as fl, defineComponent as fe, Fragment as _e, nextTick as hl, h as Ot, cloneVNode as it, createTextVNode as De, renderSlot as ml, toRef as oe } from "vue";
|
|
4
4
|
import "ant-design-vue/es/_util/props-util";
|
|
5
|
-
import { warning as
|
|
6
|
-
import { tableProps as
|
|
7
|
-
import { UpOutlined as
|
|
8
|
-
import { useFullscreen as
|
|
9
|
-
import { Grid as st, Space as
|
|
10
|
-
import { useProAppContext as
|
|
11
|
-
import { useContext as
|
|
12
|
-
import
|
|
13
|
-
import { tryOnUnmounted as
|
|
14
|
-
function
|
|
5
|
+
import { warning as vl } from "ant-design-vue/es/vc-util/warning";
|
|
6
|
+
import { tableProps as gl } from "ant-design-vue/es/table/Table";
|
|
7
|
+
import { UpOutlined as yl, DownOutlined as bl, SettingOutlined as Pt, VerticalAlignTopOutlined as Cl, VerticalAlignMiddleOutlined as xl, VerticalAlignBottomOutlined as Sl, FullscreenExitOutlined as wl, FullscreenOutlined as pl, ColumnHeightOutlined as Tl, InfoCircleOutlined as $l, ReloadOutlined as Bl, CopyOutlined as Fl } from "@ant-design/icons-vue";
|
|
8
|
+
import { useFullscreen as kt, useWindowSize as Rl } from "@vueuse/core";
|
|
9
|
+
import { Grid as st, Space as xe, Button as St, Input as wt, TimePicker as Il, DatePicker as jt, TreeSelect as Ol, Spin as nt, Select as Pl, Popover as kl, Checkbox as jl, Tooltip as de, Tree as Nl, Dropdown as El, Menu as We, Pagination as Dl, Table as Ml, message as Al, Empty as zl } from "ant-design-vue";
|
|
10
|
+
import { useProAppContext as Nt } from "@gx-design-vue/pro-app";
|
|
11
|
+
import { useContext as Kl, useProStyle as qe, unit as pt } from "@gx-design-vue/pro-provider";
|
|
12
|
+
import X from "dayjs";
|
|
13
|
+
import { tryOnUnmounted as Yl, useMemo as Ve } from "@gx-design-vue/pro-hooks";
|
|
14
|
+
function Ga(e, l) {
|
|
15
15
|
var C, x, d, S;
|
|
16
16
|
function a() {
|
|
17
|
-
return l != null && l.state &&
|
|
17
|
+
return l != null && l.state && U(l == null ? void 0 : l.state) ? ue(Te(l == null ? void 0 : l.state)) : {};
|
|
18
18
|
}
|
|
19
|
-
const o =
|
|
19
|
+
const o = we({
|
|
20
20
|
params: ((C = l == null ? void 0 : l.state) == null ? void 0 : C.params) || {},
|
|
21
21
|
// @ts-ignore
|
|
22
22
|
request: async (...u) => {
|
|
@@ -24,7 +24,7 @@ function Va(e, l) {
|
|
|
24
24
|
return l != null && l.request ? await ((n = l == null ? void 0 : l.request) == null ? void 0 : n.call(l, ...u)) : void 0;
|
|
25
25
|
}
|
|
26
26
|
});
|
|
27
|
-
l != null && l.state && (
|
|
27
|
+
l != null && l.state && (rl(l.state) ? q(() => l == null ? void 0 : l.state, () => {
|
|
28
28
|
Object.assign(o, a());
|
|
29
29
|
}, { deep: !0, immediate: !0 }) : Object.assign(o, a()));
|
|
30
30
|
const s = w(() => {
|
|
@@ -40,12 +40,12 @@ function Va(e, l) {
|
|
|
40
40
|
...((r = (n = i.value) == null ? void 0 : n.getFormState) == null ? void 0 : r.call(n)) || {}
|
|
41
41
|
};
|
|
42
42
|
}), m = E(!!((d = (x = s.value) == null ? void 0 : x.loading) != null && d.value));
|
|
43
|
-
return
|
|
43
|
+
return q(() => {
|
|
44
44
|
var u, n;
|
|
45
45
|
return (n = (u = s.value) == null ? void 0 : u.loading) == null ? void 0 : n.value;
|
|
46
46
|
}, (u) => {
|
|
47
47
|
m.value = !!u;
|
|
48
|
-
}),
|
|
48
|
+
}), q(m, (u) => {
|
|
49
49
|
var n, r;
|
|
50
50
|
(r = (n = s.value) == null ? void 0 : n.setLoading) == null || r.call(n, !!u);
|
|
51
51
|
}), {
|
|
@@ -76,8 +76,8 @@ function Va(e, l) {
|
|
|
76
76
|
return (r = (n = s.value) == null ? void 0 : n.reloadAndReset) == null ? void 0 : r.call(n, u);
|
|
77
77
|
},
|
|
78
78
|
setPageAndReload: (u, n, r, g) => {
|
|
79
|
-
var T,
|
|
80
|
-
return (
|
|
79
|
+
var T, O;
|
|
80
|
+
return (O = (T = s.value) == null ? void 0 : T.setPageAndReload) == null ? void 0 : O.call(T, u, n, r, g);
|
|
81
81
|
},
|
|
82
82
|
setPagination: (u) => {
|
|
83
83
|
var n, r;
|
|
@@ -94,8 +94,8 @@ function Va(e, l) {
|
|
|
94
94
|
}
|
|
95
95
|
};
|
|
96
96
|
}
|
|
97
|
-
const
|
|
98
|
-
...Ge(
|
|
97
|
+
const Ll = ["rowKey", "rowSelection", "columns", "pagination", "size", "bordered", "loading"], Et = {
|
|
98
|
+
...Ge(gl(), Ll),
|
|
99
99
|
transformCellText: Function,
|
|
100
100
|
/**
|
|
101
101
|
* @Author gx12358
|
|
@@ -116,7 +116,7 @@ const Yl = ["rowKey", "rowSelection", "columns", "pagination", "size", "bordered
|
|
|
116
116
|
default: void 0
|
|
117
117
|
}
|
|
118
118
|
}, re = {
|
|
119
|
-
...
|
|
119
|
+
...Et,
|
|
120
120
|
rowSelection: {
|
|
121
121
|
type: Object,
|
|
122
122
|
default: void 0
|
|
@@ -384,18 +384,18 @@ const Yl = ["rowKey", "rowSelection", "columns", "pagination", "size", "bordered
|
|
|
384
384
|
onBeforeSearchSubmit: Function,
|
|
385
385
|
onColumnsStateChange: Function
|
|
386
386
|
};
|
|
387
|
-
function
|
|
387
|
+
function Wl(e) {
|
|
388
388
|
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !ce(e);
|
|
389
389
|
}
|
|
390
|
-
function
|
|
390
|
+
function Hl(e, l, a, o) {
|
|
391
391
|
if (!l) return e;
|
|
392
392
|
let s = e;
|
|
393
|
-
if (
|
|
393
|
+
if (U(l)) {
|
|
394
394
|
const i = l.node === "a" ? "span" : l.node;
|
|
395
|
-
return c(i,
|
|
395
|
+
return c(i, _((l == null ? void 0 : l.attr) || {}, {
|
|
396
396
|
class: [l.class, l.node === "a" ? `${a}-a` : ""],
|
|
397
397
|
onClick: l.click
|
|
398
|
-
}),
|
|
398
|
+
}), Wl(e) ? e : {
|
|
399
399
|
default: () => [e]
|
|
400
400
|
});
|
|
401
401
|
}
|
|
@@ -406,30 +406,30 @@ function Wl(e, l, a, o) {
|
|
|
406
406
|
}, [e]);
|
|
407
407
|
break;
|
|
408
408
|
case "time":
|
|
409
|
-
s =
|
|
409
|
+
s = X(e).format("HH:mm:ss");
|
|
410
410
|
break;
|
|
411
411
|
case "dateMonth":
|
|
412
|
-
s = `${
|
|
412
|
+
s = `${X(e).month() + 1}月`;
|
|
413
413
|
break;
|
|
414
414
|
case "dateTime":
|
|
415
|
-
s =
|
|
415
|
+
s = X(e).format("YYYY-MM-DD HH:mm:ss");
|
|
416
416
|
break;
|
|
417
417
|
}
|
|
418
418
|
return s;
|
|
419
419
|
}
|
|
420
|
-
function
|
|
420
|
+
function Vl(e, l) {
|
|
421
421
|
const a = l && l.current || 1, o = l && l.pageSize || 10;
|
|
422
422
|
return e.filter((s, i) => i < a * o && i >= o * (a - 1));
|
|
423
423
|
}
|
|
424
|
-
function
|
|
424
|
+
function Gl(e) {
|
|
425
425
|
const l = document.createElement("textarea");
|
|
426
426
|
l.style.position = "absolute", l.style.opacity = "0", l.value = e, document.body.appendChild(l), l.select(), document.execCommand("copy"), document.body.removeChild(l);
|
|
427
427
|
}
|
|
428
|
-
function
|
|
428
|
+
function Ql({ emit: e, loading: l }) {
|
|
429
429
|
var i;
|
|
430
|
-
const a = E(
|
|
431
|
-
|
|
432
|
-
a.value =
|
|
430
|
+
const a = E(ie(l.value) ? l.value : U(l.value) ? (i = l.value) == null ? void 0 : i.spinning : !1);
|
|
431
|
+
q(() => l.value, (f) => {
|
|
432
|
+
a.value = ie(f) ? f : U(f) ? f == null ? void 0 : f.spinning : a.value;
|
|
433
433
|
});
|
|
434
434
|
const o = w(() => a.value);
|
|
435
435
|
function s(f) {
|
|
@@ -437,7 +437,7 @@ function Gl({ emit: e, loading: l }) {
|
|
|
437
437
|
}
|
|
438
438
|
return { loadingComputed: o, loading: a, setLoading: s };
|
|
439
439
|
}
|
|
440
|
-
function
|
|
440
|
+
function _l({ size: e, emit: l }) {
|
|
441
441
|
const a = E("middle");
|
|
442
442
|
Ae(() => {
|
|
443
443
|
a.value = e.value;
|
|
@@ -447,19 +447,19 @@ function Ql({ size: e, emit: l }) {
|
|
|
447
447
|
}
|
|
448
448
|
return { sizeRef: a, setTableSize: o };
|
|
449
449
|
}
|
|
450
|
-
function
|
|
450
|
+
function ql({
|
|
451
451
|
slots: e,
|
|
452
452
|
props: l,
|
|
453
453
|
pagination: a
|
|
454
454
|
}) {
|
|
455
|
-
const o =
|
|
456
|
-
|
|
455
|
+
const o = we({}), s = E();
|
|
456
|
+
q(() => a.value, () => {
|
|
457
457
|
var x;
|
|
458
|
-
if (
|
|
458
|
+
if (ie(a.value) && !a.value) {
|
|
459
459
|
s.value = !1;
|
|
460
460
|
return;
|
|
461
461
|
}
|
|
462
|
-
const f =
|
|
462
|
+
const f = Bt(e, b(l), "pageItemRender"), m = Ee(f) ? {
|
|
463
463
|
itemRender: ({
|
|
464
464
|
page: d,
|
|
465
465
|
type: S,
|
|
@@ -488,11 +488,11 @@ function _l({
|
|
|
488
488
|
immediate: !0
|
|
489
489
|
});
|
|
490
490
|
function i(f) {
|
|
491
|
-
if (
|
|
491
|
+
if (U(s.value) && U(f)) {
|
|
492
492
|
const m = {};
|
|
493
493
|
Object.keys(f).forEach((C) => {
|
|
494
494
|
Object.prototype.hasOwnProperty.call(f, C) && s.value[C] === f[C] || (m[C] = f[C]);
|
|
495
|
-
}), Object.keys(m).length > 0 && (Object.assign(s.value, m),
|
|
495
|
+
}), Object.keys(m).length > 0 && (Object.assign(s.value, m), Xl(m) && Object.assign(o, m));
|
|
496
496
|
}
|
|
497
497
|
}
|
|
498
498
|
return {
|
|
@@ -501,19 +501,19 @@ function _l({
|
|
|
501
501
|
setPagination: i
|
|
502
502
|
};
|
|
503
503
|
}
|
|
504
|
-
function
|
|
504
|
+
function Xl(e) {
|
|
505
505
|
if (typeof e != "object" || e === null)
|
|
506
506
|
return !1;
|
|
507
507
|
const l = Object.keys(e);
|
|
508
508
|
return l.length === 2 && l.includes("pageNum") && l.includes("pageSize");
|
|
509
509
|
}
|
|
510
|
-
function
|
|
510
|
+
function Ul(e, l) {
|
|
511
511
|
const a = E([]), o = E([]);
|
|
512
|
-
|
|
512
|
+
q(() => {
|
|
513
513
|
var d;
|
|
514
514
|
return (d = l.value) == null ? void 0 : d.selectedRowKeys;
|
|
515
515
|
}, (d) => {
|
|
516
|
-
a.value =
|
|
516
|
+
a.value = tl([...d || []]);
|
|
517
517
|
}, {
|
|
518
518
|
deep: !0,
|
|
519
519
|
immediate: !0
|
|
@@ -539,7 +539,7 @@ function Xl(e, l) {
|
|
|
539
539
|
if (e.value && a.value.length !== o.value.length) {
|
|
540
540
|
const S = o.value.map((n) => n[e.value]), u = a.value.filter((n) => !S.includes(n));
|
|
541
541
|
d.forEach((n) => {
|
|
542
|
-
u.includes(n[e.value]) && o.value.push(
|
|
542
|
+
u.includes(n[e.value]) && o.value.push(ue(n));
|
|
543
543
|
});
|
|
544
544
|
}
|
|
545
545
|
},
|
|
@@ -548,7 +548,7 @@ function Xl(e, l) {
|
|
|
548
548
|
}
|
|
549
549
|
};
|
|
550
550
|
}
|
|
551
|
-
function
|
|
551
|
+
function Jl(e, l) {
|
|
552
552
|
const a = w(() => l || 0), o = E(), s = E(e);
|
|
553
553
|
function i() {
|
|
554
554
|
o.value && clearTimeout(o.value);
|
|
@@ -561,12 +561,12 @@ function Ul(e, l) {
|
|
|
561
561
|
}, a.value);
|
|
562
562
|
}));
|
|
563
563
|
}
|
|
564
|
-
return
|
|
564
|
+
return Yl(i), {
|
|
565
565
|
cancel: i,
|
|
566
566
|
run: f
|
|
567
567
|
};
|
|
568
568
|
}
|
|
569
|
-
function
|
|
569
|
+
function Zl(e) {
|
|
570
570
|
const l = w(() => e.polling), a = w(() => e.debounceTime), o = w(() => e.dataSource);
|
|
571
571
|
return {
|
|
572
572
|
polling: l,
|
|
@@ -576,129 +576,129 @@ function Jl(e) {
|
|
|
576
576
|
dataSource: o
|
|
577
577
|
};
|
|
578
578
|
}
|
|
579
|
-
function
|
|
580
|
-
const M = E(),
|
|
581
|
-
var
|
|
582
|
-
return
|
|
583
|
-
}),
|
|
579
|
+
function ea({ polling: e, request: l, postData: a, dataSource: o, waitRequest: s, debounceTime: i }, { search: f, columns: m, loading: C, setLoading: x, setColumns: d, removeRowKeys: S, syncSelectedRows: u, formParamsRef: n, setPagination: r, paginationInfo: g, onBeforeSearchSubmit: T, hasCustomRender: O }, F) {
|
|
580
|
+
const M = E(), H = E(!0), L = E(!1), W = E(!1), z = E([]), Q = E(), V = w(() => {
|
|
581
|
+
var R;
|
|
582
|
+
return U(f.value) ? ((R = f.value) == null ? void 0 : R.type) === "button" : !!f.value;
|
|
583
|
+
}), se = async (R = {}) => {
|
|
584
584
|
var ze;
|
|
585
|
-
const { pagination:
|
|
586
|
-
if (!l || !Ee(l) || b(s) && C.value ||
|
|
585
|
+
const { pagination: k, filters: v = {}, sorter: Y = {}, removeKeys: $e = [], isPolling: Xe = !1 } = R;
|
|
586
|
+
if (!l || !Ee(l) || b(s) && C.value || L.value)
|
|
587
587
|
return o.value || [];
|
|
588
|
-
if (
|
|
589
|
-
|
|
588
|
+
if (L.value = !0, !Xe || b(s) || H.value ? x(!0) : y(!0), b(s)) {
|
|
589
|
+
H.value = !1, L.value = !1;
|
|
590
590
|
return;
|
|
591
591
|
}
|
|
592
|
-
|
|
592
|
+
k && r(k);
|
|
593
593
|
try {
|
|
594
594
|
let ve = {};
|
|
595
|
-
if (
|
|
595
|
+
if (ie(k) && !k || ie(g))
|
|
596
596
|
ve = {};
|
|
597
597
|
else {
|
|
598
|
-
const { current:
|
|
599
|
-
ve.pageNum =
|
|
598
|
+
const { current: K = 1, pageSize: ye = 10, total: Z } = b(g) || {};
|
|
599
|
+
ve.pageNum = nl({ current: K, pageSize: ye, total: Z }, $e.length), $e.length && S($e), ve.pageSize = ye;
|
|
600
600
|
}
|
|
601
|
-
const Ke =
|
|
602
|
-
Ke.forEach((
|
|
603
|
-
const ye = (
|
|
604
|
-
|
|
601
|
+
const Ke = U(Y) ? [Y] : Y;
|
|
602
|
+
Ke.forEach((K) => {
|
|
603
|
+
const ye = (K == null ? void 0 : K.columnKey) || (K == null ? void 0 : K.field);
|
|
604
|
+
K && (K != null && K.order) ? d(b(m).map((Z) => (Z.dataIndex === ye ? Z.sortOrder = K == null ? void 0 : K.order : Z.sortOrder = null, Z))) : K && d(b(m).map((Z) => (Z.dataIndex === ye && (Z.sortOrder = null), Z)));
|
|
605
605
|
});
|
|
606
|
-
let
|
|
606
|
+
let Ie = {
|
|
607
607
|
...ve || {},
|
|
608
|
-
...
|
|
608
|
+
...R.params,
|
|
609
609
|
...n
|
|
610
610
|
};
|
|
611
|
-
T && Ee(T) && (
|
|
612
|
-
let
|
|
613
|
-
const ge = await (l == null ? void 0 : l(
|
|
614
|
-
if (
|
|
615
|
-
|
|
616
|
-
const
|
|
617
|
-
return
|
|
618
|
-
total:
|
|
619
|
-
}), p(
|
|
611
|
+
T && Ee(T) && (Ie = await T(Ie, Y, v));
|
|
612
|
+
let ee = [];
|
|
613
|
+
const ge = await (l == null ? void 0 : l(Ie, Ke, v));
|
|
614
|
+
if (L.value = !1, ge && (ge != null && ge.success)) {
|
|
615
|
+
ee = ge.data || [], a && Ee(a) && (ee = await (a == null ? void 0 : a(ee))), u(ee);
|
|
616
|
+
const K = ge.total || (ee == null ? void 0 : ee.length) || 0;
|
|
617
|
+
return K !== ((ze = b(g)) == null ? void 0 : ze.total) && r({
|
|
618
|
+
total: K || 0
|
|
619
|
+
}), p(ee), ee;
|
|
620
620
|
} else
|
|
621
621
|
return [];
|
|
622
622
|
} catch (ve) {
|
|
623
|
-
|
|
623
|
+
z.value === void 0 && p([]), F("requestError", ve);
|
|
624
624
|
} finally {
|
|
625
|
-
|
|
625
|
+
H.value = !1, x(!1);
|
|
626
626
|
}
|
|
627
627
|
return [];
|
|
628
|
-
},
|
|
629
|
-
|
|
630
|
-
const
|
|
631
|
-
return v && !M.value && (
|
|
632
|
-
|
|
633
|
-
}, Math.max(v, 2e3))),
|
|
628
|
+
}, te = Jl(async (R) => {
|
|
629
|
+
Q.value && clearTimeout(Q.value);
|
|
630
|
+
const k = await se(R), v = ll(e.value, k);
|
|
631
|
+
return v && !M.value && (Q.value = setTimeout(() => {
|
|
632
|
+
te.run({ ...R, isPolling: v });
|
|
633
|
+
}, Math.max(v, 2e3))), k;
|
|
634
634
|
}, i.value || 10);
|
|
635
|
-
|
|
636
|
-
M.value = !0, clearTimeout(
|
|
637
|
-
}),
|
|
638
|
-
M.value = !0, clearTimeout(
|
|
639
|
-
}),
|
|
640
|
-
e.value ?
|
|
641
|
-
}, { immediate: !0 }),
|
|
635
|
+
cl(() => {
|
|
636
|
+
M.value = !0, clearTimeout(Q.value);
|
|
637
|
+
}), dl(() => {
|
|
638
|
+
M.value = !0, clearTimeout(Q.value);
|
|
639
|
+
}), q(() => e.value, () => {
|
|
640
|
+
e.value ? te.run({ isPolling: !0 }) : clearTimeout(Q.value);
|
|
641
|
+
}, { immediate: !0 }), q([() => s.value, () => o.value], () => {
|
|
642
642
|
me();
|
|
643
|
-
}, { deep: !0, immediate: !0 }),
|
|
644
|
-
|
|
643
|
+
}, { deep: !0, immediate: !0 }), q([() => n], () => {
|
|
644
|
+
V.value || me();
|
|
645
645
|
}, {
|
|
646
646
|
deep: !0,
|
|
647
647
|
immediate: !0
|
|
648
648
|
});
|
|
649
649
|
function me() {
|
|
650
|
-
|
|
650
|
+
Re(l) ? (!H.value || !e.value) && te.run({ isPolling: !1 }) : p(o.value || []);
|
|
651
651
|
}
|
|
652
|
-
const
|
|
653
|
-
if (
|
|
654
|
-
return b(
|
|
655
|
-
const
|
|
656
|
-
return !b(
|
|
657
|
-
}), t = w(() => b(
|
|
658
|
-
function y(
|
|
659
|
-
|
|
652
|
+
const J = w(() => {
|
|
653
|
+
if (O.value)
|
|
654
|
+
return b(z);
|
|
655
|
+
const R = m.value.filter((k) => k.show || k.show === void 0);
|
|
656
|
+
return !b(z) || !R || R.length === 0 ? [] : b(z);
|
|
657
|
+
}), t = w(() => b(z).some((R) => ne(R.children) && R.children.length > 0));
|
|
658
|
+
function y(R) {
|
|
659
|
+
W.value = R;
|
|
660
660
|
}
|
|
661
|
-
function
|
|
662
|
-
|
|
661
|
+
function I(R, k, v, Y) {
|
|
662
|
+
te.run({ pagination: R, filters: k, sorter: v, extra: Y, isPolling: !1 }), F("change", R, k, v, Y);
|
|
663
663
|
}
|
|
664
|
-
function p(
|
|
664
|
+
function p(R) {
|
|
665
665
|
var v;
|
|
666
|
-
const
|
|
667
|
-
if (!He(
|
|
668
|
-
const
|
|
669
|
-
|
|
670
|
-
total:
|
|
666
|
+
const k = al(ue(R), b(g.value));
|
|
667
|
+
if (!He(k, z.value) && (z.value = k, !l || !Ee(l))) {
|
|
668
|
+
const Y = k.length || 0;
|
|
669
|
+
Y !== ((v = b(g)) == null ? void 0 : v.total) && r({
|
|
670
|
+
total: Y
|
|
671
671
|
});
|
|
672
672
|
}
|
|
673
673
|
}
|
|
674
|
-
function D({ key:
|
|
674
|
+
function D({ key: R, record: k, type: v = "update" }) {
|
|
675
675
|
switch (v) {
|
|
676
676
|
case "update":
|
|
677
|
-
|
|
677
|
+
z.value = z.value.map((Y) => R && k[R] === Y[R] ? { ...Y, ...k } : Y);
|
|
678
678
|
break;
|
|
679
679
|
case "push":
|
|
680
|
-
|
|
680
|
+
z.value.push(k);
|
|
681
681
|
break;
|
|
682
682
|
case "unshift":
|
|
683
|
-
|
|
683
|
+
z.value.unshift(k);
|
|
684
684
|
break;
|
|
685
685
|
case "delete":
|
|
686
|
-
|
|
686
|
+
z.value = z.value.filter((Y) => R ? R && k[R] !== Y[R] : !0);
|
|
687
687
|
break;
|
|
688
688
|
}
|
|
689
689
|
}
|
|
690
690
|
return {
|
|
691
|
-
dataSource:
|
|
691
|
+
dataSource: J,
|
|
692
692
|
isTreeDataRef: t,
|
|
693
693
|
reSetDataList: p,
|
|
694
694
|
changeDataValue: D,
|
|
695
|
-
handleTableChange:
|
|
696
|
-
reload: async (
|
|
697
|
-
|
|
695
|
+
handleTableChange: I,
|
|
696
|
+
reload: async (R) => {
|
|
697
|
+
Re(l) ? await te.run({ ...R, isPolling: !1 }) : F("reload");
|
|
698
698
|
}
|
|
699
699
|
};
|
|
700
700
|
}
|
|
701
|
-
function
|
|
701
|
+
function ta(e) {
|
|
702
702
|
const l = {};
|
|
703
703
|
return e.forEach((a) => {
|
|
704
704
|
let o = a.initialValue;
|
|
@@ -706,8 +706,8 @@ function ea(e) {
|
|
|
706
706
|
!o && s.includes(a.valueType) ? o = void 0 : !o && i.includes(a.valueType) ? o = null : o || (o = ""), a.name === "dateRange" ? (l[a.rangeStartName || "start"] = o ? o[0] : null, l[a.rangeEndName || "end"] = o ? o[1] : null) : a.name && (l[a.name] = o);
|
|
707
707
|
}), l;
|
|
708
708
|
}
|
|
709
|
-
function
|
|
710
|
-
const s =
|
|
709
|
+
function la({ searchMap: e, params: l, columns: a, setPagination: o }) {
|
|
710
|
+
const s = we({}), i = we({}), f = E([]), m = (x) => {
|
|
711
711
|
var S, u;
|
|
712
712
|
const d = [];
|
|
713
713
|
if ((x === "all" || x === "searchMap") && ((S = e.value) == null || S.forEach((n) => d.push(n)), d.forEach((n) => {
|
|
@@ -724,20 +724,20 @@ function ta({ searchMap: e, params: l, columns: a, setPagination: o }) {
|
|
|
724
724
|
} : r) : f.value.push(n);
|
|
725
725
|
})), x === "all" || x === "searchMap" || x === "columns") {
|
|
726
726
|
o({ current: 1 });
|
|
727
|
-
const n =
|
|
727
|
+
const n = ta(d);
|
|
728
728
|
Object.assign(i, { ...n });
|
|
729
729
|
for (const r in n)
|
|
730
730
|
s[r] || (s[r] = n[r]);
|
|
731
731
|
}
|
|
732
732
|
(x === "all" || x === "params") && (o({ current: 1 }), Object.assign(s, l.value));
|
|
733
733
|
};
|
|
734
|
-
|
|
734
|
+
fl(() => {
|
|
735
735
|
m("all");
|
|
736
|
-
}),
|
|
736
|
+
}), q(() => l.value, () => {
|
|
737
737
|
m("params");
|
|
738
|
-
}, { deep: !0 }),
|
|
738
|
+
}, { deep: !0 }), q(() => e.value, () => {
|
|
739
739
|
m("searchMap");
|
|
740
|
-
}, { deep: !0 }),
|
|
740
|
+
}, { deep: !0 }), q(() => a.value, () => {
|
|
741
741
|
m("columns");
|
|
742
742
|
}, { deep: !0 });
|
|
743
743
|
function C(x) {
|
|
@@ -745,12 +745,12 @@ function ta({ searchMap: e, params: l, columns: a, setPagination: o }) {
|
|
|
745
745
|
}
|
|
746
746
|
return { formDataRef: f, formParamsRef: s, defaultParamsRef: i, setFormParams: C };
|
|
747
747
|
}
|
|
748
|
-
function
|
|
749
|
-
const o = E(void 0), s =
|
|
750
|
-
|
|
748
|
+
function aa({ columns: e, columnsState: l, changeColumns: a }) {
|
|
749
|
+
const o = E(void 0), s = we({}), i = we({}), f = we({}), m = E([]);
|
|
750
|
+
q(() => e.value, () => {
|
|
751
751
|
var S;
|
|
752
752
|
(S = b(e)) == null || S.forEach(({ show: u, key: n, fixed: r }, g) => {
|
|
753
|
-
const T =
|
|
753
|
+
const T = Ft(n, g);
|
|
754
754
|
T && (f[T] = { show: u === void 0 ? !0 : u, fixed: r });
|
|
755
755
|
});
|
|
756
756
|
const d = b(e).map((u) => u.key);
|
|
@@ -778,7 +778,7 @@ function la({ columns: e, columnsState: l, changeColumns: a }) {
|
|
|
778
778
|
setSortKeyColumns: x
|
|
779
779
|
};
|
|
780
780
|
}
|
|
781
|
-
function
|
|
781
|
+
function na(e) {
|
|
782
782
|
const l = w(() => e.draggabled), a = w(() => e.neverScroll), o = w(() => e.autoScroll);
|
|
783
783
|
return {
|
|
784
784
|
draggabled: l,
|
|
@@ -786,9 +786,9 @@ function aa(e) {
|
|
|
786
786
|
autoScroll: o
|
|
787
787
|
};
|
|
788
788
|
}
|
|
789
|
-
function
|
|
789
|
+
function ua({ scroll: e, columns: l, breakpoint: a, draggabled: o, autoScroll: s, neverScroll: i }) {
|
|
790
790
|
const f = E([]), m = E([]);
|
|
791
|
-
|
|
791
|
+
q([
|
|
792
792
|
() => e.value,
|
|
793
793
|
() => l.value,
|
|
794
794
|
() => a.value,
|
|
@@ -797,14 +797,14 @@ function na({ scroll: e, columns: l, breakpoint: a, draggabled: o, autoScroll: s
|
|
|
797
797
|
() => s.value,
|
|
798
798
|
() => i.value
|
|
799
799
|
], () => {
|
|
800
|
-
const r = d(
|
|
801
|
-
He(r,
|
|
800
|
+
const r = d(Te(l.value));
|
|
801
|
+
He(r, Te(f.value)) || (f.value = ue(r)), He(r, Te(m.value)) || (m.value = ue(r));
|
|
802
802
|
}, {
|
|
803
803
|
deep: !0,
|
|
804
804
|
immediate: !0
|
|
805
805
|
});
|
|
806
806
|
const C = w(() => {
|
|
807
|
-
const r = x(b(f).filter((
|
|
807
|
+
const r = x(b(f).filter((O) => O.fixed === "left")), g = x(b(f).filter((O) => O.fixed !== "left" && O.fixed !== "right")), T = x(b(f).filter((O) => O.fixed === "right"));
|
|
808
808
|
return [
|
|
809
809
|
...r,
|
|
810
810
|
...g,
|
|
@@ -812,19 +812,19 @@ function na({ scroll: e, columns: l, breakpoint: a, draggabled: o, autoScroll: s
|
|
|
812
812
|
];
|
|
813
813
|
});
|
|
814
814
|
function x(r) {
|
|
815
|
-
return r.sort((g, T) =>
|
|
815
|
+
return r.sort((g, T) => ul(g, T, "order", 0));
|
|
816
816
|
}
|
|
817
817
|
function d(r) {
|
|
818
|
-
return
|
|
819
|
-
var
|
|
820
|
-
if (g.dataIndex === "action" || T === r.length - 1 ? g.resizable = !1 : g.resizable =
|
|
818
|
+
return ue(r).map((g, T) => {
|
|
819
|
+
var O;
|
|
820
|
+
if (g.dataIndex === "action" || T === r.length - 1 ? g.resizable = !1 : g.resizable = ie(g.resizable) ? g.resizable : !!(Qe(g.width) && b(o)), !g.width || b(i))
|
|
821
821
|
return g;
|
|
822
822
|
if (g.dataIndex === "action" && b(s))
|
|
823
|
-
if ((
|
|
823
|
+
if ((O = b(e)) != null && O.x || !b(a))
|
|
824
824
|
g.width = g.width || 100, g.fixed = "right";
|
|
825
825
|
else {
|
|
826
|
-
const
|
|
827
|
-
g.width = (
|
|
826
|
+
const F = b(l).find((M) => M.dataIndex === g.dataIndex);
|
|
827
|
+
g.width = (F == null ? void 0 : F.width) || "", g.fixed = F == null ? void 0 : F.fixed;
|
|
828
828
|
}
|
|
829
829
|
return g;
|
|
830
830
|
});
|
|
@@ -837,14 +837,14 @@ function na({ scroll: e, columns: l, breakpoint: a, draggabled: o, autoScroll: s
|
|
|
837
837
|
f.value = [];
|
|
838
838
|
return;
|
|
839
839
|
}
|
|
840
|
-
He(d(r),
|
|
840
|
+
He(d(r), Te(f.value)) || (f.value = d(r));
|
|
841
841
|
}
|
|
842
842
|
function n(r) {
|
|
843
|
-
u(
|
|
844
|
-
var
|
|
843
|
+
u(ue(Te(l.value)).map((g) => {
|
|
844
|
+
var O, F, M;
|
|
845
845
|
const T = g.key ? {
|
|
846
|
-
show: (
|
|
847
|
-
fixed: (
|
|
846
|
+
show: (O = r[g.key]) == null ? void 0 : O.show,
|
|
847
|
+
fixed: (F = r[g.key]) == null ? void 0 : F.fixed,
|
|
848
848
|
order: (M = r[g.key]) == null ? void 0 : M.order
|
|
849
849
|
} : {};
|
|
850
850
|
return { ...g, ...T };
|
|
@@ -859,7 +859,7 @@ function na({ scroll: e, columns: l, breakpoint: a, draggabled: o, autoScroll: s
|
|
|
859
859
|
resizeColumnWidth: S
|
|
860
860
|
};
|
|
861
861
|
}
|
|
862
|
-
function
|
|
862
|
+
function ia(e) {
|
|
863
863
|
const l = w(() => e.scroll), a = w(() => e.autoScroll), o = w(() => e.modalScroll), s = w(() => e.neverScroll), i = w(() => e.rowSelection), f = w(() => e.scrollBreakpoint);
|
|
864
864
|
return {
|
|
865
865
|
scroll: l,
|
|
@@ -870,29 +870,29 @@ function ua(e) {
|
|
|
870
870
|
scrollBreakpoint: f
|
|
871
871
|
};
|
|
872
872
|
}
|
|
873
|
-
function
|
|
873
|
+
function sa({ scroll: e, columns: l, autoScroll: a, modalScroll: o, neverScroll: s, rowSelection: i, screens: f, innerWidth: m, scrollBreakpoint: C }) {
|
|
874
874
|
const x = w(() => {
|
|
875
875
|
var u, n, r;
|
|
876
|
-
return b(C) ? Qe(b(C)) ? m.value > b(C) :
|
|
876
|
+
return b(C) ? Qe(b(C)) ? m.value > b(C) : Rt(b(C)) ? (u = f.value) == null ? void 0 : u[b(C)] : (n = f.value) == null ? void 0 : n.xl : (r = f.value) == null ? void 0 : r.xl;
|
|
877
877
|
}), d = w(() => {
|
|
878
878
|
let u = 0;
|
|
879
|
-
const n = b(i) ? 60 : 0, r = 150, g =
|
|
880
|
-
g.forEach((
|
|
881
|
-
u += Number.parseInt(String(
|
|
879
|
+
const n = b(i) ? 60 : 0, r = 150, g = ue(b(l));
|
|
880
|
+
g.forEach((F) => {
|
|
881
|
+
u += Number.parseInt(String(F.width)) || 0;
|
|
882
882
|
});
|
|
883
|
-
const
|
|
884
|
-
return
|
|
883
|
+
const O = g.filter((F) => !Reflect.has(F, "width")).length;
|
|
884
|
+
return O !== 0 && (u += O * r), n && (u += n), u;
|
|
885
885
|
});
|
|
886
886
|
return { proScroll: w(() => {
|
|
887
887
|
var u, n;
|
|
888
888
|
return b(s) ? {} : b(e) && Object.keys(b(e)).length ? b(e) : b(o) ? {
|
|
889
889
|
y: ((u = b(e)) == null ? void 0 : u.y) || ((n = f.value) != null && n.xl ? 400 : 235)
|
|
890
|
-
} : b(a) ? x.value ? {} :
|
|
890
|
+
} : b(a) ? x.value ? {} : ie(x.value) ? { x: b(d) } : {} : {};
|
|
891
891
|
}), breakpoint: x };
|
|
892
892
|
}
|
|
893
|
-
const { provideContext:
|
|
894
|
-
function
|
|
895
|
-
const a =
|
|
893
|
+
const { provideContext: oa, useInjectContext: he } = Kl("pro-table");
|
|
894
|
+
function ra(e, l) {
|
|
895
|
+
const a = we({});
|
|
896
896
|
function o() {
|
|
897
897
|
Object.keys(e).forEach((f) => {
|
|
898
898
|
s(f, e[f]);
|
|
@@ -915,7 +915,7 @@ function oa(e, l) {
|
|
|
915
915
|
changeFormState: s
|
|
916
916
|
};
|
|
917
917
|
}
|
|
918
|
-
const
|
|
918
|
+
const ca = (e) => ({
|
|
919
919
|
[`${e.componentCls}-search`]: {
|
|
920
920
|
position: "relative",
|
|
921
921
|
display: "flex",
|
|
@@ -982,31 +982,31 @@ const ra = (e) => ({
|
|
|
982
982
|
alignItems: "center"
|
|
983
983
|
}
|
|
984
984
|
});
|
|
985
|
-
function
|
|
986
|
-
return typeof l == "function" ? l(
|
|
985
|
+
function Ce(e, l) {
|
|
986
|
+
return typeof l == "function" ? l(X(e)) : X(e).format(l);
|
|
987
987
|
}
|
|
988
988
|
function Ne(e, l) {
|
|
989
989
|
return l ? "YYYY-MM-DD HH:mm:ss" : e ?? "YYYY-MM-DD";
|
|
990
990
|
}
|
|
991
|
-
const
|
|
992
|
-
if (
|
|
991
|
+
const Tt = (e, l, a = "string") => {
|
|
992
|
+
if (ne(e)) {
|
|
993
993
|
const [o, s] = e;
|
|
994
994
|
let i, f;
|
|
995
995
|
if (Array.isArray(l) ? (i = l[0], f = l[1]) : typeof l == "object" && l.type === "mask" ? (i = l.format, f = l.format) : (i = l, f = l), a === "string") {
|
|
996
|
-
const m = o ?
|
|
996
|
+
const m = o ? Ce(o, i) : "", C = s ? Ce(s, f) : "";
|
|
997
997
|
return [m, C];
|
|
998
998
|
}
|
|
999
|
-
return [
|
|
999
|
+
return [X(o), X(s)];
|
|
1000
1000
|
}
|
|
1001
1001
|
}, {
|
|
1002
|
-
useBreakpoint:
|
|
1002
|
+
useBreakpoint: da
|
|
1003
1003
|
} = st, {
|
|
1004
|
-
MonthPicker:
|
|
1005
|
-
RangePicker:
|
|
1006
|
-
YearPicker:
|
|
1007
|
-
WeekPicker:
|
|
1008
|
-
QuarterPicker:
|
|
1009
|
-
} =
|
|
1004
|
+
MonthPicker: fa,
|
|
1005
|
+
RangePicker: ha,
|
|
1006
|
+
YearPicker: ma,
|
|
1007
|
+
WeekPicker: va,
|
|
1008
|
+
QuarterPicker: ga
|
|
1009
|
+
} = jt, Je = [{
|
|
1010
1010
|
value: "xxl",
|
|
1011
1011
|
span: 4
|
|
1012
1012
|
}, {
|
|
@@ -1024,7 +1024,7 @@ const pt = (e, l, a = "string") => {
|
|
|
1024
1024
|
}, {
|
|
1025
1025
|
value: "xs",
|
|
1026
1026
|
span: 1
|
|
1027
|
-
}],
|
|
1027
|
+
}], Dt = /* @__PURE__ */ fe({
|
|
1028
1028
|
name: "ProTableForm",
|
|
1029
1029
|
props: {
|
|
1030
1030
|
modal: re.modalScroll,
|
|
@@ -1045,7 +1045,7 @@ const pt = (e, l, a = "string") => {
|
|
|
1045
1045
|
const {
|
|
1046
1046
|
wrapSSR: o,
|
|
1047
1047
|
hashId: s
|
|
1048
|
-
} = qe("ProTableForm", [
|
|
1048
|
+
} = qe("ProTableForm", [ca], e.prefixCls), i = Nt(), f = da(), {
|
|
1049
1049
|
manualSearch: m,
|
|
1050
1050
|
searchConfig: C,
|
|
1051
1051
|
searchActions: x
|
|
@@ -1053,51 +1053,51 @@ const pt = (e, l, a = "string") => {
|
|
|
1053
1053
|
formState: d,
|
|
1054
1054
|
resetFormState: S,
|
|
1055
1055
|
changeFormState: u
|
|
1056
|
-
} =
|
|
1056
|
+
} = ra(e.defaultParams || {}, e.searchMap || []), n = E(!1), r = w(() => {
|
|
1057
1057
|
var t, y;
|
|
1058
|
-
return
|
|
1058
|
+
return ie((t = x.value) == null ? void 0 : t.reset) ? (y = x.value) == null ? void 0 : y.reset : m.value;
|
|
1059
1059
|
}), g = w(() => {
|
|
1060
1060
|
var t;
|
|
1061
|
-
return
|
|
1061
|
+
return O((t = C.value) == null ? void 0 : t.span);
|
|
1062
1062
|
}), T = w(() => {
|
|
1063
1063
|
var t;
|
|
1064
1064
|
return (t = C.value) == null ? void 0 : t.label;
|
|
1065
1065
|
});
|
|
1066
|
-
|
|
1066
|
+
q(() => {
|
|
1067
1067
|
var t;
|
|
1068
1068
|
return (t = C.value) == null ? void 0 : t.defaultCollapsed;
|
|
1069
1069
|
}, (t) => {
|
|
1070
1070
|
n.value = n.value || !!t;
|
|
1071
1071
|
});
|
|
1072
|
-
function
|
|
1072
|
+
function O(t) {
|
|
1073
1073
|
let y = 4;
|
|
1074
|
-
for (let
|
|
1075
|
-
const p = Je[
|
|
1074
|
+
for (let I = 0; I < Je.length; I += 1) {
|
|
1075
|
+
const p = Je[I].value;
|
|
1076
1076
|
if (f.value[p]) {
|
|
1077
|
-
y = (t == null ? void 0 : t[p]) || (e.modal ? 3 : Je[
|
|
1077
|
+
y = (t == null ? void 0 : t[p]) || (e.modal ? 3 : Je[I].span);
|
|
1078
1078
|
break;
|
|
1079
1079
|
}
|
|
1080
1080
|
}
|
|
1081
1081
|
return y;
|
|
1082
1082
|
}
|
|
1083
|
-
const
|
|
1083
|
+
const F = (t) => {
|
|
1084
1084
|
n.value = t;
|
|
1085
|
-
}, M = (t, y,
|
|
1086
|
-
...
|
|
1085
|
+
}, M = (t, y, I) => (t + 1) % y === 0 ? {
|
|
1086
|
+
...I,
|
|
1087
1087
|
marginRight: 0
|
|
1088
1088
|
} : {
|
|
1089
|
-
...
|
|
1089
|
+
...I,
|
|
1090
1090
|
marginRight: "2%"
|
|
1091
|
-
},
|
|
1092
|
-
const t =
|
|
1093
|
-
return y && (t[y.name] = d[y.name] || y.initialValue || ""),
|
|
1094
|
-
},
|
|
1095
|
-
|
|
1096
|
-
var
|
|
1097
|
-
(m.value || t) && ((
|
|
1091
|
+
}, H = () => {
|
|
1092
|
+
const t = ue(d), y = e.searchMap.find((D) => D.valueType === "text") || "", I = e.searchMap.find((D) => D.valueType === "dateRange") || "", p = e.searchMap.find((D) => D.valueType === "treeSelect");
|
|
1093
|
+
return y && (t[y.name] = d[y.name] || y.initialValue || ""), I && (t[I.rangeStartName || "start"] = t[I.name] ? t[I.name][0] : "", t[I.rangeEndName || "end"] = t[I.name] ? t[I.name][1] : "", delete t[I.name]), p && (p != null && p.name && ne(d[p == null ? void 0 : p.name]) && (t[p.name] = d[p.name].length ? d[p.name].map((D) => D[p.valueKey === "text" ? "label" : "value"]).join() : ""), p != null && p.name && ne(t[p == null ? void 0 : p.name]) && (t[p.name] = t[p.name].length ? t[p.name].map((D) => D[p.valueKey === "text" ? "label" : "value"]) : "")), t;
|
|
1094
|
+
}, L = (t = !1, y) => {
|
|
1095
|
+
hl(() => {
|
|
1096
|
+
var I;
|
|
1097
|
+
(m.value || t) && ((I = e.onSearch) == null || I.call(e, H(), t ? y ? "reset" : "submit" : void 0));
|
|
1098
1098
|
});
|
|
1099
|
-
},
|
|
1100
|
-
var
|
|
1099
|
+
}, W = (t, y) => {
|
|
1100
|
+
var I, p;
|
|
1101
1101
|
switch (y.valueType) {
|
|
1102
1102
|
case "text":
|
|
1103
1103
|
u(y.name || "", t || "");
|
|
@@ -1106,101 +1106,101 @@ const pt = (e, l, a = "string") => {
|
|
|
1106
1106
|
u(y.name || "", t ?? void 0);
|
|
1107
1107
|
break;
|
|
1108
1108
|
case "treeSelect":
|
|
1109
|
-
u(y.name || "", t ?? ((
|
|
1109
|
+
u(y.name || "", t ?? ((I = y.field) != null && I.treeCheckable || (p = y.field) != null && p.multiple ? [] : null));
|
|
1110
1110
|
break;
|
|
1111
1111
|
case "date":
|
|
1112
|
-
u(y.name || "", t ?
|
|
1112
|
+
u(y.name || "", t ? Ce(t, Ne(y.valueFormat, y.showTime)) : null);
|
|
1113
1113
|
break;
|
|
1114
1114
|
case "dateWeek":
|
|
1115
|
-
u(y.name || "", t ?
|
|
1115
|
+
u(y.name || "", t ? Ce(t, "YYYY-wo") : null);
|
|
1116
1116
|
break;
|
|
1117
1117
|
case "dateMonth":
|
|
1118
|
-
u(y.name || "", t ?
|
|
1118
|
+
u(y.name || "", t ? Ce(t, "YYYY-MM") : null);
|
|
1119
1119
|
break;
|
|
1120
1120
|
case "dateQuarter":
|
|
1121
|
-
u(y.name || "", t ?
|
|
1121
|
+
u(y.name || "", t ? Ce(t, "YYYY-QQ") : null);
|
|
1122
1122
|
break;
|
|
1123
1123
|
case "dateYear":
|
|
1124
|
-
u(y.name || "", t ?
|
|
1124
|
+
u(y.name || "", t ? Ce(t, "YYYY") : null);
|
|
1125
1125
|
break;
|
|
1126
1126
|
case "dateRange":
|
|
1127
|
-
u(y.name || "", t &&
|
|
1127
|
+
u(y.name || "", t && ne(t) && t.length === 2 ? Tt(t, Ne(y.valueFormat, y.showTime)) : null);
|
|
1128
1128
|
break;
|
|
1129
1129
|
case "time":
|
|
1130
|
-
u(y.name || "", t ?
|
|
1130
|
+
u(y.name || "", t ? Ce(t, y.valueFormat || "HH:mm:ss") : null);
|
|
1131
1131
|
break;
|
|
1132
1132
|
}
|
|
1133
|
-
y.valueType === "treeSelect" || y.valueType,
|
|
1134
|
-
},
|
|
1135
|
-
S(),
|
|
1133
|
+
y.valueType === "treeSelect" || y.valueType, L();
|
|
1134
|
+
}, z = (t = !0) => {
|
|
1135
|
+
S(), L(!0, t);
|
|
1136
1136
|
};
|
|
1137
1137
|
a({
|
|
1138
|
-
getFormState: () =>
|
|
1139
|
-
resetForm:
|
|
1138
|
+
getFormState: () => H(),
|
|
1139
|
+
resetForm: z
|
|
1140
1140
|
});
|
|
1141
|
-
const
|
|
1141
|
+
const Q = () => {
|
|
1142
1142
|
var y;
|
|
1143
1143
|
const t = (y = i == null ? void 0 : i.emptyText) == null ? void 0 : y.value;
|
|
1144
1144
|
if (t) {
|
|
1145
|
-
const
|
|
1145
|
+
const I = ce(t), p = I ? Ot(t) : It(t || []);
|
|
1146
1146
|
return c("div", {
|
|
1147
|
-
class:
|
|
1148
|
-
}, [
|
|
1147
|
+
class: Se(`${e.prefixCls}-search-empty-text`, s.value)
|
|
1148
|
+
}, [I ? p : ne(p) ? p.map((D) => it(D)) : void 0]);
|
|
1149
1149
|
}
|
|
1150
|
-
},
|
|
1151
|
-
default: () => [r.value && c(
|
|
1152
|
-
onClick: () =>
|
|
1150
|
+
}, V = () => (m.value || r.value) && c(xe, null, {
|
|
1151
|
+
default: () => [r.value && c(St, {
|
|
1152
|
+
onClick: () => z()
|
|
1153
1153
|
}, {
|
|
1154
1154
|
default: () => {
|
|
1155
1155
|
var t;
|
|
1156
1156
|
return [((t = x.value) == null ? void 0 : t.resetText) || "重置"];
|
|
1157
1157
|
}
|
|
1158
|
-
}), m.value && c(
|
|
1158
|
+
}), m.value && c(St, {
|
|
1159
1159
|
loading: e.loading,
|
|
1160
1160
|
type: "primary",
|
|
1161
|
-
onClick: () =>
|
|
1161
|
+
onClick: () => L(!0)
|
|
1162
1162
|
}, {
|
|
1163
1163
|
default: () => {
|
|
1164
1164
|
var t;
|
|
1165
1165
|
return [((t = x.value) == null ? void 0 : t.searchText) || "查询"];
|
|
1166
1166
|
}
|
|
1167
1167
|
})]
|
|
1168
|
-
}),
|
|
1168
|
+
}), se = ({
|
|
1169
1169
|
formItemStyle: t,
|
|
1170
1170
|
advanced: y,
|
|
1171
|
-
showAdvanced:
|
|
1171
|
+
showAdvanced: I = !0
|
|
1172
1172
|
}) => c("div", {
|
|
1173
1173
|
style: t,
|
|
1174
1174
|
class: `${e.prefixCls}-search-collapse-button ${s.value}`
|
|
1175
|
-
}, [c(
|
|
1175
|
+
}, [c(xe, {
|
|
1176
1176
|
size: 16
|
|
1177
1177
|
}, {
|
|
1178
1178
|
default: () => {
|
|
1179
1179
|
var p, D;
|
|
1180
|
-
return [
|
|
1180
|
+
return [V(), I && c("span", {
|
|
1181
1181
|
class: `${e.prefixCls}-a ${s.value}`,
|
|
1182
|
-
onClick: () =>
|
|
1183
|
-
}, [y ? "收起" : "展开", (p = C.value) != null && p.collapseRender ? (D = C.value) == null ? void 0 : D.collapseRender(y) : y ? c(
|
|
1182
|
+
onClick: () => F(!y)
|
|
1183
|
+
}, [y ? "收起" : "展开", (p = C.value) != null && p.collapseRender ? (D = C.value) == null ? void 0 : D.collapseRender(y) : y ? c(yl, null, null) : c(bl, null, null)])];
|
|
1184
1184
|
}
|
|
1185
|
-
})]),
|
|
1186
|
-
var p, D,
|
|
1185
|
+
})]), te = (t) => {
|
|
1186
|
+
var p, D, R, k;
|
|
1187
1187
|
let y;
|
|
1188
|
-
const
|
|
1188
|
+
const I = m.value ? wt : wt.Search;
|
|
1189
1189
|
switch (t.valueType) {
|
|
1190
1190
|
case "text":
|
|
1191
|
-
y = c(
|
|
1191
|
+
y = c(I, _({
|
|
1192
1192
|
style: {
|
|
1193
1193
|
width: "100%"
|
|
1194
1194
|
},
|
|
1195
1195
|
value: d[t.name],
|
|
1196
1196
|
placeholder: t.placeholder || "请输入",
|
|
1197
1197
|
allowClear: t.allowClear || t.allowClear === !1 ? t.allowClear : !0,
|
|
1198
|
-
onChange: (v) =>
|
|
1199
|
-
onSearch: (v) =>
|
|
1198
|
+
onChange: (v) => W(v.target.value, t),
|
|
1199
|
+
onSearch: (v) => L()
|
|
1200
1200
|
}, t.field || {}), null);
|
|
1201
1201
|
break;
|
|
1202
1202
|
case "select":
|
|
1203
|
-
y = c(
|
|
1203
|
+
y = c(Pl, _({
|
|
1204
1204
|
style: {
|
|
1205
1205
|
width: "100%"
|
|
1206
1206
|
},
|
|
@@ -1213,8 +1213,8 @@ const pt = (e, l, a = "string") => {
|
|
|
1213
1213
|
notFoundContent: t.loading === void 0 ? void 0 : t.loading ? c(nt, {
|
|
1214
1214
|
size: "small",
|
|
1215
1215
|
indicator: (p = i == null ? void 0 : i.indicator) == null ? void 0 : p.value
|
|
1216
|
-
}, null) :
|
|
1217
|
-
onChange: (v) =>
|
|
1216
|
+
}, null) : Q(),
|
|
1217
|
+
onChange: (v) => W(v, t),
|
|
1218
1218
|
options: t.loading ? [] : (D = t == null ? void 0 : t.valueEnum) == null ? void 0 : D.map((v) => ({
|
|
1219
1219
|
label: v.text,
|
|
1220
1220
|
value: v.value
|
|
@@ -1222,7 +1222,7 @@ const pt = (e, l, a = "string") => {
|
|
|
1222
1222
|
}, t.field || {}), null);
|
|
1223
1223
|
break;
|
|
1224
1224
|
case "treeSelect":
|
|
1225
|
-
y = c(
|
|
1225
|
+
y = c(Ol, _({
|
|
1226
1226
|
style: {
|
|
1227
1227
|
width: "100%"
|
|
1228
1228
|
},
|
|
@@ -1233,95 +1233,95 @@ const pt = (e, l, a = "string") => {
|
|
|
1233
1233
|
getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
|
|
1234
1234
|
notFoundContent: t.loading === void 0 ? void 0 : t.loading ? c(nt, {
|
|
1235
1235
|
size: "small",
|
|
1236
|
-
indicator: (
|
|
1237
|
-
}, null) :
|
|
1238
|
-
onChange: (v) =>
|
|
1236
|
+
indicator: (R = i == null ? void 0 : i.indicator) == null ? void 0 : R.value
|
|
1237
|
+
}, null) : Q(),
|
|
1238
|
+
onChange: (v) => W(v, t)
|
|
1239
1239
|
}, t.field || {}), null);
|
|
1240
1240
|
break;
|
|
1241
1241
|
case "date":
|
|
1242
|
-
y = c(
|
|
1242
|
+
y = c(jt, _({
|
|
1243
1243
|
style: {
|
|
1244
1244
|
width: "100%"
|
|
1245
1245
|
},
|
|
1246
|
-
value: d[t.name] ?
|
|
1246
|
+
value: d[t.name] ? X(d[t.name]) : void 0,
|
|
1247
1247
|
getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
|
|
1248
1248
|
placeholder: t.placeholder || "请选择",
|
|
1249
1249
|
allowClear: t.allowClear || t.allowClear === !1 ? t.allowClear : !0,
|
|
1250
1250
|
format: Ne(t.valueFormat, t.showTime),
|
|
1251
1251
|
showTime: t.showTime,
|
|
1252
1252
|
showToday: t.showToday || !0,
|
|
1253
|
-
onChange: (v) =>
|
|
1253
|
+
onChange: (v) => W(v, t)
|
|
1254
1254
|
}, t.field || {}), null);
|
|
1255
1255
|
break;
|
|
1256
1256
|
case "dateWeek":
|
|
1257
|
-
y = c(
|
|
1257
|
+
y = c(va, _({
|
|
1258
1258
|
style: {
|
|
1259
1259
|
width: "100%"
|
|
1260
1260
|
},
|
|
1261
|
-
value: d[t.name] ?
|
|
1261
|
+
value: d[t.name] ? X(d[t.name], t.valueFormat || "YYYY-wo") : void 0,
|
|
1262
1262
|
getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
|
|
1263
1263
|
placeholder: t.placeholder || "请选择",
|
|
1264
|
-
onChange: (v) =>
|
|
1264
|
+
onChange: (v) => W(v, t)
|
|
1265
1265
|
}, t.field || {}), null);
|
|
1266
1266
|
break;
|
|
1267
1267
|
case "dateMonth":
|
|
1268
|
-
y = c(
|
|
1268
|
+
y = c(fa, _({
|
|
1269
1269
|
style: {
|
|
1270
1270
|
width: "100%"
|
|
1271
1271
|
},
|
|
1272
|
-
value: d[t.name] ?
|
|
1272
|
+
value: d[t.name] ? X(d[t.name], t.valueFormat || "YYYY-MM") : void 0,
|
|
1273
1273
|
getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
|
|
1274
1274
|
placeholder: t.placeholder || "请选择",
|
|
1275
|
-
onChange: (v) =>
|
|
1275
|
+
onChange: (v) => W(v, t)
|
|
1276
1276
|
}, t.field || {}), null);
|
|
1277
1277
|
break;
|
|
1278
1278
|
case "dateQuarter":
|
|
1279
|
-
y = c(
|
|
1279
|
+
y = c(ga, _({
|
|
1280
1280
|
style: {
|
|
1281
1281
|
width: "100%"
|
|
1282
1282
|
},
|
|
1283
|
-
value: d[t.name] ?
|
|
1283
|
+
value: d[t.name] ? X(d[t.name], t.valueFormat || "YYYY-QQ") : void 0,
|
|
1284
1284
|
getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
|
|
1285
1285
|
placeholder: t.placeholder || "请选择",
|
|
1286
|
-
onChange: (v) =>
|
|
1286
|
+
onChange: (v) => W(v, t)
|
|
1287
1287
|
}, t.field || {}), null);
|
|
1288
1288
|
break;
|
|
1289
1289
|
case "dateYear":
|
|
1290
|
-
y = c(
|
|
1290
|
+
y = c(ma, _({
|
|
1291
1291
|
style: {
|
|
1292
1292
|
width: "100%"
|
|
1293
1293
|
},
|
|
1294
|
-
value: d[t.name] ?
|
|
1294
|
+
value: d[t.name] ? X(d[t.name], t.valueFormat || "YYYY") : void 0,
|
|
1295
1295
|
getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
|
|
1296
1296
|
placeholder: t.placeholder || "请选择",
|
|
1297
|
-
onChange: (v) =>
|
|
1297
|
+
onChange: (v) => W(v, t)
|
|
1298
1298
|
}, t.field || {}), null);
|
|
1299
1299
|
break;
|
|
1300
1300
|
case "dateRange":
|
|
1301
|
-
y = c(
|
|
1301
|
+
y = c(ha, _({
|
|
1302
1302
|
style: {
|
|
1303
1303
|
width: "100%"
|
|
1304
1304
|
},
|
|
1305
|
-
value: d[t.name] &&
|
|
1305
|
+
value: d[t.name] && ne(d[t.name]) && ((k = d[t.name]) == null ? void 0 : k.length) === 2 ? Tt(d[t.name], Ne(t.valueFormat, t.showTime), "dayjs") : void 0,
|
|
1306
1306
|
getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
|
|
1307
1307
|
placeholder: t.placeholder || ["开始日期", "结束日期"],
|
|
1308
1308
|
format: Ne(t.valueFormat, t.showTime),
|
|
1309
1309
|
showTime: t.showTime,
|
|
1310
|
-
onChange: (v) =>
|
|
1310
|
+
onChange: (v) => W(v, t)
|
|
1311
1311
|
}, t.field || {}), null);
|
|
1312
1312
|
break;
|
|
1313
1313
|
case "time":
|
|
1314
|
-
y = c(
|
|
1314
|
+
y = c(Il, _({
|
|
1315
1315
|
style: {
|
|
1316
1316
|
width: "100%"
|
|
1317
1317
|
},
|
|
1318
|
-
value: d[t.name] ?
|
|
1318
|
+
value: d[t.name] ? X(d[t.name], t.valueFormat || "HH:mm:ss") : void 0,
|
|
1319
1319
|
getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
|
|
1320
1320
|
placeholder: t.placeholder || "请选择",
|
|
1321
1321
|
allowClear: t.allowClear || t.allowClear === !1 ? t.allowClear : !0,
|
|
1322
1322
|
use12Hours: t.use12Hours,
|
|
1323
1323
|
format: t.valueFormat || "HH:mm:ss",
|
|
1324
|
-
onChange: (v) =>
|
|
1324
|
+
onChange: (v) => W(v, t)
|
|
1325
1325
|
}, t.field || {}), null);
|
|
1326
1326
|
break;
|
|
1327
1327
|
}
|
|
@@ -1330,33 +1330,33 @@ const pt = (e, l, a = "string") => {
|
|
|
1330
1330
|
formItemStyle: t = {},
|
|
1331
1331
|
item: y
|
|
1332
1332
|
}) => {
|
|
1333
|
-
var p, D,
|
|
1334
|
-
const
|
|
1333
|
+
var p, D, R, k, v, Y;
|
|
1334
|
+
const I = y.labelAlign || ((p = T.value) == null ? void 0 : p.align);
|
|
1335
1335
|
return c("div", {
|
|
1336
1336
|
class: `${e.prefixCls}-search-item`,
|
|
1337
1337
|
style: {
|
|
1338
1338
|
...t,
|
|
1339
|
-
gap: (D = T.value) != null && D.gap ?
|
|
1339
|
+
gap: (D = T.value) != null && D.gap ? pt((R = T.value) == null ? void 0 : R.gap) : void 0
|
|
1340
1340
|
}
|
|
1341
1341
|
}, [y.label && c("div", {
|
|
1342
|
-
class:
|
|
1342
|
+
class: Se(`${e.prefixCls}-search-item-label`, ((k = T.value) == null ? void 0 : k.colon) === !1 && `${e.prefixCls}-search-item-label-no-colon`, I && `${e.prefixCls}-search-item-label-${I}`),
|
|
1343
1343
|
style: {
|
|
1344
|
-
width: (v = T.value) != null && v.width ?
|
|
1344
|
+
width: (v = T.value) != null && v.width ? pt((Y = T.value) == null ? void 0 : Y.width) : void 0
|
|
1345
1345
|
}
|
|
1346
1346
|
}, [y.label]), c("div", {
|
|
1347
|
-
class:
|
|
1348
|
-
}, [ce(y) ? y :
|
|
1349
|
-
},
|
|
1350
|
-
var
|
|
1351
|
-
const t = [...e.searchMap, ...((
|
|
1347
|
+
class: Se(`${e.prefixCls}-search-item-children`)
|
|
1348
|
+
}, [ce(y) ? y : te(y)])]);
|
|
1349
|
+
}, J = () => {
|
|
1350
|
+
var I;
|
|
1351
|
+
const t = [...e.searchMap, ...((I = l.default) == null ? void 0 : I.call(l)) || []], y = {
|
|
1352
1352
|
width: `${(100 - (g.value - 1) * 2) / g.value}%`
|
|
1353
1353
|
};
|
|
1354
1354
|
return t.map((p, D) => {
|
|
1355
|
-
const
|
|
1355
|
+
const R = M(D, g.value, y);
|
|
1356
1356
|
return t.length < g.value || n.value ? c(_e, null, [me({
|
|
1357
|
-
formItemStyle:
|
|
1357
|
+
formItemStyle: R,
|
|
1358
1358
|
item: p
|
|
1359
|
-
}), D === t.length - 1 &&
|
|
1359
|
+
}), D === t.length - 1 && se({
|
|
1360
1360
|
formItemStyle: {
|
|
1361
1361
|
flex: 1,
|
|
1362
1362
|
justifyContent: "flex-end"
|
|
@@ -1364,12 +1364,12 @@ const pt = (e, l, a = "string") => {
|
|
|
1364
1364
|
advanced: n.value,
|
|
1365
1365
|
showAdvanced: n.value
|
|
1366
1366
|
})]) : c(_e, null, [D < g.value - 1 && me({
|
|
1367
|
-
formItemStyle:
|
|
1367
|
+
formItemStyle: R,
|
|
1368
1368
|
item: p
|
|
1369
1369
|
}), D === g.value - 1 && (g.value - 1 === 0 || t.length === g.value) && me({
|
|
1370
|
-
formItemStyle:
|
|
1370
|
+
formItemStyle: R,
|
|
1371
1371
|
item: p
|
|
1372
|
-
}), D === g.value - 1 && t.length >= g.value &&
|
|
1372
|
+
}), D === g.value - 1 && t.length >= g.value && se({
|
|
1373
1373
|
formItemStyle: {
|
|
1374
1374
|
flex: 1,
|
|
1375
1375
|
justifyContent: "flex-end"
|
|
@@ -1383,19 +1383,19 @@ const pt = (e, l, a = "string") => {
|
|
|
1383
1383
|
var y;
|
|
1384
1384
|
const t = e.cardBordered && `${e.prefixCls}-search-border`;
|
|
1385
1385
|
return o(c("div", {
|
|
1386
|
-
class:
|
|
1387
|
-
}, [
|
|
1386
|
+
class: Se(s.value, `${e.prefixCls}-search`, t, s.value, (y = C.value) == null ? void 0 : y.className)
|
|
1387
|
+
}, [J()]));
|
|
1388
1388
|
};
|
|
1389
1389
|
}
|
|
1390
1390
|
});
|
|
1391
|
-
|
|
1391
|
+
Dt.inheritAttrs = !1;
|
|
1392
1392
|
const Me = (e) => {
|
|
1393
1393
|
const l = E(null);
|
|
1394
1394
|
return l.value = e, (...a) => {
|
|
1395
1395
|
var o;
|
|
1396
1396
|
return (o = l.value) == null ? void 0 : o.call(l, ...a);
|
|
1397
1397
|
};
|
|
1398
|
-
},
|
|
1398
|
+
}, ya = (e) => ({
|
|
1399
1399
|
[`${e.componentCls}`]: {
|
|
1400
1400
|
width: "auto",
|
|
1401
1401
|
"&-title": {
|
|
@@ -1512,7 +1512,7 @@ const Me = (e) => {
|
|
|
1512
1512
|
}, [(m = s.default) == null ? void 0 : m.call(s)])];
|
|
1513
1513
|
}
|
|
1514
1514
|
}) : null;
|
|
1515
|
-
},
|
|
1515
|
+
}, ba = /* @__PURE__ */ fe({
|
|
1516
1516
|
props: {
|
|
1517
1517
|
treeKey: String,
|
|
1518
1518
|
hashId: String,
|
|
@@ -1537,21 +1537,21 @@ const Me = (e) => {
|
|
|
1537
1537
|
title: "固定在列首",
|
|
1538
1538
|
show: e.fixed !== "left" && !o.value
|
|
1539
1539
|
}, {
|
|
1540
|
-
default: () => [c(
|
|
1540
|
+
default: () => [c(Cl, null, null)]
|
|
1541
1541
|
}), c(Ze, {
|
|
1542
1542
|
treeKey: e.treeKey || "",
|
|
1543
1543
|
fixed: void 0,
|
|
1544
1544
|
title: "不固定",
|
|
1545
1545
|
show: !!e.fixed && !o.value
|
|
1546
1546
|
}, {
|
|
1547
|
-
default: () => [c(
|
|
1547
|
+
default: () => [c(xl, null, null)]
|
|
1548
1548
|
}), c(Ze, {
|
|
1549
1549
|
treeKey: e.treeKey || "",
|
|
1550
1550
|
fixed: "right",
|
|
1551
1551
|
title: "固定在列尾",
|
|
1552
1552
|
show: e.fixed !== "right"
|
|
1553
1553
|
}, {
|
|
1554
|
-
default: () => [c(
|
|
1554
|
+
default: () => [c(Sl, null, null)]
|
|
1555
1555
|
})]);
|
|
1556
1556
|
return c("span", {
|
|
1557
1557
|
class: [`${e.className}-list-item`, e.hashId],
|
|
@@ -1584,57 +1584,57 @@ const Me = (e) => {
|
|
|
1584
1584
|
key: r,
|
|
1585
1585
|
children: g,
|
|
1586
1586
|
uuid: T,
|
|
1587
|
-
...
|
|
1587
|
+
...O
|
|
1588
1588
|
}) => {
|
|
1589
|
-
var
|
|
1590
|
-
const
|
|
1589
|
+
var L;
|
|
1590
|
+
const F = (m == null ? void 0 : m.columnsMap[r || "null"]) || {
|
|
1591
1591
|
show: !0
|
|
1592
1592
|
};
|
|
1593
1593
|
let M = !1;
|
|
1594
|
-
|
|
1595
|
-
const
|
|
1594
|
+
F.show !== !1 && (n == null ? void 0 : n.show) !== !1 && !g && (M = !0);
|
|
1595
|
+
const H = {
|
|
1596
1596
|
key: T || "",
|
|
1597
|
-
...Ge(
|
|
1597
|
+
...Ge(O, ["dataIndex"]),
|
|
1598
1598
|
checked: M,
|
|
1599
1599
|
selectable: !1,
|
|
1600
|
-
disabled:
|
|
1601
|
-
disableCheckbox: typeof
|
|
1600
|
+
disabled: F.disable === !0,
|
|
1601
|
+
disableCheckbox: typeof F.disable == "boolean" ? F.disable : (L = F.disable) == null ? void 0 : L.checkbox,
|
|
1602
1602
|
isLeaf: !0
|
|
1603
1603
|
};
|
|
1604
|
-
return g && (
|
|
1604
|
+
return g && (H.children = C(g, F)), H;
|
|
1605
1605
|
});
|
|
1606
1606
|
Ae(() => {
|
|
1607
1607
|
const u = C(e.list || []);
|
|
1608
1608
|
o.value = u, s.value = u.filter((n) => n.checked).map((n) => n.key), (m == null ? void 0 : m.operationType.value) === "fixed" && (l.value = at().uuid(15));
|
|
1609
1609
|
});
|
|
1610
1610
|
const x = Me((u, n, r) => {
|
|
1611
|
-
var
|
|
1612
|
-
const g = ((
|
|
1611
|
+
var z, Q;
|
|
1612
|
+
const g = ((z = b(i).find((V) => V.uuid === u)) == null ? void 0 : z.key) || "", T = ((Q = b(i).find((V) => V.uuid === n)) == null ? void 0 : Q.key) || "", O = {
|
|
1613
1613
|
...m == null ? void 0 : m.columnsMap
|
|
1614
|
-
},
|
|
1614
|
+
}, F = [...m.sortKeyColumns.value], M = F.findIndex((V) => V === g), H = F.findIndex((V) => V === T), L = r > M;
|
|
1615
1615
|
if (M < 0)
|
|
1616
1616
|
return;
|
|
1617
|
-
const
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
...
|
|
1621
|
-
order:
|
|
1617
|
+
const W = F[M];
|
|
1618
|
+
F.splice(M, 1), r === 0 ? F.unshift(W) : F.splice(L ? H : H + 1, 0, W), F.forEach((V, se) => {
|
|
1619
|
+
O[V] = {
|
|
1620
|
+
...O[V] || {},
|
|
1621
|
+
order: se
|
|
1622
1622
|
};
|
|
1623
|
-
}), m == null || m.setColumnsMap(
|
|
1623
|
+
}), m == null || m.setColumnsMap(O, "drop"), m == null || m.setSortKeyColumns(F);
|
|
1624
1624
|
}), d = Me((u) => {
|
|
1625
|
-
var
|
|
1626
|
-
const n = u.node.key, r = ((
|
|
1625
|
+
var F;
|
|
1626
|
+
const n = u.node.key, r = ((F = b(i).find((M) => M.uuid === n)) == null ? void 0 : F.key) || "", T = {
|
|
1627
1627
|
...(m == null ? void 0 : m.columnsMap[r]) || {}
|
|
1628
1628
|
};
|
|
1629
1629
|
T.show = u.checked;
|
|
1630
|
-
const
|
|
1630
|
+
const O = {
|
|
1631
1631
|
...m == null ? void 0 : m.columnsMap,
|
|
1632
1632
|
[r]: T
|
|
1633
1633
|
};
|
|
1634
|
-
m == null || m.setColumnsMap(
|
|
1634
|
+
m == null || m.setColumnsMap(O, "show");
|
|
1635
1635
|
}), S = (u) => {
|
|
1636
1636
|
const n = b(i).find((r) => r.uuid === u.key);
|
|
1637
|
-
return u.title ||
|
|
1637
|
+
return u.title || ml(f, "headerCell", {
|
|
1638
1638
|
title: n.title,
|
|
1639
1639
|
column: n
|
|
1640
1640
|
}, () => [n.title]);
|
|
@@ -1643,7 +1643,7 @@ const Me = (e) => {
|
|
|
1643
1643
|
var u, n;
|
|
1644
1644
|
return a.value ? c(_e, null, [e.showTitle && c("span", {
|
|
1645
1645
|
class: [`${e.className}-list-title`, e.hashId]
|
|
1646
|
-
}, [e.title]), c(
|
|
1646
|
+
}, [e.title]), c(Nl, {
|
|
1647
1647
|
key: l.value,
|
|
1648
1648
|
draggable: e.draggable && !!((u = o.value) != null && u.length) && ((n = o.value) == null ? void 0 : n.length) > 1,
|
|
1649
1649
|
checkable: e.checkable,
|
|
@@ -1653,9 +1653,9 @@ const Me = (e) => {
|
|
|
1653
1653
|
height: 280,
|
|
1654
1654
|
onDrop: (r) => {
|
|
1655
1655
|
const g = r.node.key, T = r.dragNode.key, {
|
|
1656
|
-
dropPosition:
|
|
1657
|
-
dropToGap:
|
|
1658
|
-
} = r, M =
|
|
1656
|
+
dropPosition: O,
|
|
1657
|
+
dropToGap: F
|
|
1658
|
+
} = r, M = O === -1 || !F ? O + 1 : O;
|
|
1659
1659
|
x(T, g, M);
|
|
1660
1660
|
},
|
|
1661
1661
|
onCheck: (r, g) => d(g),
|
|
@@ -1669,7 +1669,7 @@ const Me = (e) => {
|
|
|
1669
1669
|
title: S(r),
|
|
1670
1670
|
autoScroll: (T = m == null ? void 0 : m.autoScroll) == null ? void 0 : T.value
|
|
1671
1671
|
};
|
|
1672
|
-
return c(
|
|
1672
|
+
return c(ba, _({
|
|
1673
1673
|
hashId: e.hashId,
|
|
1674
1674
|
className: e.className
|
|
1675
1675
|
}, g, {
|
|
@@ -1679,7 +1679,7 @@ const Me = (e) => {
|
|
|
1679
1679
|
})]) : null;
|
|
1680
1680
|
};
|
|
1681
1681
|
}
|
|
1682
|
-
}),
|
|
1682
|
+
}), Ca = /* @__PURE__ */ fe({
|
|
1683
1683
|
props: {
|
|
1684
1684
|
hashId: String,
|
|
1685
1685
|
className: String,
|
|
@@ -1690,7 +1690,7 @@ const Me = (e) => {
|
|
|
1690
1690
|
const {
|
|
1691
1691
|
columns: l
|
|
1692
1692
|
} = he(), a = E([]), o = E([]), s = E([]), i = E([]);
|
|
1693
|
-
|
|
1693
|
+
q(() => l.value, (C) => {
|
|
1694
1694
|
a.value = [], o.value = [], s.value = [], C.forEach((x) => {
|
|
1695
1695
|
if (x.hideInSetting)
|
|
1696
1696
|
return;
|
|
@@ -1746,7 +1746,7 @@ const Me = (e) => {
|
|
|
1746
1746
|
className: e.className
|
|
1747
1747
|
}, null)]);
|
|
1748
1748
|
}
|
|
1749
|
-
}),
|
|
1749
|
+
}), xa = /* @__PURE__ */ fe({
|
|
1750
1750
|
props: {
|
|
1751
1751
|
draggable: {
|
|
1752
1752
|
type: Boolean,
|
|
@@ -1766,7 +1766,7 @@ const Me = (e) => {
|
|
|
1766
1766
|
}), {
|
|
1767
1767
|
wrapSSR: a,
|
|
1768
1768
|
hashId: o
|
|
1769
|
-
} = qe("ColumnSetting", [
|
|
1769
|
+
} = qe("ColumnSetting", [ya], l), {
|
|
1770
1770
|
columns: s,
|
|
1771
1771
|
settingsAction: i
|
|
1772
1772
|
} = he(), f = Me((S = !0) => {
|
|
@@ -1774,14 +1774,14 @@ const Me = (e) => {
|
|
|
1774
1774
|
r.forEach(({
|
|
1775
1775
|
key: g,
|
|
1776
1776
|
fixed: T,
|
|
1777
|
-
index:
|
|
1778
|
-
children:
|
|
1777
|
+
index: O,
|
|
1778
|
+
children: F
|
|
1779
1779
|
}) => {
|
|
1780
|
-
const M =
|
|
1780
|
+
const M = Ft(g, O);
|
|
1781
1781
|
M && (u[M] = {
|
|
1782
1782
|
show: S,
|
|
1783
1783
|
fixed: T
|
|
1784
|
-
}),
|
|
1784
|
+
}), F && n(F);
|
|
1785
1785
|
});
|
|
1786
1786
|
};
|
|
1787
1787
|
n(s.value), i == null || i.setColumnsMap(u, "show");
|
|
@@ -1793,11 +1793,11 @@ const Me = (e) => {
|
|
|
1793
1793
|
// @ts-ignore
|
|
1794
1794
|
Object.values(i == null ? void 0 : i.columnsMap).filter((S) => !S || S.show === !1)
|
|
1795
1795
|
)), d = w(() => b(x).length > 0 && b(x).length !== s.value.length);
|
|
1796
|
-
return () => a(c(
|
|
1796
|
+
return () => a(c(kl, {
|
|
1797
1797
|
arrowPointAtCenter: !0,
|
|
1798
1798
|
title: c("div", {
|
|
1799
1799
|
class: [`${l}-title`, o.value]
|
|
1800
|
-
}, [c(
|
|
1800
|
+
}, [c(jl, {
|
|
1801
1801
|
indeterminate: d.value,
|
|
1802
1802
|
checked: b(x).length === 0 && b(x).length !== s.value.length,
|
|
1803
1803
|
onChange: (S) => m(S)
|
|
@@ -1806,7 +1806,7 @@ const Me = (e) => {
|
|
|
1806
1806
|
}), e.checkedReset ? c("a", {
|
|
1807
1807
|
onClick: C,
|
|
1808
1808
|
class: [`${l}-action-rest-button`, o.value]
|
|
1809
|
-
}, [De("重置")]) : null, e != null && e.extra ? c(
|
|
1809
|
+
}, [De("重置")]) : null, e != null && e.extra ? c(xe, {
|
|
1810
1810
|
size: 12,
|
|
1811
1811
|
align: "center"
|
|
1812
1812
|
}, {
|
|
@@ -1815,7 +1815,7 @@ const Me = (e) => {
|
|
|
1815
1815
|
overlayClassName: `${l}-overlay ${o.value}`,
|
|
1816
1816
|
trigger: "click",
|
|
1817
1817
|
placement: "bottomRight",
|
|
1818
|
-
content: c(
|
|
1818
|
+
content: c(Ca, {
|
|
1819
1819
|
hashId: o.value,
|
|
1820
1820
|
checkable: e.checkable ?? !0,
|
|
1821
1821
|
draggable: e.draggable ?? !0,
|
|
@@ -1825,31 +1825,31 @@ const Me = (e) => {
|
|
|
1825
1825
|
default: () => [c(de, {
|
|
1826
1826
|
title: "列设置"
|
|
1827
1827
|
}, {
|
|
1828
|
-
default: () => [c(
|
|
1828
|
+
default: () => [c(Pt, null, null)]
|
|
1829
1829
|
})]
|
|
1830
1830
|
}));
|
|
1831
1831
|
}
|
|
1832
|
-
}),
|
|
1832
|
+
}), Mt = /* @__PURE__ */ fe({
|
|
1833
1833
|
setup() {
|
|
1834
1834
|
const {
|
|
1835
1835
|
isFullscreen: e
|
|
1836
|
-
} =
|
|
1836
|
+
} = kt();
|
|
1837
1837
|
return () => e.value ? c(de, {
|
|
1838
1838
|
title: "退出全屏"
|
|
1839
1839
|
}, {
|
|
1840
|
-
default: () => [c(
|
|
1840
|
+
default: () => [c(wl, null, null)]
|
|
1841
1841
|
}) : c(de, {
|
|
1842
1842
|
title: "全屏"
|
|
1843
1843
|
}, {
|
|
1844
|
-
default: () => [c(
|
|
1844
|
+
default: () => [c(pl, null, null)]
|
|
1845
1845
|
});
|
|
1846
1846
|
}
|
|
1847
|
-
}),
|
|
1847
|
+
}), Sa = () => {
|
|
1848
1848
|
const {
|
|
1849
1849
|
action: e,
|
|
1850
1850
|
tableSize: l
|
|
1851
1851
|
} = he();
|
|
1852
|
-
return c(
|
|
1852
|
+
return c(El, {
|
|
1853
1853
|
overlay: c(We, {
|
|
1854
1854
|
selectedKeys: [l.value],
|
|
1855
1855
|
onClick: ({
|
|
@@ -1881,10 +1881,10 @@ const Me = (e) => {
|
|
|
1881
1881
|
default: () => [c(de, {
|
|
1882
1882
|
title: "表格密度"
|
|
1883
1883
|
}, {
|
|
1884
|
-
default: () => [c(
|
|
1884
|
+
default: () => [c(Tl, null, null)]
|
|
1885
1885
|
})]
|
|
1886
1886
|
});
|
|
1887
|
-
},
|
|
1887
|
+
}, wa = (e) => ({
|
|
1888
1888
|
[`${e.componentCls}`]: {
|
|
1889
1889
|
lineHeight: 1,
|
|
1890
1890
|
"&-container": {
|
|
@@ -1926,13 +1926,13 @@ const Me = (e) => {
|
|
|
1926
1926
|
}
|
|
1927
1927
|
}
|
|
1928
1928
|
});
|
|
1929
|
-
function
|
|
1929
|
+
function $t(e) {
|
|
1930
1930
|
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !ce(e);
|
|
1931
1931
|
}
|
|
1932
1932
|
const {
|
|
1933
|
-
useBreakpoint:
|
|
1933
|
+
useBreakpoint: pa
|
|
1934
1934
|
} = st;
|
|
1935
|
-
function
|
|
1935
|
+
function Ta(e) {
|
|
1936
1936
|
if (ce(e))
|
|
1937
1937
|
return e;
|
|
1938
1938
|
if (e) {
|
|
@@ -1955,7 +1955,7 @@ function pa(e) {
|
|
|
1955
1955
|
}
|
|
1956
1956
|
return null;
|
|
1957
1957
|
}
|
|
1958
|
-
const
|
|
1958
|
+
const At = /* @__PURE__ */ fe({
|
|
1959
1959
|
props: {
|
|
1960
1960
|
actions: re.toolBarBtn,
|
|
1961
1961
|
settings: [Array],
|
|
@@ -1969,7 +1969,7 @@ const Mt = /* @__PURE__ */ fe({
|
|
|
1969
1969
|
const {
|
|
1970
1970
|
wrapSSR: l,
|
|
1971
1971
|
hashId: a
|
|
1972
|
-
} = qe("ListToolBar", [
|
|
1972
|
+
} = qe("ListToolBar", [wa], e.prefixCls), o = pa(), {
|
|
1973
1973
|
isMobile: s
|
|
1974
1974
|
} = he(), i = w(() => {
|
|
1975
1975
|
var u;
|
|
@@ -1980,9 +1980,9 @@ const Mt = /* @__PURE__ */ fe({
|
|
|
1980
1980
|
}), m = w(() => !!(e.titleTip || e.headerTitle)), C = w(() => {
|
|
1981
1981
|
var n;
|
|
1982
1982
|
let u;
|
|
1983
|
-
return Array.isArray(e.actions) ? ((n = e.actions) == null ? void 0 : n.length) < 1 ? null : c(
|
|
1983
|
+
return Array.isArray(e.actions) ? ((n = e.actions) == null ? void 0 : n.length) < 1 ? null : c(xe, {
|
|
1984
1984
|
align: "center"
|
|
1985
|
-
},
|
|
1985
|
+
}, $t(u = e.actions.map((r, g) => ce(r) ? it(r, {
|
|
1986
1986
|
key: g,
|
|
1987
1987
|
...r == null ? void 0 : r.props
|
|
1988
1988
|
}) : c("template", {
|
|
@@ -1992,7 +1992,7 @@ const Mt = /* @__PURE__ */ fe({
|
|
|
1992
1992
|
}) : e.actions;
|
|
1993
1993
|
}), x = Ve(() => !i.value && f.value ? c("div", {
|
|
1994
1994
|
class: `${e.prefixCls}-left ${a.value}`
|
|
1995
|
-
}, null) : m.value ? c(
|
|
1995
|
+
}, null) : m.value ? c(xe, {
|
|
1996
1996
|
class: `${e.prefixCls}-left ${a.value}`
|
|
1997
1997
|
}, {
|
|
1998
1998
|
default: () => [c("div", {
|
|
@@ -2000,11 +2000,11 @@ const Mt = /* @__PURE__ */ fe({
|
|
|
2000
2000
|
}, [e.headerTitle, e.titleTip && c(de, {
|
|
2001
2001
|
title: e.titleTipText
|
|
2002
2002
|
}, {
|
|
2003
|
-
default: () => [
|
|
2003
|
+
default: () => [ie(e.titleTip) && e.titleTip ? c($l, null, null) : e.titleTip]
|
|
2004
2004
|
})]), C.value && c("div", {
|
|
2005
2005
|
class: `${e.prefixCls}-actions ${a.value}`
|
|
2006
2006
|
}, [C.value])]
|
|
2007
|
-
}) : c(
|
|
2007
|
+
}) : c(xe, {
|
|
2008
2008
|
class: `${e.prefixCls}-left ${a.value}`
|
|
2009
2009
|
}, {
|
|
2010
2010
|
default: () => [C.value && c("div", {
|
|
@@ -2012,7 +2012,7 @@ const Mt = /* @__PURE__ */ fe({
|
|
|
2012
2012
|
}, [C.value])]
|
|
2013
2013
|
}), [() => i.value, () => f.value, () => m.value, () => e.prefixCls, () => e.headerTitle, () => e.titleTipText, () => e.titleTip]), d = Ve(() => {
|
|
2014
2014
|
let u;
|
|
2015
|
-
return f.value ? c(
|
|
2015
|
+
return f.value ? c(xe, {
|
|
2016
2016
|
size: 16,
|
|
2017
2017
|
class: `${e.prefixCls}-right ${a.value}`,
|
|
2018
2018
|
align: o.value.lg ? "center" : "end",
|
|
@@ -2020,12 +2020,12 @@ const Mt = /* @__PURE__ */ fe({
|
|
|
2020
2020
|
}, {
|
|
2021
2021
|
default: () => {
|
|
2022
2022
|
var n;
|
|
2023
|
-
return [e.optionsExtra, (n = e.settings) != null && n.length ? c(
|
|
2023
|
+
return [e.optionsExtra, (n = e.settings) != null && n.length ? c(xe, {
|
|
2024
2024
|
size: 12,
|
|
2025
2025
|
align: "center",
|
|
2026
2026
|
class: `${e.prefixCls}-setting-items`
|
|
2027
|
-
},
|
|
2028
|
-
const T =
|
|
2027
|
+
}, $t(u = e.settings.map((r, g) => {
|
|
2028
|
+
const T = Ta(r);
|
|
2029
2029
|
return c("div", {
|
|
2030
2030
|
key: g,
|
|
2031
2031
|
class: `${e.prefixCls}-setting-item`
|
|
@@ -2051,28 +2051,28 @@ const Mt = /* @__PURE__ */ fe({
|
|
|
2051
2051
|
}, [S.value]));
|
|
2052
2052
|
}
|
|
2053
2053
|
});
|
|
2054
|
-
|
|
2055
|
-
function
|
|
2054
|
+
At.inheritAttrs = !1;
|
|
2055
|
+
function $a() {
|
|
2056
2056
|
return {
|
|
2057
2057
|
reload: {
|
|
2058
2058
|
text: "刷新",
|
|
2059
|
-
icon: c(
|
|
2059
|
+
icon: c(Bl, null, null)
|
|
2060
2060
|
},
|
|
2061
2061
|
density: {
|
|
2062
2062
|
text: "表格密度",
|
|
2063
|
-
icon: c(
|
|
2063
|
+
icon: c(Sa, null, null)
|
|
2064
2064
|
},
|
|
2065
2065
|
setting: {
|
|
2066
2066
|
text: "列设置",
|
|
2067
|
-
icon: c(
|
|
2067
|
+
icon: c(Pt, null, null)
|
|
2068
2068
|
},
|
|
2069
2069
|
fullScreen: {
|
|
2070
2070
|
text: "全屏",
|
|
2071
|
-
icon: c(
|
|
2071
|
+
icon: c(Mt, null, null)
|
|
2072
2072
|
}
|
|
2073
2073
|
};
|
|
2074
2074
|
}
|
|
2075
|
-
function
|
|
2075
|
+
function Ba(e, l) {
|
|
2076
2076
|
return Object.keys(e).filter((a) => a).map((a) => {
|
|
2077
2077
|
const o = e[a];
|
|
2078
2078
|
if (!o)
|
|
@@ -2080,15 +2080,15 @@ function $a(e, l) {
|
|
|
2080
2080
|
let s = o === !0 ? l[a] : () => o == null ? void 0 : o();
|
|
2081
2081
|
if (typeof s != "function" && (s = () => {
|
|
2082
2082
|
}), a === "setting")
|
|
2083
|
-
return c(
|
|
2083
|
+
return c(xa, _(e[a], {
|
|
2084
2084
|
key: a
|
|
2085
2085
|
}), null);
|
|
2086
2086
|
if (a === "fullScreen")
|
|
2087
2087
|
return c("span", {
|
|
2088
2088
|
key: a,
|
|
2089
2089
|
onClick: s
|
|
2090
|
-
}, [c(
|
|
2091
|
-
const i =
|
|
2090
|
+
}, [c(Mt, null, null)]);
|
|
2091
|
+
const i = $a()[a];
|
|
2092
2092
|
return i ? c("span", {
|
|
2093
2093
|
key: a,
|
|
2094
2094
|
onClick: s
|
|
@@ -2099,7 +2099,7 @@ function $a(e, l) {
|
|
|
2099
2099
|
})]) : null;
|
|
2100
2100
|
}).filter((a) => a);
|
|
2101
2101
|
}
|
|
2102
|
-
const
|
|
2102
|
+
const Fa = {
|
|
2103
2103
|
options: [Boolean, Object, Array],
|
|
2104
2104
|
titleTip: [Function, Boolean, Object, String],
|
|
2105
2105
|
settingExtra: [Function, Boolean, Object, Array],
|
|
@@ -2107,8 +2107,8 @@ const Ba = {
|
|
|
2107
2107
|
titleTipText: [String],
|
|
2108
2108
|
toolBarBtn: [Function, Boolean, Object, Array],
|
|
2109
2109
|
headerTitle: [Function, Boolean, Object, Array, String]
|
|
2110
|
-
},
|
|
2111
|
-
props:
|
|
2110
|
+
}, Ra = /* @__PURE__ */ fe({
|
|
2111
|
+
props: Fa,
|
|
2112
2112
|
inheritAttrs: !1,
|
|
2113
2113
|
setup(e) {
|
|
2114
2114
|
const l = ut({
|
|
@@ -2129,13 +2129,13 @@ const Ba = {
|
|
|
2129
2129
|
...s,
|
|
2130
2130
|
...e.options
|
|
2131
2131
|
};
|
|
2132
|
-
return i.setting !== !1 && e.settingExtra && (i.setting = {}, i.setting.extra = e.settingExtra),
|
|
2132
|
+
return i.setting !== !1 && e.settingExtra && (i.setting = {}, i.setting.extra = e.settingExtra), Ba(i, {
|
|
2133
2133
|
...s
|
|
2134
2134
|
});
|
|
2135
2135
|
}, [() => a, () => e.options]);
|
|
2136
2136
|
return () => {
|
|
2137
2137
|
const s = e.toolBarBtn || [];
|
|
2138
|
-
return c(
|
|
2138
|
+
return c(At, {
|
|
2139
2139
|
prefixCls: l,
|
|
2140
2140
|
optionsExtra: e.optionsExtra,
|
|
2141
2141
|
headerTitle: e.headerTitle,
|
|
@@ -2159,7 +2159,7 @@ const Ba = {
|
|
|
2159
2159
|
backgroundColor: "transparent",
|
|
2160
2160
|
borderRadius: 2
|
|
2161
2161
|
}
|
|
2162
|
-
},
|
|
2162
|
+
}, Ia = (e) => {
|
|
2163
2163
|
const l = `${e.antCls}-table`;
|
|
2164
2164
|
return {
|
|
2165
2165
|
[e.componentCls]: {
|
|
@@ -2366,12 +2366,12 @@ const Ba = {
|
|
|
2366
2366
|
}
|
|
2367
2367
|
};
|
|
2368
2368
|
};
|
|
2369
|
-
function
|
|
2369
|
+
function Oa(e) {
|
|
2370
2370
|
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !ce(e);
|
|
2371
2371
|
}
|
|
2372
2372
|
const {
|
|
2373
|
-
useBreakpoint:
|
|
2374
|
-
} = st,
|
|
2373
|
+
useBreakpoint: Pa
|
|
2374
|
+
} = st, ka = {
|
|
2375
2375
|
reload: !0,
|
|
2376
2376
|
density: !0,
|
|
2377
2377
|
setting: !0,
|
|
@@ -2394,278 +2394,278 @@ const {
|
|
|
2394
2394
|
}), {
|
|
2395
2395
|
wrapSSR: f,
|
|
2396
2396
|
hashId: m
|
|
2397
|
-
} = qe("ProBaseTable", [
|
|
2397
|
+
} = qe("ProBaseTable", [Ia], i), C = Pa(), {
|
|
2398
2398
|
width: x
|
|
2399
|
-
} =
|
|
2399
|
+
} = Rl(), d = Nt(), S = E(), u = E(), n = E(e.waitRequest);
|
|
2400
2400
|
Ae(() => n.value = e.waitRequest);
|
|
2401
2401
|
const {
|
|
2402
2402
|
toggle: r,
|
|
2403
2403
|
isFullscreen: g
|
|
2404
|
-
} =
|
|
2404
|
+
} = kt(S), T = w(() => ({
|
|
2405
2405
|
...e
|
|
2406
|
-
})),
|
|
2407
|
-
var h,
|
|
2408
|
-
return e.virtualScroll &&
|
|
2409
|
-
}), M = w(() => e.search === !1 ? !1 :
|
|
2406
|
+
})), O = w(() => !C.value.xl), F = w(() => {
|
|
2407
|
+
var h, $;
|
|
2408
|
+
return e.virtualScroll && vl(!((h = e.scroll) != null && h.y), "参数scroll的Y值不能为空!"), !!(($ = e.scroll) != null && $.y && e.virtualScroll);
|
|
2409
|
+
}), M = w(() => e.search === !1 ? !1 : U(e.search) ? e.search : {
|
|
2410
2410
|
type: "auto",
|
|
2411
2411
|
resetText: "重置",
|
|
2412
2412
|
searchText: "查询"
|
|
2413
|
-
}),
|
|
2413
|
+
}), H = w(() => M.value === !1 ? {} : M.value), L = w(() => {
|
|
2414
2414
|
var h;
|
|
2415
|
-
return ((h =
|
|
2416
|
-
}),
|
|
2415
|
+
return ((h = H.value) == null ? void 0 : h.type) === "button";
|
|
2416
|
+
}), W = w(() => {
|
|
2417
2417
|
var h;
|
|
2418
|
-
return (h =
|
|
2419
|
-
}),
|
|
2420
|
-
const h = (e.columns || []).filter((
|
|
2421
|
-
|
|
2422
|
-
key:
|
|
2423
|
-
align:
|
|
2418
|
+
return (h = H.value) == null ? void 0 : h.actions;
|
|
2419
|
+
}), z = w(() => {
|
|
2420
|
+
const h = (e.columns || []).filter(($) => $.key || $.dataIndex).map(($) => ({
|
|
2421
|
+
...$,
|
|
2422
|
+
key: $.key || $.dataIndex,
|
|
2423
|
+
align: $.align || e.align,
|
|
2424
2424
|
uuid: at().uuid(15)
|
|
2425
2425
|
}));
|
|
2426
|
-
return
|
|
2426
|
+
return il(h, {
|
|
2427
2427
|
align: e.align || "left",
|
|
2428
2428
|
showIndex: e.showIndex || !1
|
|
2429
2429
|
});
|
|
2430
2430
|
}), {
|
|
2431
|
-
loadingComputed:
|
|
2432
|
-
loading:
|
|
2433
|
-
setLoading:
|
|
2434
|
-
} =
|
|
2431
|
+
loadingComputed: Q,
|
|
2432
|
+
loading: V,
|
|
2433
|
+
setLoading: se
|
|
2434
|
+
} = Ql({
|
|
2435
2435
|
emit: l,
|
|
2436
2436
|
loading: oe(e, "loading")
|
|
2437
2437
|
}), {
|
|
2438
|
-
sizeRef:
|
|
2438
|
+
sizeRef: te,
|
|
2439
2439
|
setTableSize: me
|
|
2440
|
-
} =
|
|
2440
|
+
} = _l({
|
|
2441
2441
|
emit: l,
|
|
2442
2442
|
size: oe(e, "size")
|
|
2443
2443
|
}), {
|
|
2444
|
-
paginationInfo:
|
|
2444
|
+
paginationInfo: J,
|
|
2445
2445
|
requestPagination: t,
|
|
2446
2446
|
setPagination: y
|
|
2447
|
-
} =
|
|
2447
|
+
} = ql({
|
|
2448
2448
|
slots: a,
|
|
2449
2449
|
props: T,
|
|
2450
2450
|
pagination: oe(e, "pagination")
|
|
2451
|
-
}),
|
|
2451
|
+
}), I = ia(e), {
|
|
2452
2452
|
proScroll: p,
|
|
2453
2453
|
breakpoint: D
|
|
2454
|
-
} =
|
|
2455
|
-
...
|
|
2454
|
+
} = sa({
|
|
2455
|
+
...I,
|
|
2456
2456
|
innerWidth: x,
|
|
2457
|
-
columns:
|
|
2457
|
+
columns: z,
|
|
2458
2458
|
screens: C
|
|
2459
|
-
}),
|
|
2460
|
-
proColumns:
|
|
2459
|
+
}), R = na(e), {
|
|
2460
|
+
proColumns: k,
|
|
2461
2461
|
cacheProColumns: v,
|
|
2462
|
-
setColumns:
|
|
2463
|
-
changeColumns:
|
|
2462
|
+
setColumns: Y,
|
|
2463
|
+
changeColumns: $e,
|
|
2464
2464
|
resizeColumnWidth: Xe
|
|
2465
|
-
} =
|
|
2466
|
-
...
|
|
2465
|
+
} = ua({
|
|
2466
|
+
...R,
|
|
2467
2467
|
breakpoint: D,
|
|
2468
2468
|
scroll: p,
|
|
2469
|
-
columns:
|
|
2469
|
+
columns: z
|
|
2470
2470
|
}), {
|
|
2471
2471
|
columnsMap: ze,
|
|
2472
2472
|
operationType: ve,
|
|
2473
2473
|
setColumnsMap: Ke,
|
|
2474
|
-
sortKeyColumns:
|
|
2475
|
-
cacheColumnsMap:
|
|
2474
|
+
sortKeyColumns: Ie,
|
|
2475
|
+
cacheColumnsMap: ee,
|
|
2476
2476
|
setSortKeyColumns: ge
|
|
2477
|
-
} =
|
|
2477
|
+
} = aa({
|
|
2478
2478
|
columns: v,
|
|
2479
2479
|
columnsState: oe(e, "columnsState"),
|
|
2480
|
-
changeColumns:
|
|
2480
|
+
changeColumns: $e
|
|
2481
2481
|
}), {
|
|
2482
|
-
formDataRef:
|
|
2482
|
+
formDataRef: K,
|
|
2483
2483
|
formParamsRef: ye,
|
|
2484
|
-
defaultParamsRef:
|
|
2484
|
+
defaultParamsRef: Z,
|
|
2485
2485
|
setFormParams: Ue
|
|
2486
|
-
} =
|
|
2486
|
+
} = la({
|
|
2487
2487
|
searchMap: oe(e, "searchMap"),
|
|
2488
2488
|
params: oe(e, "params"),
|
|
2489
|
-
columns:
|
|
2489
|
+
columns: z,
|
|
2490
2490
|
setPagination: y
|
|
2491
2491
|
}), {
|
|
2492
2492
|
selectedKeys: ot,
|
|
2493
|
-
selectedItems:
|
|
2494
|
-
changeRowKey:
|
|
2493
|
+
selectedItems: zt,
|
|
2494
|
+
changeRowKey: Kt,
|
|
2495
2495
|
selectRowKey: rt,
|
|
2496
2496
|
selectAllRowKey: ct,
|
|
2497
2497
|
syncSelectedRows: dt,
|
|
2498
2498
|
removeRowKeys: ft,
|
|
2499
|
-
clearAllRowKeys:
|
|
2500
|
-
} =
|
|
2499
|
+
clearAllRowKeys: Yt
|
|
2500
|
+
} = Ul(oe(e, "rowKey"), oe(e, "rowSelection")), Lt = Zl(e), {
|
|
2501
2501
|
reload: Ye,
|
|
2502
|
-
reSetDataList:
|
|
2503
|
-
changeDataValue:
|
|
2504
|
-
isTreeDataRef:
|
|
2505
|
-
dataSource:
|
|
2502
|
+
reSetDataList: Wt,
|
|
2503
|
+
changeDataValue: Ht,
|
|
2504
|
+
isTreeDataRef: Vt,
|
|
2505
|
+
dataSource: Oe,
|
|
2506
2506
|
handleTableChange: ht
|
|
2507
|
-
} =
|
|
2508
|
-
...
|
|
2507
|
+
} = ea({
|
|
2508
|
+
...Lt,
|
|
2509
2509
|
waitRequest: n
|
|
2510
2510
|
}, {
|
|
2511
|
-
loading:
|
|
2512
|
-
paginationInfo:
|
|
2511
|
+
loading: Q,
|
|
2512
|
+
paginationInfo: J,
|
|
2513
2513
|
setPagination: y,
|
|
2514
2514
|
removeRowKeys: ft,
|
|
2515
2515
|
syncSelectedRows: dt,
|
|
2516
|
-
setLoading:
|
|
2517
|
-
setColumns:
|
|
2516
|
+
setLoading: se,
|
|
2517
|
+
setColumns: Y,
|
|
2518
2518
|
search: M,
|
|
2519
|
-
columns:
|
|
2519
|
+
columns: k,
|
|
2520
2520
|
formParamsRef: ye,
|
|
2521
2521
|
onBeforeSearchSubmit: e.onBeforeSearchSubmit,
|
|
2522
|
-
hasCustomRender: w(() =>
|
|
2523
|
-
}, l),
|
|
2524
|
-
...
|
|
2525
|
-
...
|
|
2526
|
-
} : !1),
|
|
2527
|
-
size: b(
|
|
2522
|
+
hasCustomRender: w(() => Re(e.customRender || (a == null ? void 0 : a.customRender)))
|
|
2523
|
+
}, l), Pe = w(() => e.options ? {
|
|
2524
|
+
...ka,
|
|
2525
|
+
...U(e.options) ? e.options : {}
|
|
2526
|
+
} : !1), Gt = w(() => ({
|
|
2527
|
+
size: b(te),
|
|
2528
2528
|
scroll: b(p),
|
|
2529
|
-
dataSource: b(
|
|
2530
|
-
pagination: b(
|
|
2531
|
-
virtualScroll:
|
|
2532
|
-
columns: b(
|
|
2529
|
+
dataSource: b(Oe),
|
|
2530
|
+
pagination: b(J),
|
|
2531
|
+
virtualScroll: F.value,
|
|
2532
|
+
columns: b(k).filter((h) => h.show || h.show === void 0)
|
|
2533
2533
|
})), mt = w(() => {
|
|
2534
|
-
var B
|
|
2535
|
-
const h =
|
|
2536
|
-
return !h.indicator && ((
|
|
2537
|
-
spinning: e.showLoading ?
|
|
2534
|
+
var $, B;
|
|
2535
|
+
const h = U(e.loading) ? Ge(e.loading, "spinning") : {};
|
|
2536
|
+
return !h.indicator && (($ = d == null ? void 0 : d.indicator) != null && $.value) && (h.indicator = (B = d == null ? void 0 : d.indicator) == null ? void 0 : B.value), {
|
|
2537
|
+
spinning: e.showLoading ? Re(V.value) : !1,
|
|
2538
2538
|
...h
|
|
2539
2539
|
};
|
|
2540
2540
|
}), vt = w(() => {
|
|
2541
|
-
var
|
|
2541
|
+
var j;
|
|
2542
2542
|
let h;
|
|
2543
|
-
const
|
|
2544
|
-
if (
|
|
2545
|
-
const
|
|
2546
|
-
!
|
|
2543
|
+
const $ = b(T).direction === "rtl" ? "bottomLeft" : "right", B = (j = b(J)) == null ? void 0 : j.position;
|
|
2544
|
+
if (B !== null && Array.isArray(B)) {
|
|
2545
|
+
const P = B.find((A) => A.includes("top")), G = B.find((A) => A.includes("bottom")), le = B.every((A) => `${A}` == "none");
|
|
2546
|
+
!P && !G && !le && (h = $), P && (h = P.toLowerCase().replace("top", "")), G && (h = G.toLowerCase().replace("bottom", ""));
|
|
2547
2547
|
} else
|
|
2548
|
-
h =
|
|
2548
|
+
h = $;
|
|
2549
2549
|
return h;
|
|
2550
|
-
}), gt = async (h,
|
|
2551
|
-
var
|
|
2552
|
-
|
|
2550
|
+
}), gt = async (h, $) => {
|
|
2551
|
+
var B;
|
|
2552
|
+
L.value ? (B = W.value) != null && B.reload && $ ? (Ue(h), await Ye()) : Ue(h) : (Ue({
|
|
2553
2553
|
...e.params || {},
|
|
2554
2554
|
...h
|
|
2555
2555
|
}), await Ye());
|
|
2556
|
-
},
|
|
2557
|
-
|
|
2558
|
-
}, yt = (h, B,
|
|
2559
|
-
y(
|
|
2560
|
-
},
|
|
2561
|
-
var
|
|
2556
|
+
}, Qt = async (h, $) => {
|
|
2557
|
+
$ === "reset" ? (l("reset", h), e.request && await gt(h, $)) : e.request ? (l("submit", h), await gt(h, $)) : l("submit", h);
|
|
2558
|
+
}, yt = (h, $, B, j) => {
|
|
2559
|
+
y(xt(h, ["current", "pageSize"])), ht(h, $, B, j);
|
|
2560
|
+
}, _t = (h, $) => {
|
|
2561
|
+
var B;
|
|
2562
2562
|
y({
|
|
2563
2563
|
current: h,
|
|
2564
|
-
pageSize:
|
|
2564
|
+
pageSize: $
|
|
2565
2565
|
}), ht({
|
|
2566
2566
|
current: h,
|
|
2567
|
-
pageSize:
|
|
2568
|
-
total:
|
|
2567
|
+
pageSize: $,
|
|
2568
|
+
total: J.value && ((B = J.value) == null ? void 0 : B.total) || 0
|
|
2569
2569
|
}, {}, {});
|
|
2570
|
-
},
|
|
2570
|
+
}, qt = (h) => {
|
|
2571
2571
|
l("expandedRowsChange", h);
|
|
2572
|
-
},
|
|
2573
|
-
l("expand", h,
|
|
2574
|
-
},
|
|
2575
|
-
var
|
|
2576
|
-
let
|
|
2577
|
-
if (
|
|
2578
|
-
const
|
|
2572
|
+
}, Xt = (h, $) => {
|
|
2573
|
+
l("expand", h, $);
|
|
2574
|
+
}, Ut = (h, $) => Xe(h, $), Jt = (h, $, B) => {
|
|
2575
|
+
var P, G, le;
|
|
2576
|
+
let j = h;
|
|
2577
|
+
if ($) {
|
|
2578
|
+
const A = ne(h) ? typeof ((P = h == null ? void 0 : h[0]) == null ? void 0 : P.children) == "string" ? (G = h == null ? void 0 : h[0]) == null ? void 0 : G.children : "" : h.toString(), N = B.tooltip === !1 ? {} : B.tooltip, be = B.tooltip === !1 ? 1 : Qe(N == null ? void 0 : N.hiddenLine) && (N == null ? void 0 : N.hiddenLine) > 0 ? N == null ? void 0 : N.hiddenLine : 1, ae = B.tooltip === !1 ? 0 : Qe(N == null ? void 0 : N.width) ? N == null ? void 0 : N.width : 0, Be = B.tooltip !== !1 && Rt(A) && ae > 0 ? ol(A, {
|
|
2579
2579
|
root: `.${i}-hidden`,
|
|
2580
|
-
cssObject:
|
|
2581
|
-
}) : 0,
|
|
2580
|
+
cssObject: N == null ? void 0 : N.targetStyle
|
|
2581
|
+
}) : 0, Le = document.querySelector(`.${i} .ant-table-tbody`), pe = c("div", {
|
|
2582
2582
|
class: `${i}-ellipsis-text`
|
|
2583
|
-
}, [h]),
|
|
2583
|
+
}, [h]), ke = () => B.tooltip === !1 || U(B.tooltip) && Be < ae && ae > 0 ? pe : c(de, _({
|
|
2584
2584
|
title: h,
|
|
2585
|
-
getPopupContainer: (
|
|
2586
|
-
var
|
|
2587
|
-
return
|
|
2585
|
+
getPopupContainer: (je) => {
|
|
2586
|
+
var Ct;
|
|
2587
|
+
return Le ?? ((Ct = je == null ? void 0 : je.parentNode) == null ? void 0 : Ct.parentNode);
|
|
2588
2588
|
}
|
|
2589
|
-
},
|
|
2589
|
+
}, U(B.tooltip) ? B.tooltip : {}, {
|
|
2590
2590
|
destroyTooltipOnHide: !0
|
|
2591
|
-
}),
|
|
2592
|
-
default: () => [
|
|
2591
|
+
}), Oa(pe) ? pe : {
|
|
2592
|
+
default: () => [pe]
|
|
2593
2593
|
});
|
|
2594
|
-
if (
|
|
2595
|
-
class: `${i}-ellipsis ${
|
|
2594
|
+
if (j = c("div", {
|
|
2595
|
+
class: `${i}-ellipsis ${(N == null ? void 0 : N.class) ?? ""}`,
|
|
2596
2596
|
style: {
|
|
2597
|
-
"-webkit-line-clamp":
|
|
2597
|
+
"-webkit-line-clamp": be
|
|
2598
2598
|
}
|
|
2599
|
-
}, [
|
|
2600
|
-
const
|
|
2601
|
-
|
|
2599
|
+
}, [ke()]), B.copyable) {
|
|
2600
|
+
const je = typeof B.copyText == "function" ? (le = B.copyText) == null ? void 0 : le.call(B, B) : B.copyText || A;
|
|
2601
|
+
j = c("div", {
|
|
2602
2602
|
class: `${i}-copyable`
|
|
2603
2603
|
}, [c("div", {
|
|
2604
|
-
class: `${i}-ellipsis ${
|
|
2604
|
+
class: `${i}-ellipsis ${(N == null ? void 0 : N.class) ?? ""}`,
|
|
2605
2605
|
style: {
|
|
2606
|
-
"-webkit-line-clamp":
|
|
2606
|
+
"-webkit-line-clamp": be
|
|
2607
2607
|
}
|
|
2608
|
-
}, [
|
|
2608
|
+
}, [ke()]), c(Fl, {
|
|
2609
2609
|
class: `${i}-copyable-icon`,
|
|
2610
2610
|
onClick: () => {
|
|
2611
|
-
|
|
2611
|
+
Gl(je), Al.success("复制成功");
|
|
2612
2612
|
}
|
|
2613
2613
|
}, null)]);
|
|
2614
2614
|
}
|
|
2615
2615
|
}
|
|
2616
|
-
return
|
|
2616
|
+
return j;
|
|
2617
2617
|
};
|
|
2618
2618
|
function bt() {
|
|
2619
|
-
var
|
|
2620
|
-
const h =
|
|
2621
|
-
if (h !== !1 && ((
|
|
2622
|
-
const
|
|
2619
|
+
var B, j, P, G, le;
|
|
2620
|
+
const h = Fe(a, e, "emptyText");
|
|
2621
|
+
if (h !== !1 && ((B = d == null ? void 0 : d.emptyText) == null ? void 0 : B.value) !== !1) {
|
|
2622
|
+
const A = ((j = e.emptyTextProps) == null ? void 0 : j.extraProps) || {}, N = h || ((P = d == null ? void 0 : d.emptyText) == null ? void 0 : P.value), be = ce(N), ae = be ? Ot(N, A) : It(N || []);
|
|
2623
2623
|
return c("div", {
|
|
2624
|
-
class:
|
|
2625
|
-
style: (
|
|
2626
|
-
}, [
|
|
2624
|
+
class: Se(`${i}-empty-text`, m.value, (G = e.emptyTextProps) == null ? void 0 : G.class),
|
|
2625
|
+
style: (le = e.emptyTextProps) == null ? void 0 : le.style
|
|
2626
|
+
}, [be ? ae : ne(ae) ? ae.map((Be) => it(Be, A)) : c(zl, null, null)]);
|
|
2627
2627
|
}
|
|
2628
2628
|
return null;
|
|
2629
2629
|
}
|
|
2630
|
-
const
|
|
2631
|
-
var
|
|
2632
|
-
const h =
|
|
2630
|
+
const Zt = () => {
|
|
2631
|
+
var $;
|
|
2632
|
+
const h = Bt(a, e, "customRender");
|
|
2633
2633
|
if (h) {
|
|
2634
|
-
if ((
|
|
2635
|
-
const
|
|
2634
|
+
if (($ = Oe.value) != null && $.length) {
|
|
2635
|
+
const B = ue(b(Oe));
|
|
2636
2636
|
return h == null ? void 0 : h({
|
|
2637
|
-
dataSource:
|
|
2638
|
-
currentData:
|
|
2637
|
+
dataSource: B,
|
|
2638
|
+
currentData: Vl(B, J.value)
|
|
2639
2639
|
});
|
|
2640
2640
|
}
|
|
2641
2641
|
return bt();
|
|
2642
2642
|
}
|
|
2643
2643
|
return c(_e, null, null);
|
|
2644
|
-
},
|
|
2645
|
-
var
|
|
2646
|
-
const
|
|
2647
|
-
return c(
|
|
2648
|
-
headerTitle:
|
|
2649
|
-
titleTip:
|
|
2644
|
+
}, el = (h) => {
|
|
2645
|
+
var P, G;
|
|
2646
|
+
const $ = Fe(a, e, "headerTitle"), B = Fe(a, e, "titleTip"), j = Fe(a, e, "toolBarBtn");
|
|
2647
|
+
return c(Ra, {
|
|
2648
|
+
headerTitle: $,
|
|
2649
|
+
titleTip: B,
|
|
2650
2650
|
titleTipText: e.titleTipText,
|
|
2651
|
-
options:
|
|
2652
|
-
...
|
|
2653
|
-
setting: h ? !1 : (
|
|
2654
|
-
density: h ? !1 : (
|
|
2651
|
+
options: ie(Pe.value) ? Pe.value : {
|
|
2652
|
+
...Pe.value,
|
|
2653
|
+
setting: h ? !1 : (P = Pe.value) == null ? void 0 : P.setting,
|
|
2654
|
+
density: h ? !1 : (G = Pe.value) == null ? void 0 : G.density
|
|
2655
2655
|
},
|
|
2656
|
-
settingExtra:
|
|
2657
|
-
optionsExtra:
|
|
2658
|
-
toolBarBtn:
|
|
2656
|
+
settingExtra: Fe(a, e, "settingExtra"),
|
|
2657
|
+
optionsExtra: Fe(a, e, "optionsExtra"),
|
|
2658
|
+
toolBarBtn: j
|
|
2659
2659
|
}, null);
|
|
2660
2660
|
};
|
|
2661
|
-
return
|
|
2662
|
-
tableSize:
|
|
2663
|
-
columns:
|
|
2664
|
-
cacheColumns:
|
|
2665
|
-
isMobile:
|
|
2666
|
-
searchConfig:
|
|
2667
|
-
manualSearch:
|
|
2668
|
-
searchActions:
|
|
2661
|
+
return oa({
|
|
2662
|
+
tableSize: te,
|
|
2663
|
+
columns: k,
|
|
2664
|
+
cacheColumns: z,
|
|
2665
|
+
isMobile: O,
|
|
2666
|
+
searchConfig: H,
|
|
2667
|
+
manualSearch: L,
|
|
2668
|
+
searchActions: W,
|
|
2669
2669
|
action: {
|
|
2670
2670
|
setTableSize: me,
|
|
2671
2671
|
reload: (h) => Ye(h),
|
|
@@ -2676,12 +2676,12 @@ const {
|
|
|
2676
2676
|
columnsMap: ze,
|
|
2677
2677
|
operationType: ve,
|
|
2678
2678
|
setColumnsMap: Ke,
|
|
2679
|
-
sortKeyColumns:
|
|
2680
|
-
cacheColumnsMap:
|
|
2679
|
+
sortKeyColumns: Ie,
|
|
2680
|
+
cacheColumnsMap: ee,
|
|
2681
2681
|
setSortKeyColumns: ge
|
|
2682
2682
|
},
|
|
2683
2683
|
setPagination: y,
|
|
2684
|
-
changeColumns:
|
|
2684
|
+
changeColumns: $e,
|
|
2685
2685
|
slots: a
|
|
2686
2686
|
}), s({
|
|
2687
2687
|
formRef: () => ({
|
|
@@ -2691,121 +2691,121 @@ const {
|
|
|
2691
2691
|
return ((h = u.value) == null ? void 0 : h.getFormState()) || {};
|
|
2692
2692
|
},
|
|
2693
2693
|
restFormState: (h) => {
|
|
2694
|
-
var
|
|
2695
|
-
n.value = !0, h && (h == null || h()), (
|
|
2694
|
+
var $;
|
|
2695
|
+
n.value = !0, h && (h == null || h()), ($ = u.value) == null || $.resetForm(!1), n.value = !1;
|
|
2696
2696
|
}
|
|
2697
2697
|
}),
|
|
2698
2698
|
actionRef: () => ({
|
|
2699
|
-
loading:
|
|
2700
|
-
dataSource:
|
|
2699
|
+
loading: V,
|
|
2700
|
+
dataSource: Oe,
|
|
2701
2701
|
pageState: t,
|
|
2702
|
-
pagination:
|
|
2702
|
+
pagination: J.value,
|
|
2703
2703
|
selectedKeys: w(() => ot.value),
|
|
2704
|
-
selectedItems: w(() =>
|
|
2704
|
+
selectedItems: w(() => zt.value),
|
|
2705
2705
|
rowsSelection: {
|
|
2706
|
-
clear:
|
|
2706
|
+
clear: Yt,
|
|
2707
2707
|
select: rt,
|
|
2708
2708
|
remove: ft,
|
|
2709
2709
|
sync: dt,
|
|
2710
2710
|
selectAll: ct
|
|
2711
2711
|
},
|
|
2712
2712
|
reload: Ye,
|
|
2713
|
-
getLoadingStatus: () => b(
|
|
2713
|
+
getLoadingStatus: () => b(Q),
|
|
2714
2714
|
reloadAndReset: async (h) => {
|
|
2715
|
-
var B,
|
|
2715
|
+
var $, B, j;
|
|
2716
2716
|
n.value = !0, y({
|
|
2717
2717
|
current: 1,
|
|
2718
2718
|
pageSize: (t == null ? void 0 : t.pageSize) || 10
|
|
2719
|
-
}), h != null && h.callBack && (h != null && h.wait ? await ((
|
|
2719
|
+
}), h != null && h.callBack && (h != null && h.wait ? await (($ = h == null ? void 0 : h.callBack) == null ? void 0 : $.call(h)) : (B = h == null ? void 0 : h.callBack) == null || B.call(h)), (j = u.value) == null || j.resetForm(!1), n.value = !1;
|
|
2720
2720
|
},
|
|
2721
|
-
reSetDataList:
|
|
2721
|
+
reSetDataList: Wt,
|
|
2722
2722
|
setPageAndReload: yt,
|
|
2723
2723
|
setPagination: y,
|
|
2724
|
-
setData:
|
|
2725
|
-
setLoading:
|
|
2724
|
+
setData: Ht,
|
|
2725
|
+
setLoading: se
|
|
2726
2726
|
})
|
|
2727
2727
|
}), () => {
|
|
2728
|
-
var B
|
|
2729
|
-
const h =
|
|
2728
|
+
var $, B;
|
|
2729
|
+
const h = Re(e.customRender || a.customRender);
|
|
2730
2730
|
return f(c("div", {
|
|
2731
2731
|
ref: S,
|
|
2732
|
-
class:
|
|
2732
|
+
class: Se([{
|
|
2733
2733
|
[`${m.value}`]: !0,
|
|
2734
2734
|
[`${i}`]: !0,
|
|
2735
2735
|
[`${o.class}`]: o.class,
|
|
2736
2736
|
[`${i}-no-scroll`]: !Object.keys(b(p) || {}).length,
|
|
2737
|
-
[`${i}-table-tree`]:
|
|
2737
|
+
[`${i}-table-tree`]: Vt.value,
|
|
2738
2738
|
[`${i}-full-screen`]: g.value
|
|
2739
2739
|
}]),
|
|
2740
2740
|
style: o.style
|
|
2741
2741
|
}, [c("div", {
|
|
2742
2742
|
class: [`${i}-content`, m.value]
|
|
2743
|
-
}, [(
|
|
2743
|
+
}, [(K.value.length > 0 || Re(a.search)) && e.search !== !1 && c(Dt, {
|
|
2744
2744
|
ref: u,
|
|
2745
2745
|
modal: e.modalScroll,
|
|
2746
2746
|
cardBordered: e.cardBordered,
|
|
2747
|
-
searchMap:
|
|
2747
|
+
searchMap: K.value,
|
|
2748
2748
|
prefixCls: i,
|
|
2749
|
-
loading: !!b(
|
|
2750
|
-
onSearch:
|
|
2751
|
-
defaultParams:
|
|
2749
|
+
loading: !!b(Q),
|
|
2750
|
+
onSearch: Qt,
|
|
2751
|
+
defaultParams: Z
|
|
2752
2752
|
}, {
|
|
2753
2753
|
default: a.search ? () => {
|
|
2754
|
-
var
|
|
2755
|
-
return (
|
|
2754
|
+
var j;
|
|
2755
|
+
return (j = a.search) == null ? void 0 : j.call(a);
|
|
2756
2756
|
} : null
|
|
2757
2757
|
}), c("div", {
|
|
2758
|
-
class:
|
|
2759
|
-
}, [
|
|
2758
|
+
class: Se(m.value, `${i}-card`, e.cardBordered && `${i}-card-border`)
|
|
2759
|
+
}, [el(h), h ? c(nt, mt.value, {
|
|
2760
2760
|
default: () => {
|
|
2761
|
-
var
|
|
2761
|
+
var j, P, G;
|
|
2762
2762
|
return [c("div", {
|
|
2763
2763
|
class: `${i}-wrapper ${m.value}`
|
|
2764
2764
|
}, [c("div", {
|
|
2765
|
-
class:
|
|
2766
|
-
style: (
|
|
2767
|
-
}, [
|
|
2765
|
+
class: Se(`${i}-list`, m.value, (j = e.tableProps) == null ? void 0 : j.class),
|
|
2766
|
+
style: (P = e.tableProps) == null ? void 0 : P.style
|
|
2767
|
+
}, [Zt()]), e.pagination !== !1 && ((G = Oe.value) == null ? void 0 : G.length) > 0 && c(Dl, _({
|
|
2768
2768
|
class: {
|
|
2769
2769
|
[`${i}-pagination ${m.value}`]: !0,
|
|
2770
2770
|
[`${i}-pagination-${vt.value} ${m.value}`]: !!vt.value
|
|
2771
2771
|
}
|
|
2772
|
-
},
|
|
2773
|
-
onChange:
|
|
2772
|
+
}, Te(b(J)), {
|
|
2773
|
+
onChange: _t
|
|
2774
2774
|
}), null)])];
|
|
2775
2775
|
}
|
|
2776
|
-
}) : c(
|
|
2777
|
-
style: (
|
|
2778
|
-
class: (
|
|
2776
|
+
}) : c(Ml, _(xt(e, Object.keys(Et)), Gt.value, {
|
|
2777
|
+
style: ($ = e.tableProps) == null ? void 0 : $.style,
|
|
2778
|
+
class: (B = e.tableProps) == null ? void 0 : B.class,
|
|
2779
2779
|
loading: mt.value,
|
|
2780
|
-
rowKey: (
|
|
2781
|
-
transformCellText: (
|
|
2782
|
-
var
|
|
2783
|
-
e.transformCellText && typeof e.transformCellText && ((
|
|
2780
|
+
rowKey: (j) => j[e.rowKey],
|
|
2781
|
+
transformCellText: (j) => {
|
|
2782
|
+
var N, be, ae, Be, Le;
|
|
2783
|
+
e.transformCellText && typeof e.transformCellText && ((N = e.transformCellText) == null || N.call(e, j));
|
|
2784
2784
|
const {
|
|
2785
|
-
column:
|
|
2786
|
-
} =
|
|
2787
|
-
if (!
|
|
2788
|
-
const
|
|
2789
|
-
let
|
|
2790
|
-
if (
|
|
2791
|
-
if (
|
|
2792
|
-
|
|
2793
|
-
const
|
|
2794
|
-
|
|
2795
|
-
} else ((
|
|
2796
|
-
return
|
|
2785
|
+
column: P
|
|
2786
|
+
} = j;
|
|
2787
|
+
if (!P) return j.text;
|
|
2788
|
+
const G = (P == null ? void 0 : P.key) || (P == null ? void 0 : P.dataIndex);
|
|
2789
|
+
let le = !0, A = j.text;
|
|
2790
|
+
if (ne(A))
|
|
2791
|
+
if (A.length === 0 || A.length === 1 && !ce(A[0])) {
|
|
2792
|
+
A = A == null ? void 0 : A[0];
|
|
2793
|
+
const pe = sl(A, (P == null ? void 0 : P.columnEmptyText) || (e == null ? void 0 : e.columnEmptyText) || "");
|
|
2794
|
+
le = pe.success, A = Hl(pe.value, (P == null ? void 0 : P.valueType) || ((ae = (be = e.columns) == null ? void 0 : be.find((ke) => (ke.key || ke.dataIndex) === G)) == null ? void 0 : ae.valueType), i, m.value);
|
|
2795
|
+
} else ((Be = A[0]) == null ? void 0 : Be.type) === "template" && (A = (Le = A[0]) == null ? void 0 : Le.children);
|
|
2796
|
+
return P != null && P.ellipsis ? Jt(A, le, P) : A;
|
|
2797
2797
|
},
|
|
2798
2798
|
rowSelection: e.rowSelection ? {
|
|
2799
2799
|
...Ge(e.rowSelection, ["onSelect", "onSelectAll", "onChange", "selectedRowKeys"]),
|
|
2800
2800
|
selectedRowKeys: ot.value,
|
|
2801
2801
|
onSelect: rt,
|
|
2802
2802
|
onSelectAll: ct,
|
|
2803
|
-
onChange:
|
|
2803
|
+
onChange: Kt
|
|
2804
2804
|
} : void 0,
|
|
2805
2805
|
onChange: yt,
|
|
2806
|
-
onExpandedRowsChange:
|
|
2807
|
-
onExpand:
|
|
2808
|
-
onResizeColumn: (
|
|
2806
|
+
onExpandedRowsChange: qt,
|
|
2807
|
+
onExpand: Xt,
|
|
2808
|
+
onResizeColumn: (j, P) => Ut(j, P)
|
|
2809
2809
|
}), {
|
|
2810
2810
|
...a,
|
|
2811
2811
|
emptyText: () => bt()
|
|
@@ -2820,5 +2820,5 @@ export {
|
|
|
2820
2820
|
lt as GProTable,
|
|
2821
2821
|
lt as default,
|
|
2822
2822
|
re as proTableProps,
|
|
2823
|
-
|
|
2823
|
+
Ga as useTable
|
|
2824
2824
|
};
|