@gx-design-vue/pro-table 0.2.0-beta.100 → 0.2.0-beta.102

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 CHANGED
@@ -1,101 +1,101 @@
1
- import { isObject as J, cloneDeep as ie, isArray as ue, isBoolean as se, classNames as Se, filterEmpty as Bt, getPrefixCls as ut, getRandomNumber as at, genColumnKey as Rt, isDeepEqualReact as Ve, compareArray as al, isNumber as Qe, runFunction as nl, convertValueBoolean as Ie, getSortIndex as ul, isFunction as Ae, handleCurrentPage as il, getSlot as Ft, arrayRepeat as sl, isString as It, handleShowIndex as ol, hanndleEmptyField as rl, getTextWidth as cl, getSlotVNode as Fe } from "@gx-design-vue/pro-utils";
2
- import { reactive as we, isReactive as dl, watch as q, computed as w, ref as j, toRaw as Be, watchEffect as Ye, defineComponent as he, createVNode as c, Fragment as _e, nextTick as Ot, isVNode as Z, mergeProps as _, h as kt, cloneVNode as it, unref as C, createTextVNode as Ke, renderSlot as fl, onActivated as hl, getCurrentInstance as ml, onUnmounted as vl, onDeactivated as gl, onMounted as yl, toRef as ce } from "vue";
3
- import { tableProps as bl } from "ant-design-vue/es/table/Table";
4
- import { omit as qe, pick as xt } from "lodash-es";
1
+ import { isObject as Z, cloneDeep as re, isArray as oe, isBoolean as ne, classNames as pe, filterEmpty as Rt, getPrefixCls as it, getRandomNumber as nt, genColumnKey as Ft, isDeepEqualReact as Ge, compareArray as al, isNumber as _e, runFunction as nl, convertValueBoolean as Oe, getSortIndex as ul, isFunction as Ke, handleCurrentPage as il, deepMerge as sl, getSlot as It, arrayRepeat as ol, isString as kt, handleShowIndex as rl, hanndleEmptyField as cl, getTextWidth as dl, getSlotVNode as ke } from "@gx-design-vue/pro-utils";
2
+ import { reactive as Te, isReactive as fl, watch as _, computed as w, ref as j, toRaw as Be, watchEffect as Le, defineComponent as ve, createVNode as c, Fragment as qe, nextTick as Ot, isVNode as le, mergeProps as Q, h as Pt, cloneVNode as st, unref as C, createTextVNode as ze, renderSlot as hl, onActivated as ml, getCurrentInstance as vl, onUnmounted as gl, onDeactivated as yl, onMounted as bl, toRef as fe } from "vue";
3
+ import { tableProps as Cl } from "ant-design-vue/es/table/Table";
4
+ import { omit as Xe, pick as St } from "lodash-es";
5
5
  import "ant-design-vue/es/_util/props-util";
