refactor: edit type

This commit is contained in:
Net 2024-08-20 17:50:09 +07:00
parent 921faed0c4
commit 26842a4c06

View file

@ -9,15 +9,20 @@ export type Customer = {
id: string;
code: string;
customerType: CustomerType;
customerName: string;
customerNameEN: string;
status: Status;
namePrefix: string;
firstName: string;
lastName: string;
firstNameEN: string;
lastNameEN: string;
gender: string;
birthDate: Date;
createdBy: string | null;
createdAt: string;
updatedBy: string | null;
updatedAt: string;
taxNo: string;
personName: string;
};
export type CustomerBranch = {
@ -98,26 +103,35 @@ export type CustomerBranchCreate = {
export type CustomerCreate = {
code: string;
customerBranch?: (CustomerBranchCreate & { id?: string })[];
taxNo?: string | null;
customerNameEN: string;
customerName: string;
customerType: CustomerType;
status?: Status;
image: File | null;
personName: string;
registeredBranchId: string;
namePrefix: string;
firstName: string;
lastName: string;
firstNameEN: string;
lastNameEN: string;
gender: string;
birthDate: Date;
};
export type CustomerUpdate = {
status?: Status;
customerType?: CustomerType;
customerName?: string;
customerNameEN?: string;
customerBranch?: (CustomerBranchCreate & { id?: string })[];
taxNo?: string | null;
image?: File;
personName: string;
registeredBranchId: string;
namePrefix: string;
firstName: string;
lastName: string;
firstNameEN: string;
lastNameEN: string;
gender: string;
birthDate: Date;
};
export type BranchAttachmentCreate = {