2
0
mirror of https://github.com/frappe/books.git synced 2024-11-08 14:50:56 +00:00
books/reports/types.ts
18alantom 27aed52044 incr: type some files, frappe -> fyo
- get books to serve albiet broken
- one step at a time
2022-05-23 16:18:22 +05:30

24 lines
613 B
TypeScript

import { AccountRootType } from 'models/baseModels/Account/types';
export type ExportExtension = 'csv' | 'json';
export interface ReportData {
rows: unknown[];
columns: unknown[];
}
export abstract class Report {
abstract run(filters: Record<string, unknown>): ReportData;
}
export type BalanceType = 'Credit' | 'Debit';
export type Periodicity = 'Monthly' | 'Quarterly' | 'Half Yearly' | 'Yearly';
export interface FinancialStatementOptions {
rootType: AccountRootType;
fromDate: string;
toDate: string;
balanceMustBe?: BalanceType;
periodicity?: Periodicity;
accumulateValues?: boolean;
}