@bash-app/bash-common 7.0.0 → 8.0.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 +9 -7
- package/src/extendedSchemas.ts +2 -1
package/package.json
CHANGED
package/prisma/schema.prisma
CHANGED
|
@@ -168,6 +168,7 @@ model BashNotification {
|
|
|
168
168
|
|
|
169
169
|
@@unique([creatorId, email, bashEventId])
|
|
170
170
|
@@unique([creatorId, email, invitationId])
|
|
171
|
+
@@index([creatorId])
|
|
171
172
|
}
|
|
172
173
|
|
|
173
174
|
model Invitation {
|
|
@@ -243,13 +244,14 @@ model BashEvent {
|
|
|
243
244
|
}
|
|
244
245
|
|
|
245
246
|
model Checkout {
|
|
246
|
-
id
|
|
247
|
-
ownerId
|
|
248
|
-
owner
|
|
249
|
-
bashEventId
|
|
250
|
-
bashEvent
|
|
251
|
-
|
|
252
|
-
|
|
247
|
+
id String @id @default(cuid())
|
|
248
|
+
ownerId String
|
|
249
|
+
owner User @relation(fields: [ownerId], references: [id], onDelete: Cascade)
|
|
250
|
+
bashEventId String
|
|
251
|
+
bashEvent BashEvent @relation(fields: [bashEventId], references: [id], onDelete: Cascade)
|
|
252
|
+
checkoutDateTime DateTime @default(now())
|
|
253
|
+
tickets Ticket[]
|
|
254
|
+
stripeCheckoutSessionId String? @unique
|
|
253
255
|
|
|
254
256
|
@@index(bashEventId)
|
|
255
257
|
}
|
package/src/extendedSchemas.ts
CHANGED
|
@@ -167,6 +167,7 @@ export interface TicketTierExt extends TicketTier {
|
|
|
167
167
|
export interface TicketExt extends Ticket {
|
|
168
168
|
owner: User;
|
|
169
169
|
forUser: User;
|
|
170
|
+
checkout?: Checkout;
|
|
170
171
|
}
|
|
171
172
|
|
|
172
173
|
export interface CheckoutExt extends Checkout {
|
|
@@ -201,7 +202,7 @@ export interface UserExt extends User {
|
|
|
201
202
|
associatedBashes?: AssociatedBash[]
|
|
202
203
|
reviews?: ReviewExt[];
|
|
203
204
|
contacts?: Contact[];
|
|
204
|
-
ticketsIOwn?:
|
|
205
|
+
ticketsIOwn?: TicketExt[];
|
|
205
206
|
}
|
|
206
207
|
|
|
207
208
|
export const USER_DATA_SELECT_REVIEWS_COMMENTS = {
|