feat: add description field to orders and support marking menu items as sold out

This commit is contained in:
Firman Ramdhani
2026-09-11 10:40:23 +07:00
parent e3c8f980f7
commit f4358eb00b
14 changed files with 435 additions and 211 deletions
+6 -4
View File
@@ -27,6 +27,7 @@ model User {
model Order {
id String @id @default(uuid())
title String
description String?
date DateTime
allow_custom Boolean @default(false)
status String @default("DRAFT")
@@ -39,10 +40,11 @@ model Order {
}
model AvailableItem {
id String @id @default(uuid())
order_id String
name String
order Order @relation(fields: [order_id], references: [id], onDelete: Cascade)
id String @id @default(uuid())
order_id String
name String
is_sold_out Boolean @default(false)
order Order @relation(fields: [order_id], references: [id], onDelete: Cascade)
created_at DateTime @default(now())
updated_at DateTime @updatedAt
}