fix: invalidate account cache on bulk uncategorizing

This commit is contained in:
Ahmed Bouhuolia
2024-08-12 10:11:40 +02:00
parent faa81abee4
commit 9a34f3e283
3 changed files with 10 additions and 8 deletions

View File

@@ -103,9 +103,10 @@ function AccountTransactionsDataTable({
// Handle selected rows change.
const handleSelectedRowsChange = (selected) => {
const selectedIds = selected?.map(
(row) => row.original.uncategorized_transaction_id,
);
const selectedIds = selected
?.filter((row) => row.original.uncategorized_transaction_id)
?.map((row) => row.original.uncategorized_transaction_id);
setCategorizedTransactionsSelected(selectedIds);
};

View File

@@ -57,7 +57,7 @@ function UncategorizeBankTransactionsBulkAlert({
>
<p>
Are you sure want to uncategorize the selected bank transactions, this
action is not revertable but you can always categorize them again?
action is not reversible but you can always categorize them again?
</p>
</Alert>
);