@dazhicheng/ui 1.6.48 → 1.6.50
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-custom-export-modal/src/TtCustomExportModal.vue.js +177 -177
- package/dist/components/tt-custom-export-modal/src/api.d.ts +12 -12
- package/dist/components/tt-custom-export-modal/src/api.js +23 -29
- package/dist/components/tt-custom-export-modal/src/components/FieldGridSection.vue.d.ts +2 -2
- package/dist/components/tt-custom-export-modal/src/components/FieldToolbarSection.vue.d.ts +1 -1
- package/dist/components/tt-custom-export-modal/src/components/TemplateManagerSection.vue.js +71 -54
- package/dist/components/tt-custom-export-modal/src/types/report.d.ts +8 -19
- package/dist/components/tt-drawer/index.d.ts +3 -3
- package/dist/components/tt-drawer/src/RenderDrawer.vue.d.ts +1 -1
- package/dist/components/tt-form/src/form-render/array-register/FormArrayRegister.d.ts +2 -2
- package/dist/components/tt-modal/index.d.ts +32 -32
- package/dist/components/tt-modal/src/RenderModal.vue.d.ts +22 -22
- package/dist/components/tt-modal/src/components/ModalWrapper.vue.d.ts +2 -2
- package/dist/components/tt-modal/src/hooks/useModalRender.d.ts +5 -5
- package/dist/components/tt-panel-select/src/components/PanelMiddle.vue.d.ts +1 -1
- package/dist/components/tt-panel-select/src/components/PanelRight.vue.d.ts +1 -1
- package/dist/components/tt-panel-select/src/index.vue.d.ts +1 -1
- package/dist/components/tt-table/index.d.ts +17 -8
- package/dist/components/tt-table/src/Table.vue.d.ts +12 -6
- package/dist/components/tt-table/src/TableForm.vue.d.ts +9 -9
- package/dist/components/tt-table/src/TableForm.vue.js +68 -68
- package/dist/components/tt-table/src/hooks/useSideSlot.d.ts +4 -4
- package/dist/components/tt-table/src/props.d.ts +7 -4
- package/dist/components/tt-table/src/props.js +4 -4
- package/dist/components/tt-table/src/types/table.d.ts +6 -0
- package/dist/components/tt-table/src/types/tableForm.d.ts +0 -6
- package/dist/components/tt-upload/index.d.ts +11 -11
- package/dist/components/tt-upload/src/TtUpload.vue.d.ts +4 -4
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -366,7 +366,7 @@ declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {
|
|
|
366
366
|
scrollLeft: number;
|
|
367
367
|
}) => any) | undefined;
|
|
368
368
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
369
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
369
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
370
370
|
wrapRef: HTMLDivElement | undefined;
|
|
371
371
|
update: () => void;
|
|
372
372
|
scrollTo: {
|
|
@@ -306,6 +306,9 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
306
306
|
type: StringConstructor;
|
|
307
307
|
default: () => string | undefined;
|
|
308
308
|
};
|
|
309
|
+
customExportConfig: {
|
|
310
|
+
type: import('vue').PropType<import('.').TtTableProps["customExportConfig"]>;
|
|
311
|
+
};
|
|
309
312
|
autoHeight: any;
|
|
310
313
|
leftSlotWidth: {
|
|
311
314
|
type: NumberConstructor;
|
|
@@ -482,6 +485,8 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
482
485
|
keyboardConfig: import("vxe-table").VxeTablePropTypes.KeyboardConfig<any>;
|
|
483
486
|
emptyText: string;
|
|
484
487
|
clearTreeExpand: boolean;
|
|
488
|
+
testId: string;
|
|
489
|
+
api: (...arg: any[]) => Promise<any>;
|
|
485
490
|
currentPageField: string;
|
|
486
491
|
pageSizeField: string;
|
|
487
492
|
totalField: string;
|
|
@@ -522,9 +527,7 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
522
527
|
rightSlotWidth: number;
|
|
523
528
|
defaultDisplayFields: string[];
|
|
524
529
|
useSearchForm: any;
|
|
525
|
-
testId: string;
|
|
526
530
|
toolTipErrorPlacement: "top" | "bottom" | "left" | "right";
|
|
527
|
-
api: (...arg: any[]) => Promise<any>;
|
|
528
531
|
afterFetch: ((data: any[], res: Recordable | Recordable[]) => Promise<any[]>) | undefined;
|
|
529
532
|
beforeFetch: ((params: Recordable) => Promise<Recordable>) | undefined;
|
|
530
533
|
beforePageChange: ((page: import("vxe-table").VxeGridPropTypes.PagerConfig) => boolean | Promise<boolean>) | undefined;
|
|
@@ -646,7 +649,7 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
646
649
|
scrollLeft: number;
|
|
647
650
|
}) => any) | undefined;
|
|
648
651
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
649
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
652
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
650
653
|
wrapRef: HTMLDivElement | undefined;
|
|
651
654
|
update: () => void;
|
|
652
655
|
scrollTo: {
|
|
@@ -773,7 +776,7 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
773
776
|
scrollLeft: number;
|
|
774
777
|
}) => any) | undefined;
|
|
775
778
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
776
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
779
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
777
780
|
wrapRef: HTMLDivElement | undefined;
|
|
778
781
|
update: () => void;
|
|
779
782
|
scrollTo: {
|
|
@@ -994,6 +997,9 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
994
997
|
type: StringConstructor;
|
|
995
998
|
default: () => string | undefined;
|
|
996
999
|
};
|
|
1000
|
+
customExportConfig: {
|
|
1001
|
+
type: import('vue').PropType<import('.').TtTableProps["customExportConfig"]>;
|
|
1002
|
+
};
|
|
997
1003
|
autoHeight: any;
|
|
998
1004
|
leftSlotWidth: {
|
|
999
1005
|
type: NumberConstructor;
|
|
@@ -1168,6 +1174,8 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
1168
1174
|
keyboardConfig: import("vxe-table").VxeTablePropTypes.KeyboardConfig<any>;
|
|
1169
1175
|
emptyText: string;
|
|
1170
1176
|
clearTreeExpand: boolean;
|
|
1177
|
+
testId: string;
|
|
1178
|
+
api: (...arg: any[]) => Promise<any>;
|
|
1171
1179
|
currentPageField: string;
|
|
1172
1180
|
pageSizeField: string;
|
|
1173
1181
|
totalField: string;
|
|
@@ -1208,9 +1216,7 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
1208
1216
|
rightSlotWidth: number;
|
|
1209
1217
|
defaultDisplayFields: string[];
|
|
1210
1218
|
useSearchForm: any;
|
|
1211
|
-
testId: string;
|
|
1212
1219
|
toolTipErrorPlacement: "top" | "bottom" | "left" | "right";
|
|
1213
|
-
api: (...arg: any[]) => Promise<any>;
|
|
1214
1220
|
afterFetch: ((data: any[], res: Recordable | Recordable[]) => Promise<any[]>) | undefined;
|
|
1215
1221
|
beforeFetch: ((params: Recordable) => Promise<Recordable>) | undefined;
|
|
1216
1222
|
beforePageChange: ((page: import("vxe-table").VxeGridPropTypes.PagerConfig) => boolean | Promise<boolean>) | undefined;
|
|
@@ -1417,6 +1423,9 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
1417
1423
|
type: StringConstructor;
|
|
1418
1424
|
default: () => string | undefined;
|
|
1419
1425
|
};
|
|
1426
|
+
customExportConfig: {
|
|
1427
|
+
type: import('vue').PropType<import('.').TtTableProps["customExportConfig"]>;
|
|
1428
|
+
};
|
|
1420
1429
|
autoHeight: any;
|
|
1421
1430
|
leftSlotWidth: {
|
|
1422
1431
|
type: NumberConstructor;
|
|
@@ -1593,6 +1602,8 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
1593
1602
|
keyboardConfig: import("vxe-table").VxeTablePropTypes.KeyboardConfig<any>;
|
|
1594
1603
|
emptyText: string;
|
|
1595
1604
|
clearTreeExpand: boolean;
|
|
1605
|
+
testId: string;
|
|
1606
|
+
api: (...arg: any[]) => Promise<any>;
|
|
1596
1607
|
currentPageField: string;
|
|
1597
1608
|
pageSizeField: string;
|
|
1598
1609
|
totalField: string;
|
|
@@ -1633,9 +1644,7 @@ export declare const TtTable: import('../../../../utils/src').SFCWithInstall<{
|
|
|
1633
1644
|
rightSlotWidth: number;
|
|
1634
1645
|
defaultDisplayFields: string[];
|
|
1635
1646
|
useSearchForm: any;
|
|
1636
|
-
testId: string;
|
|
1637
1647
|
toolTipErrorPlacement: "top" | "bottom" | "left" | "right";
|
|
1638
|
-
api: (...arg: any[]) => Promise<any>;
|
|
1639
1648
|
afterFetch: ((data: any[], res: Recordable | Recordable[]) => Promise<any[]>) | undefined;
|
|
1640
1649
|
beforeFetch: ((params: Recordable) => Promise<Recordable>) | undefined;
|
|
1641
1650
|
beforePageChange: ((page: import("vxe-table").VxeGridPropTypes.PagerConfig) => boolean | Promise<boolean>) | undefined;
|
|
@@ -143,7 +143,7 @@ declare function __VLS_template(): {
|
|
|
143
143
|
scrollLeft: number;
|
|
144
144
|
}) => any) | undefined;
|
|
145
145
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
146
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
146
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
147
147
|
wrapRef: HTMLDivElement | undefined;
|
|
148
148
|
update: () => void;
|
|
149
149
|
scrollTo: {
|
|
@@ -270,7 +270,7 @@ declare function __VLS_template(): {
|
|
|
270
270
|
scrollLeft: number;
|
|
271
271
|
}) => any) | undefined;
|
|
272
272
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
273
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
273
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
274
274
|
wrapRef: HTMLDivElement | undefined;
|
|
275
275
|
update: () => void;
|
|
276
276
|
scrollTo: {
|
|
@@ -488,6 +488,9 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
488
488
|
type: StringConstructor;
|
|
489
489
|
default: () => string | undefined;
|
|
490
490
|
};
|
|
491
|
+
customExportConfig: {
|
|
492
|
+
type: import('vue').PropType<TtTableProps["customExportConfig"]>;
|
|
493
|
+
};
|
|
491
494
|
autoHeight: any;
|
|
492
495
|
leftSlotWidth: {
|
|
493
496
|
type: NumberConstructor;
|
|
@@ -843,6 +846,9 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
843
846
|
type: StringConstructor;
|
|
844
847
|
default: () => string | undefined;
|
|
845
848
|
};
|
|
849
|
+
customExportConfig: {
|
|
850
|
+
type: import('vue').PropType<TtTableProps["customExportConfig"]>;
|
|
851
|
+
};
|
|
846
852
|
autoHeight: any;
|
|
847
853
|
leftSlotWidth: {
|
|
848
854
|
type: NumberConstructor;
|
|
@@ -926,6 +932,8 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
926
932
|
keyboardConfig: import("vxe-table").VxeTablePropTypes.KeyboardConfig<any>;
|
|
927
933
|
emptyText: string;
|
|
928
934
|
clearTreeExpand: boolean;
|
|
935
|
+
testId: string;
|
|
936
|
+
api: (...arg: any[]) => Promise<any>;
|
|
929
937
|
currentPageField: string;
|
|
930
938
|
pageSizeField: string;
|
|
931
939
|
totalField: string;
|
|
@@ -966,9 +974,7 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
966
974
|
rightSlotWidth: number;
|
|
967
975
|
defaultDisplayFields: string[];
|
|
968
976
|
useSearchForm: any;
|
|
969
|
-
testId: string;
|
|
970
977
|
toolTipErrorPlacement: "top" | "bottom" | "left" | "right";
|
|
971
|
-
api: (...arg: any[]) => Promise<any>;
|
|
972
978
|
afterFetch: ((data: any[], res: globalThis.Recordable | globalThis.Recordable[]) => Promise<any[]>) | undefined;
|
|
973
979
|
beforeFetch: ((params: globalThis.Recordable) => Promise<globalThis.Recordable>) | undefined;
|
|
974
980
|
beforePageChange: ((page: import("vxe-table").VxeGridPropTypes.PagerConfig) => boolean | Promise<boolean>) | undefined;
|
|
@@ -1090,7 +1096,7 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
1090
1096
|
scrollLeft: number;
|
|
1091
1097
|
}) => any) | undefined;
|
|
1092
1098
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
1093
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
1099
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
1094
1100
|
wrapRef: HTMLDivElement | undefined;
|
|
1095
1101
|
update: () => void;
|
|
1096
1102
|
scrollTo: {
|
|
@@ -1217,7 +1223,7 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
1217
1223
|
scrollLeft: number;
|
|
1218
1224
|
}) => any) | undefined;
|
|
1219
1225
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
1220
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
1226
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
1221
1227
|
wrapRef: HTMLDivElement | undefined;
|
|
1222
1228
|
update: () => void;
|
|
1223
1229
|
scrollTo: {
|
|
@@ -201,7 +201,7 @@ declare function __VLS_template(): {
|
|
|
201
201
|
modalApi: TtModalExtendedModalApi;
|
|
202
202
|
isExport: boolean;
|
|
203
203
|
}) => any) | undefined;
|
|
204
|
-
}>, "
|
|
204
|
+
}>, "openModal" | "setModalProps" | "handleSubmit"> & {
|
|
205
205
|
handleSubmit: () => void;
|
|
206
206
|
openModal: ({ columns: source, displayFields, disabledColumnField, isExport }: import('./components/TableColumnModal.vue').OpenModalParams) => void;
|
|
207
207
|
setModalProps: (modalProps: import('../../../index').ModalRenderState) => void;
|
|
@@ -222,6 +222,9 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
222
222
|
autoHeight: boolean;
|
|
223
223
|
columnsKey: string;
|
|
224
224
|
useSearchForm: boolean;
|
|
225
|
+
customExportConfig?: import('../../../index').TtCustomExportModalProps & {
|
|
226
|
+
onExport?: (payload: import('../../../index').ExportConfirmPayload) => void;
|
|
227
|
+
};
|
|
225
228
|
loading?: boolean;
|
|
226
229
|
emptyText?: string;
|
|
227
230
|
noSearchText?: string;
|
|
@@ -435,9 +438,6 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
435
438
|
tableFormApi: {
|
|
436
439
|
type: import('vue').PropType<TtTableExtendedTableFormApi>;
|
|
437
440
|
};
|
|
438
|
-
customExportConfig: {
|
|
439
|
-
type: import('vue').PropType<TtTableFormProps["customExportConfig"]>;
|
|
440
|
-
};
|
|
441
441
|
}>, {
|
|
442
442
|
instance: import('vue').ComponentInternalInstance | null;
|
|
443
443
|
setTableProps: (props: Partial<TtTableProps<any>>) => void;
|
|
@@ -454,6 +454,9 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
454
454
|
autoHeight: boolean;
|
|
455
455
|
columnsKey: string;
|
|
456
456
|
useSearchForm: boolean;
|
|
457
|
+
customExportConfig?: import('../../../index').TtCustomExportModalProps & {
|
|
458
|
+
onExport?: (payload: import('../../../index').ExportConfirmPayload) => void;
|
|
459
|
+
};
|
|
457
460
|
loading?: boolean;
|
|
458
461
|
emptyText?: string;
|
|
459
462
|
noSearchText?: string;
|
|
@@ -667,14 +670,11 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
667
670
|
tableFormApi: {
|
|
668
671
|
type: import('vue').PropType<TtTableExtendedTableFormApi>;
|
|
669
672
|
};
|
|
670
|
-
customExportConfig: {
|
|
671
|
-
type: import('vue').PropType<TtTableFormProps["customExportConfig"]>;
|
|
672
|
-
};
|
|
673
673
|
}>> & Readonly<{}>, {
|
|
674
674
|
form: Partial<import('../../../index').TtFormProps<Record<string, any>>>;
|
|
675
675
|
table: Partial<TtTableProps>;
|
|
676
|
-
useSearchForm: any;
|
|
677
676
|
testId: string;
|
|
677
|
+
useSearchForm: any;
|
|
678
678
|
handleSearchInfoFn: Fn<any, any>;
|
|
679
679
|
toolConfig: import('../../../index').TtTableToolsProps;
|
|
680
680
|
tableRefreshBefore: Fn<any, any>;
|
|
@@ -823,7 +823,7 @@ declare const __VLS_component: import('vue').DefineComponent<import('vue').Extra
|
|
|
823
823
|
modalApi: TtModalExtendedModalApi;
|
|
824
824
|
isExport: boolean;
|
|
825
825
|
}) => any) | undefined;
|
|
826
|
-
}>, "
|
|
826
|
+
}>, "openModal" | "setModalProps" | "handleSubmit"> & {
|
|
827
827
|
handleSubmit: () => void;
|
|
828
828
|
openModal: ({ columns: source, displayFields, disabledColumnField, isExport }: import('./components/TableColumnModal.vue').OpenModalParams) => void;
|
|
829
829
|
setModalProps: (modalProps: import('../../../index').ModalRenderState) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as je, useSlots as Ne, getCurrentInstance as We, ref as ie, shallowReactive as Ge, onScopeDispose as se, computed as g, unref as
|
|
1
|
+
import { defineComponent as je, useSlots as Ne, getCurrentInstance as We, ref as ie, shallowReactive as Ge, onScopeDispose as se, computed as g, unref as o, shallowRef as Je, toRaw as O, watch as C, toValue as h, onMounted as qe, nextTick as ne, createElementBlock as le, openBlock as B, normalizeClass as H, createCommentVNode as me, createElementVNode as Qe, createBlock as Ue, createVNode as R, renderSlot as c, createSlots as L, renderList as ue, withCtx as w, normalizeProps as pe, guardReactiveProps as ce, mergeProps as z, toHandlers as Xe, isRef as Ye } from "vue";
|
|
2
2
|
import "../../tt-button/index.js";
|
|
3
3
|
import "../../tt-checkbox/index.js";
|
|
4
4
|
import "../../tt-empty/index.js";
|
|
@@ -99,30 +99,30 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
99
99
|
return Object.hasOwn(((e = S == null ? void 0 : S.vnode) == null ? void 0 : e.props) || {}, "table");
|
|
100
100
|
}
|
|
101
101
|
const I = ie(), W = ie();
|
|
102
|
-
let
|
|
103
|
-
|
|
102
|
+
let r = n.tableFormApi;
|
|
103
|
+
r || (r = new ht(n), r.useStore = (e) => at(r.store, e));
|
|
104
104
|
const G = Ge({});
|
|
105
105
|
function J() {
|
|
106
|
-
Object.assign(G, O(
|
|
106
|
+
Object.assign(G, O(r.store.state) || {});
|
|
107
107
|
}
|
|
108
|
-
J(), se(
|
|
109
|
-
const
|
|
108
|
+
J(), se(r.store.subscribe(J));
|
|
109
|
+
const f = g(() => G), y = g(() => {
|
|
110
110
|
var t;
|
|
111
111
|
if (n.testId) return n.testId;
|
|
112
|
-
const e = (t =
|
|
112
|
+
const e = (t = o(f).table) == null ? void 0 : t.api;
|
|
113
113
|
return e ? tt(e) : "table";
|
|
114
|
-
}), we = g(() => D(
|
|
114
|
+
}), we = g(() => D(o(y), "tableform")), Se = g(() => D(o(y), "search-form-header"));
|
|
115
115
|
wt(
|
|
116
116
|
g(() => ({
|
|
117
|
-
submit: D(
|
|
118
|
-
reset: D(
|
|
117
|
+
submit: D(o(y), "search-btn-query"),
|
|
118
|
+
reset: D(o(y), "search-btn-reset")
|
|
119
119
|
}))
|
|
120
120
|
);
|
|
121
|
-
const { getSlotKeys: Ce, replaceSlotKey: ye } = de("form-"), { getSlotKeys: Te, replaceSlotKey: ve } = de("t-"), { getFormProps: V, getTableProps:
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
121
|
+
const { getSlotKeys: Ce, replaceSlotKey: ye } = de("form-"), { getSlotKeys: Te, replaceSlotKey: ve } = de("t-"), { getFormProps: V, getTableProps: l, getTableToolProps: q, submitSearchQuery: Q } = ct(
|
|
122
|
+
f,
|
|
123
|
+
r.tableApi.reload,
|
|
124
|
+
r.tableApi.getLoading,
|
|
125
|
+
r.tableApi.getPagination
|
|
126
126
|
), U = Je([]), Fe = g(() => (n.table, !N() || !n.table ? !1 : (n.table.data, Object.hasOwn(O(n.table), "data"))));
|
|
127
127
|
let x = () => {
|
|
128
128
|
};
|
|
@@ -141,14 +141,14 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
141
141
|
}
|
|
142
142
|
C(Me, (e) => Ae(e), { immediate: !0 });
|
|
143
143
|
async function Pe() {
|
|
144
|
-
await
|
|
144
|
+
await r.tableApi.reloadData([]), r.tableApi.setPagination({ total: 0 });
|
|
145
145
|
}
|
|
146
146
|
async function Ee() {
|
|
147
|
-
return !
|
|
147
|
+
return !o(f).useSearchForm || !a.isMounted ? {} : await a.getValues();
|
|
148
148
|
}
|
|
149
149
|
let K = !1;
|
|
150
150
|
async function P(e, t) {
|
|
151
|
-
const { tableSearchBefore: i } =
|
|
151
|
+
const { tableSearchBefore: i } = o(f);
|
|
152
152
|
if (!j(i)) return !0;
|
|
153
153
|
if (K) return !1;
|
|
154
154
|
K = !0;
|
|
@@ -179,7 +179,7 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
179
179
|
), { run: De } = A(
|
|
180
180
|
async (e) => {
|
|
181
181
|
const t = e;
|
|
182
|
-
await P("submit", t) && (await
|
|
182
|
+
await P("submit", t) && (await r.grid.clearFilter(), await Q(t));
|
|
183
183
|
},
|
|
184
184
|
200,
|
|
185
185
|
{ leading: !0 }
|
|
@@ -196,9 +196,9 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
196
196
|
collapseTriggerResize: !0,
|
|
197
197
|
collapsedRows: 3
|
|
198
198
|
}), { restoreColumns: $e, saveColumns: X } = ut({
|
|
199
|
-
getTableProps:
|
|
200
|
-
getProps:
|
|
201
|
-
tableMethods:
|
|
199
|
+
getTableProps: l,
|
|
200
|
+
getProps: f,
|
|
201
|
+
tableMethods: r.tableApi
|
|
202
202
|
});
|
|
203
203
|
let b = !1;
|
|
204
204
|
const T = {};
|
|
@@ -206,8 +206,8 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
206
206
|
T[t] = (...i) => M(e, ...i);
|
|
207
207
|
});
|
|
208
208
|
const { run: Ie } = A(async () => {
|
|
209
|
-
if (b || !
|
|
210
|
-
const e = (
|
|
209
|
+
if (b || !o(l).useHttpCache) return;
|
|
210
|
+
const e = (r.tableApi.getTableColumns() || []).map((t) => t.field).filter(Boolean);
|
|
211
211
|
e.length && await X(JSON.stringify(e));
|
|
212
212
|
}, 300);
|
|
213
213
|
function Ve(e) {
|
|
@@ -216,32 +216,32 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
216
216
|
}
|
|
217
217
|
const xe = g(() => ({ ...T, columnDragend: Ve }));
|
|
218
218
|
function Ke(e) {
|
|
219
|
-
|
|
219
|
+
r.setState((t) => t.table ? ot(e, t) : {}), e.table && r.tableApi.setState(e.table), e.form && (a == null || a.setState(e.form));
|
|
220
220
|
}
|
|
221
221
|
const { run: ke } = A(
|
|
222
222
|
async (e) => {
|
|
223
|
-
if (a.isMounted &&
|
|
223
|
+
if (a.isMounted && o(f).useSearchForm) {
|
|
224
224
|
if (!(await a.validate()).valid) return;
|
|
225
225
|
const i = await a.getValues();
|
|
226
|
-
await
|
|
226
|
+
await r.tableApi.reload({ ...e, searchInfo: { ...e == null ? void 0 : e.searchInfo, ...i } });
|
|
227
227
|
return;
|
|
228
228
|
}
|
|
229
|
-
await
|
|
229
|
+
await r.tableApi.reload({ ...e, searchInfo: { ...e == null ? void 0 : e.searchInfo } });
|
|
230
230
|
},
|
|
231
231
|
200,
|
|
232
232
|
{ leading: !0 }
|
|
233
233
|
), E = {
|
|
234
|
-
tableMethods:
|
|
234
|
+
tableMethods: r.tableApi,
|
|
235
235
|
formMethods: a,
|
|
236
|
-
setTableProps:
|
|
236
|
+
setTableProps: r.tableApi.setState,
|
|
237
237
|
setFormProps: a.setState,
|
|
238
238
|
setProps: Ke,
|
|
239
239
|
reload: ke,
|
|
240
|
-
selectedKeys: g(() => h(
|
|
240
|
+
selectedKeys: g(() => h(r.tableApi.selectedKeys))
|
|
241
241
|
};
|
|
242
242
|
async function Be() {
|
|
243
243
|
if (!await P("refresh")) return;
|
|
244
|
-
const { tableRefreshBefore: e } =
|
|
244
|
+
const { tableRefreshBefore: e } = o(f);
|
|
245
245
|
j(e) && await e(), E.reload();
|
|
246
246
|
}
|
|
247
247
|
let k = { width: window.innerWidth, height: window.innerHeight };
|
|
@@ -250,31 +250,31 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
250
250
|
if (await ne(), b) return;
|
|
251
251
|
const { innerWidth: e, innerHeight: t } = window, i = e !== k.width || t !== k.height;
|
|
252
252
|
if (k = { width: e, height: t }, !i) {
|
|
253
|
-
if (!
|
|
254
|
-
(s =
|
|
253
|
+
if (!o(l).autoHeight) return;
|
|
254
|
+
(s = r.tableApi) == null || s.redoHeight(!1);
|
|
255
255
|
return;
|
|
256
256
|
}
|
|
257
|
-
(m =
|
|
257
|
+
(m = r.tableApi) == null || m.redoHeight();
|
|
258
258
|
}, 100);
|
|
259
259
|
async function He(e) {
|
|
260
260
|
var m, d;
|
|
261
261
|
if (b) return;
|
|
262
|
-
const t = h((d = (m =
|
|
262
|
+
const t = h((d = (m = o(f)) == null ? void 0 : m.table) == null ? void 0 : d.columns) || [], i = new Map(t.map((p) => [p.field, p])), s = e.checkedModel.map((p) => i.get(p)).filter(Boolean);
|
|
263
263
|
if (e.isExport) {
|
|
264
264
|
M("export", e.checkedModel, e.modalApi);
|
|
265
265
|
return;
|
|
266
266
|
}
|
|
267
267
|
e.modalApi.setModalProps({ confirmLoading: !0 });
|
|
268
268
|
try {
|
|
269
|
-
if (
|
|
270
|
-
|
|
269
|
+
if (o(l).useHttpCache && await X(JSON.stringify(e.checkedModel)), b) return;
|
|
270
|
+
r.tableApi.setTableColumns(s), e.modalApi.closeModal(), M("set-columns", s);
|
|
271
271
|
} finally {
|
|
272
272
|
b || e.modalApi.setModalProps({ confirmLoading: !1 });
|
|
273
273
|
}
|
|
274
274
|
}
|
|
275
275
|
function Z(e, t = !1) {
|
|
276
276
|
var p, v, F;
|
|
277
|
-
const { notSetColumnField: i, columns: s } =
|
|
277
|
+
const { notSetColumnField: i, columns: s } = o(l), m = ((((p = r.tableApi.getTableInstance()) == null ? void 0 : p.getTableColumn()) || {}).visibleColumn || []).map((u) => u.field).filter(Boolean), d = (h(s) || []).filter((u) => u.visible === !0 || u.visible === void 0).map((u) => u.field);
|
|
278
278
|
(v = I.value) == null || v.openModal({
|
|
279
279
|
columns: (h(s) || []).filter((u) => u.visible !== !1),
|
|
280
280
|
displayFields: t ? d : m,
|
|
@@ -290,7 +290,7 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
290
290
|
}
|
|
291
291
|
function Le() {
|
|
292
292
|
var s, m;
|
|
293
|
-
const { customExportConfig: e } =
|
|
293
|
+
const { customExportConfig: e } = o(l), t = (s = fe.table) == null ? void 0 : s.columnsKey, i = (e == null ? void 0 : e.businessCode) ?? (j(t) ? t() : t);
|
|
294
294
|
if (!i) {
|
|
295
295
|
Ze.warning("请配置自定义导出的 businessCode 或 GlobalConfig.table.columnsKey");
|
|
296
296
|
return;
|
|
@@ -299,9 +299,9 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
299
299
|
businessCode: i,
|
|
300
300
|
listColumns: () => {
|
|
301
301
|
var v, F;
|
|
302
|
-
const d = (v =
|
|
302
|
+
const d = (v = o(l).customExportConfig) == null ? void 0 : v.listColumns;
|
|
303
303
|
if (d) return h(d);
|
|
304
|
-
const p = (F =
|
|
304
|
+
const p = (F = r.tableApi.getTableInstance()) == null ? void 0 : F.getTableColumn().visibleColumn;
|
|
305
305
|
return p ? p.map((u) => u.field).filter((u) => !!u) : [];
|
|
306
306
|
}
|
|
307
307
|
});
|
|
@@ -314,41 +314,41 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
314
314
|
i !== "data" && Object.assign(t, { [i]: e[i] });
|
|
315
315
|
}), t;
|
|
316
316
|
}
|
|
317
|
-
return ft(n,
|
|
317
|
+
return ft(n, r.setState, ["tableFormApi", "table"]), C(
|
|
318
318
|
ze,
|
|
319
319
|
(e) => {
|
|
320
|
-
e &&
|
|
320
|
+
e && r.setState({ table: e });
|
|
321
321
|
},
|
|
322
322
|
{ deep: !0, immediate: !0 }
|
|
323
323
|
), pt({ formInstance: a }), C(
|
|
324
|
-
() =>
|
|
324
|
+
() => r.tableApi.getLoading.value,
|
|
325
325
|
(e) => {
|
|
326
326
|
a == null || a.setState({ submitButtonOptions: { loading: e } });
|
|
327
327
|
},
|
|
328
|
-
{ immediate: (ae = (re =
|
|
329
|
-
), C(V, (e) => a == null ? void 0 : a.setState(e)), C(
|
|
328
|
+
{ immediate: (ae = (re = r.store.state) == null ? void 0 : re.table) == null ? void 0 : ae.immediate }
|
|
329
|
+
), C(V, (e) => a == null ? void 0 : a.setState(e)), C(l, (e) => {
|
|
330
330
|
var t;
|
|
331
|
-
return (t =
|
|
331
|
+
return (t = r.tableApi) == null ? void 0 : t.setState(e);
|
|
332
332
|
}), qe(() => {
|
|
333
|
-
S && M("register", E, S.uid),
|
|
333
|
+
S && M("register", E, S.uid), r.mount(E, a), a == null || a.setState(o(V)), ne(() => {
|
|
334
334
|
b || $e();
|
|
335
335
|
}), window.addEventListener("resize", Y);
|
|
336
336
|
}), se(() => {
|
|
337
|
-
b = !0, x(),
|
|
337
|
+
b = !0, x(), r == null || r.unmount(), window.removeEventListener("resize", Y);
|
|
338
338
|
}), ge({ ...E, instance: S }), (e, t) => (B(), le("div", {
|
|
339
|
-
class: H(
|
|
339
|
+
class: H(o($)),
|
|
340
340
|
"data-testid": we.value
|
|
341
341
|
}, [
|
|
342
|
-
|
|
342
|
+
f.value.useSearchForm ? (B(), le("div", {
|
|
343
343
|
key: 0,
|
|
344
|
-
class: H(`${
|
|
344
|
+
class: H(`${o($)}-header`),
|
|
345
345
|
"data-testid": Se.value
|
|
346
346
|
}, [
|
|
347
|
-
R(
|
|
347
|
+
R(o(_e), {
|
|
348
348
|
"test-id": `${y.value}-search-form`
|
|
349
349
|
}, L({ _: 2 }, [
|
|
350
|
-
ue(
|
|
351
|
-
name:
|
|
350
|
+
ue(o(Ce)(o(_)), (i) => ({
|
|
351
|
+
name: o(ye)(i),
|
|
352
352
|
fn: w((s) => [
|
|
353
353
|
c(e.$slots, i, pe(ce(s || {})))
|
|
354
354
|
])
|
|
@@ -358,30 +358,30 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
358
358
|
], 10, Ct)) : me("", !0),
|
|
359
359
|
Qe("div", {
|
|
360
360
|
class: H({
|
|
361
|
-
[`${
|
|
361
|
+
[`${o($)}-wrapper`]: !0,
|
|
362
362
|
"pt-(--tt-base-padding)!": !0,
|
|
363
|
-
"pb-(--tt-base-padding)!": !
|
|
363
|
+
"pb-(--tt-base-padding)!": !o(l).showPager
|
|
364
364
|
})
|
|
365
365
|
}, [
|
|
366
366
|
c(e.$slots, "table-top"),
|
|
367
367
|
R(bt, z({
|
|
368
|
-
...
|
|
368
|
+
...o(l),
|
|
369
369
|
...Fe.value ? { data: U.value } : {},
|
|
370
370
|
beforePageChange: Oe
|
|
371
371
|
}, {
|
|
372
|
-
"form-api":
|
|
373
|
-
"table-api": r
|
|
372
|
+
"form-api": o(a),
|
|
373
|
+
"table-api": o(r).tableApi
|
|
374
374
|
}, Xe(xe.value)), L({ _: 2 }, [
|
|
375
|
-
ue(
|
|
376
|
-
name:
|
|
375
|
+
ue(o(Te)(o(_)), (i) => ({
|
|
376
|
+
name: o(ve)(i),
|
|
377
377
|
fn: w((s) => [
|
|
378
378
|
c(e.$slots, i, pe(ce(s || {})))
|
|
379
379
|
])
|
|
380
380
|
})),
|
|
381
|
-
|
|
381
|
+
o(l).showToolbar ? {
|
|
382
382
|
name: "toolbar_tools",
|
|
383
383
|
fn: w(() => [
|
|
384
|
-
R(lt, z(
|
|
384
|
+
R(lt, z(o(q), {
|
|
385
385
|
onOnRefresh: Be,
|
|
386
386
|
onOnExport: te,
|
|
387
387
|
onOnCustomExport: Le,
|
|
@@ -402,11 +402,11 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
402
402
|
]), 1040, ["form-api", "table-api"]),
|
|
403
403
|
c(e.$slots, "table-bottom")
|
|
404
404
|
], 2),
|
|
405
|
-
|
|
405
|
+
o(q).showCustomExport ? (B(), Ue(o(st), z({
|
|
406
406
|
key: 1,
|
|
407
407
|
ref_key: "customExportModalRef",
|
|
408
408
|
ref: W
|
|
409
|
-
}, l.
|
|
409
|
+
}, o(l).customExportConfig), null, 16)) : me("", !0),
|
|
410
410
|
R(nt, {
|
|
411
411
|
ref_key: "columnModalRef",
|
|
412
412
|
ref: I,
|
|
@@ -419,7 +419,7 @@ const St = ["data-testid"], Ct = ["data-testid"], qo = /* @__PURE__ */ je({
|
|
|
419
419
|
]),
|
|
420
420
|
_: 2
|
|
421
421
|
}, [
|
|
422
|
-
|
|
422
|
+
o(_)["t-column-modal-title"] ? {
|
|
423
423
|
name: "title",
|
|
424
424
|
fn: w(() => [
|
|
425
425
|
c(e.$slots, "t-column-modal-title")
|
|
@@ -145,7 +145,7 @@ export declare function useSideSlot(propsRef: ComputedRef<TtTableProps>, grid: R
|
|
|
145
145
|
scrollLeft: number;
|
|
146
146
|
}) => any) | undefined;
|
|
147
147
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
148
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
148
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
149
149
|
wrapRef: HTMLDivElement | undefined;
|
|
150
150
|
update: () => void;
|
|
151
151
|
scrollTo: {
|
|
@@ -271,7 +271,7 @@ export declare function useSideSlot(propsRef: ComputedRef<TtTableProps>, grid: R
|
|
|
271
271
|
scrollLeft: number;
|
|
272
272
|
}) => any) | undefined;
|
|
273
273
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
274
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
274
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
275
275
|
wrapRef: HTMLDivElement | undefined;
|
|
276
276
|
update: () => void;
|
|
277
277
|
scrollTo: {
|
|
@@ -398,7 +398,7 @@ export declare function useSideSlot(propsRef: ComputedRef<TtTableProps>, grid: R
|
|
|
398
398
|
scrollLeft: number;
|
|
399
399
|
}) => any) | undefined;
|
|
400
400
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
401
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
401
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
402
402
|
wrapRef: HTMLDivElement | undefined;
|
|
403
403
|
update: () => void;
|
|
404
404
|
scrollTo: {
|
|
@@ -524,7 +524,7 @@ export declare function useSideSlot(propsRef: ComputedRef<TtTableProps>, grid: R
|
|
|
524
524
|
scrollLeft: number;
|
|
525
525
|
}) => any) | undefined;
|
|
526
526
|
"onEnd-reached"?: ((direction: import('element-plus').ScrollbarDirection) => any) | undefined;
|
|
527
|
-
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "
|
|
527
|
+
}>, "height" | "tabindex" | "tag" | "handleScroll" | "maxHeight" | "scrollTo" | "distance" | "wrapStyle" | "wrapClass" | "viewClass" | "viewStyle" | "minSize" | "wrapRef" | "update" | "setScrollTop" | "setScrollLeft"> & {
|
|
528
528
|
wrapRef: HTMLDivElement | undefined;
|
|
529
529
|
update: () => void;
|
|
530
530
|
scrollTo: {
|
|
@@ -201,6 +201,10 @@ export declare const tableProps: {
|
|
|
201
201
|
type: StringConstructor;
|
|
202
202
|
default: () => string | undefined;
|
|
203
203
|
};
|
|
204
|
+
/** 公共导出弹框配置,复用弹框的业务编码与异步导出回调。 */
|
|
205
|
+
customExportConfig: {
|
|
206
|
+
type: PropType<TtTableProps["customExportConfig"]>;
|
|
207
|
+
};
|
|
204
208
|
/**
|
|
205
209
|
* 是否自适应高度
|
|
206
210
|
*
|
|
@@ -309,6 +313,9 @@ export declare const tableFormProps: {
|
|
|
309
313
|
autoHeight: boolean;
|
|
310
314
|
columnsKey: string;
|
|
311
315
|
useSearchForm: boolean;
|
|
316
|
+
customExportConfig?: import('../../tt-custom-export-modal').TtCustomExportModalProps & {
|
|
317
|
+
onExport?: (payload: import('../../tt-custom-export-modal').ExportConfirmPayload) => void;
|
|
318
|
+
};
|
|
312
319
|
loading?: boolean;
|
|
313
320
|
emptyText?: string;
|
|
314
321
|
noSearchText?: string;
|
|
@@ -530,10 +537,6 @@ export declare const tableFormProps: {
|
|
|
530
537
|
tableFormApi: {
|
|
531
538
|
type: PropType<TtTableExtendedTableFormApi>;
|
|
532
539
|
};
|
|
533
|
-
/** 公共导出弹框配置,复用弹框的业务编码与异步导出回调。 */
|
|
534
|
-
customExportConfig: {
|
|
535
|
-
type: PropType<TtTableFormProps["customExportConfig"]>;
|
|
536
|
-
};
|
|
537
540
|
};
|
|
538
541
|
/** 表格的参数和vxe-table的参数相同需要重新定义 */
|
|
539
542
|
export declare const tableOtherProps: {
|