Allow items to have multiple uploads linked
This commit is contained in:
parent
51bc4b82d0
commit
ef0506d7c6
@ -0,0 +1,8 @@
|
||||
/*
|
||||
Warnings:
|
||||
|
||||
- You are about to drop the column `uploadId` on the `Item` table. All the data in the column will be lost.
|
||||
|
||||
*/
|
||||
-- DropIndex
|
||||
DROP INDEX "Upload.itemId_unique";
|
@ -176,7 +176,7 @@ model Upload {
|
||||
size Int
|
||||
width Int?
|
||||
height Int?
|
||||
itemId Int? @unique(map: "Upload.itemId_unique")
|
||||
itemId Int?
|
||||
userId Int
|
||||
item Item? @relation(fields: [itemId], references: [id])
|
||||
user User @relation("Uploads", fields: [userId], references: [id], onDelete: Cascade)
|
||||
@ -299,7 +299,7 @@ model Item {
|
||||
PollOption PollOption[]
|
||||
PollVote PollVote[]
|
||||
ThreadSubscription ThreadSubscription[]
|
||||
upload Upload?
|
||||
uploads Upload[]
|
||||
User User[]
|
||||
itemForwards ItemForward[]
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user