mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-17 05:10:31 +00:00
feat: export purchases by items to csv/xlsx (#327)
This commit is contained in:
@@ -1,13 +1,10 @@
|
||||
import {
|
||||
IAgingPeriod,
|
||||
IAgingPeriodTotal,
|
||||
IAgingAmount,
|
||||
IAgingSummaryQuery,
|
||||
IAgingSummaryTotal,
|
||||
IAgingSummaryContact,
|
||||
IAgingSummaryData,
|
||||
} from './AgingReport';
|
||||
import { INumberFormatQuery } from './FinancialStatements';
|
||||
import { IFinancialTable } from './Table';
|
||||
|
||||
export interface IAPAgingSummaryQuery extends IAgingSummaryQuery {
|
||||
|
||||
54
packages/server/src/interfaces/PurchasesByItemsSheet.ts
Normal file
54
packages/server/src/interfaces/PurchasesByItemsSheet.ts
Normal file
@@ -0,0 +1,54 @@
|
||||
import { INumberFormatQuery } from './FinancialStatements';
|
||||
import { IFinancialTable } from './Table';
|
||||
|
||||
export interface IPurchasesByItemsReportQuery {
|
||||
fromDate: Date | string;
|
||||
toDate: Date | string;
|
||||
itemsIds: number[];
|
||||
numberFormat: INumberFormatQuery;
|
||||
noneTransactions: boolean;
|
||||
onlyActive: boolean;
|
||||
}
|
||||
|
||||
export interface IPurchasesByItemsSheetMeta {
|
||||
organizationName: string;
|
||||
baseCurrency: string;
|
||||
}
|
||||
|
||||
export interface IPurchasesByItemsItem {
|
||||
id: number;
|
||||
name: string;
|
||||
code: string;
|
||||
quantitySold: number;
|
||||
soldCost: number;
|
||||
averageSellPrice: number;
|
||||
|
||||
quantitySoldFormatted: string;
|
||||
soldCostFormatted: string;
|
||||
averageSellPriceFormatted: string;
|
||||
currencyCode: string;
|
||||
}
|
||||
|
||||
export interface IPurchasesByItemsTotal {
|
||||
quantitySold: number;
|
||||
soldCost: number;
|
||||
quantitySoldFormatted: string;
|
||||
soldCostFormatted: string;
|
||||
currencyCode: string;
|
||||
}
|
||||
|
||||
export type IPurchasesByItemsSheetData = {
|
||||
items: IPurchasesByItemsItem[];
|
||||
total: IPurchasesByItemsTotal;
|
||||
};
|
||||
|
||||
export interface IPurchasesByItemsSheet {
|
||||
data: IPurchasesByItemsSheetData;
|
||||
query: IPurchasesByItemsReportQuery;
|
||||
meta: IPurchasesByItemsSheetMeta;
|
||||
}
|
||||
|
||||
export interface IPurchasesByItemsTable extends IFinancialTable {
|
||||
query: IPurchasesByItemsReportQuery;
|
||||
meta: IPurchasesByItemsSheetMeta;
|
||||
}
|
||||
Reference in New Issue
Block a user