fix(sever): tax rates cell.

This commit is contained in:
Ahmed Bouhuolia
2023-09-20 00:43:55 +02:00
parent 453df2ac4e
commit d48d864a5f
5 changed files with 6 additions and 4 deletions

View File

@@ -27,7 +27,7 @@ export function TaxRatesSuggestInputCell({
items={taxRates} items={taxRates}
valueAccessor={'id'} valueAccessor={'id'}
labelAccessor={'code'} labelAccessor={'code'}
textAccessor={'name'} textAccessor={'name_formatted'}
popoverProps={{ minimal: true, boundary: 'window' }} popoverProps={{ minimal: true, boundary: 'window' }}
inputProps={{ placeholder: '' }} inputProps={{ placeholder: '' }}
fill={true} fill={true}

View File

@@ -29,7 +29,7 @@ export function InvoiceDetailTableFooter() {
{invoice.taxes.map((taxRate) => ( {invoice.taxes.map((taxRate) => (
<TotalLine <TotalLine
key={taxRate.id} key={taxRate.id}
title={`${taxRate.name} (${taxRate.tax_rate}%)`} title={`${taxRate.name} [${taxRate.tax_rate}%]`}
value={taxRate.tax_rate_amount_formatted} value={taxRate.tax_rate_amount_formatted}
textStyle={TotalLineTextStyle.Regular} textStyle={TotalLineTextStyle.Regular}
/> />

View File

@@ -9,7 +9,7 @@ const ARAgingSummaryHeaderDimensonsContext = React.createContext();
/** /**
* ARAging summary header dismensions provider. * ARAging summary header dismensions provider.
* @returns * @returns {JSX.Element}
*/ */
function ARAgingSummaryHeaderDimensionsProvider({ query, ...props }) { function ARAgingSummaryHeaderDimensionsProvider({ query, ...props }) {
// Features guard. // Features guard.

View File

@@ -13,6 +13,7 @@ const taxNameAccessor = R.curry((data, column) => ({
sticky: 'left', sticky: 'left',
width: 300, width: 300,
textOverview: true, textOverview: true,
disableSortBy: true,
})); }));
const taxableAmountAccessor = R.curry((data, column) => { const taxableAmountAccessor = R.curry((data, column) => {
@@ -25,6 +26,7 @@ const taxableAmountAccessor = R.curry((data, column) => {
className: column.key, className: column.key,
width: getColumnWidth(data, accessor, { minWidth: 120 }), width: getColumnWidth(data, accessor, { minWidth: 120 }),
align: Align.Right, align: Align.Right,
disableSortBy: true,
}; };
}); });

View File

@@ -36,7 +36,7 @@ export function TaxRatesTableActionsMenu({
onClick={safeCallback(onActivate, original)} onClick={safeCallback(onActivate, original)}
/> />
)} )}
{original.active && ( {!!original.active && (
<MenuItem <MenuItem
icon={<Icon icon="pause-16" iconSize={16} />} icon={<Icon icon="pause-16" iconSize={16} />}
text={'Inactivate Tax Rate'} text={'Inactivate Tax Rate'}