diff --git a/client/src/containers/Sales/Invoice/InvoiceList.js b/client/src/containers/Sales/Invoice/InvoiceList.js index 7e031be48..261f37163 100644 --- a/client/src/containers/Sales/Invoice/InvoiceList.js +++ b/client/src/containers/Sales/Invoice/InvoiceList.js @@ -97,9 +97,10 @@ function InvoiceList({ const handleConfirmInvoiceDelete = useCallback(() => { requestDeleteInvoice(deleteInvoice.id) .then(() => { + setDeleteInvoice(false); AppToaster.show({ message: formatMessage({ - id: 'the_invocie_has_been_successfully_deleted', + id: 'the_invoice_has_been_successfully_deleted', }), intent: Intent.SUCCESS, }); @@ -109,7 +110,7 @@ function InvoiceList({ setDeleteInvoice(false); }); }, [deleteInvoice, requestDeleteInvoice, formatMessage]); - + // Handle cancel/confirm invoice deliver. const handleDeliverInvoice = useCallback((invoice) => { setDeliverInvoice(invoice); diff --git a/client/src/lang/en/index.js b/client/src/lang/en/index.js index 9e241c1dc..3e9859828 100644 --- a/client/src/lang/en/index.js +++ b/client/src/lang/en/index.js @@ -635,7 +635,7 @@ export default { 'The invoice #{number} has been successfully edited.', the_invocie_has_been_successfully_created: 'The invoice #{number} has been successfully created.', - the_invocie_has_been_successfully_deleted: + the_invoice_has_been_successfully_deleted: 'The invoice has been successfully deleted.', once_delete_this_invoice_you_will_able_to_restore_it: `Once you delete this invoice, you won\'t be able to restore it later. Are you sure you want to delete this invoice?`, receipt_list: 'Receipt List',