Files
bigcapital/packages/webapp/src/containers/Alerts/PaymentMades/_utils.ts

12 lines
367 B
TypeScript

import { AppToaster } from '@/components';
import { Intent } from '@blueprintjs/core';
export const handleDeleteErrors = (errors: any) => {
if (errors.find((e: any) => e.type === 'CANNOT_DELETE_TRANSACTION_MATCHED')) {
AppToaster.show({
intent: Intent.DANGER,
message: 'Cannot delete a transaction matched with a bank transaction.',
});
}
};