@a_team/prisma 2.0.4 → 2.0.5

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.
@@ -0,0 +1,482 @@
1
+ type AccountsMember {
2
+ user String @db.ObjectId
3
+ accessLevel String?
4
+ invitedAt DateTime? @db.Date
5
+ }
6
+
7
+ type AccountsWorkspace {
8
+ name String
9
+ description String?
10
+ logo String?
11
+ website String?
12
+ }
13
+
14
+ model Account {
15
+ id String @id @default(auto()) @map("_id") @db.ObjectId
16
+ clientCompany String? @db.ObjectId
17
+ clientCompanyModel ClientCompany? @relation(fields: [clientCompany], references: [id])
18
+ companyId String @map("company") @db.ObjectId
19
+ company Company @relation(fields: [companyId], references: [id])
20
+ members AccountsMember[]
21
+ workspace AccountsWorkspace?
22
+ billingAccount String? @db.ObjectId
23
+ createdAt DateTime? @db.Date
24
+ updatedAt DateTime? @db.Date
25
+ deletedAt DateTime? @db.Date
26
+ migrations String[]
27
+ missions Mission[]
28
+ missionSpecs MissionSpec[]
29
+
30
+ @@map("accounts")
31
+ }
32
+
33
+ model ClientCompany {
34
+ id String @id @default(auto()) @map("_id") @db.ObjectId
35
+ createdAt DateTime? @db.Date
36
+ author String? @db.ObjectId
37
+ name String
38
+ slug String?
39
+ product String?
40
+ website String?
41
+ size String?
42
+ description String?
43
+ logo String?
44
+ accounts Account[]
45
+ missionSpecs MissionSpec[]
46
+
47
+ @@map("clientCompanies")
48
+ }
49
+
50
+ type LocalHourRange {
51
+ endTime Int?
52
+ startTime Int?
53
+ }
54
+
55
+ type TimezoneObject {
56
+ name String
57
+ utcOffset Int
58
+ }
59
+
60
+ type StructuredEnrichment {
61
+ name String?
62
+ countryCode String?
63
+ city String?
64
+ timezone String?
65
+ industries String[] @db.ObjectId
66
+ companyStage String?
67
+ logoUrl String?
68
+ employeeRange String?
69
+ fundingRange String?
70
+ revenueRange String?
71
+ }
72
+
73
+ type CompanyEnrichment {
74
+ structured StructuredEnrichment?
75
+ }
76
+
77
+ model Company {
78
+ id String @id @default(auto()) @map("_id") @db.ObjectId
79
+ accounts Account[]
80
+ name String
81
+ url String
82
+ enrichment CompanyEnrichment
83
+ createdBy String? @db.ObjectId
84
+ createdAt DateTime? @db.Date
85
+ updatedAt DateTime? @db.Date
86
+ requiresDeepEnrichment Boolean?
87
+
88
+ @@index([name, createdAt], map: "name_1_createdAt_-1")
89
+ @@index([url], map: "url_1")
90
+ @@map("companiesV2")
91
+ }
92
+
93
+ model Contract {
94
+ sid String @id @default(auto()) @map("_id") @db.ObjectId
95
+ status ContractStatus
96
+ type ContractType
97
+ downloadURL String
98
+ createdAt DateTime @db.Date
99
+ updatedAt DateTime @updatedAt @db.Date
100
+ parties ContractParty[]
101
+ missionId String? @map("mission") @db.ObjectId
102
+ mission Mission? @relation(fields: [missionId], references: [mid])
103
+ role String? @db.ObjectId
104
+ custom Boolean?
105
+
106
+ @@index([type, missionId, role, createdAt], map: "type_1_mission_1_role_1_createdAt_-1")
107
+ @@index([parties.user, status, createdAt], map: "parties.user_1_status_1_createdAt_1")
108
+ @@map("contracts")
109
+ }
110
+
111
+ enum ContractStatus {
112
+ Created
113
+ Completed
114
+ }
115
+
116
+ enum ContractType {
117
+ TermsOfService
118
+ MissionAgreement
119
+ }
120
+
121
+ type ContractParty {
122
+ type ContractPartyType
123
+ user String? @db.ObjectId
124
+ ip String?
125
+ signedAt DateTime? @db.Date
126
+ accountId String? @db.ObjectId
127
+ stripeClient String?
128
+ }
129
+
130
+ enum ContractPartyType {
131
+ BillingCustomer
132
+ MissionRole
133
+ }
134
+
135
+ type MissionRoleAvailability {
136
+ date DateTime? @db.Date
137
+ scheduledEndDate DateTime? @db.Date
138
+ weeklyHoursAvailable Float
139
+ }
140
+
141
+ type MissionRoleCustomQuestion {
142
+ id String @map("_id") @db.ObjectId
143
+ createdAt DateTime? @db.Date
144
+ isRequired Boolean?
145
+ isVisible Boolean
146
+ text String
147
+ updatedAt DateTime? @db.Date
148
+ }
149
+
150
+ type MissionRolePreferredSkill {
151
+ rating Int?
152
+ talentSkillId String @db.ObjectId
153
+ }
154
+
155
+ type MissionRoleRequiredSkill {
156
+ rating Int?
157
+ talentSkillId String @db.ObjectId
158
+ }
159
+
160
+ type MissionRoleUtcOffsetRange {
161
+ from TimezoneObject?
162
+ to TimezoneObject?
163
+ }
164
+
165
+ type MissionRoleVisibility {
166
+ visibilityStatus String
167
+ }
168
+
169
+ type MissionRoleWorkingHours {
170
+ id String? @map("_id") @db.ObjectId
171
+ daily LocalHourRange[]
172
+ name String?
173
+ numberOfMinutesOverlap Int?
174
+ utcDaylightHours LocalHourRange[]
175
+ utcOffset Int?
176
+ utcStandardHours LocalHourRange[]
177
+ }
178
+
179
+ type MissionRole {
180
+ id String @map("_id") @db.ObjectId
181
+ availability MissionRoleAvailability?
182
+ builderRateMax Float?
183
+ builderRateMin Float?
184
+ category String @db.ObjectId
185
+ createdAt DateTime? @db.Date
186
+ customQuestions MissionRoleCustomQuestion[]
187
+ description String?
188
+ fullName String?
189
+ hasPerformanceIssue Boolean?
190
+ headline String?
191
+ hourlyRate Float?
192
+ monthlyRate Float?
193
+ isBadPerformance Boolean?
194
+ isLead Boolean?
195
+ locations String[]
196
+ lookingForApplications Boolean?
197
+ marginVAT Float?
198
+ preferredSkills MissionRolePreferredSkill[]
199
+ requiredSkills MissionRoleRequiredSkill[]
200
+ setAsScheduledToEndAt DateTime? @db.Date
201
+ showRateRangeToBuilders Boolean?
202
+ status String?
203
+ updatedAt DateTime? @db.Date
204
+ user String? @db.ObjectId
205
+ userAssignedAt DateTime? @db.Date
206
+ utcOffsetRange MissionRoleUtcOffsetRange?
207
+ visibility MissionRoleVisibility?
208
+ workingHours MissionRoleWorkingHours?
209
+ builderMonthlyRateMin Float?
210
+ builderMonthlyRateMax Float?
211
+ collectMonthlyRate Boolean?
212
+ isFullTimeRetainer Boolean?
213
+ }
214
+
215
+ type MissionsManager {
216
+ id String @map("_id") @db.ObjectId
217
+ accessMode String
218
+ excludeFromInvoiceEmails Boolean?
219
+ excludeFromTeamPulseEmails Boolean?
220
+ }
221
+
222
+ type MissionsAttachedLink {
223
+ URL String
224
+ title String
225
+ }
226
+
227
+ type MissionsCompanyRequest {
228
+ companyName String
229
+ description String
230
+ email String
231
+ fullName String
232
+ notes String?
233
+ phoneNumber String
234
+ role String
235
+ websiteURL String
236
+ }
237
+
238
+ type MissionsInvoicing {
239
+ purchaseOrderNumber String?
240
+ }
241
+
242
+ type MissionsTesting {
243
+ expiresAt DateTime @db.Date
244
+ type String
245
+ }
246
+
247
+ type WorkingHoursSchema {
248
+ name String
249
+ utcOffset Int
250
+ daily LocalHourRange[]
251
+ utcStandardHours LocalHourRange[]
252
+ utcDaylightHours LocalHourRange[]
253
+ }
254
+
255
+ model Mission {
256
+ mid String @id @default(auto()) @map("_id") @db.ObjectId
257
+ accountId String? @db.ObjectId
258
+ accountModel Account? @relation(fields: [accountId], references: [id])
259
+ applyStatus String?
260
+ attachedLinks MissionsAttachedLink[]
261
+ automatedStatusesDisabled Boolean?
262
+ automaticInvoicingPeriod String?
263
+ bdOwners String[]
264
+ billingPeriod String?
265
+ clientMargin Float?
266
+ companyRequest MissionsCompanyRequest?
267
+ companyStory String?
268
+ createdAt DateTime? @db.Date
269
+ creatorUser String? @db.ObjectId
270
+ creatorModel User? @relation("creator", fields: [creatorUser], references: [id])
271
+ description String?
272
+ expectedDurationMonths Int?
273
+ hidden Boolean?
274
+ hubspotDealId String?
275
+ internalDescription String?
276
+ internalMission Boolean?
277
+ invoiceEmailGreeting String?
278
+ invoicing MissionsInvoicing?
279
+ lastDeployedAt DateTime? @db.Date
280
+ logoURL String?
281
+ mainManagerUserId String?
282
+ managers MissionsManager[]
283
+ migrations String[]
284
+ missionSpecId String @unique @db.ObjectId
285
+ missionSpec MissionSpec @relation(fields: [missionSpecId], references: [id])
286
+ owner String? @db.ObjectId
287
+ ownerModel User? @relation("ownerModel", fields: [owner], references: [id])
288
+ promotedTags String[]
289
+ publishedAt DateTime? @db.Date
290
+ publisherUser String? @db.ObjectId
291
+ roles MissionRole[]
292
+ rolesMargin Float?
293
+ setAsScheduledToEndAt DateTime? @db.Date
294
+ shortCompanyDescription String?
295
+ skipContracts Boolean?
296
+ status String
297
+ talentIndustries String[]
298
+ testing MissionsTesting?
299
+ title String
300
+ updatedAt DateTime? @db.Date
301
+ videoURL String?
302
+ website String?
303
+ contracts Contract[]
304
+
305
+ @@unique([roles.id], map: "roles._id_1")
306
+ @@map("missions")
307
+ }
308
+
309
+ model MissionSpec {
310
+ id String @id @default(auto()) @map("_id") @db.ObjectId
311
+ account Account? @relation(fields: [accountId], references: [id])
312
+ accountId String? @db.ObjectId
313
+ attachedLinks AttachedLink[]
314
+ author User? @relation(fields: [authorId], references: [id], name: "author")
315
+ authorId String? @map("author") @db.ObjectId
316
+ clientCompany ClientCompany? @relation(fields: [clientCompanyId], references: [id])
317
+ clientCompanyId String? @map("clientCompany") @db.ObjectId
318
+ clientConfirmed Boolean?
319
+ collaborators String[] @db.ObjectId
320
+ companyDescription String?
321
+ createdAt DateTime? @db.Date
322
+ deletedAt DateTime? @db.Date
323
+ description String?
324
+ icon String?
325
+ lastModifier User? @relation(fields: [lastModifierId], references: [id], name: "lastModifier")
326
+ lastModifierId String? @map("lastModifier") @db.ObjectId
327
+ logo String?
328
+ metadata Metadata?
329
+ mission Mission?
330
+ platformId String? @db.ObjectId
331
+ roles MissionSpecRole[]
332
+ startDate DateTime? @db.Date
333
+ status MissionSpecStatus
334
+ statusChangedAt StatusTime?
335
+ title String
336
+ updatedAt DateTime? @db.Date
337
+ v Int @map("__v")
338
+ videoURL String?
339
+ workingHours WorkingHours?
340
+ workingHoursNumberOfMinutesOverlap Int?
341
+
342
+ @@index([accountId], map: "accountId_1")
343
+ @@index([authorId, deletedAt, platformId, createdAt], map: "author_1_deletedAt_1_platformId_1_createdAt_1")
344
+ @@index([accountId, deletedAt, platformId, createdAt], map: "accountId_1_deletedAt_1_platformId_1_createdAt_1")
345
+ @@map("missionSpecs")
346
+ }
347
+
348
+ type MissionSpecRole {
349
+ id String @map("_id") @db.ObjectId
350
+ builderRateMax Float? @db.Double
351
+ builderRateMin Float? @db.Double
352
+ margin Float? @db.Double
353
+ category String? @db.ObjectId
354
+ createdAt DateTime? @default(now()) @db.Date
355
+ createdBy String? @db.ObjectId
356
+ customQuestions ClientRoleQuestion[]
357
+ description String?
358
+ isLead Boolean @default(false)
359
+ tags String[]
360
+ locations String[]
361
+ minimumCommitment Int?
362
+ preferredSkills String[] @db.ObjectId
363
+ requiredSkills String[] @db.ObjectId
364
+ typicalHourlyRate Int?
365
+ user String? @db.ObjectId
366
+ }
367
+
368
+ type AttachedLink {
369
+ URL String
370
+ title String
371
+ }
372
+
373
+ type Metadata {
374
+ lastGeneratedAiDescriptionAt DateTime? @db.Date
375
+ lastGeneratedAiDescription String?
376
+ generatedFromGongCallAt DateTime? @db.Date
377
+ landbotCustomerId String?
378
+ bridgeType String?
379
+ }
380
+
381
+ enum MissionSpecStatus {
382
+ spec
383
+ formation
384
+ proposal
385
+ confirmed
386
+ declined
387
+ published
388
+ }
389
+
390
+ type StatusTime {
391
+ spec DateTime? @db.Date
392
+ formation DateTime? @db.Date
393
+ proposal DateTime? @db.Date
394
+ confirmed DateTime? @db.Date
395
+ declined DateTime? @db.Date
396
+ published DateTime? @db.Date
397
+ }
398
+
399
+ type WorkingHours {
400
+ name String
401
+ utcOffset Int
402
+ daily LocalHourRange[]
403
+ utcStandardHours LocalHourRange[]
404
+ utcDaylightHours LocalHourRange[]
405
+ numberOfMinutesOverlap Int?
406
+ }
407
+
408
+ type ClientRoleQuestion {
409
+ id String? @map("_id") @db.ObjectId
410
+ text String
411
+ isRequired Boolean?
412
+ isVisible Boolean?
413
+ createdAt DateTime @db.Date
414
+ updatedAt DateTime? @db.Date
415
+ }
416
+
417
+ model RoleCategory {
418
+ id String @id @default(auto()) @map("_id") @db.ObjectId
419
+ anchors String[]
420
+ title String @unique(map: "title_1")
421
+ deletedAt DateTime? @db.Date
422
+ group String?
423
+ talentCategoryIds String[]
424
+
425
+ @@map("roleCategories")
426
+ }
427
+
428
+ datasource db {
429
+ provider = "mongodb"
430
+ url = env("MONGODB_URL")
431
+ }
432
+
433
+ generator client {
434
+ provider = "prisma-client-js"
435
+ binaryTargets = ["native", "darwin"]
436
+ previewFeatures = ["prismaSchemaFolder"]
437
+ output = "../../models"
438
+ }
439
+
440
+ model TalentCategory {
441
+ id String @id @default(auto()) @map("_id") @db.ObjectId
442
+ textId String
443
+ name String
444
+ nodeType String
445
+ parentTalentCategoryIds String[]
446
+ aliases String[]
447
+ isProgrammingLanguage Boolean?
448
+ isVettingEligible Boolean?
449
+ deletedAt DateTime? @db.Date
450
+
451
+ @@map("talentCategories")
452
+ }
453
+
454
+ model TalentIndustry {
455
+ id String @id @default(auto()) @map("_id") @db.ObjectId
456
+ description String
457
+ name String
458
+ textId String @unique(map: "textId_1")
459
+
460
+ @@map("talentIndustries")
461
+ }
462
+
463
+ model User {
464
+ id String @id @default(auto()) @map("_id") @db.ObjectId
465
+ firstName String?
466
+ lastName String?
467
+ username String? @unique(map: "username_1")
468
+ email String? @unique(map: "email_1")
469
+ isAdmin Boolean @default(false)
470
+ createdMissionsModels Mission[] @relation("creator")
471
+ ownedMissionsModels Mission[] @relation("ownerModel")
472
+ type String
473
+ pictureURL String?
474
+ status String
475
+ createdAt DateTime @db.Date
476
+ titles String[]
477
+ scrubbed String?
478
+ authoredMissionSpecs MissionSpec[] @relation("author")
479
+ modifiedMissionSpecs MissionSpec[] @relation("lastModifier")
480
+
481
+ @@map("users")
482
+ }
@@ -0,0 +1 @@
1
+ export * from './index'