fix(webapp): use the server formatted value

This commit is contained in:
Ahmed Bouhuolia
2023-12-04 08:31:18 +02:00
parent fb70c94465
commit 33afa3af64
12 changed files with 31 additions and 47 deletions

View File

@@ -23,7 +23,7 @@ export default function VendorCreditDetailDrawerFooter() {
<VendorCreditTotalLines labelColWidth={'180px'} amountColWidth={'180px'}>
<TotalLine
title={<T id={'vendor_credit.drawer.label_subtotal'} />}
value={<FormatNumber value={vendorCredit.formatted_amount} />}
value={vendorCredit.formatted_amount}
borderStyle={TotalLineBorderStyle.SingleDark}
/>
<TotalLine

View File

@@ -61,9 +61,8 @@ export const useVendorCreditReadonlyEntriesTableColumns = () => {
},
{
Header: intl.get('rate'),
accessor: 'rate',
Cell: FormatNumberCell,
width: getColumnWidth(entries, 'rate', {
accessor: 'rate_formatted',
width: getColumnWidth(entries, 'rate_formatted', {
minWidth: 60,
magicSpacing: 5,
}),
@@ -73,9 +72,8 @@ export const useVendorCreditReadonlyEntriesTableColumns = () => {
},
{
Header: intl.get('amount'),
accessor: 'amount',
Cell: FormatNumberCell,
width: getColumnWidth(entries, 'amount', {
accessor: 'total_formatted',
width: getColumnWidth(entries, 'total_formatted', {
minWidth: 60,
magicSpacing: 5,
}),