@bash-app/bash-common 28.4.0 → 29.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 +22 -7
- package/src/definitions.ts +28 -1
- package/src/extendedSchemas.ts +5 -2
package/package.json
CHANGED
package/prisma/schema.prisma
CHANGED
|
@@ -698,7 +698,7 @@ model Media {
|
|
|
698
698
|
bashEventsReferencingMe BashEvent[]
|
|
699
699
|
sponsoredEventsReferencingMe SponsoredEvent[]
|
|
700
700
|
serviceReferencingMe Service[]
|
|
701
|
-
|
|
701
|
+
volunteerService VolunteerService? @relation(fields: [volunteerServiceId], references: [id])
|
|
702
702
|
volunteerServiceId String?
|
|
703
703
|
}
|
|
704
704
|
|
|
@@ -928,7 +928,7 @@ model Service {
|
|
|
928
928
|
bashesInterestedIn BashEventType[]
|
|
929
929
|
bookings Booking[]
|
|
930
930
|
media Media[]
|
|
931
|
-
ServiceLink
|
|
931
|
+
serviceLinks ServiceLink[]
|
|
932
932
|
|
|
933
933
|
eventService EventService?
|
|
934
934
|
entertainmentService EntertainmentService?
|
|
@@ -963,13 +963,15 @@ model VolunteerService {
|
|
|
963
963
|
agreedToAgreement Boolean? @default(false)
|
|
964
964
|
description String?
|
|
965
965
|
status VolunteerServiceStatus?
|
|
966
|
-
|
|
966
|
+
media Media[]
|
|
967
967
|
}
|
|
968
968
|
|
|
969
969
|
model EventService {
|
|
970
970
|
id String @id @default(cuid())
|
|
971
971
|
serviceId String @unique
|
|
972
972
|
service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade)
|
|
973
|
+
serviceRangeId String?
|
|
974
|
+
serviceRange ServiceRange? @relation(fields: [serviceRangeId], references: [id])
|
|
973
975
|
eventServiceTypes EventServiceType[]
|
|
974
976
|
eventServiceSubType String?
|
|
975
977
|
yearsOfExperience YearsOfExperience
|
|
@@ -984,6 +986,8 @@ model EntertainmentService {
|
|
|
984
986
|
id String @id @default(cuid())
|
|
985
987
|
serviceId String @unique
|
|
986
988
|
service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade)
|
|
989
|
+
serviceRangeId String?
|
|
990
|
+
serviceRange ServiceRange? @relation(fields: [serviceRangeId], references: [id])
|
|
987
991
|
entertainmentServiceTypes EntertainmentServiceType[]
|
|
988
992
|
entertainmentServiceSubType String?
|
|
989
993
|
genre MusicGenreType?
|
|
@@ -998,6 +1002,8 @@ model Vendor {
|
|
|
998
1002
|
id String @id @default(cuid())
|
|
999
1003
|
serviceId String @unique
|
|
1000
1004
|
service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade)
|
|
1005
|
+
serviceRangeId String?
|
|
1006
|
+
serviceRange ServiceRange? @relation(fields: [serviceRangeId], references: [id])
|
|
1001
1007
|
yearsOfExperience YearsOfExperience
|
|
1002
1008
|
crowdSizeId String? @unique
|
|
1003
1009
|
crowdSize AmountOfGuests? @relation(fields: [crowdSizeId], references: [id], onDelete: Cascade)
|
|
@@ -1010,6 +1016,8 @@ model Exhibitor {
|
|
|
1010
1016
|
id String @id @default(cuid())
|
|
1011
1017
|
serviceId String @unique
|
|
1012
1018
|
service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade)
|
|
1019
|
+
serviceRangeId String?
|
|
1020
|
+
serviceRange ServiceRange? @relation(fields: [serviceRangeId], references: [id])
|
|
1013
1021
|
yearsOfExperience YearsOfExperience
|
|
1014
1022
|
crowdSizeId String? @unique
|
|
1015
1023
|
crowdSize AmountOfGuests? @relation(fields: [crowdSizeId], references: [id], onDelete: Cascade)
|
|
@@ -1021,6 +1029,8 @@ model Sponsor {
|
|
|
1021
1029
|
id String @id @default(cuid())
|
|
1022
1030
|
serviceId String @unique
|
|
1023
1031
|
service Service @relation(fields: [serviceId], references: [id], onDelete: Cascade)
|
|
1032
|
+
serviceRangeId String?
|
|
1033
|
+
serviceRange ServiceRange? @relation(fields: [serviceRangeId], references: [id])
|
|
1024
1034
|
yearsOfExperience YearsOfExperience
|
|
1025
1035
|
crowdSizeId String? @unique
|
|
1026
1036
|
crowdSize AmountOfGuests? @relation(fields: [crowdSizeId], references: [id])
|
|
@@ -1123,10 +1133,15 @@ enum YearsOfExperience {
|
|
|
1123
1133
|
}
|
|
1124
1134
|
|
|
1125
1135
|
model ServiceRange {
|
|
1126
|
-
id
|
|
1127
|
-
min
|
|
1128
|
-
max
|
|
1129
|
-
volunteerServices
|
|
1136
|
+
id String @id @default(cuid())
|
|
1137
|
+
min Int @default(0)
|
|
1138
|
+
max Int @default(50)
|
|
1139
|
+
volunteerServices VolunteerService[]
|
|
1140
|
+
entertainmentServices EntertainmentService[]
|
|
1141
|
+
EventService EventService[]
|
|
1142
|
+
Vendor Vendor[]
|
|
1143
|
+
Exhibitor Exhibitor[]
|
|
1144
|
+
Sponsor Sponsor[]
|
|
1130
1145
|
}
|
|
1131
1146
|
|
|
1132
1147
|
model Availability {
|
package/src/definitions.ts
CHANGED
|
@@ -4,6 +4,7 @@ import {
|
|
|
4
4
|
BashEventVibeTags,
|
|
5
5
|
Contact,
|
|
6
6
|
DayOfWeek,
|
|
7
|
+
Prisma,
|
|
7
8
|
Ticket,
|
|
8
9
|
TicketTier,
|
|
9
10
|
User,
|
|
@@ -82,7 +83,33 @@ export const DEBOUNCE_WAIT = 1000 as const;
|
|
|
82
83
|
export const ASSET_KEY_DELIM = '__' as const;
|
|
83
84
|
export const ASSET_MAX_MD5_BYTE_LENGTH = 1024 * 100; // 100kb
|
|
84
85
|
|
|
85
|
-
|
|
86
|
+
export const SERVICE_LINK_DATA_TO_INCLUDE = {
|
|
87
|
+
link: true,
|
|
88
|
+
} satisfies Prisma.ServiceLinkInclude;
|
|
89
|
+
|
|
90
|
+
export const SERVICE_DATA_TO_INCLUDE = {
|
|
91
|
+
stripeAccount: true,
|
|
92
|
+
availableDateTimes: true,
|
|
93
|
+
targetAudience: true,
|
|
94
|
+
media: true,
|
|
95
|
+
serviceLinks: {
|
|
96
|
+
include: SERVICE_LINK_DATA_TO_INCLUDE
|
|
97
|
+
},
|
|
98
|
+
} satisfies Prisma.ServiceInclude;
|
|
99
|
+
|
|
100
|
+
export const VENUE_DATA_TO_INCLUDE = {
|
|
101
|
+
|
|
102
|
+
} satisfies Prisma.VenueInclude;
|
|
103
|
+
|
|
104
|
+
export const VOLUNTEER_DATA_TO_INCLUDE = {
|
|
105
|
+
links: {
|
|
106
|
+
include: {
|
|
107
|
+
serviceLinks: true,
|
|
108
|
+
},
|
|
109
|
+
},
|
|
110
|
+
media: true,
|
|
111
|
+
serviceRange: true,
|
|
112
|
+
} satisfies Prisma.VolunteerServiceInclude;
|
|
86
113
|
|
|
87
114
|
export type DateTimeArgType = Date | string | undefined | null;
|
|
88
115
|
export type RequiredStripeInfoMissingErrorDataType = { [k in keyof User]?: { type: string, label: string } };
|
package/src/extendedSchemas.ts
CHANGED
|
@@ -155,11 +155,10 @@ export interface ServiceExt extends Service {
|
|
|
155
155
|
|
|
156
156
|
stripeAccount?: StripeAccount;
|
|
157
157
|
|
|
158
|
-
visiblility?: VisibilityPreference;
|
|
159
158
|
availableDateTimes?: Availability[];
|
|
160
159
|
|
|
161
160
|
bookings?: Booking[];
|
|
162
|
-
|
|
161
|
+
targetAudience?: TargetAudience;
|
|
163
162
|
media?: Media[];
|
|
164
163
|
serviceLinks?: ServiceLinkExt[];
|
|
165
164
|
|
|
@@ -175,21 +174,25 @@ export interface ServiceExt extends Service {
|
|
|
175
174
|
export interface EventServiceExt extends EventService {
|
|
176
175
|
service: ServiceExt;
|
|
177
176
|
crowdSize?: AmountOfGuests;
|
|
177
|
+
serviceRange?: ServiceRange;
|
|
178
178
|
}
|
|
179
179
|
|
|
180
180
|
export interface EntertainmentServiceExt extends EntertainmentService {
|
|
181
181
|
service: ServiceExt;
|
|
182
182
|
crowdSize?: AmountOfGuests;
|
|
183
|
+
serviceRange?: ServiceRange;
|
|
183
184
|
}
|
|
184
185
|
|
|
185
186
|
export interface ExhibitorExt extends Exhibitor {
|
|
186
187
|
service: ServiceExt;
|
|
187
188
|
crowdSize?: AmountOfGuests;
|
|
189
|
+
serviceRange?: ServiceRange;
|
|
188
190
|
}
|
|
189
191
|
|
|
190
192
|
export interface SponsorExt extends Sponsor {
|
|
191
193
|
service: ServiceExt;
|
|
192
194
|
crowdSize?: AmountOfGuests;
|
|
195
|
+
serviceRange?: ServiceRange;
|
|
193
196
|
}
|
|
194
197
|
|
|
195
198
|
export interface VendorExt extends Vendor {
|