feat(server): styling financial reports pdf

This commit is contained in:
Ahmed Bouhuolia
2024-02-19 21:41:15 +02:00
parent 3509026ad8
commit c06a8d9ca3
33 changed files with 210 additions and 56 deletions

View File

@@ -2,6 +2,7 @@ import { Inject, Service } from 'typedi';
import { IBalanceSheetQuery } from '@/interfaces';
import { BalanceSheetTableInjectable } from './BalanceSheetTableInjectable';
import { TableSheetPdf } from '../TableSheetPdf';
import { HtmlTableCustomCss } from './constants';
@Service()
export class BalanceSheetPdfInjectable {
@@ -27,7 +28,8 @@ export class BalanceSheetPdfInjectable {
tenantId,
table.table,
table.meta.sheetName,
table.meta.formattedDateRange
table.meta.formattedDateRange,
HtmlTableCustomCss
);
}
}

View File

@@ -12,3 +12,15 @@ export enum IROW_TYPE {
NET_INCOME = 'NET_INCOME',
TOTAL = 'TOTAL',
}
export const HtmlTableCustomCss = `
table tr.row-type--total td {
font-weight: 600;
border-top: 1px solid #bbb;
color: #000;
}
table tr.row-type--total.row-id--assets td,
table tr.row-type--total.row-id--liability-equity td {
border-bottom: 3px double #000;
}
`;