refactor: update document filtering logic to maintain complete dataset and clear selections on filter change

This commit is contained in:
Anish Sarkar 2026-02-06 15:47:07 +05:30
parent c8273cd413
commit e01717c65d
2 changed files with 38 additions and 31 deletions

View file

@ -140,6 +140,9 @@ export default function DocumentsTable() {
}
});
setPageIndex(0);
// Clear selections when filter changes — selected IDs from the previous
// filter view are no longer visible and would cause misleading bulk actions
setSelectedIds(new Set());
};
const onBulkDelete = async () => {