@done-coding/admin-core 0.5.0 → 0.5.1-alpha.0

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.
Files changed (123) hide show
  1. package/es/bridge/index.mjs +30 -42
  2. package/es/components/app-layout/AppHeader.vue.mjs +2 -2
  3. package/es/components/app-layout/AppHeader.vue2.mjs +16 -19
  4. package/es/components/data-view/DataListView.vue.mjs +2 -2
  5. package/es/components/data-view/DataListView.vue2.mjs +63 -52
  6. package/es/components/data-view/utils.mjs +36 -0
  7. package/es/components/display/TabsMain.vue.mjs +1 -1
  8. package/es/components/list-page/ListPage.vue.mjs +2 -2
  9. package/es/components/list-page/ListPage.vue2.mjs +44 -44
  10. package/es/components/misc/ActionConfirm.vue2.mjs +16 -16
  11. package/es/components/modal/ConfirmModal.vue.mjs +3 -3
  12. package/es/components/modal/DetailModal.vue.mjs +10 -10
  13. package/es/components/table/TableMain.vue.mjs +3 -3
  14. package/es/components/table/TableMain.vue2.mjs +167 -177
  15. package/es/components/table/TableToolbar.vue.mjs +3 -3
  16. package/es/components/table/TableToolbar.vue2.mjs +8 -4
  17. package/es/index.mjs +150 -180
  18. package/es/style.css +1 -1
  19. package/package.json +6 -5
  20. package/types/bridge/index.d.ts +3 -6
  21. package/types/bridge/route.d.ts +0 -1
  22. package/types/components/app-layout/AppBody.vue.d.ts +14 -34
  23. package/types/components/app-layout/AppBreadcrumb.vue.d.ts +6 -19
  24. package/types/components/app-layout/AppFooter.vue.d.ts +1 -1
  25. package/types/components/app-layout/AppHeader.vue.d.ts +15 -39
  26. package/types/components/app-layout/AppLayout.vue.d.ts +17 -50
  27. package/types/components/app-layout/AppPage.vue.d.ts +14 -39
  28. package/types/components/app-layout/AppSidebar.vue.d.ts +15 -37
  29. package/types/components/app-layout/index.d.ts +1 -19
  30. package/types/components/app-layout/types.d.ts +0 -1
  31. package/types/components/data-view/DataListView.vue.d.ts +9 -9
  32. package/types/components/data-view/DataListViewItem.vue.d.ts +19 -17
  33. package/types/components/data-view/index.d.ts +0 -1
  34. package/types/components/data-view/types.d.ts +9 -18
  35. package/types/components/data-view/utils.d.ts +5 -0
  36. package/types/components/display/ActionBtnGroup.vue.d.ts +8 -6
  37. package/types/components/display/HeightProvider.vue.d.ts +15 -31
  38. package/types/components/display/TabsHeader.vue.d.ts +27 -34
  39. package/types/components/display/TabsMain.vue.d.ts +14 -75
  40. package/types/components/display/TabsNaturalFlow.vue.d.ts +11 -5
  41. package/types/components/display/TabsRefineFlow.vue.d.ts +13 -31
  42. package/types/components/display/WatchSize.vue.d.ts +20 -32
  43. package/types/components/display/index.d.ts +0 -3
  44. package/types/components/display/types.d.ts +1 -2
  45. package/types/components/form/FormItem.vue.d.ts +208 -33
  46. package/types/components/form/FormMain.vue.d.ts +6 -7
  47. package/types/components/form/FormRadioGroup.vue.d.ts +14 -31
  48. package/types/components/form/FormSearch.vue.d.ts +5 -6
  49. package/types/components/form/FormSelect.vue.d.ts +19 -40
  50. package/types/components/form/FormTree.vue.d.ts +2037 -32
  51. package/types/components/form/FormVerifyCode.vue.d.ts +6 -6
  52. package/types/components/form/FormVerifyImage.vue.d.ts +6 -6
  53. package/types/components/form/form-search-utils.d.ts +0 -1
  54. package/types/components/form/index.d.ts +0 -3
  55. package/types/components/form/types.d.ts +0 -1
  56. package/types/components/form/utils.d.ts +0 -1
  57. package/types/components/list-page/ListPage.vue.d.ts +32 -33
  58. package/types/components/list-page/index.d.ts +0 -3
  59. package/types/components/list-page/types.d.ts +0 -1
  60. package/types/components/menu/MenuItemSub.vue.d.ts +3 -15
  61. package/types/components/menu/MenuTree.vue.d.ts +117 -19
  62. package/types/components/menu/index.d.ts +0 -3
  63. package/types/components/misc/ActionBtn.vue.d.ts +10 -11
  64. package/types/components/misc/ActionConfirm.vue.d.ts +21 -60
  65. package/types/components/misc/AutoRefresh.vue.d.ts +18 -24
  66. package/types/components/misc/TriggerAutoImport.vue.d.ts +8 -2
  67. package/types/components/misc/index.d.ts +4 -14
  68. package/types/components/misc/types.d.ts +0 -1
  69. package/types/components/modal/DetailModal.vue.d.ts +5 -6
  70. package/types/components/modal/ModalPorter.vue.d.ts +13 -18
  71. package/types/components/modal/ModalShelf.vue.d.ts +13 -18
  72. package/types/components/modal/index.d.ts +0 -4
  73. package/types/components/modal/modal-shelf-core.d.ts +0 -1
  74. package/types/components/modal/modal-shelf-hierarchy.d.ts +0 -1
  75. package/types/components/modal/modal-shelf-types.d.ts +0 -1
  76. package/types/components/modal/types.d.ts +0 -1
  77. package/types/components/panel/PanelEditSwitch.vue.d.ts +17 -20
  78. package/types/components/panel/PanelItem.vue.d.ts +7 -16
  79. package/types/components/panel/PanelMain.vue.d.ts +5 -6
  80. package/types/components/panel/index.d.ts +0 -4
  81. package/types/components/panel/types.d.ts +0 -1
  82. package/types/components/table/TableMain.vue.d.ts +12 -12
  83. package/types/components/table/TableToolbar.vue.d.ts +17 -108
  84. package/types/components/table/ToolbarButtons.vue.d.ts +15 -17
  85. package/types/components/table/index.d.ts +0 -3
  86. package/types/components/table/types.d.ts +59 -19
  87. package/types/config/list-model.d.ts +0 -1
  88. package/types/helpers/form.d.ts +0 -1
  89. package/types/helpers/index.d.ts +0 -10
  90. package/types/helpers/list-helper.d.ts +0 -1
  91. package/types/hooks/menus-dispatch.d.ts +0 -1
  92. package/types/hooks/use-channel-viewport-height.d.ts +0 -1
  93. package/types/index.d.ts +0 -13
  94. package/types/inject/key.d.ts +0 -1
  95. package/types/router/guard/index.d.ts +0 -1
  96. package/types/router/guard/login.d.ts +0 -1
  97. package/types/router/guard/permission.d.ts +0 -1
  98. package/types/router/guard/types.d.ts +0 -1
  99. package/types/store/app.d.ts +1 -2
  100. package/types/store/router-permission.d.ts +0 -1
  101. package/types/store/user.d.ts +0 -1
  102. package/types/types/route.d.ts +0 -1
  103. package/types/utils/export.d.ts +11 -10
  104. package/types/utils/router.d.ts +0 -1
  105. package/es/components/app-layout/index.mjs +0 -32
  106. package/es/components/display/index.mjs +0 -18
  107. package/es/components/form/index.mjs +0 -32
  108. package/es/components/list-page/index.mjs +0 -14
  109. package/es/components/menu/index.mjs +0 -12
  110. package/es/components/misc/ActionButton.vue.mjs +0 -52
  111. package/es/components/misc/ActionButton.vue2.mjs +0 -4
  112. package/es/components/misc/ActionButtonDanger.vue.mjs +0 -32
  113. package/es/components/misc/ActionButtonDanger.vue2.mjs +0 -4
  114. package/es/components/misc/ActionButtonWarn.vue.mjs +0 -32
  115. package/es/components/misc/ActionButtonWarn.vue2.mjs +0 -4
  116. package/es/components/misc/index.mjs +0 -32
  117. package/es/components/modal/index.mjs +0 -23
  118. package/es/components/panel/index.mjs +0 -20
  119. package/es/components/table/index.mjs +0 -14
  120. package/types/components/misc/ActionButton.vue.d.ts +0 -24
  121. package/types/components/misc/ActionButtonDanger.vue.d.ts +0 -19
  122. package/types/components/misc/ActionButtonWarn.vue.d.ts +0 -19
  123. package/types/components/modal/ConfirmModal.vue.d.ts +0 -124
