mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-18 13:50:31 +00:00
refactor: financial reports to nestjs
This commit is contained in:
52
temp/CashFlow/constants.ts
Normal file
52
temp/CashFlow/constants.ts
Normal file
@@ -0,0 +1,52 @@
|
||||
import { ICashFlowStatementQuery } from "./Cashflow.types";
|
||||
|
||||
export const DISPLAY_COLUMNS_BY = {
|
||||
DATE_PERIODS: 'date_periods',
|
||||
TOTAL: 'total',
|
||||
};
|
||||
|
||||
export const MAP_CONFIG = { childrenPath: 'children', pathFormat: 'array' };
|
||||
export const HtmlTableCustomCss = `
|
||||
table tr.row-type--accounts td {
|
||||
border-top: 1px solid #bbb;
|
||||
}
|
||||
table tr.row-id--cash-end-period td {
|
||||
border-bottom: 3px double #333;
|
||||
}
|
||||
table tr.row-type--total {
|
||||
font-weight: 600;
|
||||
}
|
||||
table tr.row-type--total td {
|
||||
color: #000;
|
||||
}
|
||||
table tr.row-type--total:not(:first-child) td {
|
||||
border-top: 1px solid #bbb;
|
||||
}
|
||||
table .column--name,
|
||||
table .cell--name {
|
||||
width: 400px;
|
||||
}
|
||||
table .column--total,
|
||||
table .cell--total,
|
||||
table [class*="column--date-range"],
|
||||
table [class*="cell--date-range"] {
|
||||
text-align: right;
|
||||
}
|
||||
`;
|
||||
|
||||
export const getDefaultCashflowQuery = (): ICashFlowStatementQuery => ({
|
||||
displayColumnsType: 'total',
|
||||
displayColumnsBy: 'day',
|
||||
fromDate: moment().startOf('year').format('YYYY-MM-DD'),
|
||||
toDate: moment().format('YYYY-MM-DD'),
|
||||
numberFormat: {
|
||||
precision: 2,
|
||||
divideOn1000: false,
|
||||
showZero: false,
|
||||
formatMoney: 'total',
|
||||
negativeFormat: 'mines',
|
||||
},
|
||||
noneZero: false,
|
||||
noneTransactions: false,
|
||||
basis: 'cash',
|
||||
});
|
||||
Reference in New Issue
Block a user