@aplus-frontend/ui 0.5.28 → 0.5.30
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/index.mjs +86 -82
- package/es/src/ap-field/interface.d.ts +3 -0
- package/es/src/ap-grid/editable/form-item.vue.mjs +20 -19
- package/es/src/ap-grid/editable/index.vue.mjs +23 -22
- package/es/src/ap-grid/index.vue.mjs +149 -138
- package/es/src/ap-grid/interface.d.ts +9 -0
- package/es/src/ap-grid/utils/col.mjs +92 -81
- package/es/src/ap-grid/utils/table.mjs +2 -2
- package/es/src/ap-table/hooks/use-table-paging-ng.mjs +52 -52
- package/es/src/business/ap-product-info/ApProductInfo.d.ts +22 -25
- package/es/src/business/ap-product-info/ApProductInfo.mjs +59 -0
- package/es/src/business/ap-product-info/constans.d.ts +11 -14
- package/es/src/business/ap-product-info/constans.mjs +21 -0
- package/es/src/business/ap-product-info/index.d.ts +86 -0
- package/es/src/business/ap-product-info/index.mjs +7 -0
- package/es/src/business/ap-product-info/interface.d.ts +9 -7
- package/es/src/business/ap-product-info/interface.mjs +1 -0
- package/es/src/business/ap-product-info/style/css.d.ts +0 -0
- package/es/src/business/ap-product-info/style/css.js +1 -0
- package/es/src/business/ap-product-info/style/index.d.ts +0 -0
- package/es/src/business/ap-product-info/style/index.js +1 -0
- package/es/src/business/hooks/index.d.ts +1 -0
- package/es/src/business/hooks/index.mjs +6 -4
- package/es/src/business/hooks/useGridRefresh.d.ts +17 -0
- package/es/src/business/hooks/useGridRefresh.mjs +17 -0
- package/es/src/business/index.d.ts +1 -0
- package/es/src/business/index.mjs +21 -19
- package/es/src/components.d.ts +1 -0
- package/es/src/full-screen/index.vue.mjs +17 -16
- package/es/src/full-screen/interface.d.ts +2 -1
- package/es/src/index.mjs +75 -71
- package/es/src/path-map.mjs +1 -0
- package/lib/index.js +1 -1
- package/lib/src/ap-field/interface.d.ts +3 -0
- 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/index.vue.js +1 -1
- package/lib/src/ap-grid/interface.d.ts +9 -0
- package/lib/src/ap-grid/utils/col.js +1 -1
- package/lib/src/ap-grid/utils/table.js +1 -1
- package/lib/src/ap-table/hooks/use-table-paging-ng.js +1 -1
- package/lib/src/business/ap-product-info/ApProductInfo.d.ts +22 -25
- package/lib/src/business/ap-product-info/ApProductInfo.js +1 -0
- package/lib/src/business/ap-product-info/constans.d.ts +11 -14
- package/lib/src/business/ap-product-info/constans.js +1 -0
- package/lib/src/business/ap-product-info/index.d.ts +86 -0
- package/lib/src/business/ap-product-info/index.js +1 -0
- package/lib/src/business/ap-product-info/interface.d.ts +9 -7
- package/lib/src/business/ap-product-info/interface.js +1 -0
- package/lib/src/business/ap-product-info/style/css.cjs +1 -0
- package/lib/src/business/ap-product-info/style/css.d.ts +0 -0
- package/lib/src/business/ap-product-info/style/index.cjs +1 -0
- package/lib/src/business/ap-product-info/style/index.d.ts +0 -0
- package/lib/src/business/hooks/index.d.ts +1 -0
- package/lib/src/business/hooks/index.js +1 -1
- package/lib/src/business/hooks/useGridRefresh.d.ts +17 -0
- package/lib/src/business/hooks/useGridRefresh.js +1 -0
- package/lib/src/business/index.d.ts +1 -0
- package/lib/src/business/index.js +1 -1
- package/lib/src/components.d.ts +1 -0
- package/lib/src/full-screen/index.vue.js +1 -1
- package/lib/src/full-screen/interface.d.ts +2 -1
- package/lib/src/index.js +1 -1
- package/lib/src/path-map.js +1 -1
- package/package.json +1 -1
- package/theme/ap-product-info/ap-product-info.css +87 -0
- package/theme/ap-product-info/ap-product-info.less +100 -0
- package/theme/index.css +87 -0
- package/theme/index.less +1 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as Fe, useSlots as Be, getCurrentInstance as Ie, ref as k, computed as n, unref as o, watch as
|
|
1
|
+
import { defineComponent as Fe, useSlots as Be, getCurrentInstance as Ie, ref as k, computed as n, unref as o, watch as F, createElementBlock as B, openBlock as s, normalizeStyle as z, normalizeClass as g, createCommentVNode as S, createElementVNode as I, createVNode as U, mergeProps as h, createSlots as G, withCtx as v, Fragment as X, renderList as A, createBlock as p, resolveDynamicComponent as _, renderSlot as V, normalizeProps as J, guardReactiveProps as Pe } from "vue";
|
|
2
2
|
import { VxeTable as Ee, VxeColumn as Q } from "vxe-table";
|
|
3
3
|
import "vxe-table/es/style.css";
|
|
4
4
|
import "vxe-pc-ui/es/style.css";
|
|
@@ -93,6 +93,7 @@ const ko = /* @__PURE__ */ Fe({
|
|
|
93
93
|
defaultData: {},
|
|
94
94
|
dataSource: {},
|
|
95
95
|
onLoadingChange: {},
|
|
96
|
+
onShownColumnsChange: {},
|
|
96
97
|
searchForm: { type: [Boolean, Object], default: void 0 },
|
|
97
98
|
beforeSearchSubmit: {},
|
|
98
99
|
pagination: { type: [Boolean, Object], default: void 0 },
|
|
@@ -113,77 +114,77 @@ const ko = /* @__PURE__ */ Fe({
|
|
|
113
114
|
var q;
|
|
114
115
|
const L = Be(), a = ae, w = (q = Ie()) == null ? void 0 : q.appContext.app;
|
|
115
116
|
w && !w.__VXE_PC_UI_INSTALLED__ && (w.use(Y), w.__VXE_PC_UI_INSTALLED__ = !0);
|
|
116
|
-
const { e:
|
|
117
|
+
const { e: P, b: i, be: te } = Xe("ap-grid"), le = Je("valueTypeMap"), d = k([]), D = k([]), m = k(), C = k(a.size), [, c] = Ge(), { t: ne } = Qe();
|
|
117
118
|
Y.setConfig({
|
|
118
|
-
i18n: (e,
|
|
119
|
+
i18n: (e, r) => ne(`ap.${e}`, r)
|
|
119
120
|
});
|
|
120
|
-
const { renderConfig: se, updateSignal:
|
|
121
|
+
const { renderConfig: se, updateSignal: de } = Ue(d);
|
|
121
122
|
let O = 0;
|
|
122
|
-
const
|
|
123
|
-
if (
|
|
124
|
-
return
|
|
123
|
+
const ie = n(() => {
|
|
124
|
+
if (m.value)
|
|
125
|
+
return m.value.$el.querySelector(
|
|
125
126
|
".vxe-table--header-inner-wrapper"
|
|
126
127
|
);
|
|
127
128
|
}), K = n(() => {
|
|
128
|
-
var e,
|
|
129
|
-
return O++, ((
|
|
130
|
-
(
|
|
131
|
-
)) == null ? void 0 :
|
|
132
|
-
let
|
|
133
|
-
return Z(u.order) -
|
|
134
|
-
})) == null ? void 0 :
|
|
129
|
+
var e, r, l;
|
|
130
|
+
return O++, ((l = (r = (e = a.columns) == null ? void 0 : e.filter(
|
|
131
|
+
(t) => !t.hideInSearch && t.dataIndex && (t.valueType || t.customRenderFormItem) && !ze.includes(t.valueType)
|
|
132
|
+
)) == null ? void 0 : r.sort((t, u) => {
|
|
133
|
+
let y = Z(t.order);
|
|
134
|
+
return Z(u.order) - y;
|
|
135
|
+
})) == null ? void 0 : l.map((t) => {
|
|
135
136
|
const u = Ae(
|
|
136
|
-
|
|
137
|
-
_e(
|
|
138
|
-
),
|
|
139
|
-
...
|
|
137
|
+
t,
|
|
138
|
+
_e(t.fieldProps, {})
|
|
139
|
+
), y = {
|
|
140
|
+
...t,
|
|
140
141
|
fieldProps: {
|
|
141
|
-
label:
|
|
142
|
-
name:
|
|
142
|
+
label: t.title,
|
|
143
|
+
name: t.dataIndex,
|
|
143
144
|
...u || {},
|
|
144
145
|
_signal: O
|
|
145
146
|
},
|
|
146
147
|
renderNode: void 0
|
|
147
148
|
};
|
|
148
|
-
return
|
|
149
|
-
|
|
149
|
+
return y.renderNode = Ve(
|
|
150
|
+
y,
|
|
150
151
|
o(le)
|
|
151
|
-
),
|
|
152
|
+
), y;
|
|
152
153
|
})) || [];
|
|
153
|
-
}),
|
|
154
|
-
|
|
155
|
-
a.card ? null :
|
|
156
|
-
a.adaptive ?
|
|
157
|
-
a.sticky ?
|
|
158
|
-
].filter(Boolean)), $ = n(() => ee(o(
|
|
154
|
+
}), ce = n(() => [
|
|
155
|
+
i(),
|
|
156
|
+
a.card ? null : i("wrapper"),
|
|
157
|
+
a.adaptive ? i("adaptive") : null,
|
|
158
|
+
a.sticky ? i("sticky") : null
|
|
159
|
+
].filter(Boolean)), $ = n(() => ee(o(d), (e) => {
|
|
159
160
|
if (e.sorter === !0)
|
|
160
161
|
return e.key || e.dataIndex;
|
|
161
|
-
}).filter(Boolean)), H = n(() => ee(o(
|
|
162
|
+
}).filter(Boolean)), H = n(() => ee(o(d), (e) => {
|
|
162
163
|
if (e.filters && !e.onFilter)
|
|
163
164
|
return e.key || e.dataIndex;
|
|
164
165
|
}).filter(Boolean)), {
|
|
165
|
-
formRef:
|
|
166
|
+
formRef: E,
|
|
166
167
|
submit: j,
|
|
167
168
|
reset: W,
|
|
168
|
-
refresh:
|
|
169
|
-
data:
|
|
169
|
+
refresh: ue,
|
|
170
|
+
data: f,
|
|
170
171
|
tableProps: M,
|
|
171
172
|
setDataSource: pe,
|
|
172
173
|
handleTableChange: me
|
|
173
174
|
} = Le({
|
|
174
175
|
async request(e) {
|
|
175
|
-
var
|
|
176
|
-
if (!R.value.preserveSelectedRowKeys && b(a.dataSource) &&
|
|
177
|
-
const
|
|
176
|
+
var l;
|
|
177
|
+
if (!R.value.preserveSelectedRowKeys && b(a.dataSource) && T(), !b(a.dataSource)) {
|
|
178
|
+
const t = e.pageSize * (e.current - 1);
|
|
178
179
|
return {
|
|
179
|
-
data: (a.pagination === !1 ? a.dataSource : a.dataSource.slice(
|
|
180
|
+
data: (a.pagination === !1 ? a.dataSource : a.dataSource.slice(t, t + e.pageSize)) || [],
|
|
180
181
|
total: a.dataSource.length || 0
|
|
181
182
|
};
|
|
182
183
|
}
|
|
183
|
-
const
|
|
184
|
+
const r = await ((l = a.request) == null ? void 0 : l.call(a, e));
|
|
184
185
|
return {
|
|
185
|
-
data: (
|
|
186
|
-
total: (
|
|
186
|
+
data: (r == null ? void 0 : r.data) || [],
|
|
187
|
+
total: (r == null ? void 0 : r.total) || 0
|
|
187
188
|
};
|
|
188
189
|
},
|
|
189
190
|
namespace: "ap-grid",
|
|
@@ -196,160 +197,168 @@ const ko = /* @__PURE__ */ Fe({
|
|
|
196
197
|
pagination: a.pagination
|
|
197
198
|
}), { sortChangeEvent: fe, filterChangeEvent: ge, paginationChangeEvent: he } = Oe(me);
|
|
198
199
|
We({
|
|
199
|
-
columns: n(() =>
|
|
200
|
+
columns: n(() => d.value),
|
|
200
201
|
columnsBackup: n(() => D.value),
|
|
201
|
-
size: n(() =>
|
|
202
|
+
size: n(() => C.value ? qe[C.value] : "middle"),
|
|
202
203
|
updateColumns(e) {
|
|
203
|
-
|
|
204
|
+
var r;
|
|
205
|
+
d.value = e, (r = a.onShownColumnsChange) == null || r.call(a, e);
|
|
204
206
|
},
|
|
205
207
|
updateSize(e) {
|
|
206
|
-
|
|
208
|
+
C.value = Me[e];
|
|
207
209
|
},
|
|
208
210
|
renderConfig: n(() => ({
|
|
209
211
|
className: te("table-header", "title"),
|
|
210
|
-
color:
|
|
211
|
-
}))
|
|
212
|
+
color: c.value.colorPrimary
|
|
213
|
+
})),
|
|
214
|
+
dataSource: n(() => o(f).records)
|
|
212
215
|
});
|
|
213
216
|
const ve = n(
|
|
214
|
-
() =>
|
|
217
|
+
() => d.value.some(
|
|
215
218
|
(e) => e.fixed === "left" || e.fixed === !0
|
|
216
219
|
) ? "left" : void 0
|
|
217
220
|
), Ce = n(
|
|
218
|
-
() => b(a.loading) ?
|
|
221
|
+
() => b(a.loading) ? f.loading : a.loading
|
|
219
222
|
), ye = n(
|
|
220
|
-
() => b(a.dataSource) ?
|
|
221
|
-
), { selectedRows: x, rowSelection: R, ...
|
|
223
|
+
() => b(a.dataSource) ? f.records : a.dataSource
|
|
224
|
+
), { selectedRows: x, rowSelection: R, ...Se } = je({
|
|
222
225
|
...a.rowSelection === !0 ? {} : a.rowSelection,
|
|
223
226
|
dataSource: ye,
|
|
224
227
|
rowKey: a.rowKey
|
|
225
|
-
}),
|
|
226
|
-
const e =
|
|
228
|
+
}), N = () => {
|
|
229
|
+
const e = m.value;
|
|
227
230
|
e && (x.value = [
|
|
228
231
|
...e.getCheckboxReserveRecords(),
|
|
229
232
|
...e.getCheckboxRecords()
|
|
230
233
|
]);
|
|
231
|
-
},
|
|
232
|
-
const e =
|
|
234
|
+
}, be = () => {
|
|
235
|
+
const e = m.value;
|
|
233
236
|
e && (x.value = [e.getRadioRecord()]);
|
|
234
237
|
};
|
|
235
|
-
function
|
|
238
|
+
function we() {
|
|
236
239
|
var e;
|
|
237
|
-
return ((e = a.columns) == null ? void 0 : e.filter((
|
|
240
|
+
return ((e = a.columns) == null ? void 0 : e.filter((r) => !r.hideInTable)) || [];
|
|
238
241
|
}
|
|
239
242
|
function xe(e) {
|
|
240
|
-
var l, t
|
|
241
|
-
(
|
|
243
|
+
var r, l, t;
|
|
244
|
+
(t = (l = (r = E.value) == null ? void 0 : r.apForm) == null ? void 0 : l.setFieldsValue) == null || t.call(l, e);
|
|
242
245
|
}
|
|
243
246
|
function Re(e = !1) {
|
|
244
|
-
var
|
|
245
|
-
const
|
|
246
|
-
return (u = (
|
|
247
|
+
var l, t, u;
|
|
248
|
+
const r = e ? "getFieldsValueTransformed" : "getFieldsValue";
|
|
249
|
+
return (u = (t = (l = E.value) == null ? void 0 : l.apForm) == null ? void 0 : t[r]) == null ? void 0 : u.call(t, !0);
|
|
247
250
|
}
|
|
248
|
-
function
|
|
249
|
-
|
|
250
|
-
const e =
|
|
251
|
+
function T() {
|
|
252
|
+
Se.clearAll();
|
|
253
|
+
const e = m.value;
|
|
251
254
|
e && (R.value.type === "radio" ? (e.clearRadioRow(), e.clearRadioReserve()) : (e.clearCheckboxRow(), e.clearCheckboxReserve()));
|
|
252
255
|
}
|
|
253
|
-
async function ke(e,
|
|
254
|
-
var
|
|
255
|
-
const
|
|
256
|
-
if (
|
|
257
|
-
return (
|
|
256
|
+
async function ke(e, r) {
|
|
257
|
+
var t;
|
|
258
|
+
const l = f.records[e];
|
|
259
|
+
if (l)
|
|
260
|
+
return (t = m.value) == null ? void 0 : t.scrollToRow(l, r);
|
|
258
261
|
}
|
|
259
|
-
return
|
|
262
|
+
return F(
|
|
260
263
|
() => [a.columnResizable, a.columns],
|
|
261
264
|
() => {
|
|
262
|
-
|
|
263
|
-
|
|
265
|
+
var r;
|
|
266
|
+
const e = we();
|
|
267
|
+
d.value = e, (r = a.onShownColumnsChange) == null || r.call(a, e), D.value = e;
|
|
264
268
|
},
|
|
265
269
|
{
|
|
266
270
|
deep: !0,
|
|
267
271
|
immediate: !0
|
|
268
272
|
}
|
|
269
|
-
),
|
|
273
|
+
), F(
|
|
270
274
|
() => a.dataSource,
|
|
271
275
|
(e) => {
|
|
272
276
|
pe(e);
|
|
273
277
|
},
|
|
274
278
|
{ immediate: !0, deep: !0 }
|
|
275
|
-
),
|
|
276
|
-
() => o(
|
|
279
|
+
), F(
|
|
280
|
+
() => o(f).loading,
|
|
277
281
|
(e) => {
|
|
278
|
-
var
|
|
279
|
-
(
|
|
282
|
+
var r;
|
|
283
|
+
(r = a.onLoadingChange) == null || r.call(a, e);
|
|
284
|
+
}
|
|
285
|
+
), F(
|
|
286
|
+
() => a.size,
|
|
287
|
+
(e) => {
|
|
288
|
+
C.value = e;
|
|
280
289
|
}
|
|
281
290
|
), re({
|
|
282
291
|
submit: j,
|
|
283
292
|
reset: W,
|
|
284
|
-
refresh:
|
|
293
|
+
refresh: ue,
|
|
285
294
|
setSearchFormValues: xe,
|
|
286
295
|
getSearchFormValues: Re,
|
|
287
|
-
getShowColumns: () => o(
|
|
296
|
+
getShowColumns: () => o(d),
|
|
288
297
|
rowSelection: {
|
|
289
298
|
selectedRows: n(() => x.value),
|
|
290
|
-
clearAll:
|
|
299
|
+
clearAll: T
|
|
291
300
|
},
|
|
292
301
|
scrollToRow: ke
|
|
293
|
-
}), (e,
|
|
294
|
-
class:
|
|
302
|
+
}), (e, r) => (s(), B("div", {
|
|
303
|
+
class: g(ce.value),
|
|
295
304
|
style: z(e.wrapperStyle)
|
|
296
305
|
}, [
|
|
297
|
-
o(b)(e.dataSource) && e.searchForm !== !1 && K.value.length > 0 ? (s(),
|
|
306
|
+
o(b)(e.dataSource) && e.searchForm !== !1 && K.value.length > 0 ? (s(), B("div", {
|
|
298
307
|
key: 0,
|
|
299
|
-
class:
|
|
308
|
+
class: g(e.card ? o(P)("search-wrapper") : null),
|
|
300
309
|
style: z(e.searchFormWrapperStyle)
|
|
301
310
|
}, [
|
|
302
|
-
U(o(Te).SearchForm,
|
|
311
|
+
U(o(Te).SearchForm, h(e.searchForm || {}, {
|
|
303
312
|
ref_key: "formRef",
|
|
304
|
-
ref:
|
|
313
|
+
ref: E,
|
|
305
314
|
"custom-reset": "",
|
|
306
315
|
"submit-loading": o(M).loading,
|
|
307
316
|
onSubmit: o(j),
|
|
308
317
|
onReset: o(W)
|
|
309
318
|
}), G({
|
|
310
|
-
default:
|
|
311
|
-
(s(!0),
|
|
312
|
-
key:
|
|
313
|
-
item:
|
|
319
|
+
default: v(() => [
|
|
320
|
+
(s(!0), B(X, null, A(K.value, (l) => (s(), p(_(l.renderNode.Comp), h({
|
|
321
|
+
key: l.dataIndex,
|
|
322
|
+
item: l,
|
|
314
323
|
ref_for: !0
|
|
315
|
-
},
|
|
316
|
-
span:
|
|
317
|
-
"custom-render":
|
|
324
|
+
}, l.fieldProps || {}, {
|
|
325
|
+
span: l.span,
|
|
326
|
+
"custom-render": l.renderNode.render
|
|
318
327
|
}), null, 16, ["item", "span", "custom-render"]))), 128))
|
|
319
328
|
]),
|
|
320
329
|
_: 2
|
|
321
330
|
}, [
|
|
322
331
|
L.searchFormExtra ? {
|
|
323
332
|
name: "extra",
|
|
324
|
-
fn:
|
|
333
|
+
fn: v(() => [
|
|
325
334
|
V(e.$slots, "searchFormExtra")
|
|
326
335
|
]),
|
|
327
336
|
key: "0"
|
|
328
337
|
} : void 0
|
|
329
338
|
]), 1040, ["submit-loading", "onSubmit", "onReset"])
|
|
330
|
-
], 6)) :
|
|
331
|
-
|
|
332
|
-
class:
|
|
339
|
+
], 6)) : S("", !0),
|
|
340
|
+
I("div", {
|
|
341
|
+
class: g([o(P)("table-wrapper"), e.card ? o(P)("table-wrapper-card") : null]),
|
|
333
342
|
style: z(e.tableWrapperStyle)
|
|
334
343
|
}, [
|
|
335
|
-
|
|
336
|
-
class:
|
|
344
|
+
I("div", {
|
|
345
|
+
class: g(o(i)("header-wrapper"))
|
|
337
346
|
}, [
|
|
338
347
|
V(e.$slots, "title", {
|
|
339
348
|
selectedRows: o(x),
|
|
340
349
|
selectedRowKeys: o(R).selectedRowKeys,
|
|
341
|
-
shownColumns:
|
|
342
|
-
clearAll:
|
|
350
|
+
shownColumns: d.value,
|
|
351
|
+
clearAll: T
|
|
343
352
|
})
|
|
344
353
|
], 2),
|
|
345
|
-
|
|
346
|
-
class:
|
|
354
|
+
I("div", {
|
|
355
|
+
class: g(o(i)("vxe-wrapper"))
|
|
347
356
|
}, [
|
|
348
|
-
(s(),
|
|
357
|
+
(s(), p(o(Ee), h(o(Ke)(a), {
|
|
349
358
|
ref_key: "tableRef",
|
|
350
|
-
ref:
|
|
351
|
-
key: o(
|
|
352
|
-
data: o(
|
|
359
|
+
ref: m,
|
|
360
|
+
key: o(de),
|
|
361
|
+
data: o(f).records,
|
|
353
362
|
"sort-config": { remote: $.value.length > 0 },
|
|
354
363
|
"filter-config": { remote: H.value.length > 0 },
|
|
355
364
|
loading: Ce.value,
|
|
@@ -358,62 +367,64 @@ const ko = /* @__PURE__ */ Fe({
|
|
|
358
367
|
keyField: a.rowKey
|
|
359
368
|
},
|
|
360
369
|
style: {
|
|
361
|
-
"--vxe-ui-table-row-checkbox-checked-background-color": o(
|
|
362
|
-
"--vxe-ui-table-row-hover-checkbox-checked-background-color": o(
|
|
363
|
-
"--vxe-ui-font-primary-color": o(
|
|
370
|
+
"--vxe-ui-table-row-checkbox-checked-background-color": o(c).controlItemBgActive,
|
|
371
|
+
"--vxe-ui-table-row-hover-checkbox-checked-background-color": o(c).controlItemBgActiveHover,
|
|
372
|
+
"--vxe-ui-font-primary-color": o(c).colorPrimary,
|
|
364
373
|
"--vxe-ui-table-header-background-color": "var(--ap-table-header-bg)",
|
|
365
374
|
"--vxe-ui-table-cell-padding-default": "12px",
|
|
366
375
|
"--vxe-ui-table-cell-padding-medium": "9px",
|
|
367
|
-
"--vxe-ui-table-row-radio-checked-background-color": o(
|
|
368
|
-
"--vxe-ui-table-row-hover-radio-checked-background-color": o(
|
|
376
|
+
"--vxe-ui-table-row-radio-checked-background-color": o(c).controlItemBgActive,
|
|
377
|
+
"--vxe-ui-table-row-hover-radio-checked-background-color": o(c).controlItemBgActiveHover,
|
|
378
|
+
"--vxe-ui-font-color": o(c).colorTextBase,
|
|
379
|
+
"--vxe-ui-table-border-color": o(c).colorBorderSecondary
|
|
369
380
|
},
|
|
370
|
-
size:
|
|
381
|
+
size: C.value,
|
|
371
382
|
onSortChange: o(fe),
|
|
372
383
|
onFilterChange: o(ge),
|
|
373
|
-
onCheckboxChange:
|
|
374
|
-
onCheckboxRangeChange:
|
|
375
|
-
onCheckboxAll:
|
|
376
|
-
onRadioChange:
|
|
384
|
+
onCheckboxChange: N,
|
|
385
|
+
onCheckboxRangeChange: N,
|
|
386
|
+
onCheckboxAll: N,
|
|
387
|
+
onRadioChange: be
|
|
377
388
|
}), G({
|
|
378
|
-
empty:
|
|
389
|
+
empty: v(() => [
|
|
379
390
|
U(o(oe), {
|
|
380
391
|
image: o(oe).PRESENTED_IMAGE_SIMPLE
|
|
381
392
|
}, null, 8, ["image"])
|
|
382
393
|
]),
|
|
383
|
-
default:
|
|
384
|
-
a.expandable ? (s(),
|
|
385
|
-
content:
|
|
386
|
-
(s(),
|
|
394
|
+
default: v(() => [
|
|
395
|
+
a.expandable ? (s(), p(o(Q), h({ key: 0 }, o($e)(e.expandable), { fixed: ve.value }), {
|
|
396
|
+
content: v((l) => [
|
|
397
|
+
(s(), p(_(a.expandable.renderContent(l))))
|
|
387
398
|
]),
|
|
388
399
|
_: 1
|
|
389
|
-
}, 16, ["fixed"])) :
|
|
390
|
-
a.rowSelection ? (s(),
|
|
391
|
-
(s(!0),
|
|
392
|
-
key:
|
|
400
|
+
}, 16, ["fixed"])) : S("", !0),
|
|
401
|
+
a.rowSelection ? (s(), p(o(Q), J(h({ key: 1 }, o(He)(o(R), d.value))), null, 16)) : S("", !0),
|
|
402
|
+
(s(!0), B(X, null, A(o(se), (l) => (s(), p(_(l), {
|
|
403
|
+
key: l.props.colId
|
|
393
404
|
}))), 128))
|
|
394
405
|
]),
|
|
395
406
|
_: 2
|
|
396
407
|
}, [
|
|
397
|
-
A(o(Ne)(L, ["searchFormExtra"]), (
|
|
398
|
-
name:
|
|
399
|
-
fn:
|
|
400
|
-
V(e.$slots,
|
|
408
|
+
A(o(Ne)(L, ["searchFormExtra"]), (l, t) => ({
|
|
409
|
+
name: t,
|
|
410
|
+
fn: v((u) => [
|
|
411
|
+
V(e.$slots, t, J(Pe(u || {})))
|
|
401
412
|
])
|
|
402
413
|
}))
|
|
403
414
|
]), 1040, ["data", "sort-config", "filter-config", "loading", "row-config", "style", "size", "onSortChange", "onFilterChange"]))
|
|
404
415
|
], 2),
|
|
405
|
-
|
|
406
|
-
class:
|
|
416
|
+
I("div", {
|
|
417
|
+
class: g(o(i)("pagination-wrapper"))
|
|
407
418
|
}, [
|
|
408
|
-
e.sticky ? (s(),
|
|
419
|
+
e.sticky ? (s(), p(o(Ye), {
|
|
409
420
|
key: 0,
|
|
410
421
|
direction: "horizontal",
|
|
411
|
-
"scroll-container":
|
|
412
|
-
}, null, 8, ["scroll-container"])) :
|
|
413
|
-
e.pagination !== !1 ? (s(),
|
|
422
|
+
"scroll-container": ie.value
|
|
423
|
+
}, null, 8, ["scroll-container"])) : S("", !0),
|
|
424
|
+
e.pagination !== !1 ? (s(), p(o(De), h({
|
|
414
425
|
key: 1,
|
|
415
|
-
class: o(
|
|
416
|
-
}, o(M).pagination, { onChange: o(he) }), null, 16, ["class", "onChange"])) :
|
|
426
|
+
class: o(i)("pagination")
|
|
427
|
+
}, o(M).pagination, { onChange: o(he) }), null, 16, ["class", "onChange"])) : S("", !0)
|
|
417
428
|
], 2)
|
|
418
429
|
], 6)
|
|
419
430
|
], 6));
|
|
@@ -60,6 +60,10 @@ export type ApGridColumnType<RecordType = any, ExtraValueType = 'text', ValueTyp
|
|
|
60
60
|
* 指定值类型(将会用于默认渲染和查询表单生成)
|
|
61
61
|
*/
|
|
62
62
|
valueType?: MergedValueType;
|
|
63
|
+
/**
|
|
64
|
+
* 指定渲染内容是否为html
|
|
65
|
+
*/
|
|
66
|
+
html?: boolean;
|
|
63
67
|
/**
|
|
64
68
|
* 值类型额外配置的参数(用于查询表单渲染)
|
|
65
69
|
*/
|
|
@@ -158,6 +162,11 @@ export type ApGridProps<RecordType = any, ParamsType = any> = Omit<TableProps<Re
|
|
|
158
162
|
* @returns
|
|
159
163
|
*/
|
|
160
164
|
onLoadingChange?: (loading: boolean) => void;
|
|
165
|
+
/**
|
|
166
|
+
* 当可显示列变更后触发
|
|
167
|
+
* @returns
|
|
168
|
+
*/
|
|
169
|
+
onShownColumnsChange?: (columns: ApGridColumnType<RecordType>[]) => void;
|
|
161
170
|
/**
|
|
162
171
|
* 查询表单配置,设置为false表示不渲染查询表单
|
|
163
172
|
*/
|