feat: link discount to mail receipts

This commit is contained in:
Ahmed Bouhuolia
2024-12-02 18:45:16 +02:00
parent 05cf94940e
commit 5b75fa9286
14 changed files with 294 additions and 18 deletions

View File

@@ -284,6 +284,15 @@ export interface SaleEstimateMailStateResponse {
subtotal: number;
subtotalFormatted: string;
discount: number;
discountFormatted: string;
discountLabel: string;
discountPercentage: number | null;
discountPercentageFormatted: string;
adjustment: number;
adjustmentFormatted: string;
estimateNumber: string;
formatArgs: {

View File

@@ -434,6 +434,15 @@ export interface GetSaleInvoiceDefaultOptionsResponse {
subtotal: number;
subtotalFormatted: string;
discountAmount: number;
discountAmountFormatted: string;
discountLabel: string;
discountPercentage: number;
discountPercentageFormatted: string;
adjustment: number;
adjustmentFormatted: string;
total: number;
totalFormatted: string;

View File

@@ -263,6 +263,18 @@ export interface GetSaleReceiptMailStateResponse {
to: string[];
toOptions: Array<{ mail: string; label: string; primary: boolean; }>;
// # Discount
discountAmount: number;
discountAmountFormatted: string;
discountLabel: string;
discountPercentage: number | null;
discountPercentageFormatted: string;
// # Adjustment
adjustment: number,
adjustmentFormatted: string,
// # Total
total: number;
totalFormatted: string;