File tree Expand file tree Collapse file tree 1 file changed +24
-4
lines changed Expand file tree Collapse file tree 1 file changed +24
-4
lines changed Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ model Follow {
53
53
model Like {
54
54
id Int @id @default (autoincrement () )
55
55
56
- userId Int
56
+ userId Int
57
57
user User @relation (fields : [userId ] , references : [id ] )
58
58
59
59
postId Int
@@ -70,14 +70,34 @@ model Tag {
70
70
71
71
model Comment {
72
72
id Int @id @default (autoincrement () )
73
-
73
+
74
74
text String
75
75
date DateTime @default (now () )
76
76
77
- postId Int
77
+ postId Int
78
78
post Post @relation (fields : [postId ] , references : [id ] )
79
79
80
80
userId Int
81
81
user User @relation (fields : [userId ] , references : [id ] )
82
82
83
- }
83
+ }
84
+
85
+ model Post {
86
+ id Int @id @default (autoincrement () )
87
+
88
+ title String
89
+ text String
90
+
91
+ date DateTime @default (now () )
92
+
93
+ comments Comment []
94
+
95
+ likes Like []
96
+
97
+ image String
98
+
99
+ tags Tag [] @relation (" TagPost " )
100
+
101
+ authorId Int
102
+ author User @relation (fields : [authorId ] , references : [id ] )
103
+ }
You can’t perform that action at this time.
0 commit comments