@@ -1,23 +1,23 @@
1
- import { ElTable as he, ElTableColumn as ve, ElEmpty as ye, ElPagination as Ce } from "element-plus/es";
1
+ import { ElTableColumn as me, ElEmpty as de, ElPagination as he } from "element-plus/es";
2
2
  import "element-plus/es/components/base/style/css";
3
3
  import "element-plus/es/components/pagination/style/css";
4
- import "element-plus/es/components/table/style/css";
5
4
  import "element-plus/es/components/empty/style/css";
6
5
  import "element-plus/es/components/table-column/style/css";
7
- import { defineComponent as Se, useCssVars as be, useModel as we, useAttrs as xe, ref as c, computed as g, shallowRef as Y, onMounted as Ee, onActivated as Pe, watch as m, openBlock as i, createElementBlock as b, createBlock as p, unref as r, withCtx as h, createVNode as F, mergeProps as d, createCommentVNode as ke, Fragment as k, renderList as He, createSlots as Te, renderSlot as V, resolveDynamicComponent as G, createTextVNode as I, toDisplayString as U, normalizeProps as ze, guardReactiveProps as Re, withDirectives as Ve, createElementVNode as Ie, isRef as Z, vShow as _e, mergeModels as Q } from "vue";
8
- import W from "lodash/cloneDeep";
9
- import X from "lodash/omit";
10
- import ee from "lodash/set";
11
- import te from "lodash/get";
12
- import Ae from "./TableToolbar.vue.mjs";
13
- import Le from "../display/WatchSize.vue.mjs";
14
- import Ke from "../data-view/DataListView.vue.mjs";
15
- import { pickExportColumns as Ne } from "../../utils/export.mjs";
6
+ import { defineComponent as ve, useCssVars as ye, useModel as Ce, useAttrs as Se, ref as f, computed as p, markRaw as J, shallowRef as be, onMounted as we, onActivated as xe, watch as m, openBlock as s, createElementBlock as S, createBlock as d, unref as n, withCtx as h, createVNode as q, mergeProps as g, createCommentVNode as Ee, resolveDynamicComponent as I, Fragment as P, renderList as Pe, createSlots as Re, renderSlot as _, createTextVNode as k, toDisplayString as Y, normalizeProps as Te, guardReactiveProps as ze, withDirectives as Ie, createElementVNode as _e, isRef as D, vShow as ke, mergeModels as F } from "vue";
7
+ import G from "lodash/cloneDeep";
8
+ import U from "lodash/omit";
9
+ import Z from "lodash/set";
10
+ import Q from "lodash/get";
11
+ import He from "./TableToolbar.vue.mjs";
12
+ import Ae from "../display/WatchSize.vue.mjs";
13
+ import Ve from "../data-view/DataListView.vue.mjs";
14
+ import { ElTable as Ne } from "element-plus";
15
+ import { pickExportColumns as Le } from "../../utils/export.mjs";
16
16
  import { useChannelViewportHeight as Me } from "../../hooks/use-channel-viewport-height.mjs";
