Skip to content

Commit 29a392b

Browse files
committed
Add images to projects
1 parent 18b44ae commit 29a392b

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
-- AlterTable
2+
ALTER TABLE "Collection" ADD COLUMN "image" TEXT;
3+
4+
-- AlterTable
5+
ALTER TABLE "Project" ADD COLUMN "image" TEXT;

prisma/schema.prisma

+3-1
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ model Collection {
4747
name String
4848
poll_id Int
4949
parent_collection_id Int?
50+
image String?
5051
created_at DateTime @default(now())
5152
poll Poll @relation(fields: [poll_id], references: [id])
5253
parent_collection Collection? @relation("CollectionToCollection", fields: [parent_collection_id], references: [id])
@@ -72,6 +73,7 @@ model Project {
7273
url String
7374
description String
7475
collection_id Int
76+
image String?
7577
created_at DateTime @default(now())
7678
collection Collection @relation(fields: [collection_id], references: [id])
7779
results Result[]
@@ -101,7 +103,7 @@ model ProjectVote {
101103
user_id Int
102104
project1_id Int
103105
project2_id Int
104-
picked_id Int?
106+
picked_id Int?
105107
created_at DateTime @default(now())
106108
updated_at DateTime @default(now())
107109
user User @relation(fields: [user_id], references: [id])

0 commit comments

Comments
 (0)