Add change-password endpoint and VIP product pricing fields.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
co-authored by
Cursor
parent
fe78a99b78
commit
3da8a5d4a2
@@ -0,0 +1,5 @@
|
||||
-- AlterTable
|
||||
ALTER TABLE "Product" ADD COLUMN "vipOnly" BOOLEAN NOT NULL DEFAULT false;
|
||||
|
||||
-- CreateIndex
|
||||
CREATE INDEX "Product_vipOnly_idx" ON "Product"("vipOnly");
|
||||
@@ -0,0 +1,10 @@
|
||||
-- AlterTable
|
||||
ALTER TABLE "Product" ADD COLUMN "vipEnabled" BOOLEAN NOT NULL DEFAULT false;
|
||||
ALTER TABLE "Product" ADD COLUMN "vipSpecialPrice" BOOLEAN NOT NULL DEFAULT false;
|
||||
ALTER TABLE "Product" ADD COLUMN "vipPrice" INTEGER;
|
||||
|
||||
-- CreateIndex
|
||||
CREATE INDEX "Product_vipEnabled_idx" ON "Product"("vipEnabled");
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "ProductVariant" ADD COLUMN "vipPrice" INTEGER;
|
||||
+13
-6
@@ -185,18 +185,24 @@ model Product {
|
||||
imageKey String?
|
||||
galleryUrls String[] @default([])
|
||||
galleryKeys String[] @default([])
|
||||
tags String[] @default([])
|
||||
published Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
variants ProductVariant[]
|
||||
orderItems OrderItem[]
|
||||
tags String[] @default([])
|
||||
published Boolean @default(true)
|
||||
vipEnabled Boolean @default(false)
|
||||
vipOnly Boolean @default(false)
|
||||
vipSpecialPrice Boolean @default(false)
|
||||
vipPrice Int?
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
variants ProductVariant[]
|
||||
orderItems OrderItem[]
|
||||
|
||||
@@index([storeId])
|
||||
@@index([categoryId])
|
||||
@@index([brandId])
|
||||
@@index([price])
|
||||
@@index([published])
|
||||
@@index([vipEnabled])
|
||||
@@index([vipOnly])
|
||||
}
|
||||
|
||||
model ProductVariant {
|
||||
@@ -208,6 +214,7 @@ model ProductVariant {
|
||||
packageId String @default("")
|
||||
price Int @default(0)
|
||||
discountPrice Int?
|
||||
vipPrice Int?
|
||||
|
||||
@@index([productId])
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user