@gx-design-vue/pro-table 0.1.15 → 0.1.16

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.
@@ -128,12 +128,7 @@ declare const GProTable: import("vue").DefineComponent<{
128
128
  columnEmptyText: {
129
129
  type: import("vue").PropType<import("./types/TableTypings").ProFieldEmptyText | undefined>;
130
130
  default: boolean;
131
- }; /**
132
- * @Author gx12358
133
- * @DateTime 2022/1/21
134
- * @lastTime 2022/1/21
135
- * @description Tabel-datasource hooks 方法
136
- */
131
+ };
137
132
  onReset: import("vue").PropType<((params?: Partial<Record<string, any>> | undefined) => any) | undefined>;
138
133
  onReload: import("vue").PropType<((params?: Partial<Record<string, any>> | undefined) => any) | undefined>;
139
134
  onSubmit: import("vue").PropType<((params?: Partial<Record<string, any>> | undefined) => any) | undefined>;
@@ -488,12 +483,7 @@ declare const GProTable: import("vue").DefineComponent<{
488
483
  columnEmptyText: {
489
484
  type: import("vue").PropType<import("./types/TableTypings").ProFieldEmptyText | undefined>;
490
485
  default: boolean;
491
- }; /**
492
- * @Author gx12358
493
- * @DateTime 2022/1/21
494
- * @lastTime 2022/1/21
495
- * @description Tabel-datasource hooks 方法
496
- */
486
+ };
497
487
  onReset: import("vue").PropType<((params?: Partial<Record<string, any>> | undefined) => any) | undefined>;
498
488
  onReload: import("vue").PropType<((params?: Partial<Record<string, any>> | undefined) => any) | undefined>;
499
489
  onSubmit: import("vue").PropType<((params?: Partial<Record<string, any>> | undefined) => any) | undefined>;
@@ -8,5 +8,6 @@ export declare function useRowSelection(rowKey: Ref<ProTableProps['rowKey']>, ro
8
8
  selectAllRowKey: (selected: any[], selectedRows: any[], changeRows: any[]) => void;
9
9
  removeRowKeys: (keyList: (string | number)[]) => void;
10
10
  changeRowKey: () => void;
11
+ clearAllRowKeys: () => void;
11
12
  syncSelectedRows: (dataList: any[]) => void;
12
13
  };
@@ -27841,6 +27841,11 @@ function useRowSelection(rowKey, rowSelection) {
27841
27841
  }
27842
27842
  }
27843
27843
  };
27844
+ const clearAllRowKeys = () => {
27845
+ selectedKey.value = [];
27846
+ selectedItem.value = [];
27847
+ changeRowKey();
27848
+ };
27844
27849
  return {
27845
27850
  selectedKey,
27846
27851
  selectedItem,
@@ -27848,6 +27853,7 @@ function useRowSelection(rowKey, rowSelection) {
27848
27853
  selectAllRowKey,
27849
27854
  removeRowKeys,
27850
27855
  changeRowKey,
27856
+ clearAllRowKeys,
27851
27857
  syncSelectedRows
27852
27858
  };
27853
27859
  }
@@ -29752,6 +29758,7 @@ const GProTable = defineComponent({
29752
29758
  selectRowKey,
29753
29759
  selectAllRowKey,
29754
29760
  syncSelectedRows,
29761
+ clearAllRowKeys,
29755
29762
  removeRowKeys
29756
29763
  } = useRowSelection(toRef(props2, "rowKey"), toRef(props2, "rowSelection"));
29757
29764
  const configFetchData = useConfigFetchData(props2);
@@ -29860,7 +29867,8 @@ const GProTable = defineComponent({
29860
29867
  pageParams: getPaginationInfo.value,
29861
29868
  rowsSelection: {
29862
29869
  keys: selectedKey.value,
29863
- items: selectedItem.value
29870
+ items: selectedItem.value,
29871
+ clear: () => clearAllRowKeys()
29864
29872
  },
29865
29873
  getLoadingStatus: getLoading.value || false,
29866
29874
  reload,