fix: missing field

This commit is contained in:
Methapon Metanipat 2024-09-10 15:51:22 +07:00
parent c755650fed
commit c38a1ce0c0
4 changed files with 17 additions and 2 deletions

View file

@ -0,0 +1,5 @@
-- AlterTable
ALTER TABLE "Product" ADD COLUMN "selectedImage" TEXT;
-- AlterTable
ALTER TABLE "Service" ADD COLUMN "selectedImage" TEXT;

View file

@ -692,7 +692,8 @@ model Product {
shared Boolean @default(false)
remark String?
remark String?
selectedImage String?
productGroup ProductGroup @relation(fields: [productGroupId], references: [id], onDelete: Cascade)
productGroupId String
@ -719,7 +720,8 @@ model Service {
status Status @default(CREATED)
statusOrder Int @default(0)
shared Boolean @default(false)
shared Boolean @default(false)
selectedImage String?
work Work[]
quotationService QuotationService[]

View file

@ -69,6 +69,8 @@ type ProductCreate = {
serviceCharge: number;
vatIncluded?: boolean;
expenseType?: string;
selectedImage?: string;
shared?: boolean;
productGroupId: string;
remark?: string;
};
@ -84,6 +86,8 @@ type ProductUpdate = {
remark?: string;
vatIncluded?: boolean;
expenseType?: string;
selectedImage?: string;
shared?: boolean;
productGroupId?: string;
};

View file

@ -58,6 +58,8 @@ type ServiceCreate = {
productId: string[];
attributes?: { [key: string]: any };
}[];
shared?: boolean;
selectedImage?: string;
productGroupId: string;
};
@ -73,6 +75,8 @@ type ServiceUpdate = {
productId: string[];
attributes?: { [key: string]: any };
}[];
shared?: boolean;
selectedImage?: string;
productGroupId?: string;
};