6
- import { warning as Cl } from "ant-design-vue/es/vc-util/warning";
7
- import { UpOutlined as xl, DownOutlined as Sl, SettingOutlined as Pt, VerticalAlignTopOutlined as wl, VerticalAlignMiddleOutlined as pl, VerticalAlignBottomOutlined as Tl, InfoCircleOutlined as $l, ColumnHeightOutlined as Bl, FullscreenExitOutlined as Rl, FullscreenOutlined as Fl, ReloadOutlined as Il, CopyOutlined as Ol } from "@ant-design/icons-vue";
8
- import { useProAppContext as jt } from "@gx-design-vue/pro-app";
9
- import { useContext as kl, useProStyle as Xe, unit as St } from "@gx-design-vue/pro-provider";
10
- import { useFullscreen as Nt, useWindowSize as Pl } from "@vueuse/core";
11
- import { Grid as st, Space as xe, Button as wt, Input as pt, TimePicker as jl, DatePicker as Et, TreeSelect as Nl, Spin as nt, Select as El, Popover as Dl, Checkbox as Ml, Tooltip as fe, Tree as Al, Dropdown as Kl, Menu as He, Pagination as zl, Table as Yl, message as Ll, Empty as Wl } from "ant-design-vue";
12
- import X from "dayjs";
13
- import { useMemo as Ge, tryOnUnmounted as Hl } from "@gx-design-vue/pro-hooks";
14
- function Ua(e, l) {
15
- var x, S, f, b;
16
- function a() {
17
- return l != null && l.state && J(l == null ? void 0 : l.state) ? ie(Be(l == null ? void 0 : l.state)) : {};
6
+ import { warning as xl } from "ant-design-vue/es/vc-util/warning";
7
+ import { UpOutlined as Sl, DownOutlined as wl, SettingOutlined as jt, VerticalAlignTopOutlined as pl, VerticalAlignMiddleOutlined as Tl, VerticalAlignBottomOutlined as $l, InfoCircleOutlined as Bl, ColumnHeightOutlined as Rl, FullscreenExitOutlined as Fl, FullscreenOutlined as Il, ReloadOutlined as kl, CopyOutlined as Ol } from "@ant-design/icons-vue";
8
+ import { useProAppContext as Nt } from "@gx-design-vue/pro-app";
9
+ import { useContext as Pl, useProStyle as Ue, unit as wt } from "@gx-design-vue/pro-provider";
10
+ import { useFullscreen as Et, useWindowSize as jl } from "@vueuse/core";
11
+ import { Grid as ot, Space as we, Button as pt, Input as Tt, TimePicker as Nl, DatePicker as Dt, TreeSelect as El, Spin as ut, Select as Dl, Popover as Ml, Checkbox as Al, Tooltip as me, Tree as Kl, Dropdown as zl, Menu as He, Pagination as Yl, Table as Ll, message as Wl, Empty as Vl } from "ant-design-vue";
12
+ import U from "dayjs";
13
+ import { useMemo as Qe, tryOnUnmounted as Hl } from "@gx-design-vue/pro-hooks";
14
+ function Za(e, a) {
15
+ var x, S, h, b;
16
+ function l() {
17
+ return a != null && a.state && Z(a == null ? void 0 : a.state) ? re(Be(a == null ? void 0 : a.state)) : {};
18
18
  }
19
- const o = we({
20
- params: ((x = l == null ? void 0 : l.state) == null ? void 0 : x.params) || {},
19
+ const u = Te({
20
+ params: ((x = a == null ? void 0 : a.state) == null ? void 0 : x.params) || {},
21
21
  // @ts-ignore
22
- request: async (...u) => {
22
+ request: async (...i) => {
23
23
  var n;
24
- return l != null && l.request ? await ((n = l == null ? void 0 : l.request) == null ? void 0 : n.call(l, ...u)) : void 0;
24
+ return a != null && a.request ? await ((n = a == null ? void 0 : a.request) == null ? void 0 : n.call(a, ...i)) : void 0;
25
25
  }
26
26
  });
27
- l != null && l.state && (dl(l.state) ? q(() => l == null ? void 0 : l.state, () => {
28
- Object.assign(o, a());
29
- }, { deep: !0, immediate: !0 }) : Object.assign(o, a()));
30
- const s = w(() => {
31
- var u, n;
32
- return (n = (u = e == null ? void 0 : e.value) == null ? void 0 : u.actionRef) == null ? void 0 : n.call(u);
33
- }), i = w(() => {
34
- var u, n;
35
- return (n = (u = e == null ? void 0 : e.value) == null ? void 0 : u.formRef) == null ? void 0 : n.call(u);
27
+ a != null && a.state && (fl(a.state) ? _(() => a == null ? void 0 : a.state, () => {
28
+ Object.assign(u, l());
29
+ }, { deep: !0, immediate: !0 }) : Object.assign(u, l()));
30
+ const o = w(() => {
31
+ var i, n;
32
+ return (n = (i = e == null ? void 0 : e.value) == null ? void 0 : i.actionRef) == null ? void 0 : n.call(i);
33
+ }), s = w(() => {
34
+ var i, n;
35
+ return (n = (i = e == null ? void 0 : e.value) == null ? void 0 : i.formRef) == null ? void 0 : n.call(i);
36
36
  }), d = w(() => {
37
- var u, n, r;
37
+ var i, n, r;
38
38
  return {
39
- ...((u = s.value) == null ? void 0 : u.pageState) || {},
40
- ...((r = (n = i.value) == null ? void 0 : n.getFormState) == null ? void 0 : r.call(n)) || {}
39
+ ...((i = o.value) == null ? void 0 : i.pageState) || {},
40
+ ...((r = (n = s.value) == null ? void 0 : n.getFormState) == null ? void 0 : r.call(n)) || {}
41
41
  };
42
- }), m = j(!!((f = (S = s.value) == null ? void 0 : S.loading) != null && f.value));
43
- return q(() => {
44
- var u, n;
45
- return (n = (u = s.value) == null ? void 0 : u.loading) == null ? void 0 : n.value;
46
- }, (u) => {
47
- m.value = !!u;
48
- }), q(m, (u) => {
42
+ }), v = j(!!((h = (S = o.value) == null ? void 0 : S.loading) != null && h.value));
43
+ return _(() => {
44
+ var i, n;
45
+ return (n = (i = o.value) == null ? void 0 : i.loading) == null ? void 0 : n.value;
46
+ }, (i) => {
47
+ v.value = !!i;
48
+ }), _(v, (i) => {
49
49
  var n, r;
50
- (r = (n = s.value) == null ? void 0 : n.setLoading) == null || r.call(n, !!u);
50
+ (r = (n = o.value) == null ? void 0 : n.setLoading) == null || r.call(n, !!i);
51
51
  }), {
52
- formRef: i,
53
- actionRef: s,
54
- tableState: o,
52
+ formRef: s,
53
+ actionRef: o,
54
+ tableState: u,
55
55
  requestParams: d,
56
- loading: m,
56
+ loading: v,
57
57
  dataSource: w(() => {
58
- var u, n;
59
- return ((n = (u = s == null ? void 0 : s.value) == null ? void 0 : u.dataSource) == null ? void 0 : n.value) || [];
58
+ var i, n;
59
+ return ((n = (i = o == null ? void 0 : o.value) == null ? void 0 : i.dataSource) == null ? void 0 : n.value) || [];
60
60
  }),
61
61
  selectedKeys: w(() => {
62
- var u, n;
63
- return ((n = (u = s == null ? void 0 : s.value) == null ? void 0 : u.selectedKeys) == null ? void 0 : n.value) || [];
62
+ var i, n;
63
+ return ((n = (i = o == null ? void 0 : o.value) == null ? void 0 : i.selectedKeys) == null ? void 0 : n.value) || [];
64
64
  }),
65
65
  selectedItems: w(() => {
66
- var u, n;
67
- return ((n = (u = s == null ? void 0 : s.value) == null ? void 0 : u.selectedItems) == null ? void 0 : n.value) || [];
66
+ var i, n;
67
+ return ((n = (i = o == null ? void 0 : o.value) == null ? void 0 : i.selectedItems) == null ? void 0 : n.value) || [];
68
68
  }),
69
- rowsSelection: (b = s == null ? void 0 : s.value) == null ? void 0 : b.rowsSelection,
70
- mutate: (u) => {
69
+ rowsSelection: (b = o == null ? void 0 : o.value) == null ? void 0 : b.rowsSelection,
70
+ mutate: (i) => {
71
71
  var n, r;
72
- return (r = (n = s.value) == null ? void 0 : n.reSetDataList) == null ? void 0 : r.call(n, u);
72
+ return (r = (n = o.value) == null ? void 0 : n.reSetDataList) == null ? void 0 : r.call(n, i);
73
73
  },
74
- reloadAndReset: (u) => {
74
+ reloadAndReset: (i) => {
75
75
  var n, r;
76
- return (r = (n = s.value) == null ? void 0 : n.reloadAndReset) == null ? void 0 : r.call(n, u);
76
+ return (r = (n = o.value) == null ? void 0 : n.reloadAndReset) == null ? void 0 : r.call(n, i);
77
77
  },
78
- setPageAndReload: (u, n, r, y) => {
79
- var T, O;
80
- return (O = (T = s.value) == null ? void 0 : T.setPageAndReload) == null ? void 0 : O.call(T, u, n, r, y);
78
+ setPageAndReload: (i, n, r, y) => {
79
+ var p, k;
80
+ return (k = (p = o.value) == null ? void 0 : p.setPageAndReload) == null ? void 0 : k.call(p, i, n, r, y);
81
81
  },
82
- setPagination: (u) => {
82
+ setPagination: (i) => {
83
83
  var n, r;
84
- return (r = (n = s.value) == null ? void 0 : n.setPagination) == null ? void 0 : r.call(n, u);
84
+ return (r = (n = o.value) == null ? void 0 : n.setPagination) == null ? void 0 : r.call(n, i);
85
85
  },
86
- setLoading: (u) => m.value = u,
87
- setData: (u) => {
86
+ setLoading: (i) => v.value = i,
87
+ setDataValue: (i) => {
88
88
  var n, r;
89
- return (r = (n = s.value) == null ? void 0 : n.setData) == null ? void 0 : r.call(n, u);
89
+ return (r = (n = o.value) == null ? void 0 : n.setDataValue) == null ? void 0 : r.call(n, i);
90
90
  },
91
- reload: (u) => {
91
+ reload: (i) => {
92
92
  var n, r;
93
- return (r = (n = s.value) == null ? void 0 : n.reload) == null ? void 0 : r.call(n, u);
93
+ return (r = (n = o.value) == null ? void 0 : n.reload) == null ? void 0 : r.call(n, i);
94
94
  }
95
95
  };
96
96
  }
97
- const Vl = ["rowKey", "rowSelection", "columns", "pagination", "size", "bordered", "loading"], Dt = {
98
- ...qe(bl(), Vl),
97
+ const Gl = ["rowKey", "rowSelection", "columns", "pagination", "size", "bordered", "loading"], Mt = {
98
+ ...Xe(Cl(), Gl),
99
99
  transformCellText: Function,
100
100
  /**
101
101
  * @Author gx12358
@@ -115,8 +115,8 @@ const Vl = ["rowKey", "rowSelection", "columns", "pagination", "size", "bordered
115
115
  type: Object,
116
116
  default: void 0
117
117
  }
118
- }, de = {
119
- ...Dt,
118
+ }, he = {
119
+ ...Mt,
120
120
  rowSelection: {
121
121
  type: Object,
122
122
  default: void 0
@@ -183,6 +183,10 @@ const Vl = ["rowKey", "rowSelection", "columns", "pagination", "size", "bordered
183
183
  default: () => {
184
184
  }
185
185
  },
186
+ useDefaultScrollStyle: {
187
+ type: Boolean,
188
+ default: () => !1
189
+ },
186
190
  emptyText: {
187
191
  type: [Function, Object, Boolean, Array],
188
192
  default: () => {
@@ -388,24 +392,24 @@ const Vl = ["rowKey", "rowSelection", "columns", "pagination", "size", "bordered
388
392
  onRequestError: Function,
389
393
  onBeforeSearchSubmit: Function,
390
394
  onColumnsStateChange: Function
391
- }, { provideContext: Gl, useInjectContext: me } = kl("pro-table");
392
- function Ce(e, l) {
393
- return typeof l == "function" ? l(X(e)) : X(e).format(l);
395
+ }, { provideContext: Ql, useInjectContext: ge } = Pl("pro-table");
396
+ function Se(e, a) {
397
+ return typeof a == "function" ? a(U(e)) : U(e).format(a);
394
398
  }
395
- function Me(e, l) {
396
- return l ? "YYYY-MM-DD HH:mm:ss" : e ?? "YYYY-MM-DD";
399
+ function Ae(e, a) {
400
+ return a ? "YYYY-MM-DD HH:mm:ss" : e ?? "YYYY-MM-DD";
397
401
  }
398
- const Tt = (e, l, a = "string") => {
399
- if (ue(e)) {
400
- const [o, s] = e;
401
- let i, d;
402
- if (Array.isArray(l) ? (i = l[0], d = l[1]) : typeof l == "object" && l.type === "mask" ? (i = l.format, d = l.format) : (i = l, d = l), a === "string") {
403
- const m = o ? Ce(o, i) : "", x = s ? Ce(s, d) : "";
404
- return [m, x];
402
+ const $t = (e, a, l = "string") => {
403
+ if (oe(e)) {
404
+ const [u, o] = e;
405
+ let s, d;
406
+ if (Array.isArray(a) ? (s = a[0], d = a[1]) : typeof a == "object" && a.type === "mask" ? (s = a.format, d = a.format) : (s = a, d = a), l === "string") {
407
+ const v = u ? Se(u, s) : "", x = o ? Se(o, d) : "";
408
+ return [v, x];
405
409
  }
406
- return [X(o), X(s)];
410
+ return [U(u), U(o)];
407
411
  }
408
- }, Ql = (e) => ({
412
+ }, _l = (e) => ({
409
413
  [`${e.componentCls}-search`]: {
410
414
  position: "relative",
411
415
  display: "flex",
@@ -472,39 +476,39 @@ const Tt = (e, l, a = "string") => {
472
476
  alignItems: "center"
473
477
  }
474
478
  });
475
- function _l(e, l) {
476
- const a = we({});
477
- function o() {
479
+ function ql(e, a) {
480
+ const l = Te({});
481
+ function u() {
478
482
  Object.keys(e).forEach((d) => {
479
- s(d, e[d]);
483
+ o(d, e[d]);
480
484
  });
481
- const i = l.find((d) => d.valueType === "dateRange");
482
- i && s(i.name || "", e[i.rangeStartName || "start"] ? [
483
- e[i.rangeStartName || "start"],
484
- e[i.rangeEndName || "end"]
485
+ const s = a.find((d) => d.valueType === "dateRange");
486
+ s && o(s.name || "", e[s.rangeStartName || "start"] ? [
487
+ e[s.rangeStartName || "start"],
488
+ e[s.rangeEndName || "end"]
485
489
  ] : []);
486
490
  }
487
- Ye(() => {
488
- o();
491
+ Le(() => {
492
+ u();
489
493
  });
490
- function s(i, d) {
491
- a[i] = d;
494
+ function o(s, d) {
495
+ l[s] = d;
492
496
  }
493
497
  return {
494
- formState: a,
495
- resetFormState: o,
496
- changeFormState: s
498
+ formState: l,
499
+ resetFormState: u,
500
+ changeFormState: o
497
501
  };
498
502
  }
499
503
  const {
500
- useBreakpoint: ql
501
- } = st, {
502
- MonthPicker: Xl,
503
- RangePicker: Ul,
504
- YearPicker: Jl,
505
- WeekPicker: Zl,
506
- QuarterPicker: ea
507
- } = Et, Je = [{
504
+ useBreakpoint: Xl
505
+ } = ot, {
506
+ MonthPicker: Ul,
507
+ RangePicker: Jl,
508
+ YearPicker: Zl,
509
+ WeekPicker: ea,
510
+ QuarterPicker: ta
511
+ } = Dt, Ze = [{
508
512
  value: "xxl",
509
513
  span: 4
510
514
  }, {
@@ -522,382 +526,397 @@ const {
522
526
  }, {
523
527
  value: "xs",
524
528
  span: 1
525
- }], Mt = /* @__PURE__ */ he({
529
+ }];
530
+ function la(e) {
531
+ let a = e.reduce((l, u) => u.order !== void 0 ? Math.max(l, u.order) : l, 0);
532
+ return e.forEach((l) => {
533
+ l.order === void 0 && (a += 1, l.order = a);
534
+ }), e.sort((l, u) => l.order - u.order), e;
535
+ }
536
+ const At = /* @__PURE__ */ ve({
526
537
  name: "ProTableForm",
527
538
  props: {
528
- modal: de.modalScroll,
539
+ modal: he.modalScroll,
529
540
  searchMap: {
530
541
  type: Array,
531
542
  default: () => []
532
543
  },
533
- loading: de.loading,
534
- cardBordered: de.cardBordered,
544
+ loading: he.loading,
545
+ cardBordered: he.cardBordered,
535
546
  prefixCls: String,
536
547
  defaultParams: Object,
537
548
  onSearch: Function
538
549
  },
539
550
  setup(e, {
540
- slots: l,
541
- expose: a
551
+ slots: a,
552
+ expose: l
542
553
  }) {
543
554
  const {
544
- wrapSSR: o,
545
- hashId: s
546
- } = Xe("ProTableForm", [Ql], e.prefixCls), i = jt(), d = ql(), {
547
- manualSearch: m,
555
+ wrapSSR: u,
556
+ hashId: o
557
+ } = Ue("ProTableForm", [_l], e.prefixCls), s = Nt(), d = Xl(), {
558
+ manualSearch: v,
548
559
  searchConfig: x,
549
560
  searchActions: S
550
- } = me(), {
551
- formState: f,
561
+ } = ge(), {
562
+ formState: h,
552
563
  resetFormState: b,
553
- changeFormState: u
554
- } = _l(e.defaultParams || {}, e.searchMap || []), n = j(!1), r = w(() => {
564
+ changeFormState: i
565
+ } = ql(e.defaultParams || {}, e.searchMap || []), n = j(!1), r = w(() => {
555
566
  var t, g;
556
- return se((t = S.value) == null ? void 0 : t.reset) ? (g = S.value) == null ? void 0 : g.reset : m.value;
567
+ return ne((t = S.value) == null ? void 0 : t.reset) ? (g = S.value) == null ? void 0 : g.reset : v.value;
557
568
  }), y = w(() => {
558
569
  var t;
559
- return O((t = x.value) == null ? void 0 : t.span);
560
- }), T = w(() => {
570
+ return k((t = x.value) == null ? void 0 : t.span);
571
+ }), p = w(() => {
561
572
  var t;
562
573
  return (t = x.value) == null ? void 0 : t.label;
563
574
  });
564
- q(() => {
575
+ _(() => {
565
576
  var t;
566
577
  return (t = x.value) == null ? void 0 : t.defaultCollapsed;
567
578
  }, (t) => {
568
579
  n.value = n.value || !!t;
569
580
  });
570
- function O(t) {
581
+ function k(t) {
571
582
  let g = 4;
572
- for (let F = 0; F < Je.length; F += 1) {
573
- const p = Je[F].value;
574
- if (d.value[p]) {
575
- g = (t == null ? void 0 : t[p]) || (e.modal ? 3 : Je[F].span);
583
+ for (let R = 0; R < Ze.length; R += 1) {
584
+ const $ = Ze[R].value;
585
+ if (d.value[$]) {
586
+ g = (t == null ? void 0 : t[$]) || (e.modal ? 3 : Ze[R].span);
576
587
  break;
577
588
  }
578
589
  }
579
590
  return g;
580
591
  }
581
- const R = (t) => {
592
+ const F = (t) => {
582
593
  n.value = t;
583
- }, A = (t, g, F) => (t + 1) % g === 0 ? {
584
- ...F,
594
+ }, M = (t, g, R) => (t + 1) % g === 0 ? {
595
+ ...R,
585
596
  marginRight: 0
586
597
  } : {
587
- ...F,
598
+ ...R,
588
599
  marginRight: "2%"
589
- }, V = () => {
590
- const t = ie(f), g = e.searchMap.find((P) => P.valueType === "text") || "", F = e.searchMap.find((P) => P.valueType === "dateRange") || "", p = e.searchMap.find((P) => P.valueType === "treeSelect");
591
- return g && (t[g.name] = f[g.name] || g.initialValue || ""), F && (t[F.rangeStartName || "start"] = t[F.name] ? t[F.name][0] : "", t[F.rangeEndName || "end"] = t[F.name] ? t[F.name][1] : "", delete t[F.name]), p && (p != null && p.name && ue(f[p == null ? void 0 : p.name]) && (t[p.name] = f[p.name].length ? f[p.name].map((P) => P[p.valueKey === "text" ? "label" : "value"]).join() : ""), p != null && p.name && ue(t[p == null ? void 0 : p.name]) && (t[p.name] = t[p.name].length ? t[p.name].map((P) => P[p.valueKey === "text" ? "label" : "value"]) : "")), t;
592
- }, L = (t = !1, g) => {
600
+ }, G = () => {
601
+ const t = re(h), g = e.searchMap.find((P) => P.valueType === "text") || "", R = e.searchMap.find((P) => P.valueType === "dateRange") || "", $ = e.searchMap.find((P) => P.valueType === "treeSelect");
602
+ return g && (t[g.name] = h[g.name] || g.initialValue || ""), R && (t[R.rangeStartName || "start"] = t[R.name] ? t[R.name][0] : "", t[R.rangeEndName || "end"] = t[R.name] ? t[R.name][1] : "", delete t[R.name]), $ && ($ != null && $.name && oe(h[$ == null ? void 0 : $.name]) && (t[$.name] = h[$.name].length ? h[$.name].map((P) => P[$.valueKey === "text" ? "label" : "value"]).join() : ""), $ != null && $.name && oe(t[$ == null ? void 0 : $.name]) && (t[$.name] = t[$.name].length ? t[$.name].map((P) => P[$.valueKey === "text" ? "label" : "value"]) : "")), t;
603
+ }, W = (t = !1, g) => {
593
604
  Ot(() => {
594
- var F;
595
- (m.value || t) && ((F = e.onSearch) == null || F.call(e, V(), t ? g ? "reset" : "submit" : void 0));
605
+ var R;
606
+ (v.value || t) && ((R = e.onSearch) == null || R.call(e, G(), t ? g ? "reset" : "submit" : void 0));
596
607
  });
597
- }, W = (t, g) => {
598
- var F, p;
608
+ }, Y = (t, g) => {
609
+ var R, $;
599
610
  switch (g.valueType) {
600
611
  case "text":
601
- u(g.name || "", t || "");
612
+ i(g.name || "", t || "");
602
613
  break;
603
614
  case "select":
604
- u(g.name || "", t ?? void 0);
615
+ i(g.name || "", t ?? void 0);
605
616
  break;
606
617
  case "treeSelect":
607
- u(g.name || "", t ?? ((F = g.field) != null && F.treeCheckable || (p = g.field) != null && p.multiple ? [] : null));
618
+ i(g.name || "", t ?? ((R = g.field) != null && R.treeCheckable || ($ = g.field) != null && $.multiple ? [] : null));
608
619
  break;
609
620
  case "date":
610
- u(g.name || "", t ? Ce(t, Me(g.valueFormat, g.showTime)) : null);
621
+ i(g.name || "", t ? Se(t, Ae(g.valueFormat, g.showTime)) : null);
611
622
  break;
612
623
  case "dateWeek":
613
- u(g.name || "", t ? Ce(t, "YYYY-wo") : null);
624
+ i(g.name || "", t ? Se(t, "YYYY-wo") : null);
614
625
  break;
615
626
  case "dateMonth":
616
- u(g.name || "", t ? Ce(t, "YYYY-MM") : null);
627
+ i(g.name || "", t ? Se(t, "YYYY-MM") : null);
617
628
  break;
618
629
  case "dateQuarter":
619
- u(g.name || "", t ? Ce(t, "YYYY-QQ") : null);
630
+ i(g.name || "", t ? Se(t, "YYYY-QQ") : null);
620
631
  break;
621
632
  case "dateYear":
622
- u(g.name || "", t ? Ce(t, "YYYY") : null);
633
+ i(g.name || "", t ? Se(t, "YYYY") : null);
623
634
  break;
624
635
  case "dateRange":
625
- u(g.name || "", t && ue(t) && t.length === 2 ? Tt(t, Me(g.valueFormat, g.showTime)) : null);
636
+ i(g.name || "", t && oe(t) && t.length === 2 ? $t(t, Ae(g.valueFormat, g.showTime)) : null);
626
637
  break;
627
638
  case "time":
628
- u(g.name || "", t ? Ce(t, g.valueFormat || "HH:mm:ss") : null);
639
+ i(g.name || "", t ? Se(t, g.valueFormat || "HH:mm:ss") : null);
629
640
  break;
630
641
  }
631
- g.valueType === "treeSelect" || g.valueType, L();
632
- }, K = (t = !0) => {
633
- b(), L(!0, t);
642
+ g.valueType === "treeSelect" || g.valueType, W();
643
+ }, ue = (t = !0) => {
644
+ b(), W(!0, t);
634
645
  };
635
- a({
636
- getFormState: () => V(),
637
- resetForm: K
646
+ l({
647
+ getFormState: () => G(),
648
+ resetForm: ue
638
649
  });
639
- const G = () => {
650
+ const A = () => {
640
651
  var g;
641
- const t = (g = i == null ? void 0 : i.emptyText) == null ? void 0 : g.value;
652
+ const t = (g = s == null ? void 0 : s.emptyText) == null ? void 0 : g.value;
642
653
  if (t) {
643
- const F = Z(t), p = F ? kt(t) : Bt(t || []);
654
+ const R = le(t), $ = R ? Pt(t) : Rt(t || []);
644
655
  return c("div", {
645
- class: Se(`${e.prefixCls}-search-empty-text`, s.value)
646
- }, [F ? p : ue(p) ? p.map((P) => it(P)) : void 0]);
656
+ class: pe(`${e.prefixCls}-search-empty-text`, o.value)
657
+ }, [R ? $ : oe($) ? $.map((P) => st(P)) : void 0]);
647
658
  }
648
- }, H = () => (m.value || r.value) && c(xe, null, {
649
- default: () => [r.value && c(wt, {
650
- onClick: () => K()
659
+ }, K = () => (v.value || r.value) && c(we, null, {
660
+ default: () => [r.value && c(pt, {
661
+ onClick: () => ue()
651
662
  }, {
652
663
  default: () => {
653
664
  var t;
654
665
  return [((t = S.value) == null ? void 0 : t.resetText) || "重置"];
655
666
  }
656
- }), m.value && c(wt, {
667
+ }), v.value && c(pt, {
657
668
  loading: e.loading,
658
669
  type: "primary",
659
- onClick: () => L(!0)
670
+ onClick: () => W(!0)
660
671
  }, {
661
672
  default: () => {
662
673
  var t;
663
674
  return [((t = S.value) == null ? void 0 : t.searchText) || "查询"];
664
675
  }
665
676
  })]
666
- }), oe = ({
677
+ }), ce = ({
667
678
  formItemStyle: t,
668
679
  advanced: g,
669
- showAdvanced: F = !0
680
+ showAdvanced: R = !0
670
681
  }) => c("div", {
671
682
  style: t,
672
- class: `${e.prefixCls}-search-collapse-button ${s.value}`
673
- }, [c(xe, {
683
+ class: `${e.prefixCls}-search-collapse-button ${o.value}`
684
+ }, [c(we, {
674
685
  size: 16
675
686
  }, {
676
687
  default: () => {
677
- var p, P;
678
- return [H(), F && c("span", {
679
- class: `${e.prefixCls}-a ${s.value}`,
680
- onClick: () => R(!g)
681
- }, [g ? "收起" : "展开", (p = x.value) != null && p.collapseRender ? (P = x.value) == null ? void 0 : P.collapseRender(g) : g ? c(xl, null, null) : c(Sl, null, null)])];
688
+ var $, P;
689
+ return [K(), R && c("span", {
690
+ class: `${e.prefixCls}-a ${o.value}`,
691
+ onClick: () => F(!g)
692
+ }, [g ? "收起" : "展开", ($ = x.value) != null && $.collapseRender ? (P = x.value) == null ? void 0 : P.collapseRender(g) : g ? c(Sl, null, null) : c(wl, null, null)])];
682
693
  }
683
- })]), le = (t) => {
684
- var p, P, I, N;
694
+ })]), Re = (t) => {
695
+ var $, P, q, I;
685
696
  let g;
686
- const F = m.value ? pt : pt.Search;
697
+ const R = v.value ? Tt : Tt.Search;
687
698
  switch (t.valueType) {
688
699
  case "text":
689
- g = c(F, _({
700
+ g = c(R, Q({
690
701
  style: {
691
702
  width: "100%"
692
703
  },
693
- value: f[t.name],
704
+ value: h[t.name],
694
705
  placeholder: t.placeholder || "请输入",
695
706
  allowClear: t.allowClear || t.allowClear === !1 ? t.allowClear : !0,
696
- onChange: (v) => W(v.target.value, t),
697
- onSearch: (v) => L()
707
+ onChange: (f) => Y(f.target.value, t),
708
+ onSearch: (f) => W()
698
709
  }, t.field || {}), null);
699
710
  break;
700
711
  case "select":
701
- g = c(El, _({
712
+ g = c(Dl, Q({
702
713
  style: {
703
714
  width: "100%"
704
715
  },
705
- value: t.loading ? void 0 : f[t.name],
716
+ value: t.loading ? void 0 : h[t.name],
706
717
  optionFilterProp: "label",
707
718
  placeholder: t.placeholder || "请选择",
708
719
  showSearch: t.showSearch,
709
720
  allowClear: t.allowClear ?? !0,
710
- getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
711
- notFoundContent: t.loading === void 0 ? void 0 : t.loading ? c(nt, {
721
+ getPopupContainer: (f) => f && f.parentNode ? f.parentNode : f,
722
+ notFoundContent: t.loading === void 0 ? void 0 : t.loading ? c(ut, {
712
723
  size: "small",
713
- indicator: (p = i == null ? void 0 : i.indicator) == null ? void 0 : p.value
714
- }, null) : G(),
715
- onChange: (v) => W(v, t),
716
- options: t.loading ? [] : (P = t == null ? void 0 : t.valueEnum) == null ? void 0 : P.map((v) => ({
717
- label: v.text,
718
- value: v.value
724
+ indicator: ($ = s == null ? void 0 : s.indicator) == null ? void 0 : $.value
725
+ }, null) : A(),
726
+ onChange: (f) => Y(f, t),
727
+ options: t.loading ? [] : (P = t == null ? void 0 : t.valueEnum) == null ? void 0 : P.map((f) => ({
728
+ label: f.text,
729
+ value: f.value
719
730
  }))
720
731
  }, t.field || {}), null);
721
732
  break;
722
733
  case "treeSelect":
723
- g = c(Nl, _({
734
+ g = c(El, Q({
724
735
  style: {
725
736
  width: "100%"
726
737
  },
727
- value: f[t.name],
738
+ value: h[t.name],
728
739
  placeholder: t.placeholder || "请选择",
729
740
  allowClear: t.allowClear ?? !0,
730
741
  treeData: t.loading ? [] : t.valueEnum,
731
- getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
732
- notFoundContent: t.loading === void 0 ? void 0 : t.loading ? c(nt, {
742
+ getPopupContainer: (f) => f && f.parentNode ? f.parentNode : f,
743
+ notFoundContent: t.loading === void 0 ? void 0 : t.loading ? c(ut, {
733
744
  size: "small",
734
- indicator: (I = i == null ? void 0 : i.indicator) == null ? void 0 : I.value
735
- }, null) : G(),
736
- onChange: (v) => W(v, t)
745
+ indicator: (q = s == null ? void 0 : s.indicator) == null ? void 0 : q.value
746
+ }, null) : A(),
747
+ onChange: (f) => Y(f, t)
737
748
  }, t.field || {}), null);
738
749
  break;
739
750
  case "date":
740
- g = c(Et, _({
751
+ g = c(Dt, Q({
741
752
  style: {
742
753
  width: "100%"
743
754
  },
744
- value: f[t.name] ? X(f[t.name]) : void 0,
745
- getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
755
+ value: h[t.name] ? U(h[t.name]) : void 0,
756
+ getPopupContainer: (f) => f && f.parentNode ? f.parentNode : f,
746
757
  placeholder: t.placeholder || "请选择",
747
758
  allowClear: t.allowClear ?? !0,
748
- format: Me(t.valueFormat, t.showTime),
759
+ format: Ae(t.valueFormat, t.showTime),
749
760
  showTime: t.showTime,
750
761
  showToday: t.showToday || !0,
751
- onChange: (v) => W(v, t)
762
+ onChange: (f) => Y(f, t)
752
763
  }, t.field || {}), null);
753
764
  break;
754
765
  case "dateWeek":
755
- g = c(Zl, _({
766
+ g = c(ea, Q({
756
767
  style: {
757
768
  width: "100%"
758
769
  },
759
- value: f[t.name] ? X(f[t.name], t.valueFormat || "YYYY-wo") : void 0,
760
- getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
770
+ value: h[t.name] ? U(h[t.name], t.valueFormat || "YYYY-wo") : void 0,
771
+ getPopupContainer: (f) => f && f.parentNode ? f.parentNode : f,
761
772
  allowClear: t.allowClear ?? !0,
762
773
  placeholder: t.placeholder || "请选择",
763
- onChange: (v) => W(v, t)
774
+ onChange: (f) => Y(f, t)
764
775
  }, t.field || {}), null);
765
776
  break;
766
777
  case "dateMonth":
767
- g = c(Xl, _({
778
+ g = c(Ul, Q({
768
779
  style: {
769
780
  width: "100%"
770
781
  },
771
- value: f[t.name] ? X(f[t.name], t.valueFormat || "YYYY-MM") : void 0,
772
- getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
782
+ value: h[t.name] ? U(h[t.name], t.valueFormat || "YYYY-MM") : void 0,
783
+ getPopupContainer: (f) => f && f.parentNode ? f.parentNode : f,
773
784
  allowClear: t.allowClear ?? !0,
774
785
  placeholder: t.placeholder || "请选择",
775
- onChange: (v) => W(v, t)
786
+ onChange: (f) => Y(f, t)
776
787
  }, t.field || {}), null);
777
788
  break;
778
789
  case "dateQuarter":
779
- g = c(ea, _({
790
+ g = c(ta, Q({
780
791
  style: {
781
792
  width: "100%"
782
793
  },
783
- value: f[t.name] ? X(f[t.name], t.valueFormat || "YYYY-QQ") : void 0,
784
- getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
794
+ value: h[t.name] ? U(h[t.name], t.valueFormat || "YYYY-QQ") : void 0,
795
+ getPopupContainer: (f) => f && f.parentNode ? f.parentNode : f,
785
796
  allowClear: t.allowClear ?? !0,
786
797
  placeholder: t.placeholder || "请选择",
787
- onChange: (v) => W(v, t)
798
+ onChange: (f) => Y(f, t)
788
799
  }, t.field || {}), null);
789
800
  break;
790
801
  case "dateYear":
791
- g = c(Jl, _({
802
+ g = c(Zl, Q({
792
803
  style: {
793
804
  width: "100%"
794
805
  },
795
- value: f[t.name] ? X(f[t.name], t.valueFormat || "YYYY") : void 0,
796
- getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
806
+ value: h[t.name] ? U(h[t.name], t.valueFormat || "YYYY") : void 0,
807
+ getPopupContainer: (f) => f && f.parentNode ? f.parentNode : f,
797
808
  allowClear: t.allowClear ?? !0,
798
809
  placeholder: t.placeholder || "请选择",
799
- onChange: (v) => W(v, t)
810
+ onChange: (f) => Y(f, t)
800
811
  }, t.field || {}), null);
801
812
  break;
802
813
  case "dateRange":
803
- g = c(Ul, _({
814
+ g = c(Jl, Q({
804
815
  style: {
805
816
  width: "100%"
806
817
  },
807
- value: f[t.name] && ue(f[t.name]) && ((N = f[t.name]) == null ? void 0 : N.length) === 2 ? Tt(f[t.name], Me(t.valueFormat, t.showTime), "dayjs") : void 0,
808
- getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
818
+ value: h[t.name] && oe(h[t.name]) && ((I = h[t.name]) == null ? void 0 : I.length) === 2 ? $t(h[t.name], Ae(t.valueFormat, t.showTime), "dayjs") : void 0,
819
+ getPopupContainer: (f) => f && f.parentNode ? f.parentNode : f,
809
820
  placeholder: t.placeholder || ["开始日期", "结束日期"],
810
- format: Me(t.valueFormat, t.showTime),
821
+ format: Ae(t.valueFormat, t.showTime),
811
822
  showTime: t.showTime,
812
- onChange: (v) => W(v, t)
823
+ onChange: (f) => Y(f, t)
813
824
  }, t.field || {}), null);
814
825
  break;
815
826
  case "time":
816
- g = c(jl, _({
827
+ g = c(Nl, Q({
817
828
  style: {
818
829
  width: "100%"
819
830
  },
820
- value: f[t.name] ? X(f[t.name], t.valueFormat || "HH:mm:ss") : void 0,
821
- getPopupContainer: (v) => v && v.parentNode ? v.parentNode : v,
831
+ value: h[t.name] ? U(h[t.name], t.valueFormat || "HH:mm:ss") : void 0,
832
+ getPopupContainer: (f) => f && f.parentNode ? f.parentNode : f,
822
833
  placeholder: t.placeholder || "请选择",
823
834
  allowClear: t.allowClear || t.allowClear === !1 ? t.allowClear : !0,
824
835
  use12Hours: t.use12Hours,
825
836
  format: t.valueFormat || "HH:mm:ss",
826
- onChange: (v) => W(v, t)
837
+ onChange: (f) => Y(f, t)
827
838
  }, t.field || {}), null);
828
839
  break;
829
840
  }
830
841
  return g;
831
- }, re = ({
842
+ }, ee = ({
832
843
  formItemStyle: t = {},
833
844
  item: g
834
845
  }) => {
835
- var I, N, v, z, ve, pe, Te, ee;
836
- const F = Z(g) ? (I = g.props) == null ? void 0 : I.label : g.label, p = (Z(g) ? (N = g.props) == null ? void 0 : N.labelWidth : g.labelWidth) || ((v = T.value) == null ? void 0 : v.width), P = (Z(g) ? (z = g.props) == null ? void 0 : z.labelAlign : g.labelAlign) || ((ve = T.value) == null ? void 0 : ve.align);
846
+ var q, I, f, L, V, X, de, J;
847
+ const R = le(g) ? (q = g.props) == null ? void 0 : q.label : g.label, $ = (le(g) ? (I = g.props) == null ? void 0 : I.labelWidth : g.labelWidth) || ((f = p.value) == null ? void 0 : f.width), P = (le(g) ? (L = g.props) == null ? void 0 : L.labelAlign : g.labelAlign) || ((V = p.value) == null ? void 0 : V.align);
837
848
  return c("div", {
838
849
  class: `${e.prefixCls}-search-item`,
839
850
  style: {
840
851
  ...t,
841
- gap: (pe = T.value) != null && pe.gap ? St((Te = T.value) == null ? void 0 : Te.gap) : void 0
852
+ gap: (X = p.value) != null && X.gap ? wt((de = p.value) == null ? void 0 : de.gap) : void 0
842
853
  }
843
- }, [F && c("div", {
844
- class: Se(`${e.prefixCls}-search-item-label`, ((ee = T.value) == null ? void 0 : ee.colon) === !1 && `${e.prefixCls}-search-item-label-no-colon`, P && `${e.prefixCls}-search-item-label-${P}`),
854
+ }, [R && c("div", {
855
+ class: pe(`${e.prefixCls}-search-item-label`, ((J = p.value) == null ? void 0 : J.colon) === !1 && `${e.prefixCls}-search-item-label-no-colon`, P && `${e.prefixCls}-search-item-label-${P}`),
845
856
  style: {
846
- width: p ? St(p) : void 0
857
+ width: $ ? wt($) : void 0
847
858
  }
848
- }, [F]), c("div", {
849
- class: Se(`${e.prefixCls}-search-item-children`)
850
- }, [Z(g) ? g : le(g)])]);
851
- }, Oe = () => {
852
- var F;
853
- const t = [...e.searchMap, ...((F = l.default) == null ? void 0 : F.call(l)) || []], g = {
859
+ }, [R]), c("div", {
860
+ class: pe(`${e.prefixCls}-search-item-children`)
861
+ }, [le(g) ? g : Re(g)])]);
862
+ }, Fe = () => {
863
+ var $, P;
864
+ let t = (($ = a.default) == null ? void 0 : $.call(a)) || [];
865
+ t.length === 1 && t[0].type === "template" && (t = ((P = t[0]) == null ? void 0 : P.children) || []);
866
+ const g = la([...e.searchMap, ...t.map((q) => {
867
+ var I;
868
+ return {
869
+ ...q,
870
+ order: ((I = q.props) == null ? void 0 : I.order) || void 0
871
+ };
872
+ })]), R = {
854
873
  width: `${(100 - (y.value - 1) * 2) / y.value}%`
855
874
  };
856
- return t.map((p, P) => {
857
- const I = A(P, y.value, g);
858
- return t.length < y.value || n.value ? c(_e, null, [re({
859
- formItemStyle: I,
860
- item: p
861
- }), P === t.length - 1 && oe({
875
+ return g.map((q, I) => {
876
+ const f = M(I, y.value, R);
877
+ return g.length < y.value || n.value ? c(qe, null, [ee({
878
+ formItemStyle: f,
879
+ item: q
880
+ }), I === g.length - 1 && ce({
862
881
  formItemStyle: {
863
882
  flex: 1,
864
883
  justifyContent: "flex-end"
865
884
  },
866
885
  advanced: n.value,
867
886
  showAdvanced: n.value
868
- })]) : c(_e, null, [P < y.value - 1 && re({
869
- formItemStyle: I,
870
- item: p
871
- }), P === y.value - 1 && (y.value - 1 === 0 || t.length === y.value) && re({
872
- formItemStyle: I,
873
- item: p
874
- }), P === y.value - 1 && t.length >= y.value && oe({
887
+ })]) : c(qe, null, [I < y.value - 1 && ee({
888
+ formItemStyle: f,
889
+ item: q
890
+ }), I === y.value - 1 && (y.value - 1 === 0 || g.length === y.value) && ee({
891
+ formItemStyle: f,
892
+ item: q
893
+ }), I === y.value - 1 && g.length >= y.value && ce({
875
894
  formItemStyle: {
876
895
  flex: 1,
877
896
  justifyContent: "flex-end"
878
897
  },
879
898
  advanced: !1,
880
- showAdvanced: t.length !== y.value
899
+ showAdvanced: g.length !== y.value
881
900
  })]);
882
901
  });
883
902
  };
884
903
  return () => {
885
904
  var g;
886
905
  const t = e.cardBordered && `${e.prefixCls}-search-border`;
887
- return o(c("div", {
888
- class: Se(s.value, `${e.prefixCls}-search`, t, s.value, (g = x.value) == null ? void 0 : g.className)
889
- }, [Oe()]));
906
+ return u(c("div", {
907
+ class: pe(o.value, `${e.prefixCls}-search`, t, o.value, (g = x.value) == null ? void 0 : g.className)
908
+ }, [Fe()]));
890
909
  };
891
910
  }
892
911
  });
893
- Mt.inheritAttrs = !1;
894
- const ze = (e) => {
895
- const l = j(null);
896
- return l.value = e, (...a) => {
897
- var o;
898
- return (o = l.value) == null ? void 0 : o.call(l, ...a);
912
+ At.inheritAttrs = !1;
913
+ const Ye = (e) => {
914
+ const a = j(null);
915
+ return a.value = e, (...l) => {
916
+ var u;
917
+ return (u = a.value) == null ? void 0 : u.call(a, ...l);
899
918
  };
900
- }, ta = (e) => ({
919
+ }, aa = (e) => ({
901
920
  [`${e.componentCls}`]: {
902
921
  width: "auto",
903
922
  "&-title": {
@@ -979,42 +998,42 @@ const ze = (e) => {
979
998
  }
980
999
  }
981
1000
  }
982
- }), Ze = ({
1001
+ }), et = ({
983
1002
  title: e,
984
- show: l,
985
- treeKey: a,
986
- fixed: o
1003
+ show: a,
1004
+ treeKey: l,
1005
+ fixed: u
987
1006
  }, {
988
- slots: s
1007
+ slots: o
989
1008
  }) => {
990
1009
  const {
991
- cacheColumns: i,
1010
+ cacheColumns: s,
992
1011
  settingsAction: d
993
- } = me();
994
- return l ? c(fe, {
1012
+ } = ge();
1013
+ return a ? c(me, {
995
1014
  title: e
996
1015
  }, {
997
1016
  default: () => {
998
- var m;
1017
+ var v;
999
1018
  return [c("span", {
1000
1019
  onClick: (x) => {
1001
1020
  var n, r, y;
1002
1021
  x.stopPropagation(), x.preventDefault();
1003
- const S = ((r = (n = C(i)) == null ? void 0 : n.find((T) => T.uuid === a)) == null ? void 0 : r.key) || "", f = (d == null ? void 0 : d.columnsMap[S]) || {};
1004
- if (typeof f.disable == "boolean" ? f.disable : (y = f.disable) == null ? void 0 : y.icon) return;
1005
- const u = {
1022
+ const S = ((r = (n = C(s)) == null ? void 0 : n.find((p) => p.uuid === l)) == null ? void 0 : r.key) || "", h = (d == null ? void 0 : d.columnsMap[S]) || {};
1023
+ if (typeof h.disable == "boolean" ? h.disable : (y = h.disable) == null ? void 0 : y.icon) return;
1024
+ const i = {
1006
1025
  ...d == null ? void 0 : d.columnsMap,
1007
1026
  [S]: {
1008
- ...f,
1009
- fixed: o
1027
+ ...h,
1028
+ fixed: u
1010
1029
  }
1011
1030
  };
1012
- d == null || d.setColumnsMap(u, "fixed");
1031
+ d == null || d.setColumnsMap(i, "fixed");
1013
1032
  }
1014
- }, [(m = s.default) == null ? void 0 : m.call(s)])];
1033
+ }, [(v = o.default) == null ? void 0 : v.call(o)])];
1015
1034
  }
1016
1035
  }) : null;
1017
- }, la = /* @__PURE__ */ he({
1036
+ }, na = /* @__PURE__ */ ve({
1018
1037
  props: {
1019
1038
  treeKey: String,
1020
1039
  hashId: String,
@@ -1025,45 +1044,45 @@ const ze = (e) => {
1025
1044
  },
1026
1045
  setup(e) {
1027
1046
  const {
1028
- cacheColumns: l
1029
- } = me(), a = w(() => {
1030
- var s, i;
1031
- return ((i = (s = C(l)) == null ? void 0 : s.find((d) => d.uuid === e.treeKey)) == null ? void 0 : i.key) || "";
1032
- }), o = w(() => a.value === "action" && e.autoScroll);
1047
+ cacheColumns: a
1048
+ } = ge(), l = w(() => {
1049
+ var o, s;
1050
+ return ((s = (o = C(a)) == null ? void 0 : o.find((d) => d.uuid === e.treeKey)) == null ? void 0 : s.key) || "";
1051
+ }), u = w(() => l.value === "action" && e.autoScroll);
1033
1052
  return () => {
1034
- const s = c("span", {
1053
+ const o = c("span", {
1035
1054
  class: [`${e.className}-list-item-option`, e.hashId]
1036
- }, [c(Ze, {
1055
+ }, [c(et, {
1037
1056
  treeKey: e.treeKey || "",
1038
1057
  fixed: "left",
1039
1058
  title: "固定在列首",
1040
- show: e.fixed !== "left" && !o.value
1059
+ show: e.fixed !== "left" && !u.value
1041
1060
  }, {
1042
- default: () => [c(wl, null, null)]
1043
- }), c(Ze, {
1061
+ default: () => [c(pl, null, null)]
1062
+ }), c(et, {
1044
1063
  treeKey: e.treeKey || "",
1045
1064
  fixed: void 0,
1046
1065
  title: "不固定",
1047
- show: !!e.fixed && !o.value
1066
+ show: !!e.fixed && !u.value
1048
1067
  }, {
1049
- default: () => [c(pl, null, null)]
1050
- }), c(Ze, {
1068
+ default: () => [c(Tl, null, null)]
1069
+ }), c(et, {
1051
1070
  treeKey: e.treeKey || "",
1052
1071
  fixed: "right",
1053
1072
  title: "固定在列尾",
1054
1073
  show: e.fixed !== "right"
1055
1074
  }, {
1056
- default: () => [c(Tl, null, null)]
1075
+ default: () => [c($l, null, null)]
1057
1076
  })]);
1058
1077
  return c("span", {
1059
1078
  class: [`${e.className}-list-item`, e.hashId],
1060
1079
  key: e.treeKey
1061
1080
  }, [c("div", {
1062
1081
  class: [`${e.className}-list-item-title`, e.hashId]
1063
- }, [e.title]), s]);
1082
+ }, [e.title]), o]);
1064
1083
  };
1065
1084
  }
1066
- }), et = /* @__PURE__ */ he({
1085
+ }), tt = /* @__PURE__ */ ve({
1067
1086
  props: {
1068
1087
  list: Array,
1069
1088
  keys: Array,
@@ -1078,100 +1097,100 @@ const ze = (e) => {
1078
1097
  }
1079
1098
  },
1080
1099
  setup(e) {
1081
- const l = j(at().uuid(15)), a = w(() => e.list && e.list.length > 0), o = j([]), s = j([]), {
1082
- cacheColumns: i,
1100
+ const a = j(nt().uuid(15)), l = w(() => e.list && e.list.length > 0), u = j([]), o = j([]), {
1101
+ cacheColumns: s,
1083
1102
  slots: d,
1084
- settingsAction: m
1085
- } = me(), x = (u, n) => u.map(({
1103
+ settingsAction: v
1104
+ } = ge(), x = (i, n) => i.map(({
1086
1105
  key: r,
1087
1106
  children: y,
1088
- uuid: T,
1089
- ...O
1107
+ uuid: p,
1108
+ ...k
1090
1109
  }) => {
1091
- var L;
1092
- const R = (m == null ? void 0 : m.columnsMap[r || "null"]) || {
1110
+ var W;
1111
+ const F = (v == null ? void 0 : v.columnsMap[r || "null"]) || {
1093
1112
  show: !0
1094
1113
  };
1095
- let A = !1;
1096
- R.show !== !1 && (n == null ? void 0 : n.show) !== !1 && !y && (A = !0);
1097
- const V = {
1098
- key: T || "",
1099
- ...qe(O, ["dataIndex"]),
1100
- checked: A,
1114
+ let M = !1;
1115
+ F.show !== !1 && (n == null ? void 0 : n.show) !== !1 && !y && (M = !0);
1116
+ const G = {
1117
+ key: p || "",
1118
+ ...Xe(k, ["dataIndex"]),
1119
+ checked: M,
1101
1120
  selectable: !1,
1102
- disabled: R.disable === !0,
1103
- disableCheckbox: typeof R.disable == "boolean" ? R.disable : (L = R.disable) == null ? void 0 : L.checkbox,
1121
+ disabled: F.disable === !0,
1122
+ disableCheckbox: typeof F.disable == "boolean" ? F.disable : (W = F.disable) == null ? void 0 : W.checkbox,
1104
1123
  isLeaf: !0
1105
1124
  };
1106
- return y && (V.children = x(y, R)), V;
1125
+ return y && (G.children = x(y, F)), G;
1107
1126
  });
1108
- Ye(() => {
1109
- const u = x(e.list || []);
1110
- 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));
1127
+ Le(() => {
1128
+ const i = x(e.list || []);
1129
+ u.value = i, o.value = i.filter((n) => n.checked).map((n) => n.key), (v == null ? void 0 : v.operationType.value) === "fixed" && (a.value = nt().uuid(15));
1111
1130
  });
1112
- const S = ze((u, n, r) => {
1113
- var K, G;
1114
- const y = ((K = C(i).find((H) => H.uuid === u)) == null ? void 0 : K.key) || "", T = ((G = C(i).find((H) => H.uuid === n)) == null ? void 0 : G.key) || "", O = {
1115
- ...m == null ? void 0 : m.columnsMap
1116
- }, R = [...m.sortKeyColumns.value], A = R.findIndex((H) => H === y), V = R.findIndex((H) => H === T), L = r > A;
1117
- if (A < 0)
1131
+ const S = Ye((i, n, r) => {
1132
+ var ue, A;
1133
+ const y = ((ue = C(s).find((K) => K.uuid === i)) == null ? void 0 : ue.key) || "", p = ((A = C(s).find((K) => K.uuid === n)) == null ? void 0 : A.key) || "", k = {
1134
+ ...v == null ? void 0 : v.columnsMap
1135
+ }, F = [...v.sortKeyColumns.value], M = F.findIndex((K) => K === y), G = F.findIndex((K) => K === p), W = r > M;
1136
+ if (M < 0)
1118
1137
  return;
1119
- const W = R[A];
1120
- R.splice(A, 1), r === 0 ? R.unshift(W) : R.splice(L ? V : V + 1, 0, W), R.forEach((H, oe) => {
1121
- O[H] = {
1122
- ...O[H] || {},
1123
- order: oe
1138
+ const Y = F[M];
1139
+ F.splice(M, 1), r === 0 ? F.unshift(Y) : F.splice(W ? G : G + 1, 0, Y), F.forEach((K, ce) => {
1140
+ k[K] = {
1141
+ ...k[K] || {},
1142
+ order: ce
1124
1143
  };
1125
- }), m == null || m.setColumnsMap(O, "drop"), m == null || m.setSortKeyColumns(R);
1126
- }), f = ze((u) => {
1127
- var R;
1128
- const n = u.node.key, r = ((R = C(i).find((A) => A.uuid === n)) == null ? void 0 : R.key) || "", T = {
1129
- ...(m == null ? void 0 : m.columnsMap[r]) || {}
1144
+ }), v == null || v.setColumnsMap(k, "drop"), v == null || v.setSortKeyColumns(F);
1145
+ }), h = Ye((i) => {
1146
+ var F;
1147
+ const n = i.node.key, r = ((F = C(s).find((M) => M.uuid === n)) == null ? void 0 : F.key) || "", p = {
1148
+ ...(v == null ? void 0 : v.columnsMap[r]) || {}
1130
1149
  };
1131
- T.show = u.checked;
1132
- const O = {
1133
- ...m == null ? void 0 : m.columnsMap,
1134
- [r]: T
1150
+ p.show = i.checked;
1151
+ const k = {
1152
+ ...v == null ? void 0 : v.columnsMap,
1153
+ [r]: p
1135
1154
  };
1136
- m == null || m.setColumnsMap(O, "show");
1137
- }), b = (u) => {
1138
- const n = C(i).find((r) => r.uuid === u.key);
1139
- return u.title || fl(d, "headerCell", {
1155
+ v == null || v.setColumnsMap(k, "show");
1156
+ }), b = (i) => {
1157
+ const n = C(s).find((r) => r.uuid === i.key);
1158
+ return i.title || hl(d, "headerCell", {
1140
1159
  title: n.title,
1141
1160
  column: n
1142
1161
  }, () => [n.title]);
1143
1162
  };
1144
1163
  return () => {
1145
- var u, n;
1146
- return a.value ? c(_e, null, [e.showTitle && c("span", {
1164
+ var i, n;
1165
+ return l.value ? c(qe, null, [e.showTitle && c("span", {
1147
1166
  class: [`${e.className}-list-title`, e.hashId]
1148
- }, [e.title]), c(Al, {
1149
- key: l.value,
1150
- draggable: e.draggable && !!((u = o.value) != null && u.length) && ((n = o.value) == null ? void 0 : n.length) > 1,
1167
+ }, [e.title]), c(Kl, {
1168
+ key: a.value,
1169
+ draggable: e.draggable && !!((i = u.value) != null && i.length) && ((n = u.value) == null ? void 0 : n.length) > 1,
1151
1170
  checkable: e.checkable,
1152
1171
  blockNode: !0,
1153
1172
  showLine: !1,
1154
- checkedKeys: s.value,
1173
+ checkedKeys: o.value,
1155
1174
  height: 280,
1156
1175
  onDrop: (r) => {
1157
- const y = r.node.key, T = r.dragNode.key, {
1158
- dropPosition: O,
1159
- dropToGap: R
1160
- } = r, A = O === -1 || !R ? O + 1 : O;
1161
- S(T, y, A);
1176
+ const y = r.node.key, p = r.dragNode.key, {
1177
+ dropPosition: k,
1178
+ dropToGap: F
1179
+ } = r, M = k === -1 || !F ? k + 1 : k;
1180
+ S(p, y, M);
1162
1181
  },
1163
- onCheck: (r, y) => f(y),
1164
- treeData: o.value
1182
+ onCheck: (r, y) => h(y),
1183
+ treeData: u.value
1165
1184
  }, {
1166
1185
  title: (r) => {
1167
- var T;
1186
+ var p;
1168
1187
  const y = {
1169
1188
  ...r,
1170
1189
  children: void 0,
1171
1190
  title: b(r),
1172
- autoScroll: (T = m == null ? void 0 : m.autoScroll) == null ? void 0 : T.value
1191
+ autoScroll: (p = v == null ? void 0 : v.autoScroll) == null ? void 0 : p.value
1173
1192
  };
1174
- return c(la, _({
1193
+ return c(na, Q({
1175
1194
  hashId: e.hashId,
1176
1195
  className: e.className
1177
1196
  }, y, {
@@ -1181,7 +1200,7 @@ const ze = (e) => {
1181
1200
  })]) : null;
1182
1201
  };
1183
1202
  }
1184
- }), aa = /* @__PURE__ */ he({
1203
+ }), ua = /* @__PURE__ */ ve({
1185
1204
  props: {
1186
1205
  hashId: String,
1187
1206
  className: String,
@@ -1190,65 +1209,65 @@ const ze = (e) => {
1190
1209
  },
1191
1210
  setup(e) {
1192
1211
  const {
1193
- columns: l
1194
- } = me(), a = j([]), o = j([]), s = j([]), i = j([]);
1195
- q(() => l.value, (x) => {
1196
- a.value = [], o.value = [], s.value = [], x.forEach((S) => {
1212
+ columns: a
1213
+ } = ge(), l = j([]), u = j([]), o = j([]), s = j([]);
1214
+ _(() => a.value, (x) => {
1215
+ l.value = [], u.value = [], o.value = [], x.forEach((S) => {
1197
1216
  if (S.hideInSetting)
1198
1217
  return;
1199
1218
  const {
1200
- fixed: f,
1219
+ fixed: h,
1201
1220
  show: b,
1202
- uuid: u
1221
+ uuid: i
1203
1222
  } = S;
1204
- if ((b || b === void 0) && u && i.value.push(u), f === "left") {
1205
- o.value.push(S);
1223
+ if ((b || b === void 0) && i && s.value.push(i), h === "left") {
1224
+ u.value.push(S);
1206
1225
  return;
1207
1226
  }
1208
- if (f === "right") {
1209
- a.value.push(S);
1227
+ if (h === "right") {
1228
+ l.value.push(S);
1210
1229
  return;
1211
1230
  }
1212
- s.value.push(S);
1231
+ o.value.push(S);
1213
1232
  });
1214
1233
  }, {
1215
1234
  immediate: !0
1216
1235
  });
1217
- const d = w(() => a.value && a.value.length > 0), m = w(() => o.value && o.value.length > 0);
1236
+ const d = w(() => l.value && l.value.length > 0), v = w(() => u.value && u.value.length > 0);
1218
1237
  return () => c("div", {
1219
1238
  class: {
1220
1239
  [`${e.hashId}`]: !0,
1221
1240
  [`${e.className}-list`]: !0,
1222
- [`${e.className}-list-group`]: d.value || m.value
1241
+ [`${e.className}-list-group`]: d.value || v.value
1223
1242
  }
1224
- }, [c(et, {
1243
+ }, [c(tt, {
1225
1244
  title: "固定在左侧",
1226
- list: o.value,
1227
- keys: i.value,
1245
+ list: u.value,
1246
+ keys: s.value,
1228
1247
  hashId: e.hashId,
1229
1248
  draggable: e.draggable,
1230
1249
  checkable: e.checkable,
1231
1250
  className: e.className
1232
- }, null), c(et, {
1233
- list: s.value,
1234
- keys: i.value,
1251
+ }, null), c(tt, {
1252
+ list: o.value,
1253
+ keys: s.value,
1235
1254
  hashId: e.hashId,
1236
1255
  draggable: e.draggable,
1237
1256
  checkable: e.checkable,
1238
1257
  title: "不固定",
1239
- showTitle: m.value || d.value,
1258
+ showTitle: v.value || d.value,
1240
1259
  className: e.className
1241
- }, null), c(et, {
1260
+ }, null), c(tt, {
1242
1261
  title: "固定在右侧",
1243
- list: a.value,
1244
- keys: i.value,
1262
+ list: l.value,
1263
+ keys: s.value,
1245
1264
  hashId: e.hashId,
1246
1265
  draggable: e.draggable,
1247
1266
  checkable: e.checkable,
1248
1267
  className: e.className
1249
1268
  }, null)]);
1250
1269
  }
1251
- }), na = /* @__PURE__ */ he({
1270
+ }), ia = /* @__PURE__ */ ve({
1252
1271
  props: {
1253
1272
  draggable: {
1254
1273
  type: Boolean,
@@ -1262,76 +1281,76 @@ const ze = (e) => {
1262
1281
  extra: [Function, Object, String, Boolean]
1263
1282
  },
1264
1283
  setup(e) {
1265
- const l = ut({
1284
+ const a = it({
1266
1285
  suffixCls: "table-column-setting",
1267
1286
  isPor: !0
1268
1287
  }), {
1269
- wrapSSR: a,
1270
- hashId: o
1271
- } = Xe("ColumnSetting", [ta], l), {
1272
- columns: s,
1273
- settingsAction: i
1274
- } = me(), d = ze((b = !0) => {
1275
- const u = {}, n = (r) => {
1288
+ wrapSSR: l,
1289
+ hashId: u
1290
+ } = Ue("ColumnSetting", [aa], a), {
1291
+ columns: o,
1292
+ settingsAction: s
1293
+ } = ge(), d = Ye((b = !0) => {
1294
+ const i = {}, n = (r) => {
1276
1295
  r.forEach(({
1277
1296
  key: y,
1278
- fixed: T,
1279
- index: O,
1280
- children: R
1297
+ fixed: p,
1298
+ index: k,
1299
+ children: F
1281
1300
  }) => {
1282
- const A = Rt(y, O);
1283
- A && (u[A] = {
1301
+ const M = Ft(y, k);
1302
+ M && (i[M] = {
1284
1303
  show: b,
1285
- fixed: T
1286
- }), R && n(R);
1304
+ fixed: p
1305
+ }), F && n(F);
1287
1306
  });
1288
1307
  };
1289
- n(s.value), i == null || i.setColumnsMap(u, "show");
1290
- }), m = ze((b) => {
1308
+ n(o.value), s == null || s.setColumnsMap(i, "show");
1309
+ }), v = Ye((b) => {
1291
1310
  b.target.checked ? d() : d(!1);
1292
- }), x = ze(() => {
1293
- i == null || i.setColumnsMap(i == null ? void 0 : i.cacheColumnsMap, "fixed");
1311
+ }), x = Ye(() => {
1312
+ s == null || s.setColumnsMap(s == null ? void 0 : s.cacheColumnsMap, "fixed");
1294
1313
  }), S = w(() => (
1295
1314
  // @ts-ignore
1296
- Object.values(i == null ? void 0 : i.columnsMap).filter((b) => !b || b.show === !1)
1297
- )), f = w(() => C(S).length > 0 && C(S).length !== s.value.length);
1298
- return () => a(c(Dl, {
1315
+ Object.values(s == null ? void 0 : s.columnsMap).filter((b) => !b || b.show === !1)
1316
+ )), h = w(() => C(S).length > 0 && C(S).length !== o.value.length);
1317
+ return () => l(c(Ml, {
1299
1318
  arrowPointAtCenter: !0,
1300
1319
  title: c("div", {
1301
- class: [`${l}-title`, o.value]
1302
- }, [c(Ml, {
1303
- indeterminate: f.value,
1304
- checked: C(S).length === 0 && C(S).length !== s.value.length,
1305
- onChange: (b) => m(b)
1320
+ class: [`${a}-title`, u.value]
1321
+ }, [c(Al, {
1322
+ indeterminate: h.value,
1323
+ checked: C(S).length === 0 && C(S).length !== o.value.length,
1324
+ onChange: (b) => v(b)
1306
1325
  }, {
1307
- default: () => [Ke("列展示")]
1326
+ default: () => [ze("列展示")]
1308
1327
  }), e.checkedReset ? c("a", {
1309
1328
  onClick: x,
1310
- class: [`${l}-action-rest-button`, o.value]
1311
- }, [Ke("重置")]) : null, e != null && e.extra ? c(xe, {
1329
+ class: [`${a}-action-rest-button`, u.value]
1330
+ }, [ze("重置")]) : null, e != null && e.extra ? c(we, {
1312
1331
  size: 12,
1313
1332
  align: "center"
1314
1333
  }, {
1315
1334
  default: () => [e.extra]
1316
1335
  }) : null]),
1317
- overlayClassName: `${l}-overlay ${o.value}`,
1336
+ overlayClassName: `${a}-overlay ${u.value}`,
1318
1337
  trigger: "click",
1319
1338
  placement: "bottomRight",
1320
- content: c(aa, {
1321
- hashId: o.value,
1339
+ content: c(ua, {
1340
+ hashId: u.value,
1322
1341
  checkable: e.checkable ?? !0,
1323
1342
  draggable: e.draggable ?? !0,
1324
- className: l
1343
+ className: a
1325
1344
  }, null)
1326
1345
  }, {
1327
- default: () => [c(fe, {
1346
+ default: () => [c(me, {
1328
1347
  title: "列设置"
1329
1348
  }, {
1330
- default: () => [c(Pt, null, null)]
1349
+ default: () => [c(jt, null, null)]
1331
1350
  })]
1332
1351
  }));
1333
1352
  }
1334
- }), ua = (e) => ({
1353
+ }), sa = (e) => ({
1335
1354
  [`${e.componentCls}`]: {
1336
1355
  lineHeight: 1,
1337
1356
  "&-container": {
@@ -1373,145 +1392,145 @@ const ze = (e) => {
1373
1392
  }
1374
1393
  }
1375
1394
  });
1376
- function $t(e) {
1377
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !Z(e);
1395
+ function Bt(e) {
1396
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !le(e);
1378
1397
  }
1379
1398
  const {
1380
- useBreakpoint: ia
1381
- } = st;
1382
- function sa(e) {
1383
- if (Z(e))
1399
+ useBreakpoint: oa
1400
+ } = ot;
1401
+ function ra(e) {
1402
+ if (le(e))
1384
1403
  return e;
1385
1404
  if (e) {
1386
- const l = e, {
1387
- icon: a,
1388
- tooltip: o,
1389
- onClick: s,
1390
- key: i
1391
- } = l;
1392
- return a && o ? c(fe, {
1393
- title: o
1405
+ const a = e, {
1406
+ icon: l,
1407
+ tooltip: u,
1408
+ onClick: o,
1409
+ key: s
1410
+ } = a;
1411
+ return l && u ? c(me, {
1412
+ title: u
1394
1413
  }, {
1395
1414
  default: () => [c("span", {
1396
- key: i,
1415
+ key: s,
1397
1416
  onClick: () => {
1398
- s && s(i);
1417
+ o && o(s);
1399
1418
  }
1400
- }, [a])]
1401
- }) : a;
1419
+ }, [l])]
1420
+ }) : l;
1402
1421
  }
1403
1422
  return null;
1404
1423
  }
1405
- const At = /* @__PURE__ */ he({
1424
+ const Kt = /* @__PURE__ */ ve({
1406
1425
  props: {
1407
- actions: de.toolBarBtn,
1426
+ actions: he.toolBarBtn,
1408
1427
  settings: [Array],
1409
- titleTip: de.titleTip,
1428
+ titleTip: he.titleTip,
1410
1429
  prefixCls: String,
1411
- headerTitle: de.headerTitle,
1412
- titleTipText: de.titleTipText,
1413
- optionsExtra: de.optionsExtra
1430
+ headerTitle: he.headerTitle,
1431
+ titleTipText: he.titleTipText,
1432
+ optionsExtra: he.optionsExtra
1414
1433
  },
1415
1434
  setup(e) {
1416
1435
  const {
1417
- wrapSSR: l,
1418
- hashId: a
1419
- } = Xe("ListToolBar", [ua], e.prefixCls), o = ia(), {
1420
- isMobile: s
1421
- } = me(), i = w(() => {
1422
- var u;
1423
- return !!(e.titleTip || e.headerTitle || (u = e.actions) != null && u.length);
1436
+ wrapSSR: a,
1437
+ hashId: l
1438
+ } = Ue("ListToolBar", [sa], e.prefixCls), u = oa(), {
1439
+ isMobile: o
1440
+ } = ge(), s = w(() => {
1441
+ var i;
1442
+ return !!(e.titleTip || e.headerTitle || (i = e.actions) != null && i.length);
1424
1443
  }), d = w(() => {
1425
- var u;
1426
- return !!((u = e.settings) != null && u.length || e.optionsExtra);
1427
- }), m = w(() => !!(e.titleTip || e.headerTitle)), x = w(() => {
1444
+ var i;
1445
+ return !!((i = e.settings) != null && i.length || e.optionsExtra);
1446
+ }), v = w(() => !!(e.titleTip || e.headerTitle)), x = w(() => {
1428
1447
  var n;
1429
- let u;
1430
- return Array.isArray(e.actions) ? ((n = e.actions) == null ? void 0 : n.length) < 1 ? null : c(xe, {
1448
+ let i;
1449
+ return Array.isArray(e.actions) ? ((n = e.actions) == null ? void 0 : n.length) < 1 ? null : c(we, {
1431
1450
  align: "center"
1432
- }, $t(u = e.actions.map((r, y) => Z(r) ? it(r, {
1451
+ }, Bt(i = e.actions.map((r, y) => le(r) ? st(r, {
1433
1452
  key: y,
1434
1453
  ...r == null ? void 0 : r.props
1435
1454
  }) : c("template", {
1436
1455
  key: y
1437
- }, [r]))) ? u : {
1438
- default: () => [u]
1456
+ }, [r]))) ? i : {
1457
+ default: () => [i]
1439
1458
  }) : e.actions;
1440
- }), S = Ge(() => !i.value && d.value ? c("div", {
1441
- class: `${e.prefixCls}-left ${a.value}`
1442
- }, null) : m.value ? c(xe, {
1443
- class: `${e.prefixCls}-left ${a.value}`
1459
+ }), S = Qe(() => !s.value && d.value ? c("div", {
1460
+ class: `${e.prefixCls}-left ${l.value}`
1461
+ }, null) : v.value ? c(we, {
1462
+ class: `${e.prefixCls}-left ${l.value}`
1444
1463
  }, {
1445
1464
  default: () => [c("div", {
1446
- class: `${e.prefixCls}-title ${a.value}`
1447
- }, [e.headerTitle, e.titleTip && c(fe, {
1465
+ class: `${e.prefixCls}-title ${l.value}`
1466
+ }, [e.headerTitle, e.titleTip && c(me, {
1448
1467
  title: e.titleTipText
1449
1468
  }, {
1450
- default: () => [se(e.titleTip) && e.titleTip ? c($l, null, null) : e.titleTip]
1469
+ default: () => [ne(e.titleTip) && e.titleTip ? c(Bl, null, null) : e.titleTip]
1451
1470
  })]), x.value && c("div", {
1452
- class: `${e.prefixCls}-actions ${a.value}`
1471
+ class: `${e.prefixCls}-actions ${l.value}`
1453
1472
  }, [x.value])]
1454
- }) : c(xe, {
1455
- class: `${e.prefixCls}-left ${a.value}`
1473
+ }) : c(we, {
1474
+ class: `${e.prefixCls}-left ${l.value}`
1456
1475
  }, {
1457
1476
  default: () => [x.value && c("div", {
1458
1477
  class: `${e.prefixCls}-actions`
1459
1478
  }, [x.value])]
1460
- }), [() => i.value, () => d.value, () => m.value, () => e.prefixCls, () => e.headerTitle, () => e.titleTipText, () => e.titleTip]), f = Ge(() => {
1461
- let u;
1462
- return d.value ? c(xe, {
1479
+ }), [() => s.value, () => d.value, () => v.value, () => e.prefixCls, () => e.headerTitle, () => e.titleTipText, () => e.titleTip]), h = Qe(() => {
1480
+ let i;
1481
+ return d.value ? c(we, {
1463
1482
  size: 16,
1464
- class: `${e.prefixCls}-right ${a.value}`,
1465
- align: o.value.lg ? "center" : "end",
1466
- direction: o.value.lg ? "horizontal" : "vertical"
1483
+ class: `${e.prefixCls}-right ${l.value}`,
1484
+ align: u.value.lg ? "center" : "end",
1485
+ direction: u.value.lg ? "horizontal" : "vertical"
1467
1486
  }, {
1468
1487
  default: () => {
1469
1488
  var n;
1470
- return [e.optionsExtra, (n = e.settings) != null && n.length ? c(xe, {
1489
+ return [e.optionsExtra, (n = e.settings) != null && n.length ? c(we, {
1471
1490
  size: 12,
1472
1491
  align: "center",
1473
1492
  class: `${e.prefixCls}-setting-items`
1474
- }, $t(u = e.settings.map((r, y) => {
1475
- const T = sa(r);
1493
+ }, Bt(i = e.settings.map((r, y) => {
1494
+ const p = ra(r);
1476
1495
  return c("div", {
1477
1496
  key: y,
1478
1497
  class: `${e.prefixCls}-setting-item`
1479
- }, [T]);
1480
- })) ? u : {
1481
- default: () => [u]
1498
+ }, [p]);
1499
+ })) ? i : {
1500
+ default: () => [i]
1482
1501
  }) : null];
1483
1502
  }
1484
1503
  }) : null;
1485
- }, [() => o.value, () => d.value, () => e.prefixCls, () => m.value, () => x.value, () => e.settings]), b = Ge(() => {
1486
- if (!d.value && !i.value) return null;
1487
- const u = {
1488
- [`${a.value}`]: !0,
1504
+ }, [() => u.value, () => d.value, () => e.prefixCls, () => v.value, () => x.value, () => e.settings]), b = Qe(() => {
1505
+ if (!d.value && !s.value) return null;
1506
+ const i = {
1507
+ [`${l.value}`]: !0,
1489
1508
  [`${e.prefixCls}-container`]: !0,
1490
- [`${e.prefixCls}-container-mobile`]: s.value
1509
+ [`${e.prefixCls}-container-mobile`]: o.value
1491
1510
  };
1492
1511
  return c("div", {
1493
- class: u
1494
- }, [S.value, f.value]);
1495
- }, [() => s.value, () => i.value, () => d.value, () => S.value, () => e.prefixCls, () => f.value]);
1496
- return () => l(c("div", {
1497
- class: `${e.prefixCls} ${a.value}`
1512
+ class: i
1513
+ }, [S.value, h.value]);
1514
+ }, [() => o.value, () => s.value, () => d.value, () => S.value, () => e.prefixCls, () => h.value]);
1515
+ return () => a(c("div", {
1516
+ class: `${e.prefixCls} ${l.value}`
1498
1517
  }, [b.value]));
1499
1518
  }
1500
1519
  });
1501
- At.inheritAttrs = !1;
1502
- const oa = () => {
1520
+ Kt.inheritAttrs = !1;
1521
+ const ca = () => {
1503
1522
  const {
1504
1523
  action: e,
1505
- tableSize: l
1506
- } = me();
1507
- return c(Kl, {
1524
+ tableSize: a
1525
+ } = ge();
1526
+ return c(zl, {
1508
1527
  overlay: c(He, {
1509
- selectedKeys: [l.value],
1528
+ selectedKeys: [a.value],
1510
1529
  onClick: ({
1511
- key: a
1530
+ key: l
1512
1531
  }) => {
1513
- var o;
1514
- (o = e.setTableSize) == null || o.call(e, a);
1532
+ var u;
1533
+ (u = e.setTableSize) == null || u.call(e, l);
1515
1534
  },
1516
1535
  style: {
1517
1536
  width: 80
@@ -1520,89 +1539,89 @@ const oa = () => {
1520
1539
  default: () => [c(He.Item, {
1521
1540
  key: "large"
1522
1541
  }, {
1523
- default: () => [Ke("默认")]
1542
+ default: () => [ze("默认")]
1524
1543
  }), c(He.Item, {
1525
1544
  key: "middle"
1526
1545
  }, {
1527
- default: () => [Ke("中等")]
1546
+ default: () => [ze("中等")]
1528
1547
  }), c(He.Item, {
1529
1548
  key: "small"
1530
1549
  }, {
1531
- default: () => [Ke("紧凑")]
1550
+ default: () => [ze("紧凑")]
1532
1551
  })]
1533
1552
  }),
1534
1553
  trigger: ["click"]
1535
1554
  }, {
1536
- default: () => [c(fe, {
1555
+ default: () => [c(me, {
1537
1556
  title: "表格密度"
1538
1557
  }, {
1539
- default: () => [c(Bl, null, null)]
1558
+ default: () => [c(Rl, null, null)]
1540
1559
  })]
1541
1560
  });
1542
- }, Kt = /* @__PURE__ */ he({
1561
+ }, zt = /* @__PURE__ */ ve({
1543
1562
  setup() {
1544
1563
  const {
1545
1564
  isFullscreen: e
1546
- } = Nt();
1547
- return () => e.value ? c(fe, {
1565
+ } = Et();
1566
+ return () => e.value ? c(me, {
1548
1567
  title: "退出全屏"
1549
1568
  }, {
1550
- default: () => [c(Rl, null, null)]
1551
- }) : c(fe, {
1569
+ default: () => [c(Fl, null, null)]
1570
+ }) : c(me, {
1552
1571
  title: "全屏"
1553
1572
  }, {
1554
- default: () => [c(Fl, null, null)]
1573
+ default: () => [c(Il, null, null)]
1555
1574
  });
1556
1575
  }
1557
1576
  });
1558
- function ra() {
1577
+ function da() {
1559
1578
  return {
1560
1579
  reload: {
1561
1580
  text: "刷新",
1562
- icon: c(Il, null, null)
1581
+ icon: c(kl, null, null)
1563
1582
  },
1564
1583
  density: {
1565
1584
  text: "表格密度",
1566
- icon: c(oa, null, null)
1585
+ icon: c(ca, null, null)
1567
1586
  },
1568
1587
  setting: {
1569
1588
  text: "列设置",
1570
- icon: c(Pt, null, null)
1589
+ icon: c(jt, null, null)
1571
1590
  },
1572
1591
  fullScreen: {
1573
1592
  text: "全屏",
1574
- icon: c(Kt, null, null)
1593
+ icon: c(zt, null, null)
1575
1594
  }
1576
1595
  };
1577
1596
  }
1578
- function ca(e, l) {
1579
- return Object.keys(e).filter((a) => a).map((a) => {
1580
- const o = e[a];
1581
- if (!o)
1597
+ function fa(e, a) {
1598
+ return Object.keys(e).filter((l) => l).map((l) => {
1599
+ const u = e[l];
1600
+ if (!u)
1582
1601
  return null;
1583
- let s = o === !0 ? l[a] : () => o == null ? void 0 : o();
1584
- if (typeof s != "function" && (s = () => {
1585
- }), a === "setting")
1586
- return c(na, _(e[a], {
1587
- key: a
1602
+ let o = u === !0 ? a[l] : () => u == null ? void 0 : u();
1603
+ if (typeof o != "function" && (o = () => {
1604
+ }), l === "setting")
1605
+ return c(ia, Q(e[l], {
1606
+ key: l
1588
1607
  }), null);
1589
- if (a === "fullScreen")
1608
+ if (l === "fullScreen")
1590
1609
  return c("span", {
1591
- key: a,
1592
- onClick: s
1593
- }, [c(Kt, null, null)]);
1594
- const i = ra()[a];
1595
- return i ? c("span", {
1596
- key: a,
1597
- onClick: s
1598
- }, [c(fe, {
1599
- title: i.text
1610
+ key: l,
1611
+ onClick: o
1612
+ }, [c(zt, null, null)]);
1613
+ const s = da()[l];
1614
+ return s ? c("span", {
1615
+ key: l,
1616
+ onClick: o
1617
+ }, [c(me, {
1618
+ title: s.text
1600
1619
  }, {
1601
- default: () => [i.icon]
1620
+ default: () => [s.icon]
1602
1621
  })]) : null;
1603
- }).filter((a) => a);
1622
+ }).filter((l) => l);
1604
1623
  }
1605
- const da = {
1624
+ const ha = {
1606
1625
  options: [Boolean, Object, Array],
1607
1626
  titleTip: [Function, Boolean, Object, String],
1608
1627
  settingExtra: [Function, Boolean, Object, Array],
@@ -1610,349 +1629,353 @@ const da = {
1610
1629
  titleTipText: [String],
1611
1630
  toolBarBtn: [Function, Boolean, Object, Array],
1612
1631
  headerTitle: [Function, Boolean, Object, Array, String]
1613
- }, fa = /* @__PURE__ */ he({
1614
- props: da,
1632
+ }, ma = /* @__PURE__ */ ve({
1633
+ props: ha,
1615
1634
  inheritAttrs: !1,
1616
1635
  setup(e) {
1617
- const l = ut({
1636
+ const a = it({
1618
1637
  suffixCls: "table-list-toolbar",
1619
1638
  isPor: !0
1620
1639
  }), {
1621
- action: a
1622
- } = me(), o = Ge(() => {
1640
+ action: l
1641
+ } = ge(), u = Qe(() => {
1623
1642
  var d;
1624
- const s = {
1625
- reload: () => a == null ? void 0 : a.reload(),
1643
+ const o = {
1644
+ reload: () => l == null ? void 0 : l.reload(),
1626
1645
  density: !0,
1627
1646
  setting: !0,
1628
- fullScreen: () => a == null ? void 0 : a.toggle()
1647
+ fullScreen: () => l == null ? void 0 : l.toggle()
1629
1648
  };
1630
1649
  if (e.options === !1 || ((d = Object.keys(e.options)) == null ? void 0 : d.length) === 0) return [];
1631
- const i = {
1632
- ...s,
1650
+ const s = {
1651
+ ...o,
1633
1652
  ...e.options
1634
1653
  };
1635
- return i.setting !== !1 && e.settingExtra && (i.setting = {}, i.setting.extra = e.settingExtra), ca(i, {
1636
- ...s
1654
+ return s.setting !== !1 && e.settingExtra && (s.setting = {}, s.setting.extra = e.settingExtra), fa(s, {
1655
+ ...o
1637
1656
  });
1638
- }, [() => a, () => e.options]);
1657
+ }, [() => l, () => e.options]);
1639
1658
  return () => {
1640
- const s = e.toolBarBtn || [];
1641
- return c(At, {
1642
- prefixCls: l,
1659
+ const o = e.toolBarBtn || [];
1660
+ return c(Kt, {
1661
+ prefixCls: a,
1643
1662
  optionsExtra: e.optionsExtra,
1644
1663
  headerTitle: e.headerTitle,
1645
- actions: s,
1646
- settings: C(o),
1664
+ actions: o,
1665
+ settings: C(u),
1647
1666
  titleTip: e.titleTip,
1648
1667
  titleTipText: e.titleTipText
1649
1668
  }, null);
1650
1669
  };
1651
1670
  }
1652
1671
  });
1653
- function ha(e) {
1654
- return ml();
1672
+ function va(e) {
1673
+ return vl();
1655
1674
  }
1656
- function ma(e, l = !0, a) {
1657
- ha() ? hl(e, a) : l ? e() : Ot(e);
1675
+ function ga(e, a = !0, l) {
1676
+ va() ? ml(e, l) : a ? e() : Ot(e);
1658
1677
  }
1659
- function va({ columns: e, columnsState: l, changeColumns: a }) {
1660
- const o = j(void 0), s = we({}), i = we({}), d = we({}), m = j([]);
1661
- q(() => e.value, () => {
1678
+ function ya({ columns: e, columnsState: a, changeColumns: l }) {
1679
+ const u = j(void 0), o = Te({}), s = Te({}), d = Te({}), v = j([]);
1680
+ _(() => e.value, () => {
1662
1681
  var b;
1663
- (b = C(e)) == null || b.forEach(({ show: u, key: n, fixed: r }, y) => {
1664
- const T = Rt(n, y);
1665
- T && (d[T] = { show: u === void 0 ? !0 : u, fixed: r });
1682
+ (b = C(e)) == null || b.forEach(({ show: i, key: n, fixed: r }, y) => {
1683
+ const p = Ft(n, y);
1684
+ p && (d[p] = { show: i === void 0 ? !0 : i, fixed: r });
1666
1685
  });
1667
- const f = C(e).map((u) => u.key);
1668
- S(f);
1669
- }, { deep: !0, immediate: !0 }), Ye(() => {
1686
+ const h = C(e).map((i) => i.key);
1687
+ S(h);
1688
+ }, { deep: !0, immediate: !0 }), Le(() => {
1670
1689
  var b;
1671
- const f = {
1672
- ...(b = C(l)) == null ? void 0 : b.value,
1690
+ const h = {
1691
+ ...(b = C(a)) == null ? void 0 : b.value,
1673
1692
  ...C(d)
1674
1693
  };
1675
- Object.assign(s, f), Object.assign(i, f);
1694
+ Object.assign(o, h), Object.assign(s, h);
1676
1695
  });
1677
- function x(f, b) {
1678
- o.value = b, Object.assign(s, f), a == null || a(s, b === "fixed");
1696
+ function x(h, b) {
1697
+ u.value = b, Object.assign(o, h), l == null || l(o, b === "fixed");
1679
1698
  }
1680
- function S(f) {
1681
- m.value = f;
1699
+ function S(h) {
1700
+ v.value = h;
1682
1701
  }
1683
1702
  return {
1684
- columnsMap: s,
1685
- operationType: o,
1703
+ columnsMap: o,
1704
+ operationType: u,
1686
1705
  setColumnsMap: x,
1687
- sortKeyColumns: m,
1688
- cacheColumnsMap: i,
1706
+ sortKeyColumns: v,
1707
+ cacheColumnsMap: s,
1689
1708
  setSortKeyColumns: S
1690
1709
  };
1691
1710
  }
1692
- function ga(e) {
1693
- const l = w(() => e.draggabled), a = w(() => e.neverScroll), o = w(() => e.autoScroll);
1711
+ function ba(e) {
1712
+ const a = w(() => e.draggabled), l = w(() => e.neverScroll), u = w(() => e.autoScroll);
1694
1713
  return {
1695
- draggabled: l,
1696
- neverScroll: a,
1697
- autoScroll: o
1714
+ draggabled: a,
1715
+ neverScroll: l,
1716
+ autoScroll: u
1698
1717
  };
1699
1718
  }
1700
- function ya({ scroll: e, columns: l, breakpoint: a, draggabled: o, autoScroll: s, neverScroll: i }) {
1701
- const d = j([]), m = j([]);
1702
- q([
1719
+ function Ca({ scroll: e, columns: a, breakpoint: l, draggabled: u, autoScroll: o, neverScroll: s }) {
1720
+ const d = j([]), v = j([]);
1721
+ _([
1703
1722
  () => e.value,
1704
- () => l.value,
1705
1723
  () => a.value,
1724
+ () => l.value,
1725
+ () => u.value,
1726
+ () => l.value,
1706
1727
  () => o.value,
1707
- () => a.value,
1708
- () => s.value,
1709
- () => i.value
1728
+ () => s.value
1710
1729
  ], () => {
1711
- const r = f(Be(l.value));
1712
- Ve(r, Be(d.value)) || (d.value = ie(r)), Ve(r, Be(m.value)) || (m.value = ie(r));
1730
+ const r = h(Be(a.value));
1731
+ Ge(r, Be(d.value)) || (d.value = re(r)), Ge(r, Be(v.value)) || (v.value = re(r));
1713
1732
  }, {
1714
1733
  deep: !0,
1715
1734
  immediate: !0
1716
1735
  });
1717
1736
  const x = w(() => {
1718
- const r = S(C(d).filter((O) => O.fixed === "left")), y = S(C(d).filter((O) => O.fixed !== "left" && O.fixed !== "right")), T = S(C(d).filter((O) => O.fixed === "right"));
1737
+ const r = S(C(d).filter((k) => k.fixed === "left")), y = S(C(d).filter((k) => k.fixed !== "left" && k.fixed !== "right")), p = S(C(d).filter((k) => k.fixed === "right"));
1719
1738
  return [
1720
1739
  ...r,
1721
1740
  ...y,
1722
- ...T
1741
+ ...p
1723
1742
  ];
1724
1743
  });
1725
1744
  function S(r) {
1726
- return r.sort((y, T) => al(y, T, "order", 0));
1745
+ return r.sort((y, p) => al(y, p, "order", 0));
1727
1746
  }
1728
- function f(r) {
1729
- return ie(r).map((y, T) => {
1730
- var O;
1731
- if (y.dataIndex === "action" || T === r.length - 1 ? y.resizable = !1 : y.resizable = se(y.resizable) ? y.resizable : !!(Qe(y.width) && C(o)), !y.width || C(i))
1747
+ function h(r) {
1748
+ return re(r).map((y, p) => {
1749
+ var k;
1750
+ if (y.dataIndex === "action" || p === r.length - 1 ? y.resizable = !1 : y.resizable = ne(y.resizable) ? y.resizable : !!(_e(y.width) && C(u)), !y.width || C(s))
1732
1751
  return y;
1733
- if (y.dataIndex === "action" && C(s))
1734
- if ((O = C(e)) != null && O.x || !C(a))
1752
+ if (y.dataIndex === "action" && C(o))
1753
+ if ((k = C(e)) != null && k.x || !C(l))
1735
1754
  y.width = y.width || 100, y.fixed = "right";
1736
1755
  else {
1737
- const R = C(l).find((A) => A.dataIndex === y.dataIndex);
1738
- y.width = (R == null ? void 0 : R.width) || "", y.fixed = R == null ? void 0 : R.fixed;
1756
+ const F = C(a).find((M) => M.dataIndex === y.dataIndex);
1757
+ y.width = (F == null ? void 0 : F.width) || "", y.fixed = F == null ? void 0 : F.fixed;
1739
1758
  }
1740
1759
  return y;
1741
1760
  });
1742
1761
  }
1743
1762
  function b(r, y) {
1744
- d.value = d.value.map((T) => (T.uuid === y.uuid && (T.width = r), T));
1763
+ d.value = d.value.map((p) => (p.uuid === y.uuid && (p.width = r), p));
1745
1764
  }
1746
- function u(r) {
1765
+ function i(r) {
1747
1766
  if (r.length <= 0) {
1748
1767
  d.value = [];
1749
1768
  return;
1750
1769
  }
1751
- Ve(f(r), Be(d.value)) || (d.value = f(r));
1770
+ Ge(h(r), Be(d.value)) || (d.value = h(r));
1752
1771
  }
1753
1772
  function n(r) {
1754
- u(ie(Be(l.value)).map((y) => {
1755
- var O, R, A;
1756
- const T = y.key ? {
1757
- show: (O = r[y.key]) == null ? void 0 : O.show,
1758
- fixed: (R = r[y.key]) == null ? void 0 : R.fixed,
1759
- order: (A = r[y.key]) == null ? void 0 : A.order
1773
+ i(re(Be(a.value)).map((y) => {
1774
+ var k, F, M;
1775
+ const p = y.key ? {
1776
+ show: (k = r[y.key]) == null ? void 0 : k.show,
1777
+ fixed: (F = r[y.key]) == null ? void 0 : F.fixed,
1778
+ order: (M = r[y.key]) == null ? void 0 : M.order
1760
1779
  } : {};
1761
- return { ...y, ...T };
1780
+ return { ...y, ...p };
1762
1781
  }));
1763
1782
  }
1764
1783
  return {
1765
- breakpoint: a,
1784
+ breakpoint: l,
1766
1785
  proColumns: x,
1767
- cacheProColumns: m,
1768
- setColumns: u,
1786
+ cacheProColumns: v,
1787
+ setColumns: i,
1769
1788
  changeColumns: n,
1770
1789
  resizeColumnWidth: b
1771
1790
  };
1772
1791
  }
1773
- function ba(e, l) {
1774
- const a = w(() => l || 0), o = j(), s = j(e);
1775
- function i() {
1776
- o.value && clearTimeout(o.value);
1792
+ function xa(e, a) {
1793
+ const l = w(() => a || 0), u = j(), o = j(e);
1794
+ function s() {
1795
+ u.value && clearTimeout(u.value);
1777
1796
  }
1778
- async function d(...m) {
1779
- return a.value === 0 || a.value === void 0 ? s.value(...m) : (i(), new Promise(async (x) => {
1797
+ async function d(...v) {
1798
+ return l.value === 0 || l.value === void 0 ? o.value(...v) : (s(), new Promise(async (x) => {
1780
1799
  var S;
1781
- (S = m[0]) != null && S.immediate ? x(await s.value(...m)) : o.value = setTimeout(async () => {
1782
- x(await s.value(...m));
1783
- }, a.value);
1800
+ (S = v[0]) != null && S.immediate ? x(await o.value(...v)) : u.value = setTimeout(async () => {
1801
+ x(await o.value(...v));
1802
+ }, l.value);
1784
1803
  }));
1785
1804
  }
1786
- return Hl(i), {
1787
- cancel: i,
1805
+ return Hl(s), {
1806
+ cancel: s,
1788
1807
  run: d
1789
1808
  };
1790
1809
  }
1791
- function Ca(e) {
1792
- const l = w(() => e.polling), a = w(() => e.debounceTime), o = w(() => e.dataSource);
1810
+ function Sa(e) {
1811
+ const a = w(() => e.rowKey), l = w(() => e.polling), u = w(() => e.debounceTime), o = w(() => e.dataSource);
1793
1812
  return {
1813
+ rowKey: a,
1794
1814
  polling: l,
1795
1815
  request: e.request,
1796
1816
  postData: e.postData,
1797
- debounceTime: a,
1817
+ debounceTime: u,
1798
1818
  dataSource: o
1799
1819
  };
1800
1820
  }
1801
- function xa({ polling: e, request: l, postData: a, dataSource: o, waitRequest: s, debounceTime: i }, { search: d, columns: m, loading: x, setLoading: S, setColumns: f, removeRowKeys: b, syncSelectedRows: u, formParamsRef: n, setPagination: r, paginationInfo: y, onBeforeSearchSubmit: T, hasCustomRender: O }, R) {
1802
- const A = j(), V = j(!0), L = j(!1), W = j(!1), K = j([]), G = j(), H = w(() => {
1821
+ function wa({ rowKey: e, polling: a, request: l, postData: u, dataSource: o, waitRequest: s, debounceTime: d }, { search: v, columns: x, loading: S, setLoading: h, setColumns: b, removeRowKeys: i, syncSelectedRows: n, formParamsRef: r, setPagination: y, paginationInfo: p, onBeforeSearchSubmit: k, hasCustomRender: F }, M) {
1822
+ const G = j(), W = j(!0), Y = j(!1), ue = j(!1), A = j([]), K = j(), ce = w(() => {
1803
1823
  var I;
1804
- return J(d.value) ? ((I = d.value) == null ? void 0 : I.type) === "button" : !!d.value;
1805
- }), oe = async (I = {}) => {
1806
- var Te;
1807
- const { pagination: N, filters: v = {}, sorter: z = {}, removeKeys: ve = [], isPolling: pe = !1 } = I;
1808
- if (!l || !Ae(l) || C(s) && x.value || L.value)
1824
+ return Z(v.value) ? ((I = v.value) == null ? void 0 : I.type) === "button" : !!v.value;
1825
+ }), Re = async (I = {}) => {
1826
+ var J;
1827
+ const { pagination: f, filters: L = {}, sorter: V = {}, removeKeys: X = [], isPolling: de = !1 } = I;
1828
+ if (!l || !Ke(l) || C(s) && S.value || Y.value)
1809
1829
  return o.value || [];
1810
- if (L.value = !0, !pe || C(s) || V.value ? S(!0) : g(!0), C(s)) {
1811
- V.value = !1, L.value = !1;
1830
+ if (Y.value = !0, !de || C(s) || W.value ? h(!0) : R(!0), C(s)) {
1831
+ W.value = !1, Y.value = !1;
1812
1832
  return;
1813
1833
  }
1814
- N && r(N);
1834
+ f && y(f);
1815
1835
  try {
1816
- let ee = {};
1817
- if (se(N) && !N || se(y))
1818
- ee = {};
1836
+ let ye = {};
1837
+ if (ne(f) && !f || ne(p))
1838
+ ye = {};
1819
1839
  else {
1820
- const { current: Y = 1, pageSize: ye = 10, total: U } = C(y) || {};
1821
- ee.pageNum = il({ current: Y, pageSize: ye, total: U }, ve.length), ve.length && b(ve), ee.pageSize = ye;
1840
+ const { current: z = 1, pageSize: Ce = 10, total: te } = C(p) || {};
1841
+ ye.pageNum = il({ current: z, pageSize: Ce, total: te }, X.length), X.length && i(X), ye.pageSize = Ce;
1822
1842
  }
1823
- const Le = J(z) ? [z] : z;
1824
- Le.forEach((Y) => {
1825
- const ye = (Y == null ? void 0 : Y.columnKey) || (Y == null ? void 0 : Y.field);
1826
- Y && (Y != null && Y.order) ? f(C(m).map((U) => (U.dataIndex === ye ? U.sortOrder = Y == null ? void 0 : Y.order : U.sortOrder = null, U))) : Y && f(C(m).map((U) => (U.dataIndex === ye && (U.sortOrder = null), U)));
1843
+ const We = Z(V) ? [V] : V;
1844
+ We.forEach((z) => {
1845
+ const Ce = (z == null ? void 0 : z.columnKey) || (z == null ? void 0 : z.field);
1846
+ z && (z != null && z.order) ? b(C(x).map((te) => (te.dataIndex === Ce ? te.sortOrder = z == null ? void 0 : z.order : te.sortOrder = null, te))) : z && b(C(x).map((te) => (te.dataIndex === Ce && (te.sortOrder = null), te)));
1827
1847
  });
1828
- let ke = {
1829
- ...ee || {},
1848
+ let Pe = {
1849
+ ...ye || {},
1830
1850
  ...I.params,
1831
- ...n
1851
+ ...r
1832
1852
  };
1833
- T && Ae(T) && (ke = await T(ke, z, v));
1834
- let te = [];
1835
- const ge = await (l == null ? void 0 : l(ke, Le, v));
1836
- if (L.value = !1, ge && (ge != null && ge.success)) {
1837
- te = ge.data || [], a && Ae(a) && (te = await (a == null ? void 0 : a(te))), u(te);
1838
- const Y = ge.total || (te == null ? void 0 : te.length) || 0;
1839
- return Y !== ((Te = C(y)) == null ? void 0 : Te.total) && r({
1840
- total: Y || 0
1841
- }), p(te), te;
1853
+ k && Ke(k) && (Pe = await k(Pe, V, L));
1854
+ let ae = [];
1855
+ const be = await (l == null ? void 0 : l(Pe, We, L));
1856
+ if (Y.value = !1, be && (be != null && be.success)) {
1857
+ ae = be.data || [], u && Ke(u) && (ae = await (u == null ? void 0 : u(ae))), n(ae);
1858
+ const z = be.total || (ae == null ? void 0 : ae.length) || 0;
1859
+ return z !== ((J = C(p)) == null ? void 0 : J.total) && y({
1860
+ total: z || 0
1861
+ }), P(ae), ae;
1842
1862
  } else
1843
1863
  return [];
1844
- } catch (ee) {
1845
- K.value === void 0 && p([]), R("requestError", ee);
1864
+ } catch (ye) {
1865
+ A.value === void 0 && P([]), M("requestError", ye);
1846
1866
  } finally {
1847
- V.value = !1, S(!1);
1867
+ W.value = !1, h(!1);
1848
1868
  }
1849
1869
  return [];
1850
- }, le = ba(async (I) => {
1851
- G.value && clearTimeout(G.value);
1852
- const N = await oe(I), v = nl(e.value, N);
1853
- return v && !A.value && (G.value = setTimeout(() => {
1854
- le.run({ ...I, isPolling: v });
1855
- }, Math.max(v, 2e3))), N;
1856
- }, i.value || 10);
1857
- vl(() => {
1858
- A.value = !0, clearTimeout(G.value);
1859
- }), gl(() => {
1860
- A.value = !0, clearTimeout(G.value);
1861
- }), q(() => e.value, () => {
1862
- e.value ? le.run({ isPolling: !0 }) : clearTimeout(G.value);
1863
- }, { immediate: !0 }), q([() => s.value, () => o.value], () => {
1864
- re();
1865
- }, { deep: !0, immediate: !0 }), q([() => n], () => {
1866
- H.value || re();
1870
+ }, ee = xa(async (I) => {
1871
+ K.value && clearTimeout(K.value);
1872
+ const f = await Re(I), L = nl(a.value, f);
1873
+ return L && !G.value && (K.value = setTimeout(() => {
1874
+ ee.run({ ...I, isPolling: L });
1875
+ }, Math.max(L, 2e3))), f;
1876
+ }, d.value || 10);
1877
+ gl(() => {
1878
+ G.value = !0, clearTimeout(K.value);
1879
+ }), yl(() => {
1880
+ G.value = !0, clearTimeout(K.value);
1881
+ }), _(() => a.value, () => {
1882
+ a.value ? ee.run({ isPolling: !0 }) : clearTimeout(K.value);
1883
+ }, { immediate: !0 }), _([() => s.value, () => o.value], () => {
1884
+ Fe();
1885
+ }, { deep: !0, immediate: !0 }), _([() => r], () => {
1886
+ ce.value || Fe();
1867
1887
  }, {
1868
1888
  deep: !0,
1869
1889
  immediate: !0
1870
1890
  });
1871
- function re() {
1872
- Ie(l) ? (!V.value || !e.value) && le.run({ isPolling: !1 }) : p(o.value || []);
1891
+ function Fe() {
1892
+ Oe(l) ? (!W.value || !a.value) && ee.run({ isPolling: !1 }) : P(o.value || []);
1873
1893
  }
1874
- const Oe = w(() => {
1875
- if (O.value)
1876
- return C(K);
1877
- const I = m.value.filter((N) => N.show || N.show === void 0);
1878
- return !C(K) || !I || I.length === 0 ? [] : C(K);
1879
- }), t = w(() => C(K).some((I) => ue(I.children) && I.children.length > 0));
1880
- function g(I) {
1881
- W.value = I;
1894
+ const t = w(() => {
1895
+ if (F.value)
1896
+ return C(A);
1897
+ const I = x.value.filter((f) => f.show || f.show === void 0);
1898
+ return !C(A) || !I || I.length === 0 ? [] : C(A);
1899
+ }), g = w(() => C(A).some((I) => oe(I.children) && I.children.length > 0));
1900
+ function R(I) {
1901
+ ue.value = I;
1882
1902
  }
1883
- function F(I, N, v, z) {
1884
- le.run({ pagination: I, filters: N, sorter: v, extra: z, isPolling: !1 }), R("change", I, N, v, z);
1903
+ function $(I, f, L, V) {
1904
+ ee.run({ pagination: I, filters: f, sorter: L, extra: V, isPolling: !1 }), M("change", I, f, L, V);
1885
1905
  }
1886
- function p(I) {
1887
- var v;
1888
- const N = ul(ie(I), C(y.value));
1889
- if (!Ve(N, K.value) && (K.value = N, !l || !Ae(l))) {
1890
- const z = N.length || 0;
1891
- z !== ((v = C(y)) == null ? void 0 : v.total) && r({
1892
- total: z
1906
+ function P(I) {
1907
+ var L;
1908
+ const f = ul(re(I), C(p.value));
1909
+ if (!Ge(f, A.value) && (A.value = f, !l || !Ke(l))) {
1910
+ const V = f.length || 0;
1911
+ V !== ((L = C(p)) == null ? void 0 : L.total) && y({
1912
+ total: V
1893
1913
  });
1894
1914
  }
1895
1915
  }
1896
- function P({ key: I, record: N, type: v = "update" }) {
1897
- switch (v) {
1898
- case "update":
1899
- K.value = K.value.map((z) => I && N[I] === z[I] ? { ...z, ...N } : z);
1900
- break;
1901
- case "push":
1902
- K.value.push(N);
1903
- break;
1904
- case "unshift":
1905
- K.value.unshift(N);
1906
- break;
1907
- case "delete":
1908
- K.value = K.value.filter((z) => I ? I && N[I] !== z[I] : !0);
1909
- break;
1910
- }
1911
- }
1912
1916
  return {
1913
- dataSource: Oe,
1914
- isTreeDataRef: t,
1915
- reSetDataList: p,
1916
- changeDataValue: P,
1917
- handleTableChange: F,
1917
+ dataSource: t,
1918
+ isTreeDataRef: g,
1919
+ reSetDataList: P,
1920
+ changeDataValue: ({ key: I, params: f, value: L, type: V = "update" }) => {
1921
+ const X = I ?? e.value, de = f[X] ?? L;
1922
+ switch (V) {
1923
+ case "update":
1924
+ X && de && (A.value = A.value.map((J) => de === J[X] ? sl(J, f, {
1925
+ omitNil: !1,
1926
+ omitEmpty: !1
1927
+ }) : J));
1928
+ break;
1929
+ case "push":
1930
+ A.value.push(f);
1931
+ break;
1932
+ case "unshift":
1933
+ A.value.unshift(f);
1934
+ break;
1935
+ case "delete":
1936
+ X && (A.value = A.value.filter((J) => L !== J[X]));
1937
+ break;
1938
+ }
1939
+ },
1940
+ handleTableChange: $,
1918
1941
  reload: async (I) => {
1919
- Ie(l) ? await le.run({ ...I, isPolling: !1 }) : R("reload");
1942
+ Oe(l) ? await ee.run({ ...I, isPolling: !1 }) : M("reload");
1920
1943
  }
1921
1944
  };
1922
1945
  }
1923
- function Sa({ emit: e, loading: l }) {
1924
- var i;
1925
- const a = j(se(l.value) ? l.value : J(l.value) ? (i = l.value) == null ? void 0 : i.spinning : !1);
1926
- q(() => l.value, (d) => {
1927
- a.value = se(d) ? d : J(d) ? d == null ? void 0 : d.spinning : a.value;
1946
+ function pa({ emit: e, loading: a }) {
1947
+ var s;
1948
+ const l = j(ne(a.value) ? a.value : Z(a.value) ? (s = a.value) == null ? void 0 : s.spinning : !1);
1949
+ _(() => a.value, (d) => {
1950
+ l.value = ne(d) ? d : Z(d) ? d == null ? void 0 : d.spinning : l.value;
1928
1951
  });
1929
- const o = w(() => a.value);
1930
- function s(d) {
1931
- a.value = d, e("loadingChange", !0);
1952
+ const u = w(() => l.value);
1953
+ function o(d) {
1954
+ l.value = d, e("loadingChange", !0);
1932
1955
  }
1933
- return { loadingComputed: o, loading: a, setLoading: s };
1956
+ return { loadingComputed: u, loading: l, setLoading: o };
1934
1957
  }
1935
- function wa({
1958
+ function Ta({
1936
1959
  slots: e,
1937
- props: l,
1938
- pagination: a
1960
+ props: a,
1961
+ pagination: l
1939
1962
  }) {
1940
- const o = we({}), s = j();
1941
- q(() => a.value, () => {
1963
+ const u = Te({}), o = j();
1964
+ _(() => l.value, () => {
1942
1965
  var S;
1943
- if (se(a.value) && !a.value) {
1944
- s.value = !1;
1966
+ if (ne(l.value) && !l.value) {
1967
+ o.value = !1;
1945
1968
  return;
1946
1969
  }
1947
- const d = Ft(e, C(l), "pageItemRender"), m = Ae(d) ? {
1970
+ const d = It(e, C(a), "pageItemRender"), v = Ke(d) ? {
1948
1971
  itemRender: ({
1949
- page: f,
1972
+ page: h,
1950
1973
  type: b,
1951
- originalElement: u
1974
+ originalElement: i
1952
1975
  }) => d ? d({
1953
- page: f,
1976
+ page: h,
1954
1977
  type: b,
1955
- originalElement: u
1978
+ originalElement: i
1956
1979
  }) : null
1957
1980
  } : null, x = {
1958
1981
  current: 1,
@@ -1961,10 +1984,10 @@ function wa({
1961
1984
  showQuickJumper: !0,
1962
1985
  showSizeChanger: !0,
1963
1986
  pageSizeOptions: ["10", "20", "50", "100"],
1964
- ...a.value || {},
1965
- ...m || {}
1987
+ ...l.value || {},
1988
+ ...v || {}
1966
1989
  };
1967
- (S = a.value) != null && S.showTotal || (x.showTotal = (f) => `共${f < x.pageSize ? 1 : Math.ceil(f / (x.pageSize || 10))}页 ${f}条记录`), s.value = x, Object.assign(o, {
1990
+ (S = l.value) != null && S.showTotal || (x.showTotal = (h) => `共${h < x.pageSize ? 1 : Math.ceil(h / (x.pageSize || 10))}页 ${h}条记录`), o.value = x, Object.assign(u, {
1968
1991
  pageNum: x.current,
1969
1992
  pageSize: x.pageSize
1970
1993
  });
@@ -1972,156 +1995,156 @@ function wa({
1972
1995
  deep: 1,
1973
1996
  immediate: !0
1974
1997
  });
1975
- function i(d) {
1976
- if (J(s.value) && J(d)) {
1977
- const m = {};
1998
+ function s(d) {
1999
+ if (Z(o.value) && Z(d)) {
2000
+ const v = {};
1978
2001
  Object.keys(d).forEach((x) => {
1979
- Object.prototype.hasOwnProperty.call(d, x) && s.value[x] === d[x] || (m[x] = d[x]);
1980
- }), Object.keys(m).length > 0 && (Object.assign(s.value, m), pa(m) && Object.assign(o, m));
2002
+ Object.prototype.hasOwnProperty.call(d, x) && o.value[x] === d[x] || (v[x] = d[x]);
2003
+ }), Object.keys(v).length > 0 && (Object.assign(o.value, v), $a(v) && Object.assign(u, v));
1981
2004
  }
1982
2005
  }
1983
2006
  return {
1984
- paginationInfo: s,
1985
- requestPagination: o,
1986
- setPagination: i
2007
+ paginationInfo: o,
2008
+ requestPagination: u,
2009
+ setPagination: s
1987
2010
  };
1988
2011
  }
1989
- function pa(e) {
2012
+ function $a(e) {
1990
2013
  if (typeof e != "object" || e === null)
1991
2014
  return !1;
1992
- const l = Object.keys(e);
1993
- return l.length === 2 && l.includes("pageNum") && l.includes("pageSize");
2015
+ const a = Object.keys(e);
2016
+ return a.length === 2 && a.includes("pageNum") && a.includes("pageSize");
1994
2017
  }
1995
- function Ta(e, l) {
1996
- const a = j([]), o = j([]);
1997
- q(() => {
1998
- var f;
1999
- return (f = l.value) == null ? void 0 : f.selectedRowKeys;
2000
- }, (f) => {
2001
- a.value = sl([...f || []]);
2018
+ function Ba(e, a) {
2019
+ const l = j([]), u = j([]);
2020
+ _(() => {
2021
+ var h;
2022
+ return (h = a.value) == null ? void 0 : h.selectedRowKeys;
2023
+ }, (h) => {
2024
+ l.value = ol([...h || []]);
2002
2025
  }, {
2003
2026
  deep: !0,
2004
2027
  immediate: !0
2005
2028
  });
2006
- const s = (f, b) => {
2007
- e.value && (b ? f != null && f[e.value] && (a.value.push(f[e.value]), o.value.push(f)) : (a.value = a.value.filter((u) => u !== f[e.value]), o.value = o.value.filter((u) => u[e.value] !== f[e.value])));
2008
- }, i = () => {
2009
- var f, b;
2010
- l.value && ((b = (f = l.value) == null ? void 0 : f.onChange) == null || b.call(f, a.value, o.value));
2029
+ const o = (h, b) => {
2030
+ e.value && (b ? h != null && h[e.value] && (l.value.push(h[e.value]), u.value.push(h)) : (l.value = l.value.filter((i) => i !== h[e.value]), u.value = u.value.filter((i) => i[e.value] !== h[e.value])));
2031
+ }, s = () => {
2032
+ var h, b;
2033
+ a.value && ((b = (h = a.value) == null ? void 0 : h.onChange) == null || b.call(h, l.value, u.value));
2011
2034
  };
2012
2035
  return {
2013
- selectedKeys: a,
2014
- selectedItems: o,
2015
- selectRowKey: s,
2016
- selectAllRowKey: (f, b, u) => {
2017
- e.value && (f ? b.map((n) => (a.value.every((r) => r !== (n == null ? void 0 : n[e.value])) && n != null && n[e.value] && (a.value.push(n[e.value]), o.value.push(n)), n)) : u.map((n) => (a.value.includes(n == null ? void 0 : n[e.value]) && (a.value = a.value.filter((r) => r !== n[e.value]), o.value = o.value.filter((r) => r[e.value] !== n[e.value])), n)));
2036
+ selectedKeys: l,
2037
+ selectedItems: u,
2038
+ selectRowKey: o,
2039
+ selectAllRowKey: (h, b, i) => {
2040
+ e.value && (h ? b.map((n) => (l.value.every((r) => r !== (n == null ? void 0 : n[e.value])) && n != null && n[e.value] && (l.value.push(n[e.value]), u.value.push(n)), n)) : i.map((n) => (l.value.includes(n == null ? void 0 : n[e.value]) && (l.value = l.value.filter((r) => r !== n[e.value]), u.value = u.value.filter((r) => r[e.value] !== n[e.value])), n)));
2018
2041
  },
2019
- removeRowKeys: (f) => {
2020
- a.value = a.value.filter((b) => !f.includes(b)), o.value = o.value.filter((b) => !f.includes(b == null ? void 0 : b[e.value || ""])), i();
2042
+ removeRowKeys: (h) => {
2043
+ l.value = l.value.filter((b) => !h.includes(b)), u.value = u.value.filter((b) => !h.includes(b == null ? void 0 : b[e.value || ""])), s();
2021
2044
  },
2022
- changeRowKey: i,
2023
- syncSelectedRows: (f) => {
2024
- if (e.value && a.value.length !== o.value.length) {
2025
- const b = o.value.map((n) => n[e.value]), u = a.value.filter((n) => !b.includes(n));
2026
- f.forEach((n) => {
2027
- u.includes(n[e.value]) && o.value.push(ie(n));
2045
+ changeRowKey: s,
2046
+ syncSelectedRows: (h) => {
2047
+ if (e.value && l.value.length !== u.value.length) {
2048
+ const b = u.value.map((n) => n[e.value]), i = l.value.filter((n) => !b.includes(n));
2049
+ h.forEach((n) => {
2050
+ i.includes(n[e.value]) && u.value.push(re(n));
2028
2051
  });
2029
2052
  }
2030
2053
  },
2031
2054
  clearAllRowKeys: () => {
2032
- a.value = [], o.value = [], i();
2055
+ l.value = [], u.value = [], s();
2033
2056
  }
2034
2057
  };
2035
2058
  }
2036
- function $a(e) {
2037
- const l = {};
2038
- return e.forEach((a) => {
2039
- let o = a.initialValue;
2040
- const s = ["select"], i = ["date", "time", "dateRange"];
2041
- !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);
2042
- }), l;
2059
+ function Ra(e) {
2060
+ const a = {};
2061
+ return e.forEach((l) => {
2062
+ let u = l.initialValue;
2063
+ const o = ["select"], s = ["date", "time", "dateRange"];
2064
+ !u && o.includes(l.valueType) ? u = void 0 : !u && s.includes(l.valueType) ? u = null : u || (u = ""), l.name === "dateRange" ? (a[l.rangeStartName || "start"] = u ? u[0] : null, a[l.rangeEndName || "end"] = u ? u[1] : null) : l.name && (a[l.name] = u);
2065
+ }), a;
2043
2066
  }
2044
- function Ba({ searchMap: e, params: l, columns: a, setPagination: o }) {
2045
- const s = we({}), i = we({}), d = j([]), m = (S) => {
2046
- var b, u;
2047
- const f = [];
2048
- if ((S === "all" || S === "searchMap") && ((b = e.value) == null || b.forEach((n) => f.push(n)), f.forEach((n) => {
2067
+ function Fa({ searchMap: e, params: a, columns: l, setPagination: u }) {
2068
+ const o = Te({}), s = Te({}), d = j([]), v = (S) => {
2069
+ var b, i;
2070
+ const h = [];
2071
+ if ((S === "all" || S === "searchMap") && ((b = e.value) == null || b.forEach((n) => h.push(n)), h.forEach((n) => {
2049
2072
  d.value.some((r) => r.name === n.name) ? d.value = d.value.map((r) => r.name === n.name ? {
2050
2073
  ...r,
2051
2074
  ...n
2052
2075
  } : r) : d.value.push(n);
2053
- })), (S === "all" || S === "columns") && ((u = a.value) != null && u.length) && (a.value && a.value.forEach((n) => {
2054
- n.searchConfig && f.push(n.searchConfig);
2055
- }), f.forEach((n) => {
2076
+ })), (S === "all" || S === "columns") && ((i = l.value) != null && i.length) && (l.value && l.value.forEach((n) => {
2077
+ n.searchConfig && h.push(n.searchConfig);
2078
+ }), h.forEach((n) => {
2056
2079
  d.value.some((r) => r.name === n.name) ? d.value = d.value.map((r) => r.name === n.name ? {
2057
2080
  ...r,
2058
2081
  ...n
2059
2082
  } : r) : d.value.push(n);
2060
2083
  })), S === "all" || S === "searchMap" || S === "columns") {
2061
- o({ current: 1 });
2062
- const n = $a(f);
2063
- Object.assign(i, { ...n });
2084
+ u({ current: 1 });
2085
+ const n = Ra(h);
2086
+ Object.assign(s, { ...n });
2064
2087
  for (const r in n)
2065
- s[r] || (s[r] = n[r]);
2088
+ o[r] || (o[r] = n[r]);
2066
2089
  }
2067
- (S === "all" || S === "params") && (o({ current: 1 }), Object.assign(s, l.value));
2090
+ (S === "all" || S === "params") && (u({ current: 1 }), Object.assign(o, a.value));
2068
2091
  };
2069
- yl(() => {
2070
- m("all");
2071
- }), q(() => l.value, () => {
2072
- m("params");
2073
- }, { deep: !0 }), q(() => e.value, () => {
2074
- m("searchMap");
2075
- }, { deep: !0 }), q(() => a.value, () => {
2076
- m("columns");
2092
+ bl(() => {
2093
+ v("all");
2094
+ }), _(() => a.value, () => {
2095
+ v("params");
2096
+ }, { deep: !0 }), _(() => e.value, () => {
2097
+ v("searchMap");
2098
+ }, { deep: !0 }), _(() => l.value, () => {
2099
+ v("columns");
2077
2100
  }, { deep: !0 });
2078
2101
  function x(S) {
2079
- o({ current: 1 }), Object.assign(s, S);
2102
+ u({ current: 1 }), Object.assign(o, S);
2080
2103
  }
2081
- return { formDataRef: d, formParamsRef: s, defaultParamsRef: i, setFormParams: x };
2104
+ return { formDataRef: d, formParamsRef: o, defaultParamsRef: s, setFormParams: x };
2082
2105
  }
2083
- function Ra(e) {
2084
- const l = w(() => e.scroll), a = w(() => e.autoScroll), o = w(() => e.modalScroll), s = w(() => e.neverScroll), i = w(() => e.rowSelection), d = w(() => e.scrollBreakpoint);
2106
+ function Ia(e) {
2107
+ const a = w(() => e.scroll), l = w(() => e.autoScroll), u = w(() => e.modalScroll), o = w(() => e.neverScroll), s = w(() => e.rowSelection), d = w(() => e.scrollBreakpoint);
2085
2108
  return {
2086
- scroll: l,
2087
- neverScroll: s,
2088
- rowSelection: i,
2089
- autoScroll: a,
2090
- modalScroll: o,
2109
+ scroll: a,
2110
+ neverScroll: o,
2111
+ rowSelection: s,
2112
+ autoScroll: l,
2113
+ modalScroll: u,
2091
2114
  scrollBreakpoint: d
2092
2115
  };
2093
2116
  }
2094
- function Fa({ scroll: e, columns: l, autoScroll: a, modalScroll: o, neverScroll: s, rowSelection: i, screens: d, innerWidth: m, scrollBreakpoint: x }) {
2117
+ function ka({ scroll: e, columns: a, autoScroll: l, modalScroll: u, neverScroll: o, rowSelection: s, screens: d, innerWidth: v, scrollBreakpoint: x }) {
2095
2118
  const S = w(() => {
2096
- var u, n, r;
2097
- return C(x) ? Qe(C(x)) ? m.value > C(x) : It(C(x)) ? (u = d.value) == null ? void 0 : u[C(x)] : (n = d.value) == null ? void 0 : n.xl : (r = d.value) == null ? void 0 : r.xl;
2098
- }), f = w(() => {
2099
- let u = 0;
2100
- const n = C(i) ? 60 : 0, r = 150, y = ie(C(l));
2101
- y.forEach((R) => {
2102
- u += Number.parseInt(String(R.width)) || 0;
2119
+ var i, n, r;
2120
+ return C(x) ? _e(C(x)) ? v.value > C(x) : kt(C(x)) ? (i = d.value) == null ? void 0 : i[C(x)] : (n = d.value) == null ? void 0 : n.xl : (r = d.value) == null ? void 0 : r.xl;
2121
+ }), h = w(() => {
2122
+ let i = 0;
2123
+ const n = C(s) ? 60 : 0, r = 150, y = re(C(a));
2124
+ y.forEach((F) => {
2125
+ i += Number.parseInt(String(F.width)) || 0;
2103
2126
  });
2104
- const O = y.filter((R) => !Reflect.has(R, "width")).length;
2105
- return O !== 0 && (u += O * r), n && (u += n), u;
2127
+ const k = y.filter((F) => !Reflect.has(F, "width")).length;
2128
+ return k !== 0 && (i += k * r), n && (i += n), i;
2106
2129
  });
2107
2130
  return { proScroll: w(() => {
2108
- var u, n;
2109
- return C(s) ? {} : C(e) && Object.keys(C(e)).length ? C(e) : C(o) ? {
2110
- y: ((u = C(e)) == null ? void 0 : u.y) || ((n = d.value) != null && n.xl ? 400 : 235)
2111
- } : C(a) ? S.value ? {} : se(S.value) ? { x: C(f) } : {} : {};
2131
+ var i, n;
2132
+ return C(o) ? {} : C(e) && Object.keys(C(e)).length ? C(e) : C(u) ? {
2133
+ y: ((i = C(e)) == null ? void 0 : i.y) || ((n = d.value) != null && n.xl ? 400 : 235)
2134
+ } : C(l) ? S.value ? {} : ne(S.value) ? { x: C(h) } : {} : {};
2112
2135
  }), breakpoint: S };
2113
2136
  }
2114
- function Ia({ size: e, emit: l }) {
2115
- const a = j("middle");
2116
- Ye(() => {
2117
- a.value = e.value;
2137
+ function Oa({ size: e, emit: a }) {
2138
+ const l = j("middle");
2139
+ Le(() => {
2140
+ l.value = e.value;
2118
2141
  });
2119
- function o(s) {
2120
- a.value = s, l("sizeChange", s);
2142
+ function u(o) {
2143
+ l.value = o, a("sizeChange", o);
2121
2144
  }
2122
- return { sizeRef: a, setTableSize: o };
2145
+ return { sizeRef: l, setTableSize: u };
2123
2146
  }
2124
- const tt = {
2147
+ const lt = {
2125
2148
  "&::-webkit-scrollbar": {
2126
2149
  width: 4,
2127
2150
  height: 4
@@ -2134,8 +2157,8 @@ const tt = {
2134
2157
  backgroundColor: "transparent",
2135
2158
  borderRadius: 2
2136
2159
  }
2137
- }, Oa = (e) => {
2138
- const l = `${e.antCls}-table`;
2160
+ }, Pa = (e) => {
2161
+ const a = `${e.antCls}-table`;
2139
2162
  return {
2140
2163
  [e.componentCls]: {
2141
2164
  "&-a": {
@@ -2145,8 +2168,8 @@ const tt = {
2145
2168
  color: e.colorPrimaryHover
2146
2169
  }
2147
2170
  },
2148
- [`${l}`]: {
2149
- [`${l}-cell-ellipsis`]: {
2171
+ [`${a}`]: {
2172
+ [`${a}-cell-ellipsis`]: {
2150
2173
  overflow: "unset",
2151
2174
  whiteSpace: "unset"
2152
2175
  }
@@ -2325,512 +2348,515 @@ const tt = {
2325
2348
  color: e.colorWhite
2326
2349
  }
2327
2350
  },
2328
- [`${e.antCls}-table-content`]: tt,
2329
- [`${e.antCls}-table-body`]: tt,
2330
- [`${e.antCls}-table-empty`]: {
2331
- [`${e.antCls}-table-content`]: tt
2351
+ [`&${e.componentCls}-beautify-scroll`]: {
2352
+ [`${e.antCls}-table-content`]: lt,
2353
+ [`${e.antCls}-table-body`]: lt,
2354
+ [`${e.antCls}-table-empty`]: {
2355
+ [`${e.antCls}-table-content`]: lt
2356
+ }
2332
2357
  }
2333
2358
  }
2334
2359
  };
2335
2360
  };
2336
- function ka(e) {
2337
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !Z(e);
2361
+ function ja(e) {
2362
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !le(e);
2338
2363
  }
2339
- function Pa(e, l, a, o) {
2340
- if (!l) return e;
2341
- let s = e;
2342
- if (J(l)) {
2343
- const i = l.node === "a" ? "span" : l.node;
2344
- return c(i, _((l == null ? void 0 : l.attr) || {}, {
2345
- class: [l.class, l.node === "a" ? `${a}-a` : ""],
2346
- onClick: l.click
2347
- }), ka(e) ? e : {
2364
+ function Na(e, a, l, u) {
2365
+ if (!a) return e;
2366
+ let o = e;
2367
+ if (Z(a)) {
2368
+ const s = a.node === "a" ? "span" : a.node;
2369
+ return c(s, Q((a == null ? void 0 : a.attr) || {}, {
2370
+ class: [a.class, a.node === "a" ? `${l}-a` : ""],
2371
+ onClick: a.click
2372
+ }), ja(e) ? e : {
2348
2373
  default: () => [e]
2349
2374
  });
2350
2375
  }
2351
- switch (l) {
2376
+ switch (a) {
2352
2377
  case "link":
2353
- s = c("span", {
2354
- class: [`${a}-a`, o]
2378
+ o = c("span", {
2379
+ class: [`${l}-a`, u]
2355
2380
  }, [e]);
2356
2381
  break;
2357
2382
  case "time":
2358
- s = X(e).format("HH:mm:ss");
2383
+ o = U(e).format("HH:mm:ss");
2359
2384
  break;
2360
2385
  case "dateMonth":
2361
- s = `${X(e).month() + 1}月`;
2386
+ o = `${U(e).month() + 1}月`;
2362
2387
  break;
2363
2388
  case "date":
2364
- s = X(e).format("YYYY-MM-DD");
2389
+ o = U(e).format("YYYY-MM-DD");
2365
2390
  break;
2366
2391
  case "dateTime":
2367
- s = X(e).format("YYYY-MM-DD HH:mm:ss");
2392
+ o = U(e).format("YYYY-MM-DD HH:mm:ss");
2368
2393
  break;
2369
2394
  }
2370
- return s;
2395
+ return o;
2371
2396
  }
2372
- function ja(e, l) {
2373
- const a = l && l.current || 1, o = l && l.pageSize || 10;
2374
- return e.filter((s, i) => i < a * o && i >= o * (a - 1));
2397
+ function Ea(e, a) {
2398
+ const l = a && a.current || 1, u = a && a.pageSize || 10;
2399
+ return e.filter((o, s) => s < l * u && s >= u * (l - 1));
2375
2400
  }
2376
- function Na(e) {
2377
- const l = document.createElement("textarea");
2378
- l.style.position = "absolute", l.style.opacity = "0", l.value = e, document.body.appendChild(l), l.select(), document.execCommand("copy"), document.body.removeChild(l);
2401
+ function Da(e) {
2402
+ const a = document.createElement("textarea");
2403
+ a.style.position = "absolute", a.style.opacity = "0", a.value = e, document.body.appendChild(a), a.select(), document.execCommand("copy"), document.body.removeChild(a);
2379
2404
  }
2380
- function Ea(e) {
2381
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !Z(e);
2405
+ function Ma(e) {
2406
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !le(e);
2382
2407
  }
2383
2408
  const {
2384
- useBreakpoint: Da
2385
- } = st, Ma = {
2409
+ useBreakpoint: Aa
2410
+ } = ot, Ka = {
2386
2411
  reload: !0,
2387
2412
  density: !0,
2388
2413
  setting: !0,
2389
2414
  fullScreen: !0
2390
- }, lt = /* @__PURE__ */ he({
2415
+ }, at = /* @__PURE__ */ ve({
2391
2416
  name: "GProTable",
2392
2417
  inheritAttrs: !1,
2393
- props: de,
2418
+ props: he,
2394
2419
  emits: ["reset", "reload", "submit", "sizeChange", "expandedRowsChange", "expand", "change", "requestError", "beforeSearchSubmit", "columnsStateChange", "loadingChange"],
2395
2420
  slots: Object,
2396
2421
  setup(e, {
2397
- emit: l,
2398
- slots: a,
2399
- attrs: o,
2400
- expose: s
2422
+ emit: a,
2423
+ slots: l,
2424
+ attrs: u,
2425
+ expose: o
2401
2426
  }) {
2402
- const i = ut({
2427
+ const s = it({
2403
2428
  suffixCls: "table",
2404
2429
  isPor: !0
2405
2430
  }), {
2406
2431
  wrapSSR: d,
2407
- hashId: m
2408
- } = Xe("ProBaseTable", [Oa], i), x = Da(), {
2432
+ hashId: v
2433
+ } = Ue("ProBaseTable", [Pa], s), x = Aa(), {
2409
2434
  width: S
2410
- } = Pl(), f = j(!1), b = jt(), u = j(), n = j(), r = j(e.waitRequest);
2411
- Ye(() => r.value = e.waitRequest);
2435
+ } = jl(), h = j(!1), b = Nt(), i = j(), n = j(), r = j(e.waitRequest);
2436
+ Le(() => r.value = e.waitRequest);
2412
2437
  const {
2413
2438
  toggle: y,
2414
- isFullscreen: T
2415
- } = Nt(u), O = w(() => ({
2439
+ isFullscreen: p
2440
+ } = Et(i), k = w(() => ({
2416
2441
  ...e
2417
- })), R = w(() => !x.value.xl), A = w(() => {
2418
- var h, $;
2419
- return e.virtualScroll && Cl(!((h = e.scroll) != null && h.y), "参数scroll的Y值不能为空!"), !!(($ = e.scroll) != null && $.y && e.virtualScroll);
2420
- }), V = w(() => e.search === !1 ? !1 : J(e.search) ? e.search : {
2442
+ })), F = w(() => !x.value.xl), M = w(() => {
2443
+ var m, T;
2444
+ return e.virtualScroll && xl(!((m = e.scroll) != null && m.y), "参数scroll的Y值不能为空!"), !!((T = e.scroll) != null && T.y && e.virtualScroll);
2445
+ }), G = w(() => e.search === !1 ? !1 : Z(e.search) ? e.search : {
2421
2446
  type: "auto",
2422
2447
  resetText: "重置",
2423
2448
  searchText: "查询"
2424
- }), L = w(() => V.value === !1 ? {} : V.value), W = w(() => {
2425
- var h;
2426
- return ((h = L.value) == null ? void 0 : h.type) === "button";
2427
- }), K = w(() => {
2428
- var h;
2429
- return (h = L.value) == null ? void 0 : h.actions;
2430
- }), G = w(() => {
2431
- const h = (e.columns || []).filter(($) => $.key || $.dataIndex).map(($) => ({
2432
- ...$,
2433
- key: $.key || $.dataIndex,
2434
- align: $.align || e.align,
2435
- uuid: at().uuid(15)
2449
+ }), W = w(() => G.value === !1 ? {} : G.value), Y = w(() => {
2450
+ var m;
2451
+ return ((m = W.value) == null ? void 0 : m.type) === "button";
2452
+ }), ue = w(() => {
2453
+ var m;
2454
+ return (m = W.value) == null ? void 0 : m.actions;
2455
+ }), A = w(() => {
2456
+ const m = (e.columns || []).filter((T) => T.key || T.dataIndex).map((T) => ({
2457
+ ...T,
2458
+ key: T.key || T.dataIndex,
2459
+ align: T.align || e.align,
2460
+ uuid: nt().uuid(15)
2436
2461
  }));
2437
- return ol(h, {
2462
+ return rl(m, {
2438
2463
  align: e.align || "left",
2439
2464
  showIndex: e.showIndex || !1
2440
2465
  });
2441
2466
  }), {
2442
- loadingComputed: H,
2443
- loading: oe,
2444
- setLoading: le
2445
- } = Sa({
2446
- emit: l,
2447
- loading: ce(e, "loading")
2467
+ loadingComputed: K,
2468
+ loading: ce,
2469
+ setLoading: Re
2470
+ } = pa({
2471
+ emit: a,
2472
+ loading: fe(e, "loading")
2448
2473
  }), {
2449
- sizeRef: re,
2450
- setTableSize: Oe
2451
- } = Ia({
2452
- emit: l,
2453
- size: ce(e, "size")
2474
+ sizeRef: ee,
2475
+ setTableSize: Fe
2476
+ } = Oa({
2477
+ emit: a,
2478
+ size: fe(e, "size")
2454
2479
  }), {
2455
2480
  paginationInfo: t,
2456
2481
  requestPagination: g,
2457
- setPagination: F
2458
- } = wa({
2459
- slots: a,
2460
- props: O,
2461
- pagination: ce(e, "pagination")
2462
- }), p = Ra(e), {
2482
+ setPagination: R
2483
+ } = Ta({
2484
+ slots: l,
2485
+ props: k,
2486
+ pagination: fe(e, "pagination")
2487
+ }), $ = Ia(e), {
2463
2488
  proScroll: P,
2464
- breakpoint: I
2465
- } = Fa({
2466
- ...p,
2489
+ breakpoint: q
2490
+ } = ka({
2491
+ ...$,
2467
2492
  innerWidth: S,
2468
- columns: G,
2493
+ columns: A,
2469
2494
  screens: x
2470
- }), N = ga(e), {
2471
- proColumns: v,
2472
- cacheProColumns: z,
2473
- setColumns: ve,
2474
- changeColumns: pe,
2475
- resizeColumnWidth: Te
2476
- } = ya({
2477
- ...N,
2478
- breakpoint: I,
2495
+ }), I = ba(e), {
2496
+ proColumns: f,
2497
+ cacheProColumns: L,
2498
+ setColumns: V,
2499
+ changeColumns: X,
2500
+ resizeColumnWidth: de
2501
+ } = Ca({
2502
+ ...I,
2503
+ breakpoint: q,
2479
2504
  scroll: P,
2480
- columns: G
2505
+ columns: A
2481
2506
  }), {
2482
- columnsMap: ee,
2483
- operationType: Le,
2484
- setColumnsMap: ke,
2485
- sortKeyColumns: te,
2486
- cacheColumnsMap: ge,
2487
- setSortKeyColumns: Y
2488
- } = va({
2489
- columns: z,
2490
- columnsState: ce(e, "columnsState"),
2491
- changeColumns: pe
2507
+ columnsMap: J,
2508
+ operationType: ye,
2509
+ setColumnsMap: We,
2510
+ sortKeyColumns: Pe,
2511
+ cacheColumnsMap: ae,
2512
+ setSortKeyColumns: be
2513
+ } = ya({
2514
+ columns: L,
2515
+ columnsState: fe(e, "columnsState"),
2516
+ changeColumns: X
2492
2517
  }), {
2493
- formDataRef: ye,
2494
- formParamsRef: U,
2495
- defaultParamsRef: zt,
2496
- setFormParams: Ue
2497
- } = Ba({
2498
- searchMap: ce(e, "searchMap"),
2499
- params: ce(e, "params"),
2500
- columns: G,
2501
- setPagination: F
2518
+ formDataRef: z,
2519
+ formParamsRef: Ce,
2520
+ defaultParamsRef: te,
2521
+ setFormParams: Je
2522
+ } = Fa({
2523
+ searchMap: fe(e, "searchMap"),
2524
+ params: fe(e, "params"),
2525
+ columns: A,
2526
+ setPagination: R
2502
2527
  }), {
2503
- selectedKeys: ot,
2528
+ selectedKeys: rt,
2504
2529
  selectedItems: Yt,
2505
2530
  changeRowKey: Lt,
2506
- selectRowKey: rt,
2507
- selectAllRowKey: ct,
2508
- syncSelectedRows: dt,
2509
- removeRowKeys: ft,
2531
+ selectRowKey: ct,
2532
+ selectAllRowKey: dt,
2533
+ syncSelectedRows: ft,
2534
+ removeRowKeys: ht,
2510
2535
  clearAllRowKeys: Wt
2511
- } = Ta(ce(e, "rowKey"), ce(e, "rowSelection")), Ht = Ca(e), {
2512
- reload: Pe,
2513
- reSetDataList: Vt,
2536
+ } = Ba(fe(e, "rowKey"), fe(e, "rowSelection")), Vt = Sa(e), {
2537
+ reload: je,
2538
+ reSetDataList: Ht,
2514
2539
  changeDataValue: Gt,
2515
2540
  isTreeDataRef: Qt,
2516
- dataSource: je,
2517
- handleTableChange: ht
2518
- } = xa({
2519
- ...Ht,
2541
+ dataSource: Ne,
2542
+ handleTableChange: mt
2543
+ } = wa({
2544
+ ...Vt,
2520
2545
  waitRequest: r
2521
2546
  }, {
2522
- loading: H,
2547
+ loading: K,
2523
2548
  paginationInfo: t,
2524
- setPagination: F,
2525
- removeRowKeys: ft,
2526
- syncSelectedRows: dt,
2527
- setLoading: le,
2528
- setColumns: ve,
2529
- search: V,
2530
- columns: v,
2531
- formParamsRef: U,
2549
+ setPagination: R,
2550
+ removeRowKeys: ht,
2551
+ syncSelectedRows: ft,
2552
+ setLoading: Re,
2553
+ setColumns: V,
2554
+ search: G,
2555
+ columns: f,
2556
+ formParamsRef: Ce,
2532
2557
  onBeforeSearchSubmit: e.onBeforeSearchSubmit,
2533
- hasCustomRender: w(() => Ie(e.customRender || (a == null ? void 0 : a.customRender)))
2534
- }, l), Ne = w(() => e.options ? {
2535
- ...Ma,
2536
- ...J(e.options) ? e.options : {}
2558
+ hasCustomRender: w(() => Oe(e.customRender || (l == null ? void 0 : l.customRender)))
2559
+ }, a), Ee = w(() => e.options ? {
2560
+ ...Ka,
2561
+ ...Z(e.options) ? e.options : {}
2537
2562
  } : !1), _t = w(() => ({
2538
- size: C(re),
2563
+ size: C(ee),
2539
2564
  scroll: C(P),
2540
- dataSource: C(je),
2565
+ dataSource: C(Ne),
2541
2566
  pagination: C(t),
2542
- virtualScroll: A.value,
2543
- columns: C(v).filter((h) => h.show || h.show === void 0)
2544
- })), mt = w(() => {
2545
- var $, B;
2546
- const h = J(e.loading) ? qe(e.loading, "spinning") : {};
2547
- return !h.indicator && (($ = b == null ? void 0 : b.indicator) != null && $.value) && (h.indicator = (B = b == null ? void 0 : b.indicator) == null ? void 0 : B.value), {
2548
- spinning: e.showLoading ? Ie(oe.value) : !1,
2549
- ...h
2567
+ virtualScroll: M.value,
2568
+ columns: C(f).filter((m) => m.show || m.show === void 0)
2569
+ })), vt = w(() => {
2570
+ var T, B;
2571
+ const m = Z(e.loading) ? Xe(e.loading, "spinning") : {};
2572
+ return !m.indicator && ((T = b == null ? void 0 : b.indicator) != null && T.value) && (m.indicator = (B = b == null ? void 0 : b.indicator) == null ? void 0 : B.value), {
2573
+ spinning: e.showLoading ? Oe(ce.value) : !1,
2574
+ ...m
2550
2575
  };
2551
- }), vt = w(() => {
2552
- var E;
2553
- let h;
2554
- const $ = C(O).direction === "rtl" ? "bottomLeft" : "right", B = (E = C(t)) == null ? void 0 : E.position;
2576
+ }), gt = w(() => {
2577
+ var N;
2578
+ let m;
2579
+ const T = C(k).direction === "rtl" ? "bottomLeft" : "right", B = (N = C(t)) == null ? void 0 : N.position;
2555
2580
  if (B !== null && Array.isArray(B)) {
2556
- const k = B.find((M) => M.includes("top")), Q = B.find((M) => M.includes("bottom")), ae = B.every((M) => `${M}` == "none");
2557
- !k && !Q && !ae && (h = $), k && (h = k.toLowerCase().replace("top", "")), Q && (h = Q.toLowerCase().replace("bottom", ""));
2581
+ const O = B.find((D) => D.includes("top")), H = B.find((D) => D.includes("bottom")), ie = B.every((D) => `${D}` == "none");
2582
+ !O && !H && !ie && (m = T), O && (m = O.toLowerCase().replace("top", "")), H && (m = H.toLowerCase().replace("bottom", ""));
2558
2583
  } else
2559
- h = $;
2560
- return h;
2584
+ m = T;
2585
+ return m;
2561
2586
  });
2562
- ma(() => {
2563
- f.value && e.keepAliveReload ? Pe() : f.value = !0;
2587
+ ga(() => {
2588
+ h.value && e.keepAliveReload ? je() : h.value = !0;
2564
2589
  });
2565
- const gt = async (h, $) => {
2590
+ const yt = async (m, T) => {
2566
2591
  var B;
2567
- W.value ? (B = K.value) != null && B.reload && $ ? (Ue(h), await Pe()) : Ue(h) : (Ue({
2592
+ Y.value ? (B = ue.value) != null && B.reload && T ? (Je(m), await je()) : Je(m) : (Je({
2568
2593
  ...e.params || {},
2569
- ...h
2570
- }), await Pe());
2571
- }, qt = async (h, $) => {
2572
- $ === "reset" ? (l("reset", h), e.request && await gt(h, $)) : e.request ? (l("submit", h), await gt(h, $)) : l("submit", h);
2573
- }, yt = (h, $, B, E) => {
2574
- F(xt(h, ["current", "pageSize"])), ht(h, $, B, E);
2575
- }, Xt = (h, $) => {
2594
+ ...m
2595
+ }), await je());
2596
+ }, qt = async (m, T) => {
2597
+ T === "reset" ? (a("reset", m), e.request && await yt(m, T)) : e.request ? (a("submit", m), await yt(m, T)) : a("submit", m);
2598
+ }, bt = (m, T, B, N) => {
2599
+ R(St(m, ["current", "pageSize"])), mt(m, T, B, N);
2600
+ }, Xt = (m, T) => {
2576
2601
  var B;
2577
- F({
2578
- current: h,
2579
- pageSize: $
2580
- }), ht({
2581
- current: h,
2582
- pageSize: $,
2602
+ R({
2603
+ current: m,
2604
+ pageSize: T
2605
+ }), mt({
2606
+ current: m,
2607
+ pageSize: T,
2583
2608
  total: t.value && ((B = t.value) == null ? void 0 : B.total) || 0
2584
2609
  }, {}, {});
2585
- }, Ut = (h) => {
2586
- l("expandedRowsChange", h);
2587
- }, Jt = (h, $) => {
2588
- l("expand", h, $);
2589
- }, Zt = (h, $) => Te(h, $), el = (h, $, B) => {
2590
- var k, Q, ae;
2591
- let E = h;
2592
- if ($) {
2593
- const M = ue(h) ? typeof ((k = h == null ? void 0 : h[0]) == null ? void 0 : k.children) == "string" ? (Q = h == null ? void 0 : h[0]) == null ? void 0 : Q.children : "" : h.toString(), D = B.tooltip === !1 ? {} : B.tooltip, be = B.tooltip === !1 ? 1 : Qe(D == null ? void 0 : D.hiddenLine) && (D == null ? void 0 : D.hiddenLine) > 0 ? D == null ? void 0 : D.hiddenLine : 1, ne = B.tooltip === !1 ? 0 : Qe(D == null ? void 0 : D.width) ? D == null ? void 0 : D.width : 0, Re = B.tooltip !== !1 && It(M) && ne > 0 ? cl(M, {
2594
- cssObject: D == null ? void 0 : D.targetStyle
2595
- }) : 0, We = document.querySelector(`.${i} .ant-table-tbody`), $e = c("div", {
2596
- class: `${i}-ellipsis-text`
2597
- }, [h]), Ee = () => B.tooltip === !1 || J(B.tooltip) && Re < ne && ne > 0 ? $e : c(fe, _({
2598
- title: h,
2599
- getPopupContainer: (De) => {
2600
- var Ct;
2601
- return We ?? ((Ct = De == null ? void 0 : De.parentNode) == null ? void 0 : Ct.parentNode);
2610
+ }, Ut = (m) => {
2611
+ a("expandedRowsChange", m);
2612
+ }, Jt = (m, T) => {
2613
+ a("expand", m, T);
2614
+ }, Zt = (m, T) => de(m, T), el = (m, T, B) => {
2615
+ var O, H, ie;
2616
+ let N = m;
2617
+ if (T) {
2618
+ const D = oe(m) ? typeof ((O = m == null ? void 0 : m[0]) == null ? void 0 : O.children) == "string" ? (H = m == null ? void 0 : m[0]) == null ? void 0 : H.children : "" : m.toString(), E = B.tooltip === !1 ? {} : B.tooltip, xe = B.tooltip === !1 ? 1 : _e(E == null ? void 0 : E.hiddenLine) && (E == null ? void 0 : E.hiddenLine) > 0 ? E == null ? void 0 : E.hiddenLine : 1, se = B.tooltip === !1 ? 0 : _e(E == null ? void 0 : E.width) ? E == null ? void 0 : E.width : 0, Ie = B.tooltip !== !1 && kt(D) && se > 0 ? dl(D, {
2619
+ cssObject: E == null ? void 0 : E.targetStyle
2620
+ }) : 0, Ve = document.querySelector(`.${s} .ant-table-tbody`), $e = c("div", {
2621
+ class: `${s}-ellipsis-text`
2622
+ }, [m]), De = () => B.tooltip === !1 || Z(B.tooltip) && Ie < se && se > 0 ? $e : c(me, Q({
2623
+ title: m,
2624
+ getPopupContainer: (Me) => {
2625
+ var xt;
2626
+ return Ve ?? ((xt = Me == null ? void 0 : Me.parentNode) == null ? void 0 : xt.parentNode);
2602
2627
  }
2603
- }, J(B.tooltip) ? B.tooltip : {}, {
2628
+ }, Z(B.tooltip) ? B.tooltip : {}, {
2604
2629
  destroyTooltipOnHide: !0
2605
- }), Ea($e) ? $e : {
2630
+ }), Ma($e) ? $e : {
2606
2631
  default: () => [$e]
2607
2632
  });
2608
- if (E = c("div", {
2609
- class: `${i}-ellipsis ${(D == null ? void 0 : D.class) ?? ""}`,
2633
+ if (N = c("div", {
2634
+ class: `${s}-ellipsis ${(E == null ? void 0 : E.class) ?? ""}`,
2610
2635
  style: {
2611
- "-webkit-line-clamp": be
2636
+ "-webkit-line-clamp": xe
2612
2637
  }
2613
- }, [Ee()]), B.copyable) {
2614
- const De = typeof B.copyText == "function" ? (ae = B.copyText) == null ? void 0 : ae.call(B, B) : B.copyText || M;
2615
- E = c("div", {
2616
- class: `${i}-copyable`
2638
+ }, [De()]), B.copyable) {
2639
+ const Me = typeof B.copyText == "function" ? (ie = B.copyText) == null ? void 0 : ie.call(B, B) : B.copyText || D;
2640
+ N = c("div", {
2641
+ class: `${s}-copyable`
2617
2642
  }, [c("div", {
2618
- class: `${i}-ellipsis ${(D == null ? void 0 : D.class) ?? ""}`,
2643
+ class: `${s}-ellipsis ${(E == null ? void 0 : E.class) ?? ""}`,
2619
2644
  style: {
2620
- "-webkit-line-clamp": be
2645
+ "-webkit-line-clamp": xe
2621
2646
  }
2622
- }, [Ee()]), c(Ol, {
2623
- class: `${i}-copyable-icon`,
2647
+ }, [De()]), c(Ol, {
2648
+ class: `${s}-copyable-icon`,
2624
2649
  onClick: () => {
2625
- Na(De), Ll.success("复制成功");
2650
+ Da(Me), Wl.success("复制成功");
2626
2651
  }
2627
2652
  }, null)]);
2628
2653
  }
2629
2654
  }
2630
- return E;
2655
+ return N;
2631
2656
  };
2632
- function bt() {
2633
- var B, E, k, Q, ae;
2634
- const h = Fe(a, e, "emptyText");
2635
- if (h !== !1 && ((B = b == null ? void 0 : b.emptyText) == null ? void 0 : B.value) !== !1) {
2636
- const M = ((E = e.emptyTextProps) == null ? void 0 : E.extraProps) || {}, D = h || ((k = b == null ? void 0 : b.emptyText) == null ? void 0 : k.value), be = Z(D), ne = be ? kt(D, M) : Bt(D || []);
2657
+ function Ct() {
2658
+ var B, N, O, H, ie;
2659
+ const m = ke(l, e, "emptyText");
2660
+ if (m !== !1 && ((B = b == null ? void 0 : b.emptyText) == null ? void 0 : B.value) !== !1) {
2661
+ const D = ((N = e.emptyTextProps) == null ? void 0 : N.extraProps) || {}, E = m || ((O = b == null ? void 0 : b.emptyText) == null ? void 0 : O.value), xe = le(E), se = xe ? Pt(E, D) : Rt(E || []);
2637
2662
  return c("div", {
2638
- class: Se(`${i}-empty-text`, m.value, (Q = e.emptyTextProps) == null ? void 0 : Q.class),
2639
- style: (ae = e.emptyTextProps) == null ? void 0 : ae.style
2640
- }, [be ? ne : ue(ne) ? ne.map((Re) => it(Re, M)) : c(Wl, null, null)]);
2663
+ class: pe(`${s}-empty-text`, v.value, (H = e.emptyTextProps) == null ? void 0 : H.class),
2664
+ style: (ie = e.emptyTextProps) == null ? void 0 : ie.style
2665
+ }, [xe ? se : oe(se) ? se.map((Ie) => st(Ie, D)) : c(Vl, null, null)]);
2641
2666
  }
2642
2667
  return null;
2643
2668
  }
2644
2669
  const tl = () => {
2645
- var $;
2646
- const h = Ft(a, e, "customRender");
2647
- if (h) {
2648
- if (($ = je.value) != null && $.length) {
2649
- const B = ie(C(je));
2650
- return h == null ? void 0 : h({
2670
+ var T;
2671
+ const m = It(l, e, "customRender");
2672
+ if (m) {
2673
+ if ((T = Ne.value) != null && T.length) {
2674
+ const B = re(C(Ne));
2675
+ return m == null ? void 0 : m({
2651
2676
  dataSource: B,
2652
- currentData: ja(B, t.value)
2677
+ currentData: Ea(B, t.value)
2653
2678
  });
2654
2679
  }
2655
- return bt();
2680
+ return Ct();
2656
2681
  }
2657
- return c(_e, null, null);
2658
- }, ll = (h) => {
2659
- var k, Q;
2660
- const $ = Fe(a, e, "headerTitle"), B = Fe(a, e, "titleTip"), E = Fe(a, e, "toolBarBtn");
2661
- return c(fa, {
2662
- headerTitle: $,
2682
+ return c(qe, null, null);
2683
+ }, ll = (m) => {
2684
+ var O, H;
2685
+ const T = ke(l, e, "headerTitle"), B = ke(l, e, "titleTip"), N = ke(l, e, "toolBarBtn");
2686
+ return c(ma, {
2687
+ headerTitle: T,
2663
2688
  titleTip: B,
2664
2689
  titleTipText: e.titleTipText,
2665
- options: se(Ne.value) ? Ne.value : {
2666
- ...Ne.value,
2667
- setting: h ? !1 : (k = Ne.value) == null ? void 0 : k.setting,
2668
- density: h ? !1 : (Q = Ne.value) == null ? void 0 : Q.density
2690
+ options: ne(Ee.value) ? Ee.value : {
2691
+ ...Ee.value,
2692
+ setting: m ? !1 : (O = Ee.value) == null ? void 0 : O.setting,
2693
+ density: m ? !1 : (H = Ee.value) == null ? void 0 : H.density
2669
2694
  },
2670
- settingExtra: Fe(a, e, "settingExtra"),
2671
- optionsExtra: Fe(a, e, "optionsExtra"),
2672
- toolBarBtn: E
2695
+ settingExtra: ke(l, e, "settingExtra"),
2696
+ optionsExtra: ke(l, e, "optionsExtra"),
2697
+ toolBarBtn: N
2673
2698
  }, null);
2674
2699
  };
2675
- return Gl({
2676
- tableSize: re,
2677
- columns: v,
2678
- cacheColumns: G,
2679
- isMobile: R,
2680
- searchConfig: L,
2681
- manualSearch: W,
2682
- searchActions: K,
2700
+ return Ql({
2701
+ tableSize: ee,
2702
+ columns: f,
2703
+ cacheColumns: A,
2704
+ isMobile: F,
2705
+ searchConfig: W,
2706
+ manualSearch: Y,
2707
+ searchActions: ue,
2683
2708
  action: {
2684
- setTableSize: Oe,
2685
- reload: (h) => Pe(h),
2709
+ setTableSize: Fe,
2710
+ reload: (m) => je(m),
2686
2711
  toggle: y
2687
2712
  },
2688
2713
  settingsAction: {
2689
- autoScroll: ce(e, "autoScroll"),
2690
- columnsMap: ee,
2691
- operationType: Le,
2692
- setColumnsMap: ke,
2693
- sortKeyColumns: te,
2694
- cacheColumnsMap: ge,
2695
- setSortKeyColumns: Y
2714
+ autoScroll: fe(e, "autoScroll"),
2715
+ columnsMap: J,
2716
+ operationType: ye,
2717
+ setColumnsMap: We,
2718
+ sortKeyColumns: Pe,
2719
+ cacheColumnsMap: ae,
2720
+ setSortKeyColumns: be
2696
2721
  },
2697
- setPagination: F,
2698
- changeColumns: pe,
2699
- slots: a
2700
- }), s({
2722
+ setPagination: R,
2723
+ changeColumns: X,
2724
+ slots: l
2725
+ }), o({
2701
2726
  formRef: () => ({
2702
- getFormState: () => C(U),
2727
+ getFormState: () => C(Ce),
2703
2728
  getFormInnerState: () => {
2704
- var h;
2705
- return ((h = n.value) == null ? void 0 : h.getFormState()) || {};
2729
+ var m;
2730
+ return ((m = n.value) == null ? void 0 : m.getFormState()) || {};
2706
2731
  },
2707
- restFormState: (h) => {
2708
- var $;
2709
- r.value = !0, h && (h == null || h()), ($ = n.value) == null || $.resetForm(!1), r.value = !1;
2732
+ restFormState: (m) => {
2733
+ var T;
2734
+ r.value = !0, m && (m == null || m()), (T = n.value) == null || T.resetForm(!1), r.value = !1;
2710
2735
  }
2711
2736
  }),
2712
2737
  actionRef: () => ({
2713
- loading: oe,
2714
- dataSource: je,
2738
+ loading: ce,
2739
+ dataSource: Ne,
2715
2740
  pageState: g,
2716
2741
  pagination: t.value,
2717
- selectedKeys: w(() => ot.value),
2742
+ selectedKeys: w(() => rt.value),
2718
2743
  selectedItems: w(() => Yt.value),
2719
2744
  rowsSelection: {
2720
2745
  clear: Wt,
2721
- select: rt,
2722
- remove: ft,
2723
- sync: dt,
2724
- selectAll: ct
2746
+ select: ct,
2747
+ remove: ht,
2748
+ sync: ft,
2749
+ selectAll: dt
2725
2750
  },
2726
- reload: Pe,
2727
- getLoadingStatus: () => C(H),
2728
- reloadAndReset: async (h) => {
2729
- var $, B, E;
2730
- r.value = !0, F({
2751
+ reload: je,
2752
+ getLoadingStatus: () => C(K),
2753
+ reloadAndReset: async (m) => {
2754
+ var T, B, N;
2755
+ r.value = !0, R({
2731
2756
  current: 1,
2732
2757
  pageSize: (g == null ? void 0 : g.pageSize) || 10
2733
- }), 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)), (E = n.value) == null || E.resetForm(!1), r.value = !1;
2758
+ }), m != null && m.callBack && (m != null && m.wait ? await ((T = m == null ? void 0 : m.callBack) == null ? void 0 : T.call(m)) : (B = m == null ? void 0 : m.callBack) == null || B.call(m)), (N = n.value) == null || N.resetForm(!1), r.value = !1;
2734
2759
  },
2735
- reSetDataList: Vt,
2736
- setPageAndReload: yt,
2737
- setPagination: F,
2738
- setData: Gt,
2739
- setLoading: le
2760
+ reSetDataList: Ht,
2761
+ setPageAndReload: bt,
2762
+ setPagination: R,
2763
+ setDataValue: Gt,
2764
+ setLoading: Re
2740
2765
  })
2741
2766
  }), () => {
2742
- var $, B;
2743
- const h = Ie(e.customRender || a.customRender);
2767
+ var T, B;
2768
+ const m = Oe(e.customRender || l.customRender);
2744
2769
  return d(c("div", {
2745
- ref: u,
2746
- class: Se([{
2747
- [`${m.value}`]: !0,
2748
- [`${i}`]: !0,
2749
- [`${o.class}`]: o.class,
2750
- [`${i}-no-scroll`]: !Object.keys(C(P) || {}).length,
2751
- [`${i}-table-tree`]: Qt.value,
2752
- [`${i}-full-screen`]: T.value
2770
+ ref: i,
2771
+ class: pe([{
2772
+ [`${v.value}`]: !0,
2773
+ [`${s}`]: !0,
2774
+ [`${u.class}`]: u.class,
2775
+ [`${s}-beautify-scroll`]: ne(e.useDefaultScrollStyle) ? !e.useDefaultScrollStyle : !0,
2776
+ [`${s}-no-scroll`]: !Object.keys(C(P) || {}).length,
2777
+ [`${s}-table-tree`]: Qt.value,
2778
+ [`${s}-full-screen`]: p.value
2753
2779
  }]),
2754
- style: o.style
2780
+ style: u.style
2755
2781
  }, [c("div", {
2756
- class: [`${i}-content`, m.value]
2757
- }, [(ye.value.length > 0 || Ie(a.search)) && e.search !== !1 && c(Mt, {
2782
+ class: [`${s}-content`, v.value]
2783
+ }, [(z.value.length > 0 || Oe(l.search)) && e.search !== !1 && c(At, {
2758
2784
  ref: n,
2759
2785
  modal: e.modalScroll,
2760
2786
  cardBordered: e.cardBordered,
2761
- searchMap: ye.value,
2762
- prefixCls: i,
2763
- loading: !!C(H),
2787
+ searchMap: z.value,
2788
+ prefixCls: s,
2789
+ loading: !!C(K),
2764
2790
  onSearch: qt,
2765
- defaultParams: zt
2791
+ defaultParams: te
2766
2792
  }, {
2767
- default: a.search ? () => {
2768
- var E;
2769
- return (E = a.search) == null ? void 0 : E.call(a);
2793
+ default: l.search ? () => {
2794
+ var N;
2795
+ return (N = l.search) == null ? void 0 : N.call(l);
2770
2796
  } : null
2771
2797
  }), c("div", {
2772
- class: Se(m.value, `${i}-card`, e.cardBordered && `${i}-card-border`)
2773
- }, [ll(h), h ? c(nt, mt.value, {
2798
+ class: pe(v.value, `${s}-card`, e.cardBordered && `${s}-card-border`)
2799
+ }, [ll(m), m ? c(ut, vt.value, {
2774
2800
  default: () => {
2775
- var E, k, Q;
2801
+ var N, O, H;
2776
2802
  return [c("div", {
2777
- class: `${i}-wrapper ${m.value}`
2803
+ class: `${s}-wrapper ${v.value}`
2778
2804
  }, [c("div", {
2779
- class: Se(`${i}-list`, m.value, (E = e.tableProps) == null ? void 0 : E.class),
2780
- style: (k = e.tableProps) == null ? void 0 : k.style
2781
- }, [tl()]), e.pagination !== !1 && ((Q = je.value) == null ? void 0 : Q.length) > 0 && c(zl, _({
2805
+ class: pe(`${s}-list`, v.value, (N = e.tableProps) == null ? void 0 : N.class),
2806
+ style: (O = e.tableProps) == null ? void 0 : O.style
2807
+ }, [tl()]), e.pagination !== !1 && ((H = Ne.value) == null ? void 0 : H.length) > 0 && c(Yl, Q({
2782
2808
  class: {
2783
- [`${i}-pagination ${m.value}`]: !0,
2784
- [`${i}-pagination-${vt.value} ${m.value}`]: !!vt.value
2809
+ [`${s}-pagination ${v.value}`]: !0,
2810
+ [`${s}-pagination-${gt.value} ${v.value}`]: !!gt.value
2785
2811
  }
2786
2812
  }, Be(C(t)), {
2787
2813
  onChange: Xt
2788
2814
  }), null)])];
2789
2815
  }
2790
- }) : c(Yl, _(xt(e, Object.keys(Dt)), _t.value, {
2791
- style: ($ = e.tableProps) == null ? void 0 : $.style,
2816
+ }) : c(Ll, Q(St(e, Object.keys(Mt)), _t.value, {
2817
+ style: (T = e.tableProps) == null ? void 0 : T.style,
2792
2818
  class: (B = e.tableProps) == null ? void 0 : B.class,
2793
- loading: mt.value,
2794
- rowKey: (E) => E[e.rowKey],
2795
- transformCellText: (E) => {
2796
- var D, be, ne, Re, We;
2797
- e.transformCellText && typeof e.transformCellText && ((D = e.transformCellText) == null || D.call(e, E));
2819
+ loading: vt.value,
2820
+ rowKey: (N) => N[e.rowKey],
2821
+ transformCellText: (N) => {
2822
+ var E, xe, se, Ie, Ve;
2823
+ e.transformCellText && typeof e.transformCellText && ((E = e.transformCellText) == null || E.call(e, N));
2798
2824
  const {
2799
- column: k
2800
- } = E;
2801
- if (!k) return E.text;
2802
- const Q = (k == null ? void 0 : k.key) || (k == null ? void 0 : k.dataIndex);
2803
- let ae = !0, M = E.text;
2804
- if (ue(M))
2805
- if (M.length === 0 || M.length === 1 && !Z(M[0])) {
2806
- M = M == null ? void 0 : M[0];
2807
- const $e = rl(M, (k == null ? void 0 : k.columnEmptyText) || (e == null ? void 0 : e.columnEmptyText) || "");
2808
- ae = $e.success, M = Pa($e.value, (k == null ? void 0 : k.valueType) || ((ne = (be = e.columns) == null ? void 0 : be.find((Ee) => (Ee.key || Ee.dataIndex) === Q)) == null ? void 0 : ne.valueType), i, m.value);
2809
- } else ((Re = M[0]) == null ? void 0 : Re.type) === "template" && (M = (We = M[0]) == null ? void 0 : We.children);
2810
- return k != null && k.ellipsis ? el(M, ae, k) : M;
2825
+ column: O
2826
+ } = N;
2827
+ if (!O) return N.text;
2828
+ const H = (O == null ? void 0 : O.key) || (O == null ? void 0 : O.dataIndex);
2829
+ let ie = !0, D = N.text;
2830
+ if (oe(D))
2831
+ if (D.length === 0 || D.length === 1 && !le(D[0])) {
2832
+ D = D == null ? void 0 : D[0];
2833
+ const $e = cl(D, (O == null ? void 0 : O.columnEmptyText) || (e == null ? void 0 : e.columnEmptyText) || "");
2834
+ ie = $e.success, D = Na($e.value, (O == null ? void 0 : O.valueType) || ((se = (xe = e.columns) == null ? void 0 : xe.find((De) => (De.key || De.dataIndex) === H)) == null ? void 0 : se.valueType), s, v.value);
2835
+ } else ((Ie = D[0]) == null ? void 0 : Ie.type) === "template" && (D = (Ve = D[0]) == null ? void 0 : Ve.children);
2836
+ return O != null && O.ellipsis ? el(D, ie, O) : D;
2811
2837
  },
2812
2838
  rowSelection: e.rowSelection ? {
2813
- ...qe(e.rowSelection, ["onSelect", "onSelectAll", "onChange", "selectedRowKeys"]),
2814
- selectedRowKeys: ot.value,
2815
- onSelect: rt,
2816
- onSelectAll: ct,
2839
+ ...Xe(e.rowSelection, ["onSelect", "onSelectAll", "onChange", "selectedRowKeys"]),
2840
+ selectedRowKeys: rt.value,
2841
+ onSelect: ct,
2842
+ onSelectAll: dt,
2817
2843
  onChange: Lt
2818
2844
  } : void 0,
2819
- onChange: yt,
2845
+ onChange: bt,
2820
2846
  onExpandedRowsChange: Ut,
2821
2847
  onExpand: Jt,
2822
- onResizeColumn: (E, k) => Zt(E, k)
2848
+ onResizeColumn: (N, O) => Zt(N, O)
2823
2849
  }), {
2824
- ...a,
2825
- emptyText: () => bt()
2850
+ ...l,
2851
+ emptyText: () => Ct()
2826
2852
  })])])]));
2827
2853
  };
2828
2854
  }
2829
2855
  });
2830
- lt.install = (e) => (e.component(lt.name, lt), e);
2856
+ at.install = (e) => (e.component(at.name, at), e);
2831
2857
  export {
2832
- lt as GProTable,
2833
- lt as default,
2834
- de as proTableProps,
2835
- Ua as useTable
2858
+ at as GProTable,
2859
+ at as default,
2860
+ he as proTableProps,
2861
+ Za as useTable
2836
2862
  };