mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-19 22:30:31 +00:00
feat(BalanceSheet|ProfitLoss): comparions feature.
This commit is contained in:
14
src/containers/FinancialStatements/ProfitLossSheet/hooks.js
Normal file
14
src/containers/FinancialStatements/ProfitLossSheet/hooks.js
Normal file
@@ -0,0 +1,14 @@
|
||||
import React from 'react';
|
||||
import { dynamicColumns } from './utils';
|
||||
import { useProfitLossSheetContext } from './ProfitLossProvider';
|
||||
|
||||
export const useProfitLossSheetColumns = () => {
|
||||
const {
|
||||
profitLossSheet: { table },
|
||||
} = useProfitLossSheetContext();
|
||||
|
||||
return React.useMemo(
|
||||
() => dynamicColumns(table.columns || [], table.rows || []),
|
||||
[table],
|
||||
);
|
||||
};
|
||||
Reference in New Issue
Block a user