qidian-vue-ui 1.1.41 → 1.1.43
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/crud/search/index.vue.mjs +1 -1
- package/dist/components/crud/search/index.vue2.mjs +4 -4
- package/dist/components/crud/search/index.vue2.mjs.map +1 -1
- package/dist/components/dialog/index.vue.mjs +1 -1
- package/dist/components/dialog/index.vue.mjs.map +1 -1
- package/dist/components/service-dialog-table-select/index.vue.d.ts +28 -0
- package/dist/components/service-dialog-table-select/index.vue.mjs +1 -1
- package/dist/components/service-dialog-table-select/index.vue2.mjs +360 -211
- package/dist/components/service-dialog-table-select/index.vue2.mjs.map +1 -1
- package/dist/components/service-dialog-table-select/types.d.ts +5 -1
- package/dist/components/service-popup-table-select/index.vue.d.ts +28 -0
- package/dist/components/service-popup-table-select/index.vue.mjs +1 -1
- package/dist/components/service-popup-table-select/index.vue2.mjs +350 -192
- package/dist/components/service-popup-table-select/index.vue2.mjs.map +1 -1
- package/dist/components/service-popup-table-select/types.d.ts +5 -1
- package/dist/qidian-vue-ui.css +20 -20
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent, mergeDefaults, ref, reactive, computed, watch, createBlock, openBlock, unref, mergeProps, isRef, withCtx,
|
|
1
|
+
import { defineComponent, mergeDefaults, ref, reactive, computed, createVNode, watch, createBlock, openBlock, unref, mergeProps, isRef, withCtx, createSlots, renderList, createElementBlock, renderSlot, normalizeProps, guardReactiveProps } from "vue";
|
|
2
2
|
import { isEmpty, identifyType, extractSlotsWithPrefix } from "qidian-shared";
|
|
3
3
|
import { Popup, Select, Input, Space, Button } from "tdesign-vue-next";
|
|
4
|
-
import {
|
|
4
|
+
import { AddIcon, SearchIcon } from "tdesign-icons-vue-next";
|
|
5
5
|
import { qdServicePopup, qdServicePopupTableSelectProps } from "./props.mjs";
|
|
6
6
|
import { useVModels } from "../../node_modules/.pnpm/@vueuse_core@14.0.0_vue@3.5.22_typescript@5.9.3_/node_modules/@vueuse/core/dist/index.mjs";
|
|
7
7
|
import { qdDialogTableSelectSearchGrid } from "../service-dialog-table-select/props.mjs";
|
|
@@ -35,34 +35,60 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
35
35
|
__name: "index",
|
|
36
36
|
props: /* @__PURE__ */ mergeDefaults({
|
|
37
37
|
tableSize: {},
|
|
38
|
+
addBtn: {},
|
|
39
|
+
addConfirmBtn: {},
|
|
40
|
+
addCancelBtn: {},
|
|
41
|
+
addInput: {},
|
|
38
42
|
title: {},
|
|
39
43
|
permiPrefix: {},
|
|
40
44
|
search: {},
|
|
41
45
|
searchData: {},
|
|
42
46
|
detail: {},
|
|
43
|
-
headerBg: {
|
|
47
|
+
headerBg: {
|
|
48
|
+
type: Boolean
|
|
49
|
+
},
|
|
44
50
|
tree: {},
|
|
45
|
-
loadingWithData: {
|
|
46
|
-
|
|
51
|
+
loadingWithData: {
|
|
52
|
+
type: Boolean
|
|
53
|
+
},
|
|
54
|
+
beforeDragSort: {
|
|
55
|
+
type: Function
|
|
56
|
+
},
|
|
47
57
|
expandedTreeNodes: {},
|
|
48
58
|
defaultExpandedTreeNodes: {},
|
|
49
59
|
treeExpandAndFoldIcon: {},
|
|
50
|
-
onAbnormalDragSort: {
|
|
51
|
-
|
|
52
|
-
|
|
60
|
+
onAbnormalDragSort: {
|
|
61
|
+
type: Function
|
|
62
|
+
},
|
|
63
|
+
onExpandedTreeNodesChange: {
|
|
64
|
+
type: Function
|
|
65
|
+
},
|
|
66
|
+
onTreeExpandChange: {
|
|
67
|
+
type: Function
|
|
68
|
+
},
|
|
53
69
|
asyncLoading: {},
|
|
54
70
|
columnController: {},
|
|
55
|
-
columnControllerVisible: {
|
|
56
|
-
|
|
71
|
+
columnControllerVisible: {
|
|
72
|
+
type: Boolean
|
|
73
|
+
},
|
|
74
|
+
defaultColumnControllerVisible: {
|
|
75
|
+
type: Boolean
|
|
76
|
+
},
|
|
57
77
|
columns: {},
|
|
58
78
|
displayColumns: {},
|
|
59
79
|
defaultDisplayColumns: {},
|
|
60
80
|
dragSort: {},
|
|
61
81
|
dragSortOptions: {},
|
|
62
|
-
editableCellState: {
|
|
82
|
+
editableCellState: {
|
|
83
|
+
type: Function
|
|
84
|
+
},
|
|
63
85
|
editableRowKeys: {},
|
|
64
|
-
expandIcon: {
|
|
65
|
-
|
|
86
|
+
expandIcon: {
|
|
87
|
+
type: Boolean
|
|
88
|
+
},
|
|
89
|
+
expandOnRowClick: {
|
|
90
|
+
type: Boolean
|
|
91
|
+
},
|
|
66
92
|
expandedRow: {},
|
|
67
93
|
expandedRowKeys: {},
|
|
68
94
|
defaultExpandedRowKeys: {},
|
|
@@ -70,104 +96,222 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
70
96
|
filterRow: {},
|
|
71
97
|
filterValue: {},
|
|
72
98
|
defaultFilterValue: {},
|
|
73
|
-
hideSortTips: {
|
|
99
|
+
hideSortTips: {
|
|
100
|
+
type: Boolean
|
|
101
|
+
},
|
|
74
102
|
indeterminateSelectedRowKeys: {},
|
|
75
|
-
multipleSort: {
|
|
76
|
-
|
|
103
|
+
multipleSort: {
|
|
104
|
+
type: Boolean
|
|
105
|
+
},
|
|
106
|
+
rowSelectionAllowUncheck: {
|
|
107
|
+
type: Boolean
|
|
108
|
+
},
|
|
77
109
|
rowSelectionType: {},
|
|
78
|
-
selectOnRowClick: {
|
|
110
|
+
selectOnRowClick: {
|
|
111
|
+
type: Boolean
|
|
112
|
+
},
|
|
79
113
|
defaultSelectedRowKeys: {},
|
|
80
|
-
showSortColumnBgColor: {
|
|
114
|
+
showSortColumnBgColor: {
|
|
115
|
+
type: Boolean
|
|
116
|
+
},
|
|
81
117
|
sort: {},
|
|
82
118
|
defaultSort: {},
|
|
83
119
|
sortIcon: {},
|
|
84
|
-
sortOnRowDraggable: {
|
|
120
|
+
sortOnRowDraggable: {
|
|
121
|
+
type: Boolean
|
|
122
|
+
},
|
|
85
123
|
defaultActiveRowKeys: {},
|
|
86
|
-
allowResizeColumnWidth: {
|
|
87
|
-
|
|
88
|
-
|
|
124
|
+
allowResizeColumnWidth: {
|
|
125
|
+
type: Boolean
|
|
126
|
+
},
|
|
127
|
+
attach: {
|
|
128
|
+
type: [String, Function]
|
|
129
|
+
},
|
|
130
|
+
bordered: {
|
|
131
|
+
type: Boolean
|
|
132
|
+
},
|
|
89
133
|
bottomContent: {},
|
|
90
134
|
cellEmptyContent: {},
|
|
91
135
|
data: {},
|
|
92
|
-
disableDataPage: {
|
|
93
|
-
|
|
136
|
+
disableDataPage: {
|
|
137
|
+
type: Boolean
|
|
138
|
+
},
|
|
139
|
+
disableSpaceInactiveRow: {
|
|
140
|
+
type: Boolean
|
|
141
|
+
},
|
|
94
142
|
empty: {},
|
|
95
143
|
firstFullRow: {},
|
|
96
144
|
fixedRows: {},
|
|
97
145
|
footData: {},
|
|
98
146
|
footerAffixProps: {},
|
|
99
|
-
footerAffixedBottom: {
|
|
147
|
+
footerAffixedBottom: {
|
|
148
|
+
type: [Boolean, Object]
|
|
149
|
+
},
|
|
100
150
|
footerSummary: {},
|
|
101
151
|
headerAffixProps: {},
|
|
102
|
-
headerAffixedTop: {
|
|
152
|
+
headerAffixedTop: {
|
|
153
|
+
type: [Boolean, Object]
|
|
154
|
+
},
|
|
103
155
|
height: {},
|
|
104
|
-
horizontalScrollAffixedBottom: {
|
|
105
|
-
|
|
106
|
-
|
|
156
|
+
horizontalScrollAffixedBottom: {
|
|
157
|
+
type: [Boolean, Object]
|
|
158
|
+
},
|
|
159
|
+
hover: {
|
|
160
|
+
type: Boolean
|
|
161
|
+
},
|
|
162
|
+
keyboardRowHover: {
|
|
163
|
+
type: Boolean
|
|
164
|
+
},
|
|
107
165
|
lastFullRow: {},
|
|
108
|
-
lazyLoad: {
|
|
109
|
-
|
|
166
|
+
lazyLoad: {
|
|
167
|
+
type: Boolean
|
|
168
|
+
},
|
|
169
|
+
loading: {
|
|
170
|
+
type: Boolean
|
|
171
|
+
},
|
|
110
172
|
loadingProps: {},
|
|
111
173
|
locale: {},
|
|
112
174
|
maxHeight: {},
|
|
113
|
-
paginationAffixedBottom: {
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
175
|
+
paginationAffixedBottom: {
|
|
176
|
+
type: [Boolean, Object]
|
|
177
|
+
},
|
|
178
|
+
resizable: {
|
|
179
|
+
type: Boolean
|
|
180
|
+
},
|
|
181
|
+
rowAttributes: {
|
|
182
|
+
type: [Object, Function, Array]
|
|
183
|
+
},
|
|
184
|
+
rowClassName: {
|
|
185
|
+
type: [Object, Array, String, Function]
|
|
186
|
+
},
|
|
187
|
+
rowspanAndColspan: {
|
|
188
|
+
type: Function
|
|
189
|
+
},
|
|
190
|
+
rowspanAndColspanInFooter: {
|
|
191
|
+
type: Function
|
|
192
|
+
},
|
|
119
193
|
scroll: {},
|
|
120
|
-
showHeader: {
|
|
121
|
-
|
|
194
|
+
showHeader: {
|
|
195
|
+
type: Boolean
|
|
196
|
+
},
|
|
197
|
+
stripe: {
|
|
198
|
+
type: Boolean
|
|
199
|
+
},
|
|
122
200
|
tableContentWidth: {},
|
|
123
201
|
tableLayout: {},
|
|
124
202
|
topContent: {},
|
|
125
203
|
verticalAlign: {},
|
|
126
|
-
onActiveChange: {
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
204
|
+
onActiveChange: {
|
|
205
|
+
type: Function
|
|
206
|
+
},
|
|
207
|
+
onActiveRowAction: {
|
|
208
|
+
type: Function
|
|
209
|
+
},
|
|
210
|
+
onColumnResizeChange: {
|
|
211
|
+
type: Function
|
|
212
|
+
},
|
|
213
|
+
onPageChange: {
|
|
214
|
+
type: Function
|
|
215
|
+
},
|
|
216
|
+
onRowClick: {
|
|
217
|
+
type: Function
|
|
218
|
+
},
|
|
219
|
+
onRowDblclick: {
|
|
220
|
+
type: Function
|
|
221
|
+
},
|
|
222
|
+
onRowMousedown: {
|
|
223
|
+
type: Function
|
|
224
|
+
},
|
|
225
|
+
onRowMouseenter: {
|
|
226
|
+
type: Function
|
|
227
|
+
},
|
|
228
|
+
onRowMouseleave: {
|
|
229
|
+
type: Function
|
|
230
|
+
},
|
|
231
|
+
onRowMouseover: {
|
|
232
|
+
type: Function
|
|
233
|
+
},
|
|
234
|
+
onRowMouseup: {
|
|
235
|
+
type: Function
|
|
236
|
+
},
|
|
237
|
+
onScroll: {
|
|
238
|
+
type: Function
|
|
239
|
+
},
|
|
240
|
+
onScrollX: {
|
|
241
|
+
type: Function
|
|
242
|
+
},
|
|
243
|
+
onScrollY: {
|
|
244
|
+
type: Function
|
|
245
|
+
},
|
|
246
|
+
cacheKey: {
|
|
247
|
+
type: [String, Function]
|
|
248
|
+
},
|
|
141
249
|
cacheTime: {},
|
|
142
250
|
pollingInterval: {},
|
|
143
|
-
onBefore: {
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
251
|
+
onBefore: {
|
|
252
|
+
type: Function
|
|
253
|
+
},
|
|
254
|
+
onAfter: {
|
|
255
|
+
type: Function
|
|
256
|
+
},
|
|
257
|
+
onSuccess: {
|
|
258
|
+
type: Function
|
|
259
|
+
},
|
|
260
|
+
onError: {
|
|
261
|
+
type: Function
|
|
262
|
+
},
|
|
263
|
+
service: {
|
|
264
|
+
type: Function
|
|
265
|
+
},
|
|
266
|
+
manual: {
|
|
267
|
+
type: Boolean
|
|
268
|
+
},
|
|
269
|
+
transformParams: {
|
|
270
|
+
type: Function
|
|
271
|
+
},
|
|
272
|
+
transformRes: {
|
|
273
|
+
type: Function
|
|
274
|
+
},
|
|
151
275
|
pagination: {},
|
|
152
276
|
modelValue: {},
|
|
153
|
-
multiple: {
|
|
154
|
-
|
|
155
|
-
|
|
277
|
+
multiple: {
|
|
278
|
+
type: Boolean
|
|
279
|
+
},
|
|
280
|
+
readonly: {
|
|
281
|
+
type: Boolean
|
|
282
|
+
},
|
|
283
|
+
disabled: {
|
|
284
|
+
type: Boolean
|
|
285
|
+
},
|
|
156
286
|
placeholder: {},
|
|
157
|
-
clearable: {
|
|
158
|
-
|
|
287
|
+
clearable: {
|
|
288
|
+
type: Boolean
|
|
289
|
+
},
|
|
290
|
+
creatable: {
|
|
291
|
+
type: Boolean
|
|
292
|
+
},
|
|
159
293
|
keys: {},
|
|
160
294
|
size: {},
|
|
161
295
|
valueType: {},
|
|
162
296
|
fillOptions: {},
|
|
163
|
-
popupVisible: {
|
|
297
|
+
popupVisible: {
|
|
298
|
+
type: Boolean
|
|
299
|
+
},
|
|
164
300
|
popupProps: {},
|
|
165
|
-
onClear: {
|
|
166
|
-
|
|
167
|
-
|
|
301
|
+
onClear: {
|
|
302
|
+
type: Function
|
|
303
|
+
},
|
|
304
|
+
onCreate: {
|
|
305
|
+
type: Function
|
|
306
|
+
},
|
|
307
|
+
onChange: {
|
|
308
|
+
type: Function
|
|
309
|
+
}
|
|
168
310
|
}, qdServicePopupTableSelectProps),
|
|
169
311
|
emits: ["update:modelValue", "update:popupVisible", "update:searchData", "update:data", "update:columnControllerVisible", "update:displayColumns", "update:expandedRowKeys", "update:filterValue", "update:sort", "update:expandedTreeNodes"],
|
|
170
|
-
setup(__props, {
|
|
312
|
+
setup(__props, {
|
|
313
|
+
emit: __emit
|
|
314
|
+
}) {
|
|
171
315
|
const props = __props;
|
|
172
316
|
const emit = __emit;
|
|
173
317
|
const {
|
|
@@ -184,7 +328,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
184
328
|
} = useVModels(props, emit, {
|
|
185
329
|
passive: true
|
|
186
330
|
});
|
|
187
|
-
const {
|
|
331
|
+
const {
|
|
332
|
+
t
|
|
333
|
+
} = useConfig("dialogTableSelect");
|
|
188
334
|
const tdReadonly = useReadonly();
|
|
189
335
|
const tdDisabled = useDisabled();
|
|
190
336
|
const selectedRowKeys = ref([]);
|
|
@@ -222,9 +368,15 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
222
368
|
onChange,
|
|
223
369
|
search,
|
|
224
370
|
tableSize,
|
|
371
|
+
addBtn,
|
|
372
|
+
addConfirmBtn,
|
|
373
|
+
addCancelBtn,
|
|
374
|
+
addInput,
|
|
225
375
|
...tableOptions
|
|
226
376
|
} = props;
|
|
227
|
-
const rePopupOptions = merge({}, qdServicePopup, {
|
|
377
|
+
const rePopupOptions = merge({}, qdServicePopup, {
|
|
378
|
+
trigger: "click"
|
|
379
|
+
}, popupProps, {
|
|
228
380
|
disabled: tdDisabled.value || tdReadonly.value || disabled || readonly || popupProps?.disabled
|
|
229
381
|
});
|
|
230
382
|
const onVisibleChange = rePopupOptions.onVisibleChange;
|
|
@@ -252,6 +404,40 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
252
404
|
reOverlayClassName["qd-popup-table-select__overlay"] = true;
|
|
253
405
|
}
|
|
254
406
|
rePopupOptions.overlayClassName = reOverlayClassName;
|
|
407
|
+
const addBtnOptions = merge({}, {
|
|
408
|
+
block: true,
|
|
409
|
+
theme: "primary",
|
|
410
|
+
variant: "dashed",
|
|
411
|
+
icon: () => createVNode(AddIcon, null, null),
|
|
412
|
+
content: t("addText"),
|
|
413
|
+
onClick: () => {
|
|
414
|
+
addCustom.visible = true;
|
|
415
|
+
}
|
|
416
|
+
}, typeof addBtn === "string" ? {
|
|
417
|
+
content: addBtn
|
|
418
|
+
} : addBtn);
|
|
419
|
+
const addConfirmBtnOptions = merge({}, {
|
|
420
|
+
content: t("addConfirmText"),
|
|
421
|
+
onClick: confirmAddCustom
|
|
422
|
+
}, typeof addConfirmBtn === "string" ? {
|
|
423
|
+
content: addConfirmBtn,
|
|
424
|
+
disabled: addConfirmDisabled.value
|
|
425
|
+
} : {
|
|
426
|
+
...addConfirmBtn,
|
|
427
|
+
disabled: addConfirmDisabled.value || addConfirmBtn?.disabled
|
|
428
|
+
});
|
|
429
|
+
const addCancelBtnOptions = merge({}, {
|
|
430
|
+
variant: "outline",
|
|
431
|
+
content: t("addCancelText"),
|
|
432
|
+
onClick: cancelAddCustom
|
|
433
|
+
}, typeof addCancelBtn === "string" ? {
|
|
434
|
+
content: addCancelBtn
|
|
435
|
+
} : addCancelBtn);
|
|
436
|
+
const addInputOptions = merge({}, {
|
|
437
|
+
clearable: true
|
|
438
|
+
}, typeof addInput === "string" ? {
|
|
439
|
+
placeholder: addInput
|
|
440
|
+
} : addInput);
|
|
255
441
|
return {
|
|
256
442
|
creatable,
|
|
257
443
|
fillOptions,
|
|
@@ -279,6 +465,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
279
465
|
onClear,
|
|
280
466
|
onCreate,
|
|
281
467
|
onChange,
|
|
468
|
+
addBtnOptions,
|
|
469
|
+
addConfirmBtnOptions,
|
|
470
|
+
addCancelBtnOptions,
|
|
471
|
+
addInputOptions,
|
|
282
472
|
models: {
|
|
283
473
|
modelValue: modelValue2,
|
|
284
474
|
popupVisible: popupVisible2,
|
|
@@ -296,7 +486,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
296
486
|
let fillOptionsWatchStop;
|
|
297
487
|
function handleSelectChange(rowKeys, options) {
|
|
298
488
|
selectedRows.value = options.selectedRowData;
|
|
299
|
-
const {
|
|
489
|
+
const {
|
|
490
|
+
selectOptions
|
|
491
|
+
} = reProps.value;
|
|
300
492
|
const valueKey = selectOptions.keys?.value || qdServiceSelectKeys.value;
|
|
301
493
|
const labelKey = selectOptions.keys?.label || qdServiceSelectKeys.label;
|
|
302
494
|
if (selectOptions.valueType === "value") {
|
|
@@ -344,127 +536,93 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
344
536
|
value: ""
|
|
345
537
|
});
|
|
346
538
|
}
|
|
347
|
-
fillOptionsWatchStop = watch(
|
|
348
|
-
()
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
);
|
|
539
|
+
fillOptionsWatchStop = watch(() => reProps.value.fillOptions, (fillOpts) => {
|
|
540
|
+
if (!fillOpts?.length) return;
|
|
541
|
+
selectedRows.value = fillOpts;
|
|
542
|
+
}, {
|
|
543
|
+
immediate: true,
|
|
544
|
+
deep: true
|
|
545
|
+
});
|
|
355
546
|
return (_ctx, _cache) => {
|
|
356
547
|
return openBlock(), createBlock(unref(Popup), mergeProps({
|
|
357
548
|
modelValue: unref(popupVisible),
|
|
358
|
-
"onUpdate:modelValue": _cache[
|
|
549
|
+
"onUpdate:modelValue": _cache[12] || (_cache[12] = ($event) => isRef(popupVisible) ? popupVisible.value = $event : null)
|
|
359
550
|
}, reProps.value.popupOptions), {
|
|
360
|
-
content: withCtx(() => [
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
key: "0"
|
|
436
|
-
} : void 0,
|
|
437
|
-
renderList(unref(extractSlotsWithPrefix)(_ctx.$slots, "search"), (item) => {
|
|
438
|
-
return {
|
|
439
|
-
name: item.filterName,
|
|
440
|
-
fn: withCtx((slotProps) => [
|
|
441
|
-
renderSlot(_ctx.$slots, item.originalName, normalizeProps(guardReactiveProps(slotProps)), void 0, true)
|
|
442
|
-
])
|
|
443
|
-
};
|
|
444
|
-
}),
|
|
445
|
-
renderList(unref(extractSlotsWithPrefix)(_ctx.$slots, "table"), (item) => {
|
|
446
|
-
return {
|
|
447
|
-
name: item.filterName,
|
|
448
|
-
fn: withCtx((slotProps) => [
|
|
449
|
-
renderSlot(_ctx.$slots, item.originalName, normalizeProps(guardReactiveProps(slotProps)), void 0, true)
|
|
450
|
-
])
|
|
451
|
-
};
|
|
452
|
-
})
|
|
453
|
-
]), 1040, ["search-data", "data", "selected-row-keys", "active-row-keys", "column-controller-visible", "display-columns", "expanded-rowKeys", "filter-value", "sort", "expanded-tree-nodes"])
|
|
454
|
-
]),
|
|
455
|
-
default: withCtx(() => [
|
|
456
|
-
createVNode(unref(Select), mergeProps({
|
|
457
|
-
modelValue: unref(modelValue),
|
|
458
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(modelValue) ? modelValue.value = $event : null),
|
|
459
|
-
options: selectedRows.value,
|
|
460
|
-
"popup-visible": false
|
|
461
|
-
}, reProps.value.selectOptions, { onClear: handleClear }), {
|
|
462
|
-
suffixIcon: withCtx(() => [
|
|
463
|
-
createVNode(unref(SearchIcon))
|
|
464
|
-
]),
|
|
465
|
-
_: 1
|
|
466
|
-
}, 16, ["modelValue", "options"])
|
|
467
|
-
]),
|
|
551
|
+
content: withCtx(() => [createVNode(unref(QdCrudTable), mergeProps({
|
|
552
|
+
class: "qd-popup-table-select__table",
|
|
553
|
+
"search-data": unref(searchData),
|
|
554
|
+
"onUpdate:searchData": _cache[2] || (_cache[2] = ($event) => isRef(searchData) ? searchData.value = $event : null),
|
|
555
|
+
data: unref(data),
|
|
556
|
+
"onUpdate:data": _cache[3] || (_cache[3] = ($event) => isRef(data) ? data.value = $event : null),
|
|
557
|
+
"selected-row-keys": selectedRowKeys.value,
|
|
558
|
+
"onUpdate:selectedRowKeys": _cache[4] || (_cache[4] = ($event) => selectedRowKeys.value = $event),
|
|
559
|
+
"active-row-keys": selectedRowKeys.value,
|
|
560
|
+
"onUpdate:activeRowKeys": _cache[5] || (_cache[5] = ($event) => selectedRowKeys.value = $event),
|
|
561
|
+
"column-controller-visible": unref(columnControllerVisible),
|
|
562
|
+
"onUpdate:columnControllerVisible": _cache[6] || (_cache[6] = ($event) => isRef(columnControllerVisible) ? columnControllerVisible.value = $event : null),
|
|
563
|
+
"display-columns": unref(displayColumns),
|
|
564
|
+
"onUpdate:displayColumns": _cache[7] || (_cache[7] = ($event) => isRef(displayColumns) ? displayColumns.value = $event : null),
|
|
565
|
+
"expanded-rowKeys": unref(expandedRowKeys),
|
|
566
|
+
"onUpdate:expandedRowKeys": _cache[8] || (_cache[8] = ($event) => isRef(expandedRowKeys) ? expandedRowKeys.value = $event : null),
|
|
567
|
+
"filter-value": unref(filterValue),
|
|
568
|
+
"onUpdate:filterValue": _cache[9] || (_cache[9] = ($event) => isRef(filterValue) ? filterValue.value = $event : null),
|
|
569
|
+
sort: unref(sort),
|
|
570
|
+
"onUpdate:sort": _cache[10] || (_cache[10] = ($event) => isRef(sort) ? sort.value = $event : null),
|
|
571
|
+
"expanded-tree-nodes": unref(expandedTreeNodes),
|
|
572
|
+
"onUpdate:expandedTreeNodes": _cache[11] || (_cache[11] = ($event) => isRef(expandedTreeNodes) ? expandedTreeNodes.value = $event : null),
|
|
573
|
+
"reserve-selected-row-on-paginate": "",
|
|
574
|
+
"active-row-type": "multiple"
|
|
575
|
+
}, reProps.value.tableOptions, {
|
|
576
|
+
onSelectChange: handleSelectChange
|
|
577
|
+
}), createSlots({
|
|
578
|
+
_: 2
|
|
579
|
+
}, [reProps.value.creatable ? {
|
|
580
|
+
name: "table-bottom-content",
|
|
581
|
+
fn: withCtx(() => [addCustom.visible ? (openBlock(), createElementBlock("div", _hoisted_1, [renderSlot(_ctx.$slots, "add-input", {
|
|
582
|
+
addCustom
|
|
583
|
+
}, () => [createVNode(unref(Input), mergeProps({
|
|
584
|
+
modelValue: addCustom.value,
|
|
585
|
+
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => addCustom.value = $event)
|
|
586
|
+
}, reProps.value.addInputOptions), null, 16, ["modelValue"])], true), createVNode(unref(Space), {
|
|
587
|
+
size: "small"
|
|
588
|
+
}, {
|
|
589
|
+
default: withCtx(() => [renderSlot(_ctx.$slots, "add-confirm-btn", {
|
|
590
|
+
addCustom
|
|
591
|
+
}, () => [createVNode(unref(Button), normalizeProps(guardReactiveProps(reProps.value.addConfirmBtnOptions)), null, 16)], true), renderSlot(_ctx.$slots, "add-cancel-btn", {
|
|
592
|
+
addCustom
|
|
593
|
+
}, () => [createVNode(unref(Button), normalizeProps(guardReactiveProps(reProps.value.addCancelBtnOptions)), null, 16)], true)]),
|
|
594
|
+
_: 3
|
|
595
|
+
})])) : renderSlot(_ctx.$slots, "add-btn", {
|
|
596
|
+
key: 1,
|
|
597
|
+
addCustom
|
|
598
|
+
}, () => [createVNode(unref(Button), mergeProps({
|
|
599
|
+
class: "qd-popup-table-select__table-add"
|
|
600
|
+
}, reProps.value.addBtnOptions), null, 16)], true)]),
|
|
601
|
+
key: "0"
|
|
602
|
+
} : void 0, renderList(unref(extractSlotsWithPrefix)(_ctx.$slots, "search"), (item) => {
|
|
603
|
+
return {
|
|
604
|
+
name: item.filterName,
|
|
605
|
+
fn: withCtx((slotProps) => [renderSlot(_ctx.$slots, item.originalName, normalizeProps(guardReactiveProps(slotProps)), void 0, true)])
|
|
606
|
+
};
|
|
607
|
+
}), renderList(unref(extractSlotsWithPrefix)(_ctx.$slots, "table"), (item) => {
|
|
608
|
+
return {
|
|
609
|
+
name: item.filterName,
|
|
610
|
+
fn: withCtx((slotProps) => [renderSlot(_ctx.$slots, item.originalName, mergeProps({
|
|
611
|
+
addCustom
|
|
612
|
+
}, slotProps), void 0, true)])
|
|
613
|
+
};
|
|
614
|
+
})]), 1040, ["search-data", "data", "selected-row-keys", "active-row-keys", "column-controller-visible", "display-columns", "expanded-rowKeys", "filter-value", "sort", "expanded-tree-nodes"])]),
|
|
615
|
+
default: withCtx(() => [createVNode(unref(Select), mergeProps({
|
|
616
|
+
modelValue: unref(modelValue),
|
|
617
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(modelValue) ? modelValue.value = $event : null),
|
|
618
|
+
options: selectedRows.value,
|
|
619
|
+
"popup-visible": false
|
|
620
|
+
}, reProps.value.selectOptions, {
|
|
621
|
+
onClear: handleClear
|
|
622
|
+
}), {
|
|
623
|
+
suffixIcon: withCtx(() => [createVNode(unref(SearchIcon))]),
|
|
624
|
+
_: 1
|
|
625
|
+
}, 16, ["modelValue", "options"])]),
|
|
468
626
|
_: 3
|
|
469
627
|
}, 16, ["modelValue"]);
|
|
470
628
|
};
|