Variable CreateInvoiceSchemaConst
CreateInvoiceSchema: ZodObject<
{
number: ZodOptional<ZodString>;
clientId: ZodString;
salesOrderId: ZodEffects<
ZodOptional<ZodString>,
string | undefined,
string | undefined,
>;
invoiceDate: ZodString;
dueDate: ZodEffects<
ZodOptional<ZodString>,
string | undefined,
string | undefined,
>;
status: ZodDefault<
ZodEnum<
[
"DRAFT",
"SENT",
"UNPAID",
"PARTIALLY_PAID",
"PAID",
"OVERDUE",
"CREDIT_NOTE",
"CANCELLED",
],
>,
>;
subtotal: ZodNumber;
taxRate: ZodNumber;
taxAmount: ZodNumber;
totalAmount: ZodNumber;
currencyId: ZodEffects<
ZodOptional<ZodString>,
string | undefined,
string | undefined,
>;
globalTaxId: ZodEffects<
ZodOptional<ZodString>,
string | undefined,
string | undefined,
>;
notes: ZodEffects<
ZodOptional<ZodString>,
string | undefined,
string | undefined,
>;
lines: ZodArray<
ZodObject<
{
id: ZodEffects<
ZodOptional<ZodString>,
string | undefined,
string | undefined,
>;
description: ZodString;
quantity: ZodNumber;
unitPrice: ZodNumber;
totalPrice: ZodNumber;
taxId: ZodEffects<
ZodOptional<ZodString>,
string | undefined,
string | undefined,
>;
taxRate: ZodNumber;
taxAmount: ZodNumber;
notes: ZodEffects<
ZodOptional<ZodString>,
string | undefined,
string | undefined,
>;
finishedProductId: ZodEffects<
ZodOptional<ZodString>,
string | undefined,
string | undefined,
>;
},
"strip",
ZodTypeAny,
{
id?: string;
description: string;
quantity: number;
unitPrice: number;
totalPrice: number;
taxId?: string;
taxRate: number;
taxAmount: number;
notes?: string;
finishedProductId?: string;
},
{
id?: string;
description: string;
quantity: number;
unitPrice: number;
totalPrice: number;
taxId?: string;
taxRate: number;
taxAmount: number;
notes?: string;
finishedProductId?: string;
},
>,
"many",
>;
},
"strip",
ZodTypeAny,
{
number?: string;
clientId: string;
salesOrderId?: string;
invoiceDate: string;
dueDate?: string;
status: | "DRAFT"
| "SENT"
| "CANCELLED"
| "PAID"
| "PARTIALLY_PAID"
| "UNPAID"
| "OVERDUE"
| "CREDIT_NOTE";
subtotal: number;
taxRate: number;
taxAmount: number;
totalAmount: number;
currencyId?: string;
globalTaxId?: string;
notes?: string;
lines: {
id?: string;
description: string;
quantity: number;
unitPrice: number;
totalPrice: number;
taxId?: string;
taxRate: number;
taxAmount: number;
notes?: string;
finishedProductId?: string;
}[];
},
{
number?: string;
clientId: string;
salesOrderId?: string;
invoiceDate: string;
dueDate?: string;
status?: | "DRAFT"
| "SENT"
| "CANCELLED"
| "PAID"
| "PARTIALLY_PAID"
| "UNPAID"
| "OVERDUE"
| "CREDIT_NOTE";
subtotal: number;
taxRate: number;
taxAmount: number;
totalAmount: number;
currencyId?: string;
globalTaxId?: string;
notes?: string;
lines: {
id?: string;
description: string;
quantity: number;
unitPrice: number;
totalPrice: number;
taxId?: string;
taxRate: number;
taxAmount: number;
notes?: string;
finishedProductId?: string;
}[];
},
> = ...