@dazhicheng/ui 1.6.19 → 1.6.20
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/components/tt-form/index.d.ts +2 -2
- package/dist/components/tt-form/src/formApi.d.ts +11 -2
- package/dist/components/tt-form/src/group-form/LazyFormField.vue.js +162 -114
- package/dist/components/tt-form/src/group-form/groupFormApi.js +0 -6
- package/dist/components/tt-form/src/group-form/lazyContext.d.ts +18 -0
- package/dist/components/tt-form/src/group-form/lazyContext.js +64 -36
- package/dist/components/tt-form/src/group-form/types.d.ts +39 -6
- package/dist/components/tt-form/src/group-form/useGroupForm.d.ts +7 -5
- package/dist/components/tt-form/src/types.d.ts +58 -26
- package/dist/components/tt-form/src/useForm.d.ts +1 -1
- package/dist/components/tt-form/src/useForm.js +5 -5
- package/dist/components/tt-modal-form/props.d.ts +9 -4
- package/dist/components/tt-modal-form/useModalForm.d.ts +1 -1
- package/dist/components/tt-table/index.d.ts +15 -0
- package/dist/components/tt-table/src/Table.vue.d.ts +9 -0
- package/dist/components/tt-table/src/Table.vue.js +240 -242
- package/dist/components/tt-table/src/TableForm.vue.d.ts +7 -5
- package/dist/components/tt-table/src/TableForm.vue.js +199 -180
- package/dist/components/tt-table/src/hooks/usePagination.d.ts +1 -1
- package/dist/components/tt-table/src/hooks/usePagination.js +38 -24
- package/dist/components/tt-table/src/hooks/useTableRender.d.ts +4 -4
- package/dist/components/tt-table/src/props.d.ts +6 -0
- package/dist/components/tt-table/src/props.js +5 -0
- package/dist/components/tt-table/src/types/table.d.ts +8 -0
- package/dist/components/tt-table/src/types/tableForm.d.ts +29 -14
- package/dist/components/tt-table/src/utils/table-form-api.d.ts +11 -11
- package/package.json +1 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as _t, mergeModels as fe, useModel as It, useAttrs as Vt, useSlots as Et, getCurrentInstance as Dt, ref as q, shallowReactive as zt, onScopeDispose as he, computed as m, provide as ye, unref as e, toRaw as be, nextTick as J, onMounted as Kt, createElementBlock as g, openBlock as c, normalizeClass as V, createVNode as E, mergeProps as Q, toHandlers as Mt, createSlots as At, withCtx as n, renderSlot as d, createBlock as X, createCommentVNode as D, normalizeStyle as y, createElementVNode as f, normalizeProps as R, guardReactiveProps as z, Fragment as Ft, toDisplayString as U, renderList as Y, createTextVNode as Se, toValue as Lt } from "vue";
|
|
2
2
|
import { TtErrorTooltip as Nt } from "../../tt-form-item-error-tooltip/index.js";
|
|
3
3
|
import { useLoading as Ot } from "../../../hooks/useLoading.js";
|
|
4
4
|
import "../../../node_modules/.pnpm/vue-types@5.1.3_vue@3.5.21_typescript@5.9.3_/node_modules/vue-types/shim/index.modern.js";
|
|
5
5
|
import { useDesign as Ht } from "../../../packages/hooks/src/useDesign.js";
|
|
6
6
|
import "axios";
|
|
7
|
-
import { ElScrollbar as
|
|
7
|
+
import { ElScrollbar as we } from "element-plus";
|
|
8
8
|
import "dayjs";
|
|
9
9
|
import "numeral";
|
|
10
|
-
import { extractResourceFromApi as Bt, generateTestId as
|
|
10
|
+
import { extractResourceFromApi as Bt, generateTestId as Ce } from "../../../packages/utils/src/testid-helper.js";
|
|
11
11
|
import "xe-utils";
|
|
12
12
|
import "dayjs/plugin/utc";
|
|
13
13
|
import "dayjs/plugin/timezone";
|
|
@@ -16,16 +16,16 @@ import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/aes.j
|
|
|
16
16
|
import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/enc-utf8.js";
|
|
17
17
|
import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/mode-ecb.js";
|
|
18
18
|
import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/pad-pkcs7.js";
|
|
19
|
-
import { omit as
|
|
19
|
+
import { omit as xe } from "lodash-es";
|
|
20
20
|
import "vue-router";
|
|
21
21
|
import { useStore as Gt } from "@tanstack/vue-store";
|
|
22
22
|
import { VxePager as jt } from "vxe-pc-ui";
|
|
23
23
|
import { VxeGrid as Wt } from "vxe-table";
|
|
24
|
-
import { tableProps as
|
|
25
|
-
import
|
|
26
|
-
import
|
|
27
|
-
import
|
|
28
|
-
import { TtImage as
|
|
24
|
+
import { tableProps as qt } from "vxe-table/es/table/src/props";
|
|
25
|
+
import Jt from "../../../assets/svg/paixu-jiangxu.svg.js";
|
|
26
|
+
import Qt from "../../../assets/svg/paixu-moren.svg.js";
|
|
27
|
+
import Xt from "../../../assets/svg/paixu-shengxu.svg.js";
|
|
28
|
+
import { TtImage as Ut } from "../../tt-image/index.js";
|
|
29
29
|
import { RowContext as Yt } from "./components/RowContext.js";
|
|
30
30
|
import { basicTableEmits as Zt } from "./emits.js";
|
|
31
31
|
import { useColumns as eo } from "./hooks/useColumns.js";
|
|
@@ -52,208 +52,208 @@ const Co = ["data-testid"], xo = ["src"], $o = ["src"], To = ["src"], Ro = {
|
|
|
52
52
|
key: 0
|
|
53
53
|
}, Po = {
|
|
54
54
|
key: 1
|
|
55
|
-
}, wr = /* @__PURE__ */
|
|
55
|
+
}, wr = /* @__PURE__ */ _t({
|
|
56
56
|
name: "TtTable",
|
|
57
57
|
__name: "Table",
|
|
58
|
-
props: /* @__PURE__ */
|
|
59
|
-
...
|
|
58
|
+
props: /* @__PURE__ */ fe({
|
|
59
|
+
...qt,
|
|
60
60
|
...fo,
|
|
61
61
|
...go
|
|
62
62
|
}, {
|
|
63
63
|
modelValue: {},
|
|
64
64
|
modelModifiers: {}
|
|
65
65
|
}),
|
|
66
|
-
emits: /* @__PURE__ */
|
|
67
|
-
setup(
|
|
68
|
-
expose:
|
|
69
|
-
emit:
|
|
66
|
+
emits: /* @__PURE__ */ fe(["register", "fetch-success", "fetch-error", "selection-change", ...Zt], ["update:modelValue"]),
|
|
67
|
+
setup(Z, {
|
|
68
|
+
expose: $e,
|
|
69
|
+
emit: Te
|
|
70
70
|
}) {
|
|
71
|
-
var
|
|
72
|
-
const h =
|
|
71
|
+
var me, ue;
|
|
72
|
+
const h = Z, Re = It(Z, "modelValue"), i = Te, ee = Vt(), K = Et(), C = Dt(), {
|
|
73
73
|
prefixCls: b
|
|
74
|
-
} = Ht("table"),
|
|
74
|
+
} = Ht("table"), ke = Object.hasOwn(((me = C == null ? void 0 : C.vnode) == null ? void 0 : me.props) || {}, "data"), k = q(null), p = q(), M = q({});
|
|
75
75
|
let s = h.tableApi;
|
|
76
|
-
s || (s = new wo(
|
|
77
|
-
const
|
|
78
|
-
function
|
|
79
|
-
Object.assign(
|
|
76
|
+
s || (s = new wo(xe(h, ["modelValue"])), s.useStore = (t) => Gt(s.store, t));
|
|
77
|
+
const P = zt({});
|
|
78
|
+
function te() {
|
|
79
|
+
Object.assign(P, be(s.store.state) || {});
|
|
80
80
|
}
|
|
81
|
-
|
|
82
|
-
const l = m(() =>
|
|
83
|
-
|
|
84
|
-
const
|
|
85
|
-
|
|
81
|
+
te(), he(s.store.subscribe(te));
|
|
82
|
+
const l = m(() => P), Pe = ke ? () => Lt(h.data) : () => P.data, ve = () => P.api;
|
|
83
|
+
ye(`${b}-props`, l);
|
|
84
|
+
const A = m(() => h.testId || (h.api ? Bt(h.api) : "table")), _e = m(() => Ce(e(A), "table")), Ie = m(() => Ce(e(A), "table-toolbar"));
|
|
85
|
+
ye("tableIdContext", A);
|
|
86
86
|
const {
|
|
87
87
|
getLoading: x,
|
|
88
|
-
setLoading:
|
|
88
|
+
setLoading: oe
|
|
89
89
|
} = Ot(m(() => e(l).loading || !1)), {
|
|
90
|
-
pagination:
|
|
90
|
+
pagination: F,
|
|
91
91
|
paginationInfo: S,
|
|
92
|
-
getPagination:
|
|
93
|
-
setPagination:
|
|
94
|
-
onPageChange:
|
|
92
|
+
getPagination: Ve,
|
|
93
|
+
setPagination: L,
|
|
94
|
+
onPageChange: Ee
|
|
95
95
|
} = ro(l, i), {
|
|
96
96
|
getRowKey: De,
|
|
97
|
-
getRowKeys:
|
|
98
|
-
prepareRows:
|
|
99
|
-
toVxeRowConfig:
|
|
97
|
+
getRowKeys: ze,
|
|
98
|
+
prepareRows: N,
|
|
99
|
+
toVxeRowConfig: Ke
|
|
100
100
|
} = lo(l), {
|
|
101
|
-
selectedKeys:
|
|
102
|
-
selectedRows:
|
|
103
|
-
selectedKeyList:
|
|
104
|
-
getSelectRowKeys:
|
|
105
|
-
getSelectRows:
|
|
106
|
-
syncSelection:
|
|
107
|
-
setSelectedRowKeys:
|
|
108
|
-
clearSelectedRowKeys:
|
|
109
|
-
resetSelectionAfterFetch:
|
|
110
|
-
onCheckboxChange:
|
|
111
|
-
onCheckboxAll:
|
|
112
|
-
onCheckboxRangeChange:
|
|
113
|
-
onRadioChange:
|
|
114
|
-
onCellAreaSelectionEnd:
|
|
101
|
+
selectedKeys: O,
|
|
102
|
+
selectedRows: H,
|
|
103
|
+
selectedKeyList: Me,
|
|
104
|
+
getSelectRowKeys: Ae,
|
|
105
|
+
getSelectRows: Fe,
|
|
106
|
+
syncSelection: Le,
|
|
107
|
+
setSelectedRowKeys: Ne,
|
|
108
|
+
clearSelectedRowKeys: re,
|
|
109
|
+
resetSelectionAfterFetch: Oe,
|
|
110
|
+
onCheckboxChange: He,
|
|
111
|
+
onCheckboxAll: Be,
|
|
112
|
+
onCheckboxRangeChange: Ge,
|
|
113
|
+
onRadioChange: je,
|
|
114
|
+
onCellAreaSelectionEnd: We
|
|
115
115
|
} = ao(l, p, i, {
|
|
116
116
|
getRowKey: De,
|
|
117
|
-
getRowKeys:
|
|
117
|
+
getRowKeys: ze
|
|
118
118
|
}), {
|
|
119
|
-
rows:
|
|
119
|
+
rows: v,
|
|
120
120
|
applyRows: qe,
|
|
121
121
|
getDataSource: Je,
|
|
122
122
|
runDataOperation: Qe,
|
|
123
|
-
scheduleRowsCommit:
|
|
123
|
+
scheduleRowsCommit: B,
|
|
124
124
|
cancelRowsCommit: Xe,
|
|
125
|
-
onDataChange:
|
|
126
|
-
createTableInstanceFacade:
|
|
127
|
-
isActive:
|
|
128
|
-
} = po(l, p,
|
|
129
|
-
data:
|
|
130
|
-
api:
|
|
131
|
-
prepareRows:
|
|
132
|
-
onSelectionMutated:
|
|
125
|
+
onDataChange: Ue,
|
|
126
|
+
createTableInstanceFacade: Ye,
|
|
127
|
+
isActive: Ze
|
|
128
|
+
} = po(l, p, Re, i, {
|
|
129
|
+
data: Pe,
|
|
130
|
+
api: ve,
|
|
131
|
+
prepareRows: N,
|
|
132
|
+
onSelectionMutated: Le
|
|
133
133
|
}), {
|
|
134
|
-
refresh:
|
|
135
|
-
syncScroll:
|
|
136
|
-
rowNodes:
|
|
137
|
-
headerHeight:
|
|
138
|
-
bodyHeight:
|
|
134
|
+
refresh: et,
|
|
135
|
+
syncScroll: tt,
|
|
136
|
+
rowNodes: se,
|
|
137
|
+
headerHeight: le,
|
|
138
|
+
bodyHeight: _,
|
|
139
139
|
bodyWrapperHeight: w,
|
|
140
|
-
bodyOffsetTop:
|
|
141
|
-
bodyScrollHeight:
|
|
142
|
-
leftScrollbarRef:
|
|
143
|
-
rightScrollbarRef:
|
|
144
|
-
} = no(l, p,
|
|
145
|
-
reload:
|
|
146
|
-
reloadFilter:
|
|
147
|
-
isLoaded:
|
|
140
|
+
bodyOffsetTop: ae,
|
|
141
|
+
bodyScrollHeight: ne,
|
|
142
|
+
leftScrollbarRef: ot,
|
|
143
|
+
rightScrollbarRef: rt
|
|
144
|
+
} = no(l, p, v), {
|
|
145
|
+
reload: st,
|
|
146
|
+
reloadFilter: ie,
|
|
147
|
+
isLoaded: de
|
|
148
148
|
} = so(l, {
|
|
149
149
|
grid: p,
|
|
150
|
-
pagination:
|
|
150
|
+
pagination: F,
|
|
151
151
|
paginationInfo: S,
|
|
152
|
-
setPagination:
|
|
153
|
-
setLoading:
|
|
154
|
-
resetSelectionAfterFetch:
|
|
155
|
-
rows:
|
|
152
|
+
setPagination: L,
|
|
153
|
+
setLoading: oe,
|
|
154
|
+
resetSelectionAfterFetch: Oe,
|
|
155
|
+
rows: v,
|
|
156
156
|
applyRows: qe
|
|
157
157
|
}, i), {
|
|
158
|
-
gridColumns:
|
|
159
|
-
hasExpandColumn:
|
|
160
|
-
sortIconSlots:
|
|
161
|
-
validSlots:
|
|
162
|
-
setTableColumns:
|
|
163
|
-
getTableColumns:
|
|
164
|
-
onColumnDragend:
|
|
158
|
+
gridColumns: lt,
|
|
159
|
+
hasExpandColumn: at,
|
|
160
|
+
sortIconSlots: nt,
|
|
161
|
+
validSlots: it,
|
|
162
|
+
setTableColumns: dt,
|
|
163
|
+
getTableColumns: ct,
|
|
164
|
+
onColumnDragend: pt
|
|
165
165
|
} = eo(l, p, i), {
|
|
166
|
-
footerSummaryMethod:
|
|
167
|
-
} = mo(
|
|
168
|
-
bindValues:
|
|
169
|
-
gridProps:
|
|
166
|
+
footerSummaryMethod: mt
|
|
167
|
+
} = mo(lt), {
|
|
168
|
+
bindValues: G,
|
|
169
|
+
gridProps: ut
|
|
170
170
|
} = to(l, {
|
|
171
|
-
attrs:
|
|
172
|
-
slots:
|
|
171
|
+
attrs: ee,
|
|
172
|
+
slots: K
|
|
173
173
|
}, {
|
|
174
|
-
hasExpandColumn:
|
|
175
|
-
footerSummaryMethod:
|
|
176
|
-
onTreeLoadResolved:
|
|
177
|
-
prepareRows:
|
|
178
|
-
toVxeRowConfig:
|
|
174
|
+
hasExpandColumn: at,
|
|
175
|
+
footerSummaryMethod: mt,
|
|
176
|
+
onTreeLoadResolved: B,
|
|
177
|
+
prepareRows: N,
|
|
178
|
+
toVxeRowConfig: Ke
|
|
179
179
|
}), {
|
|
180
|
-
onTableKeydown:
|
|
181
|
-
} = oo(
|
|
180
|
+
onTableKeydown: ce
|
|
181
|
+
} = oo(k), gt = m(W), ft = uo(l, p, s, {
|
|
182
182
|
runDataOperation: Qe,
|
|
183
|
-
clearSelectedRowKeys:
|
|
184
|
-
getTableInstance:
|
|
185
|
-
isActive:
|
|
186
|
-
prepareRows:
|
|
183
|
+
clearSelectedRowKeys: re,
|
|
184
|
+
getTableInstance: W,
|
|
185
|
+
isActive: Ze,
|
|
186
|
+
prepareRows: N
|
|
187
187
|
});
|
|
188
188
|
io(h, s.setState, ["tableApi", "formApi", "modelValue"]);
|
|
189
|
-
const
|
|
189
|
+
const ht = m(() => ({
|
|
190
190
|
...e(l).emptyImageStyle
|
|
191
|
-
})),
|
|
191
|
+
})), j = m(() => {
|
|
192
192
|
const {
|
|
193
193
|
api: t,
|
|
194
194
|
emptyText: o,
|
|
195
195
|
noSearchText: r
|
|
196
196
|
} = e(l);
|
|
197
|
-
return e(
|
|
197
|
+
return e(de) || !t ? o : r;
|
|
198
198
|
}), u = {};
|
|
199
199
|
ho.forEach(([t, o]) => {
|
|
200
200
|
u[o] = (...r) => {
|
|
201
|
-
t === "data-change" &&
|
|
201
|
+
t === "data-change" && Ue(), yo(t) && Xe(), bo(t, r, () => e(H)) && B(So(t)), i(t, ...r);
|
|
202
202
|
};
|
|
203
203
|
});
|
|
204
|
-
const
|
|
204
|
+
const yt = m(() => ({
|
|
205
205
|
...u,
|
|
206
|
-
headerCellClick:
|
|
207
|
-
sortChange:
|
|
208
|
-
radioChange:
|
|
209
|
-
checkboxChange:
|
|
210
|
-
checkboxAll:
|
|
211
|
-
checkboxRangeChange:
|
|
212
|
-
cellAreaSelectionEnd:
|
|
213
|
-
columnDragend:
|
|
214
|
-
scroll:
|
|
215
|
-
scrollBoundary:
|
|
216
|
-
toggleRowExpand:
|
|
217
|
-
editClosed:
|
|
206
|
+
headerCellClick: wt,
|
|
207
|
+
sortChange: Ct,
|
|
208
|
+
radioChange: je,
|
|
209
|
+
checkboxChange: He,
|
|
210
|
+
checkboxAll: Be,
|
|
211
|
+
checkboxRangeChange: Ge,
|
|
212
|
+
cellAreaSelectionEnd: We,
|
|
213
|
+
columnDragend: pt,
|
|
214
|
+
scroll: xt,
|
|
215
|
+
scrollBoundary: $t,
|
|
216
|
+
toggleRowExpand: Tt,
|
|
217
|
+
editClosed: Rt
|
|
218
218
|
}));
|
|
219
|
-
async function
|
|
219
|
+
async function bt(t) {
|
|
220
220
|
s.setState(t);
|
|
221
221
|
}
|
|
222
|
-
function
|
|
222
|
+
function pe(t = !0) {
|
|
223
223
|
J(() => {
|
|
224
224
|
var o;
|
|
225
225
|
return (o = e(p)) == null ? void 0 : o.recalculate(t);
|
|
226
226
|
});
|
|
227
227
|
}
|
|
228
|
-
function
|
|
228
|
+
function St(t, o) {
|
|
229
229
|
if (t) {
|
|
230
|
-
|
|
230
|
+
M.value[o] = t;
|
|
231
231
|
return;
|
|
232
232
|
}
|
|
233
|
-
delete
|
|
233
|
+
delete M.value[o];
|
|
234
234
|
}
|
|
235
|
-
function
|
|
235
|
+
function wt(t) {
|
|
236
236
|
var a;
|
|
237
237
|
(a = u.headerCellClick) == null || a.call(u, t);
|
|
238
238
|
const {
|
|
239
239
|
column: o
|
|
240
240
|
} = t;
|
|
241
241
|
if (o.sortable) return;
|
|
242
|
-
const r =
|
|
242
|
+
const r = be(o);
|
|
243
243
|
i("sort-change", {
|
|
244
244
|
order: r.order || "desc",
|
|
245
245
|
originOrder: r.order,
|
|
246
|
-
|
|
246
|
+
...xe(r, ["order"])
|
|
247
247
|
});
|
|
248
248
|
}
|
|
249
|
-
function
|
|
249
|
+
function Ct(t) {
|
|
250
250
|
var o;
|
|
251
|
-
(o = u.sortChange) == null || o.call(u, t),
|
|
251
|
+
(o = u.sortChange) == null || o.call(u, t), ie("sort");
|
|
252
252
|
}
|
|
253
|
-
function
|
|
254
|
-
i("scroll", t), ((t == null ? void 0 : t.type) === "body" || (t == null ? void 0 : t.type) === "table") &&
|
|
253
|
+
function xt(t) {
|
|
254
|
+
i("scroll", t), ((t == null ? void 0 : t.type) === "body" || (t == null ? void 0 : t.type) === "table") && tt(t == null ? void 0 : t.scrollTop);
|
|
255
255
|
}
|
|
256
|
-
function
|
|
256
|
+
function $t(t) {
|
|
257
257
|
i("scroll-boundary", t);
|
|
258
258
|
const {
|
|
259
259
|
isScrollFetch: o
|
|
@@ -263,124 +263,124 @@ const Co = ["data-testid"], xo = ["src"], $o = ["src"], To = ["src"], Ro = {
|
|
|
263
263
|
currentPage: r = 0,
|
|
264
264
|
total: a = 0
|
|
265
265
|
} = e(S) || {};
|
|
266
|
-
a <= e(
|
|
266
|
+
a <= e(v).length || L({
|
|
267
267
|
currentPage: r + 1
|
|
268
268
|
});
|
|
269
269
|
}
|
|
270
|
-
function
|
|
271
|
-
i("toggle-row-expand", t),
|
|
270
|
+
function Tt(t) {
|
|
271
|
+
i("toggle-row-expand", t), et(!1);
|
|
272
272
|
}
|
|
273
|
-
function
|
|
274
|
-
|
|
273
|
+
function Rt(t) {
|
|
274
|
+
B(), i("edit-closed", t);
|
|
275
275
|
}
|
|
276
|
-
function
|
|
277
|
-
return
|
|
276
|
+
function W() {
|
|
277
|
+
return Ye(e(p));
|
|
278
278
|
}
|
|
279
|
-
function
|
|
279
|
+
function kt(t) {
|
|
280
280
|
return Object.keys(t).filter((o) => o !== "empty");
|
|
281
281
|
}
|
|
282
|
-
const
|
|
283
|
-
reload:
|
|
284
|
-
setProps:
|
|
285
|
-
setTableColumns:
|
|
286
|
-
setPagination:
|
|
287
|
-
setLoading:
|
|
288
|
-
redoHeight:
|
|
282
|
+
const I = {
|
|
283
|
+
reload: st,
|
|
284
|
+
setProps: bt,
|
|
285
|
+
setTableColumns: dt,
|
|
286
|
+
setPagination: L,
|
|
287
|
+
setLoading: oe,
|
|
288
|
+
redoHeight: pe,
|
|
289
289
|
getDataSource: Je,
|
|
290
|
-
getPagination:
|
|
291
|
-
getSelectRowKeys:
|
|
292
|
-
getSelectRows:
|
|
293
|
-
getTableInstance:
|
|
290
|
+
getPagination: Ve,
|
|
291
|
+
getSelectRowKeys: Ae,
|
|
292
|
+
getSelectRows: Fe,
|
|
293
|
+
getTableInstance: W,
|
|
294
294
|
getLoading: x,
|
|
295
|
-
getTableColumns:
|
|
296
|
-
setSelectedRowKeys:
|
|
297
|
-
clearSelectedRowKeys:
|
|
298
|
-
selectedKeys:
|
|
299
|
-
selectedRows:
|
|
300
|
-
...
|
|
295
|
+
getTableColumns: ct,
|
|
296
|
+
setSelectedRowKeys: Ne,
|
|
297
|
+
clearSelectedRowKeys: re,
|
|
298
|
+
selectedKeys: O,
|
|
299
|
+
selectedRows: H,
|
|
300
|
+
...ft
|
|
301
301
|
};
|
|
302
302
|
return co({
|
|
303
|
-
...
|
|
304
|
-
wrapRef:
|
|
305
|
-
getBindValues:
|
|
306
|
-
}),
|
|
307
|
-
...
|
|
308
|
-
xGrid:
|
|
309
|
-
}), (
|
|
303
|
+
...I,
|
|
304
|
+
wrapRef: k,
|
|
305
|
+
getBindValues: G
|
|
306
|
+
}), $e({
|
|
307
|
+
...I,
|
|
308
|
+
xGrid: gt
|
|
309
|
+
}), (ue = s.bindState) == null || ue.call(s, {
|
|
310
310
|
loading: x,
|
|
311
|
-
selectedKeys:
|
|
312
|
-
selectedRows:
|
|
313
|
-
}), C && i("register",
|
|
314
|
-
e(l).autoHeight &&
|
|
311
|
+
selectedKeys: O,
|
|
312
|
+
selectedRows: H
|
|
313
|
+
}), C && i("register", I, `${C.uid}`), J(() => {
|
|
314
|
+
e(l).autoHeight && pe();
|
|
315
315
|
}), Kt(() => {
|
|
316
316
|
var t;
|
|
317
|
-
(t = s.mount) == null || t.call(s, e(p),
|
|
317
|
+
(t = s.mount) == null || t.call(s, e(p), I), J(() => {
|
|
318
318
|
var o, r;
|
|
319
|
-
return (r = (o = e(
|
|
319
|
+
return (r = (o = e(k)) == null ? void 0 : o.querySelector(".vxe-toolbar")) == null ? void 0 : r.setAttribute("data-testid", e(Ie));
|
|
320
320
|
});
|
|
321
|
-
}),
|
|
321
|
+
}), he(() => {
|
|
322
322
|
var t;
|
|
323
323
|
(t = s == null ? void 0 : s.unmount) == null || t.call(s);
|
|
324
324
|
}), (t, o) => (c(), g("div", {
|
|
325
325
|
ref_key: "wrapRef",
|
|
326
|
-
ref:
|
|
327
|
-
class:
|
|
328
|
-
"data-testid":
|
|
329
|
-
onKeydownCapture: o[
|
|
330
|
-
(...r) => e(
|
|
331
|
-
}, [
|
|
326
|
+
ref: k,
|
|
327
|
+
class: V([e(b), e(ee).class]),
|
|
328
|
+
"data-testid": _e.value,
|
|
329
|
+
onKeydownCapture: o[1] || (o[1] = //@ts-ignore
|
|
330
|
+
(...r) => e(ce) && e(ce)(...r))
|
|
331
|
+
}, [E(e(Wt), Q({
|
|
332
332
|
ref_key: "xGrid",
|
|
333
333
|
ref: p
|
|
334
|
-
}, e(
|
|
335
|
-
onFilterChange: o[
|
|
334
|
+
}, e(ut), Mt(yt.value), {
|
|
335
|
+
onFilterChange: o[0] || (o[0] = (r) => e(ie)())
|
|
336
336
|
}), At({
|
|
337
|
-
empty: n(() => [d(t.$slots, "empty",
|
|
338
|
-
isLoaded: e(
|
|
337
|
+
empty: n(() => [d(t.$slots, "empty", R(z({
|
|
338
|
+
isLoaded: e(de),
|
|
339
339
|
loading: e(x),
|
|
340
|
-
emptyTip:
|
|
340
|
+
emptyTip: j.value
|
|
341
341
|
})), () => [f("div", {
|
|
342
|
-
class:
|
|
343
|
-
}, [e(x) ? (c(), g("span", Po,
|
|
342
|
+
class: V(`${e(b)}-empty-image`)
|
|
343
|
+
}, [e(x) ? (c(), g("span", Po, U(l.value.emptyText || ""), 1)) : (c(), g(Ft, {
|
|
344
344
|
key: 0
|
|
345
|
-
}, [
|
|
346
|
-
style: y(
|
|
345
|
+
}, [E(e(Ut), {
|
|
346
|
+
style: y(ht.value),
|
|
347
347
|
status: l.value.emptyImageStatus
|
|
348
|
-
}, null, 8, ["style", "status"]),
|
|
349
|
-
left: n(() => [d(t.$slots, "left", {}, () => [e(w) ? (c(), X(e(
|
|
348
|
+
}, null, 8, ["style", "status"]), j.value ? (c(), g("span", ko, U(j.value), 1)) : D("", !0)], 64))], 2)])]),
|
|
349
|
+
left: n(() => [d(t.$slots, "left", {}, () => [e(w) ? (c(), X(e(we), {
|
|
350
350
|
key: 0,
|
|
351
351
|
ref_key: "leftScrollbarRef",
|
|
352
|
-
ref:
|
|
352
|
+
ref: ot,
|
|
353
353
|
"wrap-class": "overflow-hidden",
|
|
354
354
|
class: "tt-table-left-right-scroll",
|
|
355
355
|
height: `${e(w)}px`,
|
|
356
356
|
style: y({
|
|
357
357
|
width: `${l.value.leftSlotWidth}px`,
|
|
358
358
|
height: `${e(w)}px`,
|
|
359
|
-
marginTop: `${e(
|
|
359
|
+
marginTop: `${e(le)}px`
|
|
360
360
|
})
|
|
361
361
|
}, {
|
|
362
362
|
default: n(() => [f("div", {
|
|
363
363
|
class: "float-left w-0",
|
|
364
364
|
style: y({
|
|
365
|
-
height: `${e(
|
|
365
|
+
height: `${e(ne)}px`
|
|
366
366
|
})
|
|
367
367
|
}, null, 4), f("div", {
|
|
368
368
|
class: "relative",
|
|
369
369
|
style: y({
|
|
370
370
|
width: "100%",
|
|
371
|
-
height: `${e(
|
|
372
|
-
marginTop: `${e(
|
|
371
|
+
height: `${e(_)}px`,
|
|
372
|
+
marginTop: `${e(ae)}px`
|
|
373
373
|
})
|
|
374
|
-
}, [d(t.$slots, "tableLeft",
|
|
375
|
-
rowNodes: e(
|
|
376
|
-
height: e(
|
|
374
|
+
}, [d(t.$slots, "tableLeft", R(z({
|
|
375
|
+
rowNodes: e(se),
|
|
376
|
+
height: e(_)
|
|
377
377
|
})))], 4)]),
|
|
378
378
|
_: 3
|
|
379
|
-
}, 8, ["height", "style"])) :
|
|
380
|
-
right: n(() => [d(t.$slots, "right", {}, () => [e(w) ? (c(), X(e(
|
|
379
|
+
}, 8, ["height", "style"])) : D("", !0)])]),
|
|
380
|
+
right: n(() => [d(t.$slots, "right", {}, () => [e(w) ? (c(), X(e(we), {
|
|
381
381
|
key: 0,
|
|
382
382
|
ref_key: "rightScrollbarRef",
|
|
383
|
-
ref:
|
|
383
|
+
ref: rt,
|
|
384
384
|
"wrap-class": "overflow-hidden",
|
|
385
385
|
class: "tt-table-left-right-scroll",
|
|
386
386
|
always: "",
|
|
@@ -388,48 +388,48 @@ const Co = ["data-testid"], xo = ["src"], $o = ["src"], To = ["src"], Ro = {
|
|
|
388
388
|
style: y({
|
|
389
389
|
width: `${l.value.rightSlotWidth}px`,
|
|
390
390
|
height: `${e(w)}px`,
|
|
391
|
-
marginTop: `${e(
|
|
391
|
+
marginTop: `${e(le)}px`
|
|
392
392
|
})
|
|
393
393
|
}, {
|
|
394
394
|
default: n(() => [f("div", {
|
|
395
395
|
class: "float-left w-0",
|
|
396
396
|
style: y({
|
|
397
|
-
height: `${e(
|
|
397
|
+
height: `${e(ne)}px`
|
|
398
398
|
})
|
|
399
399
|
}, null, 4), f("div", {
|
|
400
400
|
class: "relative",
|
|
401
401
|
style: y({
|
|
402
402
|
width: "100%",
|
|
403
|
-
height: `${e(
|
|
404
|
-
marginTop: `${e(
|
|
403
|
+
height: `${e(_)}px`,
|
|
404
|
+
marginTop: `${e(ae)}px`
|
|
405
405
|
})
|
|
406
|
-
}, [d(t.$slots, "tableRight",
|
|
407
|
-
rowNodes: e(
|
|
408
|
-
height: e(
|
|
406
|
+
}, [d(t.$slots, "tableRight", R(z({
|
|
407
|
+
rowNodes: e(se),
|
|
408
|
+
height: e(_)
|
|
409
409
|
})))], 4)]),
|
|
410
410
|
_: 3
|
|
411
|
-
}, 8, ["height", "style"])) :
|
|
411
|
+
}, 8, ["height", "style"])) : D("", !0)])]),
|
|
412
412
|
_: 2
|
|
413
|
-
}, [
|
|
413
|
+
}, [Y(e(nt), (r) => ({
|
|
414
414
|
name: r,
|
|
415
415
|
fn: n(({
|
|
416
416
|
column: a
|
|
417
417
|
}) => [f("div", {
|
|
418
|
-
class:
|
|
418
|
+
class: V(["flex-x", {
|
|
419
419
|
"is-order": a.order,
|
|
420
420
|
[`${e(b)}-custom-sort`]: !0
|
|
421
421
|
}])
|
|
422
422
|
}, [a.order === "asc" ? (c(), g("img", {
|
|
423
423
|
key: 0,
|
|
424
|
-
src: e(
|
|
424
|
+
src: e(Xt)
|
|
425
425
|
}, null, 8, xo)) : a.order === "desc" ? (c(), g("img", {
|
|
426
426
|
key: 1,
|
|
427
|
-
src: e(
|
|
427
|
+
src: e(Jt)
|
|
428
428
|
}, null, 8, $o)) : (c(), g("img", {
|
|
429
429
|
key: 2,
|
|
430
|
-
src: e(
|
|
430
|
+
src: e(Qt)
|
|
431
431
|
}, null, 8, To))], 2)])
|
|
432
|
-
})),
|
|
432
|
+
})), Y(kt(t.$slots), (r) => ({
|
|
433
433
|
name: r,
|
|
434
434
|
fn: n((a) => [r.includes("action") ? (c(), X(e(Yt), {
|
|
435
435
|
key: 0,
|
|
@@ -439,58 +439,56 @@ const Co = ["data-testid"], xo = ["src"], $o = ["src"], To = ["src"], Ro = {
|
|
|
439
439
|
rowIndex: a.$rowIndex
|
|
440
440
|
}))]),
|
|
441
441
|
_: 2
|
|
442
|
-
}, 1032, ["row-index"])) : d(t.$slots, r,
|
|
442
|
+
}, 1032, ["row-index"])) : d(t.$slots, r, R(Q({
|
|
443
443
|
key: 1
|
|
444
444
|
}, a)))])
|
|
445
|
-
})), e(
|
|
445
|
+
})), e(G).showTableAlert ? {
|
|
446
446
|
name: "top",
|
|
447
447
|
fn: n(() => [f("div", {
|
|
448
|
-
class:
|
|
449
|
-
}, [o[
|
|
448
|
+
class: V(`${e(b)}-top-alert`)
|
|
449
|
+
}, [o[2] || (o[2] = Se(" 已选中 ", -1)), f("span", Ro, U(e(Me).length), 1), o[3] || (o[3] = Se(" 条 ", -1)), d(t.$slots, "top_title")], 2)]),
|
|
450
450
|
key: "0"
|
|
451
|
-
} : void 0, e(
|
|
451
|
+
} : void 0, e(K).toolbar_buttons ? {
|
|
452
452
|
name: "toolbar_buttons",
|
|
453
453
|
fn: n(() => [d(t.$slots, "toolbar_buttons")]),
|
|
454
454
|
key: "1"
|
|
455
|
-
} : void 0, e(
|
|
455
|
+
} : void 0, e(K).toolbar_tools ? {
|
|
456
456
|
name: "toolbar_tools",
|
|
457
457
|
fn: n(() => [d(t.$slots, "toolbar_tools")]),
|
|
458
458
|
key: "2"
|
|
459
|
-
} : void 0,
|
|
459
|
+
} : void 0, Y(e(it), (r) => ({
|
|
460
460
|
name: r,
|
|
461
461
|
fn: n(({
|
|
462
462
|
content: a,
|
|
463
|
-
rowIndex:
|
|
464
|
-
columnIndex:
|
|
465
|
-
column:
|
|
466
|
-
fixed:
|
|
467
|
-
}) => [!
|
|
463
|
+
rowIndex: $,
|
|
464
|
+
columnIndex: T,
|
|
465
|
+
column: Pt,
|
|
466
|
+
fixed: ge
|
|
467
|
+
}) => [!ge || ge === Pt.fixed ? (c(), g("div", {
|
|
468
468
|
key: 0,
|
|
469
|
-
ref: (vt) =>
|
|
469
|
+
ref: (vt) => St(vt, `valid_${$}_${T}`),
|
|
470
470
|
class: "h-full w-full"
|
|
471
|
-
}, [
|
|
471
|
+
}, [E(e(Nt), {
|
|
472
472
|
placement: l.value.toolTipErrorPlacement,
|
|
473
473
|
"err-msg": a,
|
|
474
|
-
"ref-dom":
|
|
475
|
-
}, null, 8, ["placement", "err-msg", "ref-dom"])], 512)) :
|
|
476
|
-
})), e(
|
|
474
|
+
"ref-dom": M.value[`valid_${$}_${T}`]
|
|
475
|
+
}, null, 8, ["placement", "err-msg", "ref-dom"])], 512)) : D("", !0)])
|
|
476
|
+
})), e(G).showPager ? {
|
|
477
477
|
name: "pager",
|
|
478
478
|
fn: n(() => {
|
|
479
|
-
var r, a, T
|
|
480
|
-
return [
|
|
481
|
-
"current-page": e(
|
|
482
|
-
"
|
|
483
|
-
"page-size": e($).pageSize,
|
|
484
|
-
"onUpdate:pageSize": o[1] || (o[1] = (k) => e($).pageSize = k),
|
|
479
|
+
var r, a, $, T;
|
|
480
|
+
return [E(e(jt), {
|
|
481
|
+
"current-page": e(F).currentPage,
|
|
482
|
+
"page-size": e(F).pageSize,
|
|
485
483
|
"page-sizes": (r = e(S)) == null ? void 0 : r.pageSizes,
|
|
486
484
|
layouts: (a = e(S)) == null ? void 0 : a.layouts,
|
|
487
|
-
total: ((
|
|
488
|
-
size: (
|
|
485
|
+
total: (($ = e(S)) == null ? void 0 : $.total) || e(v).length,
|
|
486
|
+
size: (T = e(S)) == null ? void 0 : T.size,
|
|
489
487
|
"class-name": `${e(b)}-vxe-pager`,
|
|
490
|
-
onPageChange: e(
|
|
488
|
+
onPageChange: e(Ee)
|
|
491
489
|
}, {
|
|
492
|
-
left: n(() => [d(t.$slots, "pager_left",
|
|
493
|
-
selectedKeys: e(
|
|
490
|
+
left: n(() => [d(t.$slots, "pager_left", R(z({
|
|
491
|
+
selectedKeys: e(O)
|
|
494
492
|
}))), d(t.$slots, "buttom_left")]),
|
|
495
493
|
_: 3
|
|
496
494
|
}, 8, ["current-page", "page-size", "page-sizes", "layouts", "total", "size", "class-name", "onPageChange"])];
|