@optimatech88/titomeet-shared-lib 1.0.19 → 1.0.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/*
|
|
2
|
+
Warnings:
|
|
3
|
+
|
|
4
|
+
- Added the required column `eventId` to the `Order` table without a default value. This is not possible if the table is not empty.
|
|
5
|
+
|
|
6
|
+
*/
|
|
7
|
+
-- AlterTable
|
|
8
|
+
ALTER TABLE "Order" ADD COLUMN "eventId" TEXT NOT NULL;
|
|
9
|
+
|
|
10
|
+
-- AlterTable
|
|
11
|
+
ALTER TABLE "Provider" ALTER COLUMN "email" DROP NOT NULL;
|
|
12
|
+
|
|
13
|
+
-- AddForeignKey
|
|
14
|
+
ALTER TABLE "Order" ADD CONSTRAINT "Order_eventId_fkey" FOREIGN KEY ("eventId") REFERENCES "Event"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
|
package/prisma/schema.prisma
CHANGED
|
@@ -141,6 +141,8 @@ model Event {
|
|
|
141
141
|
updatedAt DateTime @updatedAt
|
|
142
142
|
|
|
143
143
|
favorites Favorite[]
|
|
144
|
+
|
|
145
|
+
orders Order[]
|
|
144
146
|
}
|
|
145
147
|
|
|
146
148
|
model EventPrice {
|
|
@@ -301,6 +303,9 @@ model Order {
|
|
|
301
303
|
id String @id @default(cuid())
|
|
302
304
|
user User @relation(fields: [userId], references: [id])
|
|
303
305
|
userId String
|
|
306
|
+
|
|
307
|
+
event Event @relation(fields: [eventId], references: [id])
|
|
308
|
+
eventId String
|
|
304
309
|
|
|
305
310
|
email String
|
|
306
311
|
status OrderStatus @default(PENDING)
|