17
- import { APP_API_LIST_MODEL_KEY_CONFIG as H } from "../../config/list-model.mjs";
18
- const Oe = { class: "table-main" }, Be = { class: "table-main-pagination" }, nt = /* @__PURE__ */ Se({
17
+ import { APP_API_LIST_MODEL_KEY_CONFIG as R } from "../../config/list-model.mjs";
18
+ const Oe = { class: "table-main" }, Ke = { class: "table-main-pagination" }, ot = /* @__PURE__ */ ve({
19
19
  __name: "TableMain",
20
- props: /* @__PURE__ */ Q({
20
+ props: /* @__PURE__ */ F({
21
21
  showPager: { type: Boolean, default: !0 },
22
22
  customView: { type: Boolean, default: !1 },
23
23
  showToolbar: { type: Boolean, default: !0 },
@@ -42,216 +42,206 @@ const Oe = { class: "table-main" }, Be = { class: "table-main-pagination" }, nt
42
42
  isAutoRefresh: { type: Boolean },
43
43
  isAutoRefreshModifiers: {}
44
44
  }),
45
- emits: /* @__PURE__ */ Q(["pageChange", "pageSizeChange", "dataChange", "loadingChange", "pageInfoChange"], ["update:isAutoRefresh"]),
46
- setup(l, { expose: ae, emit: oe }) {
47
- be((e) => ({
48
- v028010cb: e.headerColor
45
+ emits: /* @__PURE__ */ F(["pageChange", "pageSizeChange", "dataChange", "loadingChange", "pageInfoChange"], ["update:isAutoRefresh"]),
46
+ setup(u, { expose: W, emit: X }) {
47
+ ye((e) => ({
48
+ v9176f014: e.headerColor
49
49
  }));
50
- const o = l, v = oe, _ = we(l, "isAutoRefresh"), ne = xe(), y = c([]), w = c(0), u = c(0), s = c(1), C = c(!1), T = c(!1), z = c([]), re = g(() => ({
51
- columns: Ne(o.columns),
52
- selectedList: z.value,
53
- currentPageList: y.value,
54
- api: o.api,
55
- query: o.query || {},
56
- total: w.value,
57
- hasSelection: o.columns.some((e) => e.type === "selection")
58
- })), A = c(0), le = (e) => {
59
- A.value = e;
60
- }, R = Y(), L = Y(), ie = g(
61
- () => o.columns.some((e) => e.type === "selection")
62
- ), se = (e) => {
63
- var t, n;
64
- z.value = e, (n = (t = o.tableProps) == null ? void 0 : t.onSelectionChange) == null || n.call(t, e);
65
- }, { viewportHeightFinal: ue } = Me(o, {
50
+ const a = u, v = X, H = Ce(u, "isAutoRefresh"), ee = Se(), b = f([]), w = f(0), i = f(0), l = f(1), y = f(!1), T = f(!1), A = f([]), te = p(
51
+ () => ({
52
+ columns: Le(a.columns),
53
+ selectedList: A.value,
54
+ currentPageList: b.value,
55
+ api: a.api,
56
+ query: a.query,
57
+ total: w.value,
58
+ hasSelection: a.columns.some((e) => e.type === "selection")
59
+ })
60
+ ), V = f(0), ae = (e) => {
61
+ V.value = e;
62
+ }, oe = p(
63
+ () => a.customView ? J(Ve) : J(Ne)
64
+ ), z = be(), re = p(
65
+ () => a.columns.some((e) => e.type === "selection")
66
+ ), { viewportHeightFinal: ne } = Me(a, {
66
67
  fallback: 500
67
- }), K = g(() => o.showPager ? 35 : 0), N = g(
68
- () => o.showToolbar ? A.value : 0
69
- ), M = g(() => {
70
- const { maxHeight: e, refine: t, dataViewMaxHeightMinValue: n } = o;
68
+ }), N = p(() => a.showPager ? 35 : 0), L = p(
69
+ () => a.showToolbar ? V.value : 0
70
+ ), le = p(() => {
71
+ const { maxHeight: e, refine: t, dataViewMaxHeightMinValue: r } = a;
71
72
  return e ? Math.max(
72
- e - K.value - N.value,
73
- n
73
+ e - N.value - L.value,
74
+ r
74
75
  ) : t ? Math.max(
75
- ue.value - K.value - N.value - o.refineReduceHeight,
76
- n
76
+ ne.value - N.value - L.value - a.refineReduceHeight,
77
+ r
77
78
  ) : void 0;
78
- }), x = g(() => {
79
- const e = W(o.query || {});
80
- return ee(e, H.PAGE_SIZE_KEY, u.value), ee(
79
+ }), x = p(() => {
80
+ const e = G(a.query || {});
81
+ return Z(e, R.PAGE_SIZE_KEY, i.value), Z(
81
82
  e,
82
- H.CURRENT_PAGE_KEY,
83
- s.value
83
+ R.CURRENT_PAGE_KEY,
84
+ l.value
84
85
  ), e;
85
- }), ce = g(() => {
86
- var t;
87
- const e = (t = o.tableProps) == null ? void 0 : t.onSelectionChange;
88
- return {
89
- ...o.tableProps,
90
- ...ne,
91
- /** 合并内部选中存储与外部 onSelectionChange */
92
- onSelectionChange: (n) => {
93
- z.value = n, e == null || e(n);
94
- }
95
- };
96
- }), O = (e, t = !0) => {
97
- const n = JSON.stringify(e) === JSON.stringify(x.value);
98
- return !n && t && console.warn(
86
+ }), se = p(() => ({
87
+ ...a.tableProps,
88
+ ...ee,
89
+ // customView 下,需要手动处理 selectable
90
+ ...a.customView ? {
91
+ selectable: re.value,
92
+ columns: a.columns
93
+ } : {}
94
+ })), ie = (e) => {
95
+ var r;
96
+ const t = (r = a.tableProps) == null ? void 0 : r.onSelectionChange;
97
+ A.value = e, t == null || t(e);
98
+ }, M = (e, t = !0) => {
99
+ const r = JSON.stringify(e) === JSON.stringify(x.value);
100
+ return !r && t && console.warn(
99
101
  `同一地方 并发请求 参数冰花 当前不是最新的参数 丢弃结果 ${JSON.stringify(
100
102
  e
101
103
  )} => ${JSON.stringify(x.value)}`
102
- ), n;
103
- }, B = (e = !1) => {
104
- var n, E;
105
- if (!u.value) return;
106
- C.value ? console.warn("请求并发") : C.value = !0, e || (T.value = !0), o.customView ? (n = L.value) == null || n.clearSelection() : (E = R.value) == null || E.clearSelection();
107
- const t = W(x.value);
108
- return o.api(t).then((P) => {
109
- O(t, !1) && (y.value = te(
110
- P,
111
- H.LIST_KEY
112
- ), w.value = te(
113
- P,
114
- H.TOTAL_KEY
104
+ ), r;
105
+ }, O = (e = !1) => {
106
+ var r;
107
+ if (!i.value) return;
108
+ y.value ? console.warn("请求并发") : y.value = !0, e || (T.value = !0), (r = z.value) == null || r.clearSelection();
109
+ const t = G(x.value);
110
+ return a.api(t).then((E) => {
111
+ M(t, !1) && (b.value = Q(
112
+ E,
113
+ R.LIST_KEY
114
+ ), w.value = Q(
115
+ E,
116
+ R.TOTAL_KEY
115
117
  ), v("pageInfoChange", {
116
- pageSize: u.value,
117
- currentPage: s.value,
118
+ pageSize: i.value,
119
+ currentPage: l.value,
118
120
  total: w.value
119
121
  }));
120
122
  }).finally(() => {
121
- O(t) && (C.value = !1, T.value = !1);
123
+ M(t) && (y.value = !1, T.value = !1);
122
124
  });
123
- }, $ = async (e = !1) => {
125
+ }, K = async (e = !1) => {
124
126
  var t;
125
- return (t = B(e)) == null ? void 0 : t.catch(() => {
127
+ return (t = O(e)) == null ? void 0 : t.catch(() => {
126
128
  });
127
- }, fe = async (e = !1) => {
128
- if (s.value === 1)
129
- return $(e);
130
- s.value = 1;
131
- }, j = (e) => e, ge = (e) => e, pe = (e) => e, S = {
132
- refresh: $,
133
- reload: fe,
134
- getTableInstance: () => R.value
135
- }, J = (e, t = []) => ({
136
- ...X(e, ["render", "headerRender"].concat(t)),
137
- injectInfo: o.injectInfo || {},
138
- exposeInfo: S
139
- }), q = (e) => ({
140
- ...X(e, ["render", "headerRender"]),
141
- injectInfo: o.injectInfo || {},
142
- exposeInfo: S
143
- });
144
- ae(S);
145
- const de = (e) => {
146
- u.value = e, s.value = 1;
147
- }, D = (e) => !e || e === "expand";
148
- return Ee(() => {
149
- u.value = o.pageSizeInit, Pe(() => {
150
- S.refresh();
129
+ }, ue = async (e = !1) => {
130
+ if (l.value === 1)
131
+ return K(e);
132
+ l.value = 1;
133
+ }, fe = (e) => e, C = {
134
+ refresh: K,
135
+ reload: ue,
136
+ getTableInstance: () => z.value
137
+ }, B = (e, t = []) => ({
138
+ ...U(e, ["render", "headerRender"].concat(t)),
139
+ injectInfo: a.injectInfo || {},
140
+ exposeInfo: C
141
+ }), $ = (e) => ({
142
+ ...U(e, ["render", "headerRender"]),
143
+ injectInfo: a.injectInfo || {},
144
+ exposeInfo: C
145
+ }), pe = (e) => e;
146
+ W(C);
147
+ const ce = (e) => {
148
+ i.value = e, l.value = 1;
149
+ }, j = (e) => !e || e === "expand";
150
+ return we(() => {
151
+ i.value = a.pageSizeInit, xe(() => {
152
+ C.refresh();
151
153
  });
152
- }), m(y, (e) => {
154
+ }), m(b, (e) => {
153
155
  v("dataChange", e);
154
156
  }), m(
155
- () => o.query,
157
+ () => a.query,
156
158
  (e, t) => {
157
- JSON.stringify(e) !== JSON.stringify(t) && (s.value = 1);
159
+ JSON.stringify(e) !== JSON.stringify(t) && (l.value = 1);
158
160
  }
159
161
  ), m(
160
162
  x,
161
163
  (e, t) => {
162
- JSON.stringify(e) !== JSON.stringify(t) && B();
164
+ JSON.stringify(e) !== JSON.stringify(t) && O();
163
165
  },
164
166
  {
165
167
  immediate: !0
166
168
  }
167
169
  ), m(T, (e) => {
168
170
  v("loadingChange", e);
169
- }), m(u, (e) => {
171
+ }), m(i, (e) => {
170
172
  v("pageSizeChange", e);
171
- }), m(s, (e) => {
173
+ }), m(l, (e) => {
172
174
  v("pageChange", e);
173
175
  }), (e, t) => {
174
- const n = ve, E = ye, P = he, me = Ce;
175
- return i(), b("div", Oe, [
176
- l.showToolbar ? (i(), p(r(Le), {
176
+ const r = me, E = de, ge = he;
177
+ return s(), S("div", Oe, [
178
+ u.showToolbar ? (s(), d(n(Ae), {
177
179
  key: 0,
178
- onHeightChange: le
180
+ onHeightChange: ae
179
181
  }, {
180
182
  default: h(() => [
181
- F(Ae, d({
182
- "is-auto-refresh": _.value,
183
- "onUpdate:isAutoRefresh": t[0] || (t[0] = (a) => _.value = a),
184
- tableExpose: S,
185
- loading: r(C),
186
- exportContext: r(re),
187
- currentPage: r(s),
188
- pageSize: r(u)
189
- }, l.toolbar), null, 16, ["is-auto-refresh", "loading", "exportContext", "currentPage", "pageSize"])
183
+ q(He, g({
184
+ "is-auto-refresh": H.value,
185
+ "onUpdate:isAutoRefresh": t[0] || (t[0] = (o) => H.value = o),
186
+ tableExpose: C,
187
+ loading: n(y),
188
+ exportContext: n(te),
189
+ currentPage: n(l),
190
+ pageSize: n(i)
191
+ }, u.toolbar), null, 16, ["is-auto-refresh", "loading", "exportContext", "currentPage", "pageSize"])
190
192
  ]),
191
193
  _: 1
192
- })) : ke("", !0),
193
- l.customView ? (i(), p(r(Ke), {
194
- key: 2,
195
- ref_key: "dataListView",
196
- ref: L,
197
- data: ge(r(y)),
198
- columns: pe(l.columns),
199
- rowKey: j(l.rowKey),
200
- maxHeight: r(M),
201
- selectable: r(ie),
202
- onSelectionChange: se
203
- }, {
204
- item: h((a) => [
205
- V(e.$slots, "custom-view-item", ze(Re(a)), void 0, !0)
206
- ]),
207
- _: 3
208
- }, 8, ["data", "columns", "rowKey", "maxHeight", "selectable"])) : (i(), p(P, d({
209
- key: 1,
194
+ })) : Ee("", !0),
195
+ (s(), d(I(n(oe)), g({
210
196
  ref_key: "elTable",
211
- ref: R,
197
+ ref: z,
212
198
  class: "table-main-table",
213
199
  stripe: "",
214
200
  border: "",
215
201
  highlightCurrentRow: ""
216
- }, r(ce), {
217
- maxHeight: r(M),
218
- data: r(y),
219
- rowKey: j(l.rowKey)
202
+ }, n(se), {
203
+ maxHeight: n(le),
204
+ data: n(b),
205
+ rowKey: fe(u.rowKey),
206
+ onSelectionChange: ie
220
207
  }), {
208
+ item: h((o) => [
209
+ _(e.$slots, "custom-view-item", Te(ze(pe(o))), void 0, !0)
210
+ ]),
221
211
  empty: h(() => [
222
- r(C) ? (i(), b(k, { key: 0 }, [
223
- I("加载中...")
224
- ], 64)) : (i(), p(E, { key: 1 }))
212
+ n(y) ? (s(), S(P, { key: 0 }, [
213
+ k("加载中...")
214
+ ], 64)) : (s(), d(E, { key: 1 }))
225
215
  ]),
226
216
  default: h(() => [
227
- (i(!0), b(k, null, He(l.columns, (a) => (i(), p(n, d({
228
- key: a.columnKey || a.prop
229
- }, { ref_for: !0 }, a), Te({ _: 2 }, [
230
- D(a.type) ? {
217
+ (s(!0), S(P, null, Pe(u.columns, (o) => (s(), d(r, g({
218
+ key: o.columnKey || o.prop
219
+ }, { ref_for: !0 }, o), Re({ _: 2 }, [
220
+ j(o.type) ? {
231
221
  name: "default",
232
- fn: h((f) => [
233
- V(e.$slots, a.prop, d({ ref_for: !0 }, J(f)), () => [
234
- a.render ? (i(), p(G(a.render), d({
222
+ fn: h((c) => [
223
+ _(e.$slots, o.prop, g({ ref_for: !0 }, B(c)), () => [
224
+ o.render ? (s(), d(I(o.render), g({
235
225
  key: 0,
236
226
  ref_for: !0
237
- }, J(f, ["$index"]), {
238
- _index: f.$index
239
- }), null, 16, ["_index"])) : (i(), b(k, { key: 1 }, [
240
- I(U(f.row[a.prop]), 1)
227
+ }, B(c, ["$index"]), {
228
+ _index: c.$index
229
+ }), null, 16, ["_index"])) : (s(), S(P, { key: 1 }, [
230
+ k(Y(c.row[o.prop]), 1)
241
231
  ], 64))
242
232
  ], !0)
243
233
  ]),
244
234
  key: "0"
245
235
  } : void 0,
246
- D(a.type) ? {
236
+ j(o.type) ? {
247
237
  name: "header",
248
- fn: h((f) => [
249
- V(e.$slots, `header-${a.prop}`, d({ ref_for: !0 }, q(f)), () => [
250
- a.headerRender ? (i(), p(G(a.headerRender), d({
238
+ fn: h((c) => [
239
+ _(e.$slots, `header-${o.prop}`, g({ ref_for: !0 }, $(c)), () => [
240
+ o.headerRender ? (s(), d(I(o.headerRender), g({
251
241
  key: 0,
252
242
  ref_for: !0
253
- }, q(f)), null, 16)) : (i(), b(k, { key: 1 }, [
254
- I(U(a.label), 1)
243
+ }, $(c)), null, 16)) : (s(), S(P, { key: 1 }, [
244
+ k(Y(o.label), 1)
255
245
  ], 64))
256
246
  ], !0)
257
247
  ]),
@@ -261,26 +251,26 @@ const Oe = { class: "table-main" }, Be = { class: "table-main-pagination" }, nt
261
251
  ]),
262
252
  _: 3
263
253
  }, 16, ["maxHeight", "data", "rowKey"])),
264
- Ve(Ie("div", Be, [
265
- F(me, {
266
- "current-page": r(s),
267
- "onUpdate:currentPage": t[1] || (t[1] = (a) => Z(s) ? s.value = a : null),
268
- "page-size": r(u),
269
- "onUpdate:pageSize": t[2] || (t[2] = (a) => Z(u) ? u.value = a : null),
270
- "page-sizes": l.pageSizeOptions,
254
+ Ie(_e("div", Ke, [
255
+ q(ge, {
256
+ "current-page": n(l),
257
+ "onUpdate:currentPage": t[1] || (t[1] = (o) => D(l) ? l.value = o : null),
258
+ "page-size": n(i),
259
+ "onUpdate:pageSize": t[2] || (t[2] = (o) => D(i) ? i.value = o : null),
260
+ "page-sizes": u.pageSizeOptions,
271
261
  size: "small",
272
262
  background: "",
273
- layout: l.pageLayout,
274
- total: r(w),
275
- onSizeChange: de
263
+ layout: u.pageLayout,
264
+ total: n(w),
265
+ onSizeChange: ce
276
266
  }, null, 8, ["current-page", "page-size", "page-sizes", "layout", "total"])
277
267
  ], 512), [
278
- [_e, l.showPager]
268
+ [ke, u.showPager]
279
269
  ])
280
270
  ]);
281
271
  };
282
272
  }
283
273
  });
284
274
  export {
285
- nt as default
275
+ ot as default
286
276
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./TableToolbar.vue2.mjs";
2
2
  /* empty css */
3
- import r from "../../_virtual/_plugin-vue_export-helper.mjs";
4
- const p = /* @__PURE__ */ r(o, [["__scopeId", "data-v-90cd7b54"]]);
3
+ import a from "../../_virtual/_plugin-vue_export-helper.mjs";
4
+ const m = /* @__PURE__ */ a(o, [["__scopeId", "data-v-b028e7a1"]]);
5
5
  export {
6
- p as default
6
+ m as default
7
7
  };
@@ -21,8 +21,8 @@ const Z = { class: "table-toolbar" }, _ = { class: "table-toolbar-left" }, ee =
21
21
  exportByFe: { type: Boolean, default: !0 },
22
22
  exportFn: {},
23
23
  exportColumns: {},
24
- leftExtraButtons: {},
25
- rightExtraButtons: {},
24
+ leftExtraButtons: { default: () => [] },
25
+ rightExtraButtons: { default: () => [] },
26
26
  tableExpose: {},
27
27
  loading: { type: Boolean },
28
28
  exportContext: {},
@@ -93,9 +93,13 @@ const Z = { class: "table-toolbar" }, _ = { class: "table-toolbar-left" }, ee =
93
93
  } catch {
94
94
  return;
95
95
  }
96
- u = await M(d, i, { limit: c });
96
+ u = await M(d, i, {
97
+ limit: c
98
+ });
97
99
  } else
98
- u = await M(d, i, { limit: c });
100
+ u = await M(d, i, {
101
+ limit: c
102
+ });
99
103
  } catch (a) {
100
104
  H.error(`导出失败:${(a == null ? void 0 : a.message) || (a == null ? void 0 : a.toString())}`);
101
105
  return;