draft: AR and AP aging summary report.

This commit is contained in:
a.bouhuolia
2021-01-07 13:48:45 +02:00
parent 7fa6822905
commit 22b2fd5918
17 changed files with 639 additions and 590 deletions

View File

@@ -1,45 +1,29 @@
import {
IAgingPeriod,
IAgingPeriodTotal
} from './AgingReport';
export interface IARAgingSummaryQuery {
asDate: Date | string,
agingDaysBefore: number,
agingPeriods: number,
asDate: Date | string;
agingDaysBefore: number;
agingPeriods: number;
numberFormat: {
noCents: number,
divideOn1000: number,
},
customersIds: number[],
noneZero: boolean,
noCents: number;
divideOn1000: number;
};
customersIds: number[];
noneZero: boolean;
}
export interface IAgingPeriod {
fromPeriod: Date,
toPeriod: Date,
beforeDays: number,
toDays: number,
};
export interface IAgingPeriodClosingBalance extends IAgingPeriod {
closingBalance: number,
};
export interface IAgingPeriodTotal extends IAgingPeriod {
total: number,
};
export interface ARAgingSummaryCustomerPeriod {
export interface IARAgingSummaryCustomer {
customerName: string;
aging: (IAgingPeriodTotal & IAgingPeriod)[];
total: IAgingPeriodTotal;
}
export interface ARAgingSummaryCustomerTotal {
amount: number,
formattedAmount: string,
currencyCode: string,
export interface IARAgingSummaryData {
customers: IARAgingSummaryCustomer[],
total: (IAgingPeriodTotal & IAgingPeriod)[]
}
export interface ARAgingSummaryCustomer {
customerName: string,
aging: IAgingPeriodTotal[],
total: ARAgingSummaryCustomerTotal,
};
export type IARAgingSummaryColumns = IAgingPeriod[];