@gx-design-vue/pro-table 0.1.5 → 0.1.7
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/ProTable.d.ts
CHANGED
|
@@ -24,7 +24,7 @@ declare const GProTable: import("vue").DefineComponent<{
|
|
|
24
24
|
default: undefined;
|
|
25
25
|
};
|
|
26
26
|
request: {
|
|
27
|
-
type: import("vue").PropType<import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType> | undefined>;
|
|
27
|
+
type: import("vue").PropType<import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType, any> | undefined>;
|
|
28
28
|
default: null;
|
|
29
29
|
};
|
|
30
30
|
virtualScroll: import("vue").PropType<boolean | undefined>;
|
|
@@ -124,7 +124,7 @@ declare const GProTable: import("vue").DefineComponent<{
|
|
|
124
124
|
onSizeChange: import("vue").PropType<((size: string) => any) | undefined>;
|
|
125
125
|
onLoadingChange: import("vue").PropType<((loading: boolean) => any) | undefined>;
|
|
126
126
|
onRequestError: import("vue").PropType<((e: Error) => void) | undefined>;
|
|
127
|
-
onBeforeSearchSubmit: import("vue").PropType<import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType> | undefined>;
|
|
127
|
+
onBeforeSearchSubmit: import("vue").PropType<import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType, any> | undefined>;
|
|
128
128
|
onColumnsStateChange: import("vue").PropType<((data: import("./hooks/useColumnSetting").ColumnsState[]) => void) | undefined>;
|
|
129
129
|
prefixCls: {
|
|
130
130
|
type: import("vue").PropType<string>;
|
|
@@ -369,7 +369,7 @@ declare const GProTable: import("vue").DefineComponent<{
|
|
|
369
369
|
default: undefined;
|
|
370
370
|
};
|
|
371
371
|
request: {
|
|
372
|
-
type: import("vue").PropType<import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType> | undefined>;
|
|
372
|
+
type: import("vue").PropType<import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType, any> | undefined>;
|
|
373
373
|
default: null;
|
|
374
374
|
};
|
|
375
375
|
virtualScroll: import("vue").PropType<boolean | undefined>;
|
|
@@ -469,7 +469,7 @@ declare const GProTable: import("vue").DefineComponent<{
|
|
|
469
469
|
onSizeChange: import("vue").PropType<((size: string) => any) | undefined>;
|
|
470
470
|
onLoadingChange: import("vue").PropType<((loading: boolean) => any) | undefined>;
|
|
471
471
|
onRequestError: import("vue").PropType<((e: Error) => void) | undefined>;
|
|
472
|
-
onBeforeSearchSubmit: import("vue").PropType<import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType> | undefined>;
|
|
472
|
+
onBeforeSearchSubmit: import("vue").PropType<import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType, any> | undefined>;
|
|
473
473
|
onColumnsStateChange: import("vue").PropType<((data: import("./hooks/useColumnSetting").ColumnsState[]) => void) | undefined>;
|
|
474
474
|
prefixCls: {
|
|
475
475
|
type: import("vue").PropType<string>;
|
|
@@ -822,7 +822,7 @@ declare const GProTable: import("vue").DefineComponent<{
|
|
|
822
822
|
options: boolean | OptionConfig | undefined;
|
|
823
823
|
waitRequest: boolean | undefined;
|
|
824
824
|
debounceTime: number | undefined;
|
|
825
|
-
request: import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType> | undefined;
|
|
825
|
+
request: import("./types/TableTypings").RequsetFunction<import("./typing").DefaultRecordType, any> | undefined;
|
|
826
826
|
search: import("./types/TableTypings").SearchConfig | undefined;
|
|
827
827
|
searchMap: import("./types/ColumnTypings").ProSearchMap<"text">[] | undefined;
|
|
828
828
|
titleTip: TitleTipRender;
|
|
@@ -25,6 +25,7 @@ export type ConfigFetchData = {
|
|
|
25
25
|
};
|
|
26
26
|
export declare function useConfigFetchData(props: ProTableProps): Omit<ConfigFetchData, 'waitRequest'>;
|
|
27
27
|
export declare function useFetchData({ polling, request, postData, dataSource, waitRequest, debounceTime }: ConfigFetchData, { columns, getLoading, setLoading, setColumns, removeRowKeys, syncSelectedRows, formParamsRef, setPagination, getPaginationInfo, onBeforeSearchSubmit }: ActionType, emit: any): {
|
|
28
|
+
dataSourceRef: Ref<RecordType[]>;
|
|
28
29
|
getDataSourceRef: ComputedRef<RecordType[]>;
|
|
29
30
|
isTreeDataRef: ComputedRef<boolean>;
|
|
30
31
|
reSetDataList: (list: RecordType[]) => void;
|
package/dist/pro-table.es.js
CHANGED
|
@@ -28052,6 +28052,7 @@ function useFetchData({ polling, request, postData, dataSource, waitRequest, deb
|
|
|
28052
28052
|
});
|
|
28053
28053
|
}
|
|
28054
28054
|
return {
|
|
28055
|
+
dataSourceRef,
|
|
28055
28056
|
getDataSourceRef,
|
|
28056
28057
|
isTreeDataRef,
|
|
28057
28058
|
reSetDataList,
|
|
@@ -29743,6 +29744,7 @@ const GProTable = defineComponent({
|
|
|
29743
29744
|
const configFetchData = useConfigFetchData(props2);
|
|
29744
29745
|
const {
|
|
29745
29746
|
reload,
|
|
29747
|
+
dataSourceRef,
|
|
29746
29748
|
reSetDataList,
|
|
29747
29749
|
changeDataValue,
|
|
29748
29750
|
isTreeDataRef,
|
|
@@ -29979,7 +29981,7 @@ const GProTable = defineComponent({
|
|
|
29979
29981
|
const customizeRender = getSlot$1(slots, props2, "customRender");
|
|
29980
29982
|
if (!customizeRender)
|
|
29981
29983
|
return null;
|
|
29982
|
-
return customizeRender(
|
|
29984
|
+
return customizeRender(dataSourceRef.value);
|
|
29983
29985
|
};
|
|
29984
29986
|
const toolbarDom = (headerTitle, toolBarBtn, titleTip) => createVNode(ToolbarRender, {
|
|
29985
29987
|
"headerTitle": headerTitle,
|
|
@@ -30017,14 +30019,17 @@ const GProTable = defineComponent({
|
|
|
30017
30019
|
}), !needVirtualScroll.value && toolbarDom(headerTitleRender, toolBarBtnRender, titleTipRender), !!((_b = props2.customRender) != null ? _b : slots.customRender) ? createVNode(Spin$1, {
|
|
30018
30020
|
"spinning": !!unref(getLoading)
|
|
30019
30021
|
}, {
|
|
30020
|
-
default: () =>
|
|
30021
|
-
|
|
30022
|
-
|
|
30023
|
-
|
|
30024
|
-
|
|
30025
|
-
|
|
30026
|
-
|
|
30027
|
-
|
|
30022
|
+
default: () => {
|
|
30023
|
+
var _a2;
|
|
30024
|
+
return [renderCustomize(), !!((_a2 = dataSourceRef.value) == null ? void 0 : _a2.length) && createVNode(Pagination$2, mergeProps({
|
|
30025
|
+
"class": {
|
|
30026
|
+
["ant-table-pagination"]: true,
|
|
30027
|
+
[`ant-table-pagination-${handlePagePosition.value}`]: handlePagePosition.value
|
|
30028
|
+
}
|
|
30029
|
+
}, toRaw(unref(getPaginationInfo)), {
|
|
30030
|
+
"onChange": handleChangePage
|
|
30031
|
+
}), null)];
|
|
30032
|
+
}
|
|
30028
30033
|
}) : createVNode(Table$2, mergeProps(getBindValues.value, {
|
|
30029
30034
|
"style": props2.tableStyle || void 0,
|
|
30030
30035
|
"class": props2.tableClassName,
|