@bash-app/bash-common 30.111.0 → 30.112.0
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 +1 -1
- package/prisma/schema.prisma +41 -0
package/package.json
CHANGED
package/prisma/schema.prisma
CHANGED
|
@@ -71,6 +71,8 @@ model BashFeedPost {
|
|
|
71
71
|
comments BashFeedComment[]
|
|
72
72
|
ratings BashFeedRating[]
|
|
73
73
|
reports BashFeedReport[]
|
|
74
|
+
saves BashFeedSave[]
|
|
75
|
+
reposts BashFeedRepost[]
|
|
74
76
|
|
|
75
77
|
@@index([bashId])
|
|
76
78
|
@@index([userId])
|
|
@@ -161,6 +163,36 @@ model BashFeedReport {
|
|
|
161
163
|
@@index([userId])
|
|
162
164
|
}
|
|
163
165
|
|
|
166
|
+
model BashFeedSave {
|
|
167
|
+
id String @id @default(cuid())
|
|
168
|
+
userId String
|
|
169
|
+
postId String
|
|
170
|
+
createdAt DateTime @default(now())
|
|
171
|
+
|
|
172
|
+
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
|
|
173
|
+
post BashFeedPost @relation(fields: [postId], references: [id], onDelete: Cascade)
|
|
174
|
+
|
|
175
|
+
@@unique([userId, postId])
|
|
176
|
+
@@index([postId])
|
|
177
|
+
@@index([userId])
|
|
178
|
+
@@index([createdAt])
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
model BashFeedRepost {
|
|
182
|
+
id String @id @default(cuid())
|
|
183
|
+
userId String
|
|
184
|
+
postId String
|
|
185
|
+
createdAt DateTime @default(now())
|
|
186
|
+
|
|
187
|
+
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
|
|
188
|
+
post BashFeedPost @relation(fields: [postId], references: [id], onDelete: Cascade)
|
|
189
|
+
|
|
190
|
+
@@unique([userId, postId])
|
|
191
|
+
@@index([postId])
|
|
192
|
+
@@index([userId])
|
|
193
|
+
@@index([createdAt])
|
|
194
|
+
}
|
|
195
|
+
|
|
164
196
|
model Competition {
|
|
165
197
|
id String @id @default(cuid())
|
|
166
198
|
name String
|
|
@@ -457,6 +489,7 @@ model BashEvent {
|
|
|
457
489
|
dress String?
|
|
458
490
|
allowed String?
|
|
459
491
|
notAllowed String?
|
|
492
|
+
eventFormat EventFormat? // Derived from location and videoLink: In-Person, Virtual, or Hybrid
|
|
460
493
|
nonProfit Boolean?
|
|
461
494
|
nonProfitId String?
|
|
462
495
|
privacy Privacy @default(Public)
|
|
@@ -1292,6 +1325,8 @@ model User {
|
|
|
1292
1325
|
bashFeedRatings BashFeedRating[]
|
|
1293
1326
|
bashFeedReports BashFeedReport[]
|
|
1294
1327
|
reviewedFeedReports BashFeedReport[] @relation("ReviewedReports")
|
|
1328
|
+
bashFeedSaves BashFeedSave[]
|
|
1329
|
+
bashFeedReposts BashFeedRepost[]
|
|
1295
1330
|
|
|
1296
1331
|
// Nomination Relations
|
|
1297
1332
|
nominationsReceived Nomination[] @relation("NominatedUser")
|
|
@@ -5188,3 +5223,9 @@ model NominationVote {
|
|
|
5188
5223
|
@@index([nominationId])
|
|
5189
5224
|
@@index([voterId])
|
|
5190
5225
|
}
|
|
5226
|
+
|
|
5227
|
+
enum EventFormat {
|
|
5228
|
+
InPerson
|
|
5229
|
+
Virtual
|
|
5230
|
+
Hybrid
|
|
5231
|
+
}
|