@aplus-frontend/ui 0.6.0-beta.13 → 0.6.0-beta.15
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/es/src/ap-grid/editable/form-item.vue.mjs +38 -35
- package/es/src/ap-grid/editable/index.vue.mjs +13 -10
- package/es/src/ap-grid/hooks/use-row-selection.d.ts +100 -0
- package/es/src/ap-grid/hooks/use-row-selection.mjs +122 -0
- package/es/src/ap-grid/index.vue.mjs +271 -222
- package/es/src/ap-grid/interface.d.ts +16 -0
- package/es/src/ap-grid/utils/table.mjs +15 -15
- package/es/src/ap-table/hooks/use-table-paging-ng.d.ts +6 -1
- package/es/src/ap-table/hooks/use-table-paging-ng.mjs +99 -96
- package/es/src/business/ap-copy/ApCopy.mjs +43 -43
- package/es/src/business/ap-label/group/ApLabelGroup.mjs +15 -16
- package/es/src/business/ap-label/interface.d.ts +2 -3
- package/es/src/business/ap-product-info/ApProductInfo.mjs +23 -24
- package/es/src/business/ap-table-modal/table-modal.vue2.mjs +43 -42
- package/es/src/business/ap-view/ap-view.vue.d.ts +4 -1
- package/es/src/business/ap-view/ap-view.vue2.mjs +96 -84
- package/es/src/business/ap-view/index.d.ts +12 -3
- package/es/src/business/ap-view/interface.d.ts +7 -0
- package/es/src/business/hooks/usePageListApGrid.mjs +17 -20
- package/es/src/version.d.ts +1 -1
- package/es/src/version.mjs +1 -1
- package/lib/src/ap-grid/editable/form-item.vue.js +1 -1
- package/lib/src/ap-grid/editable/index.vue.js +1 -1
- package/lib/src/ap-grid/hooks/use-row-selection.d.ts +100 -0
- package/lib/src/ap-grid/hooks/use-row-selection.js +1 -0
- package/lib/src/ap-grid/index.vue.js +1 -1
- package/lib/src/ap-grid/interface.d.ts +16 -0
- package/lib/src/ap-grid/utils/table.js +1 -1
- package/lib/src/ap-table/hooks/use-table-paging-ng.d.ts +6 -1
- package/lib/src/ap-table/hooks/use-table-paging-ng.js +1 -1
- package/lib/src/business/ap-copy/ApCopy.js +1 -1
- package/lib/src/business/ap-label/group/ApLabelGroup.js +1 -1
- package/lib/src/business/ap-label/interface.d.ts +2 -3
- package/lib/src/business/ap-product-info/ApProductInfo.js +1 -1
- package/lib/src/business/ap-table-modal/table-modal.vue2.js +1 -1
- package/lib/src/business/ap-view/ap-view.vue.d.ts +4 -1
- package/lib/src/business/ap-view/ap-view.vue2.js +1 -1
- package/lib/src/business/ap-view/index.d.ts +12 -3
- package/lib/src/business/ap-view/interface.d.ts +7 -0
- package/lib/src/business/hooks/usePageListApGrid.js +1 -1
- package/lib/src/version.d.ts +1 -1
- package/lib/src/version.js +1 -1
- package/package.json +4 -3
- package/theme/ap-copy/ap-copy.css +2 -0
- package/theme/ap-copy/ap-copy.less +2 -0
- package/theme/ap-table-modal/index.css +15 -13
- package/theme/ap-table-modal/index.less +15 -13
- package/theme/index.css +17 -13
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { VxeTable as
|
|
1
|
+
import { defineComponent as ze, useSlots as _e, getCurrentInstance as Ve, ref as F, computed as n, unref as o, nextTick as Ke, watch as B, createElementBlock as I, openBlock as c, normalizeStyle as V, normalizeClass as h, createCommentVNode as S, createElementVNode as E, createVNode as J, mergeProps as v, createSlots as Q, withCtx as C, Fragment as Y, renderList as K, createBlock as f, resolveDynamicComponent as L, renderSlot as D, normalizeProps as Le, guardReactiveProps as De } from "vue";
|
|
2
|
+
import { VxeTable as Oe, VxeColumn as Z } from "vxe-table";
|
|
3
3
|
import "vxe-table/es/style.css";
|
|
4
4
|
import "vxe-pc-ui/es/style.css";
|
|
5
|
-
import { VxeUI as
|
|
6
|
-
import { isUndefined as
|
|
7
|
-
import { ApForm as
|
|
5
|
+
import { VxeUI as ee } from "vxe-pc-ui";
|
|
6
|
+
import { isUndefined as R, isFunction as oe, omit as $e } from "lodash-unified";
|
|
7
|
+
import { ApForm as He } from "../ap-form/index.mjs";
|
|
8
8
|
import "../config-provider/index.mjs";
|
|
9
|
-
import { noRenderAsFormItemValueList as
|
|
10
|
-
import { getColumnOrder as
|
|
11
|
-
import { useTablePaging as
|
|
12
|
-
import { Empty as
|
|
13
|
-
import { useInnerParams as
|
|
14
|
-
import { toVxeProps as
|
|
15
|
-
import
|
|
16
|
-
import { useProvideApTable as
|
|
17
|
-
import { sizeReverseMap as
|
|
18
|
-
import { useRenderColumns as
|
|
19
|
-
import { useToken as
|
|
9
|
+
import { noRenderAsFormItemValueList as Me } from "../ap-table/constants.mjs";
|
|
10
|
+
import { getColumnOrder as ae, updateFormProps as We, getFieldProps as je, getSearchFormItemRenderNode as qe, recursionApColumns as te } from "../ap-table/utils.mjs";
|
|
11
|
+
import { useTablePaging as Ue } from "../ap-table/hooks/use-table-paging-ng.mjs";
|
|
12
|
+
import { Empty as re, Pagination as Ge } from "@aplus-frontend/antdv";
|
|
13
|
+
import { useInnerParams as Xe } from "./hooks/use-inner-params.mjs";
|
|
14
|
+
import { toVxeProps as Je, getRowExpandProps as Qe, getRowSelectionProps as Ye } from "./utils/table.mjs";
|
|
15
|
+
import Ze from "./hooks/use-row-selection.mjs";
|
|
16
|
+
import { useProvideApTable as eo } from "../ap-table/context.mjs";
|
|
17
|
+
import { sizeReverseMap as oo, sizeMap as ao, ROW_SELECTION_FIELD as to } from "./constants.mjs";
|
|
18
|
+
import { useRenderColumns as ro } from "./hooks/use-render-columns.mjs";
|
|
19
|
+
import { useToken as lo } from "@aplus-frontend/antdv/es/theme/internal";
|
|
20
20
|
import "../scroll-bar/index.mjs";
|
|
21
|
-
import { isDef as
|
|
22
|
-
import { getValidVNodeList as
|
|
23
|
-
import { useNamespace as
|
|
24
|
-
import { useGlobalConfig as
|
|
25
|
-
import { useLocale as
|
|
26
|
-
import
|
|
27
|
-
const
|
|
21
|
+
import { isDef as no } from "../utils/index.mjs";
|
|
22
|
+
import { getValidVNodeList as so } from "../utils/slot.mjs";
|
|
23
|
+
import { useNamespace as io } from "../config-provider/hooks/use-namespace.mjs";
|
|
24
|
+
import { useGlobalConfig as co } from "../config-provider/hooks/use-global-config.mjs";
|
|
25
|
+
import { useLocale as uo } from "../config-provider/hooks/use-locale.mjs";
|
|
26
|
+
import po from "../scroll-bar/index.vue.mjs";
|
|
27
|
+
const Oo = /* @__PURE__ */ ze({
|
|
28
28
|
name: "ApGrid",
|
|
29
29
|
__name: "index",
|
|
30
30
|
props: {
|
|
@@ -111,283 +111,331 @@ const To = /* @__PURE__ */ Be({
|
|
|
111
111
|
footer: {},
|
|
112
112
|
virtual: { type: [Boolean, Object], default: void 0 },
|
|
113
113
|
expandable: {},
|
|
114
|
-
value: {}
|
|
114
|
+
value: {},
|
|
115
|
+
rowHighlightable: { type: [Boolean, Function], default: !1 }
|
|
115
116
|
},
|
|
116
|
-
setup(
|
|
117
|
-
var
|
|
118
|
-
const
|
|
119
|
-
|
|
120
|
-
const { e: P, b:
|
|
121
|
-
|
|
122
|
-
i18n: (e,
|
|
117
|
+
setup(le, { expose: ne }) {
|
|
118
|
+
var X;
|
|
119
|
+
const b = _e(), t = le, x = (X = Ve()) == null ? void 0 : X.appContext.app;
|
|
120
|
+
x && !x.__VXE_PC_UI_INSTALLED__ && (x.use(ee), x.__VXE_PC_UI_INSTALLED__ = !0);
|
|
121
|
+
const { e: P, b: u, be: se } = io("ap-grid"), ie = co("valueTypeMap"), i = F([]), O = F([]), s = F(), k = F(t.size), [, d] = lo(), { t: ce } = uo();
|
|
122
|
+
ee.setConfig({
|
|
123
|
+
i18n: (e, a) => ce(`ap.${e}`, a)
|
|
123
124
|
});
|
|
124
|
-
const { renderConfig:
|
|
125
|
-
let
|
|
126
|
-
const
|
|
127
|
-
if (
|
|
128
|
-
return
|
|
125
|
+
const { renderConfig: de, updateSignal: ue } = ro(i);
|
|
126
|
+
let $ = 0;
|
|
127
|
+
const pe = n(() => {
|
|
128
|
+
if (s.value)
|
|
129
|
+
return s.value.$el.querySelector(
|
|
129
130
|
".vxe-table--header-inner-wrapper"
|
|
130
131
|
);
|
|
131
|
-
}),
|
|
132
|
-
var e,
|
|
133
|
-
return
|
|
134
|
-
(
|
|
135
|
-
)) == null ? void 0 :
|
|
136
|
-
let
|
|
137
|
-
return
|
|
138
|
-
})) == null ? void 0 :
|
|
139
|
-
const p =
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
),
|
|
143
|
-
...
|
|
132
|
+
}), H = n(() => {
|
|
133
|
+
var e, a, r;
|
|
134
|
+
return $++, ((r = (a = (e = t.columns) == null ? void 0 : e.filter(
|
|
135
|
+
(l) => !l.hideInSearch && l.dataIndex && (l.valueType || l.customRenderFormItem) && !Me.includes(l.valueType)
|
|
136
|
+
)) == null ? void 0 : a.sort((l, p) => {
|
|
137
|
+
let w = ae(l.order);
|
|
138
|
+
return ae(p.order) - w;
|
|
139
|
+
})) == null ? void 0 : r.map((l) => {
|
|
140
|
+
const p = We(
|
|
141
|
+
l,
|
|
142
|
+
je(l.fieldProps, {})
|
|
143
|
+
), w = {
|
|
144
|
+
...l,
|
|
144
145
|
fieldProps: {
|
|
145
|
-
label:
|
|
146
|
-
name:
|
|
146
|
+
label: l.title,
|
|
147
|
+
name: l.dataIndex,
|
|
147
148
|
// tips: 在表格中的查询表单项默认是带边框的
|
|
148
149
|
bordered: !0,
|
|
149
150
|
...p || {},
|
|
150
|
-
_signal:
|
|
151
|
+
_signal: $
|
|
151
152
|
},
|
|
152
153
|
renderNode: void 0
|
|
153
154
|
};
|
|
154
|
-
return
|
|
155
|
-
|
|
156
|
-
o(
|
|
157
|
-
),
|
|
155
|
+
return w.renderNode = qe(
|
|
156
|
+
w,
|
|
157
|
+
o(ie)
|
|
158
|
+
), w;
|
|
158
159
|
})) || [];
|
|
159
|
-
}),
|
|
160
|
-
var
|
|
161
|
-
return
|
|
162
|
-
var
|
|
163
|
-
return ((
|
|
160
|
+
}), fe = n(() => {
|
|
161
|
+
var a;
|
|
162
|
+
return no(t.manual) ? t.manual : so(((a = b.searchFormExtra) == null ? void 0 : a.call(b)) || []).some((r) => {
|
|
163
|
+
var l;
|
|
164
|
+
return ((l = r.type) == null ? void 0 : l.name) === "ApView";
|
|
164
165
|
});
|
|
165
|
-
}),
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
].filter(Boolean)),
|
|
166
|
+
}), me = n(() => [
|
|
167
|
+
u(),
|
|
168
|
+
t.card ? null : u("wrapper"),
|
|
169
|
+
t.adaptive ? u("adaptive") : null,
|
|
170
|
+
t.sticky ? u("sticky") : null
|
|
171
|
+
].filter(Boolean)), M = n(() => te(o(i), (e) => {
|
|
171
172
|
if (e.sorter === !0)
|
|
172
173
|
return e.key || e.dataIndex;
|
|
173
|
-
}).filter(Boolean)),
|
|
174
|
+
}).filter(Boolean)), W = n(() => te(o(i), (e) => {
|
|
174
175
|
if (e.filters && !e.onFilter)
|
|
175
176
|
return e.key || e.dataIndex;
|
|
176
177
|
}).filter(Boolean)), {
|
|
177
|
-
formRef:
|
|
178
|
-
submit:
|
|
179
|
-
reset:
|
|
180
|
-
refresh:
|
|
181
|
-
data:
|
|
182
|
-
tableProps:
|
|
183
|
-
setDataSource:
|
|
184
|
-
handleTableChangeOptional:
|
|
185
|
-
} =
|
|
178
|
+
formRef: T,
|
|
179
|
+
submit: N,
|
|
180
|
+
reset: A,
|
|
181
|
+
refresh: ge,
|
|
182
|
+
data: m,
|
|
183
|
+
tableProps: j,
|
|
184
|
+
setDataSource: he,
|
|
185
|
+
handleTableChangeOptional: ve
|
|
186
|
+
} = Ue({
|
|
186
187
|
async request(e) {
|
|
187
|
-
var
|
|
188
|
-
if (!
|
|
189
|
-
const
|
|
188
|
+
var r;
|
|
189
|
+
if (!g.value.preserveSelectedRowKeys && R(t.dataSource) && _(), !R(t.dataSource)) {
|
|
190
|
+
const l = e.pageSize * (e.current - 1);
|
|
190
191
|
return {
|
|
191
|
-
data: (
|
|
192
|
-
total:
|
|
192
|
+
data: (t.pagination === !1 ? t.dataSource : t.dataSource.slice(l, l + e.pageSize)) || [],
|
|
193
|
+
total: t.dataSource.length || 0
|
|
193
194
|
};
|
|
194
195
|
}
|
|
195
|
-
const
|
|
196
|
+
const a = await ((r = t.request) == null ? void 0 : r.call(t, e));
|
|
196
197
|
return {
|
|
197
|
-
data: (
|
|
198
|
-
total: (
|
|
198
|
+
data: (a == null ? void 0 : a.data) || [],
|
|
199
|
+
total: (a == null ? void 0 : a.total) || 0
|
|
199
200
|
};
|
|
200
201
|
},
|
|
201
202
|
namespace: "ap-grid",
|
|
202
|
-
filterFields:
|
|
203
|
-
sortFields:
|
|
204
|
-
defaultParams:
|
|
205
|
-
defaultData:
|
|
206
|
-
manual: o(
|
|
207
|
-
formatParams:
|
|
208
|
-
pagination:
|
|
209
|
-
onClickReset:
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
203
|
+
filterFields: W,
|
|
204
|
+
sortFields: M,
|
|
205
|
+
defaultParams: t.params,
|
|
206
|
+
defaultData: t.defaultData,
|
|
207
|
+
manual: o(fe),
|
|
208
|
+
formatParams: t.beforeSearchSubmit,
|
|
209
|
+
pagination: t.pagination,
|
|
210
|
+
onClickReset: Ne,
|
|
211
|
+
onAfterRequest: G
|
|
212
|
+
}), { sortChangeEvent: Ce, filterChangeEvent: be, paginationChangeEvent: ye } = Xe(ve);
|
|
213
|
+
eo({
|
|
214
|
+
columns: n(() => i.value),
|
|
215
|
+
columnsBackup: n(() => O.value),
|
|
216
|
+
size: n(() => ao[k.value]),
|
|
215
217
|
updateColumns(e) {
|
|
216
|
-
var
|
|
217
|
-
|
|
218
|
+
var a;
|
|
219
|
+
i.value = e, (a = t.onShownColumnsChange) == null || a.call(t, e);
|
|
218
220
|
},
|
|
219
221
|
updateSize(e) {
|
|
220
|
-
|
|
222
|
+
k.value = oo[e];
|
|
221
223
|
},
|
|
222
224
|
renderConfig: n(() => ({
|
|
223
|
-
className:
|
|
225
|
+
className: se("table-header", "title"),
|
|
224
226
|
color: d.value.colorTextTertiary
|
|
225
227
|
})),
|
|
226
|
-
dataSource: n(() => o(
|
|
228
|
+
dataSource: n(() => o(m).records),
|
|
227
229
|
getSearchFormValues: U,
|
|
228
230
|
setSearchFormValues: q,
|
|
229
|
-
submit:
|
|
230
|
-
reset:
|
|
231
|
+
submit: N,
|
|
232
|
+
reset: A
|
|
231
233
|
});
|
|
232
|
-
const
|
|
233
|
-
() =>
|
|
234
|
+
const we = n(
|
|
235
|
+
() => i.value.some(
|
|
234
236
|
(e) => e.fixed === "left" || e.fixed === !0
|
|
235
237
|
) ? "left" : void 0
|
|
236
|
-
), ye = n(
|
|
237
|
-
() => S(a.loading) ? f.loading : a.loading
|
|
238
238
|
), Se = n(
|
|
239
|
-
() =>
|
|
240
|
-
),
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
239
|
+
() => R(t.loading) ? m.loading : t.loading
|
|
240
|
+
), Re = n(
|
|
241
|
+
() => R(t.dataSource) ? m.records : t.dataSource
|
|
242
|
+
), { selectedRows: z, rowSelection: g, ...y } = Ze({
|
|
243
|
+
...t.rowSelection === !0 ? {} : t.rowSelection,
|
|
244
|
+
dataSource: Re,
|
|
245
|
+
rowKey: t.rowKey
|
|
246
|
+
}), xe = ({
|
|
247
|
+
checked: e,
|
|
248
|
+
row: a
|
|
249
|
+
}) => {
|
|
250
|
+
const r = s.value;
|
|
251
|
+
if (r && r) {
|
|
252
|
+
const l = [
|
|
253
|
+
...r.getCheckboxReserveRecords(),
|
|
254
|
+
...r.getCheckboxRecords()
|
|
255
|
+
];
|
|
256
|
+
y.selectChange(a, e, l);
|
|
257
|
+
}
|
|
258
|
+
}, ke = ({
|
|
259
|
+
checked: e
|
|
260
|
+
}) => {
|
|
261
|
+
const a = s.value;
|
|
262
|
+
a && y.selectAllChange(e, [
|
|
263
|
+
...a.getCheckboxReserveRecords(),
|
|
264
|
+
...a.getCheckboxRecords()
|
|
265
|
+
]);
|
|
266
|
+
}, Fe = () => {
|
|
267
|
+
const e = s.value;
|
|
268
|
+
e && y.selectRangeChange(e.getCheckboxRecords(), [
|
|
247
269
|
...e.getCheckboxReserveRecords(),
|
|
248
270
|
...e.getCheckboxRecords()
|
|
249
271
|
]);
|
|
250
|
-
},
|
|
251
|
-
const e =
|
|
252
|
-
e && (
|
|
272
|
+
}, Be = () => {
|
|
273
|
+
const e = s.value;
|
|
274
|
+
e && (z.value = [e.getRadioRecord()]);
|
|
275
|
+
}, Ie = ({
|
|
276
|
+
row: e
|
|
277
|
+
}) => {
|
|
278
|
+
const a = t.rowHighlightable;
|
|
279
|
+
oe(a) && a(e);
|
|
253
280
|
};
|
|
254
|
-
function
|
|
281
|
+
function Ee() {
|
|
255
282
|
var e;
|
|
256
|
-
return ((e =
|
|
283
|
+
return ((e = t.columns) == null ? void 0 : e.filter((a) => !a.hideInTable)) || [];
|
|
257
284
|
}
|
|
258
285
|
function q(e) {
|
|
259
|
-
var r, l
|
|
260
|
-
(
|
|
286
|
+
var a, r, l;
|
|
287
|
+
(l = (r = (a = T.value) == null ? void 0 : a.apForm) == null ? void 0 : r.setFieldsValue) == null || l.call(r, e);
|
|
261
288
|
}
|
|
262
289
|
function U(e = !1) {
|
|
263
|
-
var
|
|
264
|
-
const
|
|
265
|
-
return (p = (
|
|
290
|
+
var r, l, p;
|
|
291
|
+
const a = e ? "getFieldsValueTransformed" : "getFieldsValue";
|
|
292
|
+
return (p = (l = (r = T.value) == null ? void 0 : r.apForm) == null ? void 0 : l[a]) == null ? void 0 : p.call(l, !0);
|
|
266
293
|
}
|
|
267
294
|
function _() {
|
|
268
|
-
|
|
269
|
-
const e =
|
|
270
|
-
e && (
|
|
295
|
+
y.clearAll();
|
|
296
|
+
const e = s.value;
|
|
297
|
+
e && (g.value.type === "radio" ? (e.clearRadioRow(), e.clearRadioReserve()) : (e.clearCheckboxRow(), e.clearCheckboxReserve()));
|
|
298
|
+
}
|
|
299
|
+
function Pe(e) {
|
|
300
|
+
oe(t.rowKey) || (y.selectMultiByKeys(e), G());
|
|
271
301
|
}
|
|
272
|
-
function
|
|
273
|
-
const
|
|
302
|
+
function Te(e) {
|
|
303
|
+
const a = s.value;
|
|
304
|
+
if (!a)
|
|
305
|
+
return;
|
|
306
|
+
const r = String(e[t.rowKey]), l = a.getRowById(r);
|
|
307
|
+
a.setCurrentRow(l);
|
|
308
|
+
}
|
|
309
|
+
function Ne() {
|
|
310
|
+
const e = s.value;
|
|
274
311
|
e && (e.clearSort(), e.clearFilter());
|
|
275
312
|
}
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
313
|
+
function G() {
|
|
314
|
+
Ke(() => {
|
|
315
|
+
var e, a;
|
|
316
|
+
g.value.type === "radio" ? (e = s.value) == null || e.setRadioRowKey(g.value.selectedRowKeys[0]) : (a = s.value) == null || a.setCheckboxRowKey(
|
|
317
|
+
g.value.selectedRowKeys,
|
|
318
|
+
!0
|
|
319
|
+
);
|
|
320
|
+
});
|
|
321
|
+
}
|
|
322
|
+
async function Ae(e, a) {
|
|
323
|
+
var l;
|
|
324
|
+
const r = m.records[e];
|
|
325
|
+
if (r)
|
|
326
|
+
return (l = s.value) == null ? void 0 : l.scrollToRow(r, a);
|
|
281
327
|
}
|
|
282
328
|
return B(
|
|
283
|
-
() => [
|
|
329
|
+
() => [t.columnResizable, t.columns],
|
|
284
330
|
() => {
|
|
285
|
-
var
|
|
286
|
-
const e =
|
|
287
|
-
|
|
331
|
+
var a;
|
|
332
|
+
const e = Ee();
|
|
333
|
+
i.value = e, (a = t.onShownColumnsChange) == null || a.call(t, e), O.value = e;
|
|
288
334
|
},
|
|
289
335
|
{
|
|
290
336
|
deep: !0,
|
|
291
337
|
immediate: !0
|
|
292
338
|
}
|
|
293
339
|
), B(
|
|
294
|
-
() =>
|
|
340
|
+
() => t.dataSource,
|
|
295
341
|
(e) => {
|
|
296
|
-
|
|
342
|
+
he(e);
|
|
297
343
|
},
|
|
298
344
|
{ immediate: !0, deep: !0 }
|
|
299
345
|
), B(
|
|
300
|
-
() => o(
|
|
346
|
+
() => o(m).loading,
|
|
301
347
|
(e) => {
|
|
302
|
-
var
|
|
303
|
-
(
|
|
348
|
+
var a;
|
|
349
|
+
(a = t.onLoadingChange) == null || a.call(t, e);
|
|
304
350
|
}
|
|
305
351
|
), B(
|
|
306
|
-
() =>
|
|
352
|
+
() => t.size,
|
|
307
353
|
(e) => {
|
|
308
|
-
|
|
354
|
+
k.value = e;
|
|
309
355
|
}
|
|
310
|
-
),
|
|
311
|
-
submit:
|
|
312
|
-
reset:
|
|
313
|
-
refresh:
|
|
356
|
+
), ne({
|
|
357
|
+
submit: N,
|
|
358
|
+
reset: A,
|
|
359
|
+
refresh: ge,
|
|
314
360
|
setSearchFormValues: q,
|
|
315
361
|
getSearchFormValues: U,
|
|
316
|
-
getShowColumns: () => o(
|
|
362
|
+
getShowColumns: () => o(i),
|
|
317
363
|
rowSelection: {
|
|
318
|
-
selectedRows: n(() =>
|
|
364
|
+
selectedRows: n(() => z.value),
|
|
365
|
+
setSelectedRowKeys: Pe,
|
|
319
366
|
clearAll: _
|
|
320
367
|
},
|
|
321
|
-
scrollToRow:
|
|
322
|
-
getDataSource: () => o(
|
|
323
|
-
|
|
324
|
-
|
|
368
|
+
scrollToRow: Ae,
|
|
369
|
+
getDataSource: () => o(m.records),
|
|
370
|
+
setCurrentRow: Te
|
|
371
|
+
}), (e, a) => (c(), I("div", {
|
|
372
|
+
class: h(me.value),
|
|
325
373
|
style: V(e.wrapperStyle)
|
|
326
374
|
}, [
|
|
327
|
-
o(
|
|
375
|
+
o(R)(e.dataSource) && e.searchForm !== !1 && H.value.length > 0 ? (c(), I("div", {
|
|
328
376
|
key: 0,
|
|
329
|
-
class:
|
|
377
|
+
class: h(e.card ? o(P)("search-wrapper") : null),
|
|
330
378
|
style: V(e.searchFormWrapperStyle)
|
|
331
379
|
}, [
|
|
332
|
-
|
|
380
|
+
J(o(He).SearchForm, v(e.searchForm || {}, {
|
|
333
381
|
ref_key: "formRef",
|
|
334
|
-
ref:
|
|
382
|
+
ref: T,
|
|
335
383
|
"custom-reset": "",
|
|
336
|
-
"submit-loading": o(
|
|
337
|
-
onSubmit: o(
|
|
338
|
-
onReset: o(
|
|
339
|
-
}),
|
|
340
|
-
default:
|
|
341
|
-
(
|
|
342
|
-
key:
|
|
343
|
-
item:
|
|
384
|
+
"submit-loading": o(j).loading,
|
|
385
|
+
onSubmit: o(N),
|
|
386
|
+
onReset: o(A)
|
|
387
|
+
}), Q({
|
|
388
|
+
default: C(() => [
|
|
389
|
+
(c(!0), I(Y, null, K(H.value, (r) => (c(), f(L(r.renderNode.Comp), v({
|
|
390
|
+
key: r.dataIndex,
|
|
391
|
+
item: r,
|
|
344
392
|
ref_for: !0
|
|
345
|
-
},
|
|
346
|
-
span:
|
|
347
|
-
"custom-render":
|
|
393
|
+
}, r.fieldProps || {}, {
|
|
394
|
+
span: r.span,
|
|
395
|
+
"custom-render": r.renderNode.render
|
|
348
396
|
}), null, 16, ["item", "span", "custom-render"]))), 128))
|
|
349
397
|
]),
|
|
350
398
|
_: 2
|
|
351
399
|
}, [
|
|
352
|
-
|
|
400
|
+
b.searchFormExtra ? {
|
|
353
401
|
name: "extra",
|
|
354
|
-
fn:
|
|
355
|
-
|
|
402
|
+
fn: C(() => [
|
|
403
|
+
D(e.$slots, "searchFormExtra")
|
|
356
404
|
]),
|
|
357
405
|
key: "0"
|
|
358
406
|
} : void 0
|
|
359
407
|
]), 1040, ["submit-loading", "onSubmit", "onReset"])
|
|
360
|
-
], 6)) :
|
|
408
|
+
], 6)) : S("", !0),
|
|
361
409
|
E("div", {
|
|
362
|
-
class:
|
|
410
|
+
class: h([o(P)("table-wrapper"), e.card ? o(P)("table-wrapper-card") : null]),
|
|
363
411
|
style: V(e.tableWrapperStyle)
|
|
364
412
|
}, [
|
|
365
413
|
E("div", {
|
|
366
|
-
class:
|
|
414
|
+
class: h(o(u)("header-wrapper"))
|
|
367
415
|
}, [
|
|
368
|
-
|
|
369
|
-
selectedRows: o(
|
|
370
|
-
selectedRowKeys: o(
|
|
371
|
-
shownColumns:
|
|
416
|
+
D(e.$slots, "title", {
|
|
417
|
+
selectedRows: o(z),
|
|
418
|
+
selectedRowKeys: o(g).selectedRowKeys,
|
|
419
|
+
shownColumns: i.value,
|
|
372
420
|
clearAll: _
|
|
373
421
|
})
|
|
374
422
|
], 2),
|
|
375
423
|
E("div", {
|
|
376
|
-
class:
|
|
424
|
+
class: h(o(u)("vxe-wrapper"))
|
|
377
425
|
}, [
|
|
378
|
-
(
|
|
426
|
+
(c(), f(o(Oe), v(o(Je)(t), {
|
|
379
427
|
ref_key: "tableRef",
|
|
380
|
-
ref:
|
|
381
|
-
key: o(
|
|
382
|
-
data: o(
|
|
428
|
+
ref: s,
|
|
429
|
+
key: o(ue),
|
|
430
|
+
data: o(m).records,
|
|
383
431
|
"sort-config": {
|
|
384
|
-
remote:
|
|
432
|
+
remote: M.value.length > 0,
|
|
385
433
|
trigger: "cell"
|
|
386
434
|
},
|
|
387
435
|
"filter-config": {
|
|
388
|
-
remote:
|
|
436
|
+
remote: W.value.length > 0
|
|
389
437
|
},
|
|
390
|
-
loading:
|
|
438
|
+
loading: Se.value,
|
|
391
439
|
style: {
|
|
392
440
|
"--vxe-ui-table-row-checkbox-checked-background-color": o(d).controlItemBgActive,
|
|
393
441
|
"--vxe-ui-table-row-hover-checkbox-checked-background-color": o(d).controlItemBgActiveHover,
|
|
@@ -401,61 +449,62 @@ const To = /* @__PURE__ */ Be({
|
|
|
401
449
|
"--vxe-ui-table-border-color": o(d).colorBorderSecondary,
|
|
402
450
|
"--vxe-ui-table-header-font-color": o(d).colorTextBase
|
|
403
451
|
},
|
|
404
|
-
size:
|
|
405
|
-
onSortChange: o(
|
|
406
|
-
onFilterChange: o(
|
|
407
|
-
onCheckboxChange:
|
|
408
|
-
onCheckboxRangeChange:
|
|
409
|
-
onCheckboxAll:
|
|
410
|
-
onRadioChange:
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
452
|
+
size: k.value,
|
|
453
|
+
onSortChange: o(Ce),
|
|
454
|
+
onFilterChange: o(be),
|
|
455
|
+
onCheckboxChange: xe,
|
|
456
|
+
onCheckboxRangeChange: Fe,
|
|
457
|
+
onCheckboxAll: ke,
|
|
458
|
+
onRadioChange: Be,
|
|
459
|
+
onCurrentChange: Ie
|
|
460
|
+
}), Q({
|
|
461
|
+
empty: C(() => [
|
|
462
|
+
J(o(re), {
|
|
463
|
+
image: o(re).PRESENTED_IMAGE_SIMPLE
|
|
415
464
|
}, null, 8, ["image"])
|
|
416
465
|
]),
|
|
417
|
-
default:
|
|
418
|
-
|
|
419
|
-
content:
|
|
420
|
-
(
|
|
466
|
+
default: C(() => [
|
|
467
|
+
t.expandable && i.value.length ? (c(), f(o(Z), v({ key: 0 }, o(Qe)(e.expandable), { fixed: we.value }), {
|
|
468
|
+
content: C((r) => [
|
|
469
|
+
(c(), f(L(t.expandable.renderContent(r))))
|
|
421
470
|
]),
|
|
422
471
|
_: 1
|
|
423
|
-
}, 16, ["fixed"])) :
|
|
424
|
-
|
|
425
|
-
(
|
|
426
|
-
key:
|
|
472
|
+
}, 16, ["fixed"])) : S("", !0),
|
|
473
|
+
t.rowSelection && i.value.length ? (c(), f(o(Z), v({ key: 1 }, o(Ye)(o(g), i.value), { field: o(to) }), null, 16, ["field"])) : S("", !0),
|
|
474
|
+
(c(!0), I(Y, null, K(o(de), (r) => (c(), f(L(r), {
|
|
475
|
+
key: r.props.colId
|
|
427
476
|
}))), 128))
|
|
428
477
|
]),
|
|
429
478
|
_: 2
|
|
430
479
|
}, [
|
|
431
|
-
|
|
432
|
-
name:
|
|
433
|
-
fn:
|
|
434
|
-
|
|
480
|
+
K(o($e)(b, ["searchFormExtra"]), (r, l) => ({
|
|
481
|
+
name: l,
|
|
482
|
+
fn: C((p) => [
|
|
483
|
+
D(e.$slots, l, Le(De(p || {})))
|
|
435
484
|
])
|
|
436
485
|
}))
|
|
437
486
|
]), 1040, ["data", "sort-config", "filter-config", "loading", "style", "size", "onSortChange", "onFilterChange"]))
|
|
438
487
|
], 2),
|
|
439
488
|
E("div", {
|
|
440
|
-
class:
|
|
489
|
+
class: h(o(u)("pagination-wrapper"))
|
|
441
490
|
}, [
|
|
442
|
-
e.sticky ? (
|
|
491
|
+
e.sticky ? (c(), f(o(po), {
|
|
443
492
|
key: 0,
|
|
444
493
|
direction: "horizontal",
|
|
445
|
-
"scroll-container":
|
|
494
|
+
"scroll-container": pe.value,
|
|
446
495
|
"extra-size": -4.2,
|
|
447
496
|
"bar-color": "var(--ap-scrollbar-thumb-color-base)",
|
|
448
497
|
"track-color": "var(--ap-table-header-bg, #f2f6f9)"
|
|
449
|
-
}, null, 8, ["scroll-container"])) :
|
|
450
|
-
e.pagination !== !1 ? (
|
|
498
|
+
}, null, 8, ["scroll-container"])) : S("", !0),
|
|
499
|
+
e.pagination !== !1 ? (c(), f(o(Ge), v({
|
|
451
500
|
key: 1,
|
|
452
|
-
class: o(
|
|
453
|
-
}, o(
|
|
501
|
+
class: o(u)("pagination")
|
|
502
|
+
}, o(j).pagination, { onChange: o(ye) }), null, 16, ["class", "onChange"])) : S("", !0)
|
|
454
503
|
], 2)
|
|
455
504
|
], 6)
|
|
456
505
|
], 6));
|
|
457
506
|
}
|
|
458
507
|
});
|
|
459
508
|
export {
|
|
460
|
-
|
|
509
|
+
Oo as default
|
|
461
510
|
};
|