WIP feature/breadcrumb/fix_localize

This commit is contained in:
elforjani3
2020-05-13 00:02:21 +02:00
parent 4ab85eaf09
commit e6f63fbc88
69 changed files with 610 additions and 394 deletions

View File

@@ -9,6 +9,7 @@ import {
getFinancialSheetIndexByQuery,
} from 'store/financialStatement/financialStatements.selectors';
import withProfitLossDetail from './withProfitLoss';
import { FormattedMessage as T, useIntl } from 'react-intl';
function ProfitLossSheetTable({
@@ -22,6 +23,9 @@ function ProfitLossSheetTable({
onFetchData,
companyName,
}) {
const {formatMessage} =useIntl();
const columns = useMemo(() => [
{
// Build our expander column
@@ -63,18 +67,18 @@ function ProfitLossSheetTable({
disableResizing: true,
},
{
Header: 'Account Name',
Header: formatMessage({id:'account_name'}),
accessor: 'name',
className: "name",
},
{
Header: 'Acc. Code',
Header: formatMessage({id:'acc_code'}),
accessor: 'code',
className: "account_code",
},
...(profitLossQuery.display_columns_type === 'total') ? [
{
Header: 'Total',
Header: formatMessage({id:'total'}),
Cell: ({ cell }) => {
const row = cell.row.original;
if (row.total) {