diff --git a/src/layouts/CustomerInvoiceDetails.tsx b/src/layouts/CustomerInvoiceDetails.tsx index b18b246df..46f7ace62 100644 --- a/src/layouts/CustomerInvoiceDetails.tsx +++ b/src/layouts/CustomerInvoiceDetails.tsx @@ -289,7 +289,7 @@ const CustomerInvoiceDetails = () => { if (retryTaxProviderVoidingResult?.id) { addToast({ severity: 'success', - translateKey: 'text_1724769707909qoy2v4pxvku', + translateKey: 'text_172535279177716n7p2svtdb', }) } }, diff --git a/src/pages/InvoiceOverview.tsx b/src/pages/InvoiceOverview.tsx index dd04aec11..32b0b939d 100644 --- a/src/pages/InvoiceOverview.tsx +++ b/src/pages/InvoiceOverview.tsx @@ -136,8 +136,12 @@ const InvoiceOverview = memo( !!invoice?.customer?.xeroCustomer?.externalCustomerId && !!invoice?.externalIntegrationId const showNetsuiteSection = !!connectedNetsuiteIntegration?.accountId && !!invoice?.externalIntegrationId - const showAnrokSection = - !!invoice?.customer?.anrokCustomer?.externalAccountId || invoice?.taxProviderVoidable + const showAnrokReSyncButton = invoice?.taxProviderVoidable + const showAnrokLink = + (invoice?.status === InvoiceStatusTypeEnum.Finalized || + invoice?.status === InvoiceStatusTypeEnum.Voided) && + !!invoice?.customer?.anrokCustomer?.externalAccountId + const showAnrokSection = showAnrokReSyncButton || showAnrokLink const showExternalAppsSection = showXeroSection || showNetsuiteSection || showAnrokSection return ( @@ -296,7 +300,20 @@ const InvoiceOverview = memo( {translate('text_1724772240299r3u9nouqflf')} - {invoice.taxProviderVoidable ? ( + {showAnrokLink ? ( + + + {invoice?.id} + + + ) : ( @@ -318,19 +335,6 @@ const InvoiceOverview = memo( )} - ) : ( - - - {invoice?.id} - - )} )} diff --git a/translations/base.json b/translations/base.json index 8c91b74bf..7b8d8f6d8 100644 --- a/translations/base.json +++ b/translations/base.json @@ -2353,7 +2353,6 @@ "text_1724438705077s7oxv5be87m": "The invoice cannot be refreshed due to tax errors", "text_1724674592260h33v56rycaw": "This invoice contains a tax error", "text_1724702284063xef0c9kyhyl": "Sync invoice to Anrok", - "text_1724769707909qoy2v4pxvku": "NetSuite synchronisation successfully triggered.", "text_1724772240299r3u9nouqflf": "Anrok invoice url", "text_1724773425162ehwcxw6ynrp": "Invoice not synced to Anrok", "text_1724774217640gd4bmfl8ne3": "Sync voided invoice to Anrok", @@ -2381,5 +2380,6 @@ "text_172434514289283gmf8bdhh3": "Request access to progressive billing", "text_1724346450317iqs2rtvx1tp": "Hello, I would like to access your progressive billing add-on. \n\nPlease let me know if you need more info!", "text_1724936123802q74m2xxak3o": "Usage already billed", - "text_17250100329108guatmyl9tj": "Unknown" + "text_17250100329108guatmyl9tj": "Unknown", + "text_172535279177716n7p2svtdb": "Anrok synchronisation successfully triggered." }