@bash-app/bash-common 13.11.0 → 14.1.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 +32 -3
- package/src/extendedSchemas.ts +9 -1
package/package.json
CHANGED
package/prisma/schema.prisma
CHANGED
|
@@ -240,6 +240,8 @@ model BashEvent {
|
|
|
240
240
|
eventTasks EventTask[]
|
|
241
241
|
videoLink String?
|
|
242
242
|
subtitle String?
|
|
243
|
+
isFeatured Boolean?
|
|
244
|
+
isTrending Boolean?
|
|
243
245
|
}
|
|
244
246
|
|
|
245
247
|
model Checkout {
|
|
@@ -831,11 +833,35 @@ model Service {
|
|
|
831
833
|
availableDateTimes String[] /// Stored in format: ["startDateTime,endDateTime",...]
|
|
832
834
|
serviceTargetAudience ServiceTargetAudience[]
|
|
833
835
|
status ServiceStatus @default(Draft)
|
|
836
|
+
venues Venue[]
|
|
834
837
|
|
|
835
838
|
@@index([email])
|
|
836
839
|
@@index([phone])
|
|
837
840
|
}
|
|
838
841
|
|
|
842
|
+
model Venue {
|
|
843
|
+
id String @id @default(cuid())
|
|
844
|
+
Service Service? @relation(fields: [serviceId], references: [id])
|
|
845
|
+
serviceId String?
|
|
846
|
+
venueName String
|
|
847
|
+
capacity Int?
|
|
848
|
+
amenities String[]
|
|
849
|
+
additionalInfo String?
|
|
850
|
+
features String[]
|
|
851
|
+
venueTypes String[]
|
|
852
|
+
availableDateTimes Availability[] @relation("AvailableDateTimes")
|
|
853
|
+
// specialDateTimes Availability[] @relation("SpecialDateTimes")
|
|
854
|
+
mission String?
|
|
855
|
+
pitch String?
|
|
856
|
+
communityInvolvement String?
|
|
857
|
+
emergencyContact String?
|
|
858
|
+
contactDetails String?
|
|
859
|
+
rates String?
|
|
860
|
+
cancellationPolicy String?
|
|
861
|
+
refundPolicy String?
|
|
862
|
+
safetyPolicy String?
|
|
863
|
+
}
|
|
864
|
+
|
|
839
865
|
enum ServiceTag {
|
|
840
866
|
Italian
|
|
841
867
|
}
|
|
@@ -864,9 +890,12 @@ model ServiceRange {
|
|
|
864
890
|
}
|
|
865
891
|
|
|
866
892
|
model Availability {
|
|
867
|
-
id
|
|
868
|
-
startDateTime
|
|
869
|
-
endDateTime
|
|
893
|
+
id String @id @default(cuid())
|
|
894
|
+
startDateTime String
|
|
895
|
+
endDateTime String
|
|
896
|
+
venueId String?
|
|
897
|
+
venueAvailableDateTimes Venue? @relation("AvailableDateTimes", fields: [venueId], references: [id])
|
|
898
|
+
// venueSpecialDateTimes Venue? @relation("SpecialDateTimes", fields: [venueId], references: [id])
|
|
870
899
|
}
|
|
871
900
|
|
|
872
901
|
enum VisibilityPreference {
|
package/src/extendedSchemas.ts
CHANGED
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
ServiceTargetAudience,
|
|
14
14
|
Checkout,
|
|
15
15
|
ServiceLink,
|
|
16
|
-
Link,
|
|
16
|
+
Link, Venue, Availability,
|
|
17
17
|
} from "@prisma/client";
|
|
18
18
|
|
|
19
19
|
export const FRONT_END_USER_DATA_TO_SELECT = {
|
|
@@ -111,6 +111,14 @@ export const BASH_EVENT_DATA_TO_REMOVE: RemoveCommonProperties<BashEvent, BashEv
|
|
|
111
111
|
'tickets'
|
|
112
112
|
];
|
|
113
113
|
|
|
114
|
+
export interface VenueExt extends Venue {
|
|
115
|
+
availableDateTimes: Availability[];
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
export const VENUE_DATA_TO_INCLUDE = {
|
|
119
|
+
availableDateTimes: true,
|
|
120
|
+
}
|
|
121
|
+
|
|
114
122
|
export interface ServiceExt extends Service {
|
|
115
123
|
owner: User;
|
|
116
124
|
media: Media[];
|