Feat: Adjust the operation cell of the table on the file management page and dataset page #3221. (#7526)

### What problem does this PR solve?

Feat: Adjust the operation cell of the table on the file management page
and dataset page #3221.
### Type of change


- [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
balibabu
2025-05-08 15:25:26 +08:00
committed by GitHub
parent 9d3dd13fef
commit 1657755b5d
18 changed files with 163 additions and 115 deletions

View File

@ -9,11 +9,16 @@ export function useRowSelection() {
setRowSelection({});
}, []);
const selectedCount = useMemo(() => {
return Object.keys(rowSelection).length;
}, [rowSelection]);
return {
rowSelection,
setRowSelection,
rowSelectionIsEmpty: isEmpty(rowSelection),
clearRowSelection,
selectedCount,
};
}

View File

@ -93,7 +93,7 @@ export const useFetchDocumentList = () => {
filterValue,
],
initialData: { docs: [], total: 0 },
refetchInterval: 15000,
// refetchInterval: 15000,
enabled: !!knowledgeId || !!id,
queryFn: async () => {
const ret = await listDocument(