@a_team/prisma 2.1.3 → 2.1.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,501 @@
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
+ pandadocMetadata PandadocMetadata?
106
+ source ContractSource?
107
+ documentTitle String?
108
+
109
+ @@index([type, missionId, role, createdAt], map: "type_1_mission_1_role_1_createdAt_-1")
110
+ @@index([parties.user, status, createdAt], map: "parties.user_1_status_1_createdAt_1")
111
+ @@map("contracts")
112
+ }
113
+
114
+ enum ContractStatus {
115
+ Created
116
+ Completed
117
+ }
118
+
119
+ enum ContractType {
120
+ TermsOfService
121
+ MissionAgreement
122
+ ClientContract
123
+ }
124
+
125
+ type ContractParty {
126
+ type ContractPartyType
127
+ user String? @db.ObjectId
128
+ ip String?
129
+ signedAt DateTime? @db.Date
130
+ accountId String? @db.ObjectId
131
+ stripeClient String?
132
+ }
133
+
134
+ enum ContractPartyType {
135
+ BillingCustomer
136
+ MissionRole
137
+ }
138
+
139
+ type PandadocMetadata {
140
+ id String
141
+ hubspotDealId String?
142
+ hubspotCompanyId String?
143
+ }
144
+
145
+ enum ContractSource {
146
+ PandaDoc
147
+ Custom
148
+ ATeamGenerated
149
+ }
150
+
151
+ type MissionRoleAvailability {
152
+ date DateTime? @db.Date
153
+ scheduledEndDate DateTime? @db.Date
154
+ weeklyHoursAvailable Float
155
+ }
156
+
157
+ type MissionRoleCustomQuestion {
158
+ id String @map("_id") @db.ObjectId
159
+ createdAt DateTime? @db.Date
160
+ isRequired Boolean?
161
+ isVisible Boolean
162
+ text String
163
+ updatedAt DateTime? @db.Date
164
+ }
165
+
166
+ type MissionRolePreferredSkill {
167
+ rating Int?
168
+ talentSkillId String @db.ObjectId
169
+ }
170
+
171
+ type MissionRoleRequiredSkill {
172
+ rating Int?
173
+ talentSkillId String @db.ObjectId
174
+ }
175
+
176
+ type MissionRoleUtcOffsetRange {
177
+ from TimezoneObject?
178
+ to TimezoneObject?
179
+ }
180
+
181
+ type MissionRoleVisibility {
182
+ visibilityStatus String
183
+ }
184
+
185
+ type MissionRoleWorkingHours {
186
+ id String? @map("_id") @db.ObjectId
187
+ daily LocalHourRange[]
188
+ name String?
189
+ numberOfMinutesOverlap Int?
190
+ utcDaylightHours LocalHourRange[]
191
+ utcOffset Int?
192
+ utcStandardHours LocalHourRange[]
193
+ }
194
+
195
+ type MissionRole {
196
+ id String @map("_id") @db.ObjectId
197
+ availability MissionRoleAvailability?
198
+ builderRateMax Float?
199
+ builderRateMin Float?
200
+ category String @db.ObjectId
201
+ createdAt DateTime? @db.Date
202
+ customQuestions MissionRoleCustomQuestion[]
203
+ description String?
204
+ fullName String?
205
+ hasPerformanceIssue Boolean?
206
+ headline String?
207
+ hourlyRate Float?
208
+ monthlyRate Float?
209
+ isBadPerformance Boolean?
210
+ isLead Boolean?
211
+ locations String[]
212
+ lookingForApplications Boolean?
213
+ margin Float?
214
+ preferredSkills MissionRolePreferredSkill[]
215
+ requiredSkills MissionRoleRequiredSkill[]
216
+ setAsScheduledToEndAt DateTime? @db.Date
217
+ showRateRangeToBuilders Boolean?
218
+ status String?
219
+ updatedAt DateTime? @db.Date
220
+ user String? @db.ObjectId
221
+ userAssignedAt DateTime? @db.Date
222
+ utcOffsetRange MissionRoleUtcOffsetRange?
223
+ visibility MissionRoleVisibility?
224
+ workingHours MissionRoleWorkingHours?
225
+ builderMonthlyRateMin Float?
226
+ builderMonthlyRateMax Float?
227
+ collectMonthlyRate Boolean?
228
+ isFullTimeRetainer Boolean?
229
+ }
230
+
231
+ type MissionsManager {
232
+ id String @map("_id") @db.ObjectId
233
+ accessMode String
234
+ excludeFromInvoiceEmails Boolean?
235
+ excludeFromTeamPulseEmails Boolean?
236
+ }
237
+
238
+ type MissionsAttachedLink {
239
+ URL String
240
+ title String
241
+ }
242
+
243
+ type MissionsCompanyRequest {
244
+ companyName String
245
+ description String
246
+ email String
247
+ fullName String
248
+ notes String?
249
+ phoneNumber String
250
+ role String
251
+ websiteURL String
252
+ }
253
+
254
+ type MissionsInvoicing {
255
+ purchaseOrderNumber String?
256
+ }
257
+
258
+ type MissionsTesting {
259
+ expiresAt DateTime @db.Date
260
+ type String
261
+ }
262
+
263
+ type WorkingHoursSchema {
264
+ name String
265
+ utcOffset Int
266
+ daily LocalHourRange[]
267
+ utcStandardHours LocalHourRange[]
268
+ utcDaylightHours LocalHourRange[]
269
+ }
270
+
271
+ model Mission {
272
+ mid String @id @default(auto()) @map("_id") @db.ObjectId
273
+ accountId String? @db.ObjectId
274
+ accountModel Account? @relation(fields: [accountId], references: [id])
275
+ applyStatus String?
276
+ attachedLinks MissionsAttachedLink[]
277
+ automatedStatusesDisabled Boolean?
278
+ automaticInvoicingPeriod String?
279
+ bdOwners String[]
280
+ billingPeriod String?
281
+ clientMargin Float?
282
+ companyRequest MissionsCompanyRequest?
283
+ companyStory String?
284
+ createdAt DateTime? @db.Date
285
+ creatorUser String? @db.ObjectId
286
+ creatorModel User? @relation("creator", fields: [creatorUser], references: [id])
287
+ description String?
288
+ expectedDurationMonths Int?
289
+ hidden Boolean?
290
+ hubspotDealId String?
291
+ internalDescription String?
292
+ internalMission Boolean?
293
+ invoiceEmailGreeting String?
294
+ invoicing MissionsInvoicing?
295
+ lastDeployedAt DateTime? @db.Date
296
+ logoURL String?
297
+ mainManagerUserId String?
298
+ managers MissionsManager[]
299
+ migrations String[]
300
+ missionSpecId String @unique @db.ObjectId
301
+ missionSpec MissionSpec @relation(fields: [missionSpecId], references: [id])
302
+ owner String? @db.ObjectId
303
+ ownerModel User? @relation("ownerModel", fields: [owner], references: [id])
304
+ promotedTags String[]
305
+ publishedAt DateTime? @db.Date
306
+ publisherUser String? @db.ObjectId
307
+ roles MissionRole[]
308
+ rolesMargin Float?
309
+ setAsScheduledToEndAt DateTime? @db.Date
310
+ shortCompanyDescription String?
311
+ skipContracts Boolean?
312
+ status String
313
+ talentIndustries String[]
314
+ testing MissionsTesting?
315
+ title String
316
+ updatedAt DateTime? @db.Date
317
+ videoURL String?
318
+ website String?
319
+ startDate DateTime? @db.Date
320
+ overlapMinutes Int?
321
+ timezone String?
322
+ contracts Contract[]
323
+
324
+ @@unique([roles.id], map: "roles._id_1")
325
+ @@map("missions")
326
+ }
327
+
328
+ model MissionSpec {
329
+ id String @id @default(auto()) @map("_id") @db.ObjectId
330
+ account Account? @relation(fields: [accountId], references: [id])
331
+ accountId String? @db.ObjectId
332
+ attachedLinks AttachedLink[]
333
+ author User? @relation(fields: [authorId], references: [id], name: "author")
334
+ authorId String? @map("author") @db.ObjectId
335
+ clientCompany ClientCompany? @relation(fields: [clientCompanyId], references: [id])
336
+ clientCompanyId String? @map("clientCompany") @db.ObjectId
337
+ clientConfirmed Boolean?
338
+ collaborators String[] @db.ObjectId
339
+ companyDescription String?
340
+ createdAt DateTime? @db.Date
341
+ deletedAt DateTime? @db.Date
342
+ description String?
343
+ icon String?
344
+ lastModifier User? @relation(fields: [lastModifierId], references: [id], name: "lastModifier")
345
+ lastModifierId String? @map("lastModifier") @db.ObjectId
346
+ logo String?
347
+ metadata Metadata?
348
+ mission Mission?
349
+ platformId String? @db.ObjectId
350
+ roles MissionSpecRole[]
351
+ startDate DateTime? @db.Date
352
+ status MissionSpecStatus
353
+ statusChangedAt StatusTime?
354
+ title String
355
+ updatedAt DateTime? @db.Date
356
+ v Int @map("__v")
357
+ videoURL String?
358
+ workingHours WorkingHours?
359
+ workingHoursNumberOfMinutesOverlap Int?
360
+
361
+ @@index([accountId], map: "accountId_1")
362
+ @@index([authorId, deletedAt, platformId, createdAt], map: "author_1_deletedAt_1_platformId_1_createdAt_1")
363
+ @@index([accountId, deletedAt, platformId, createdAt], map: "accountId_1_deletedAt_1_platformId_1_createdAt_1")
364
+ @@map("missionSpecs")
365
+ }
366
+
367
+ type MissionSpecRole {
368
+ id String @map("_id") @db.ObjectId
369
+ builderRateMax Float? @db.Double
370
+ builderRateMin Float? @db.Double
371
+ margin Float? @db.Double
372
+ category String? @db.ObjectId
373
+ createdAt DateTime? @default(now()) @db.Date
374
+ createdBy String? @db.ObjectId
375
+ customQuestions ClientRoleQuestion[]
376
+ description String?
377
+ isLead Boolean @default(false)
378
+ tags String[]
379
+ locations String[]
380
+ minimumCommitment Int?
381
+ preferredSkills String[] @db.ObjectId
382
+ requiredSkills String[] @db.ObjectId
383
+ typicalHourlyRate Int?
384
+ user String? @db.ObjectId
385
+ }
386
+
387
+ type AttachedLink {
388
+ URL String
389
+ title String
390
+ }
391
+
392
+ type Metadata {
393
+ lastGeneratedAiDescriptionAt DateTime? @db.Date
394
+ lastGeneratedAiDescription String?
395
+ generatedFromGongCallAt DateTime? @db.Date
396
+ landbotCustomerId String?
397
+ bridgeType String?
398
+ }
399
+
400
+ enum MissionSpecStatus {
401
+ spec
402
+ formation
403
+ proposal
404
+ confirmed
405
+ declined
406
+ published
407
+ }
408
+
409
+ type StatusTime {
410
+ spec DateTime? @db.Date
411
+ formation DateTime? @db.Date
412
+ proposal DateTime? @db.Date
413
+ confirmed DateTime? @db.Date
414
+ declined DateTime? @db.Date
415
+ published DateTime? @db.Date
416
+ }
417
+
418
+ type WorkingHours {
419
+ name String
420
+ utcOffset Int
421
+ daily LocalHourRange[]
422
+ utcStandardHours LocalHourRange[]
423
+ utcDaylightHours LocalHourRange[]
424
+ numberOfMinutesOverlap Int?
425
+ }
426
+
427
+ type ClientRoleQuestion {
428
+ id String? @map("_id") @db.ObjectId
429
+ text String
430
+ isRequired Boolean?
431
+ isVisible Boolean?
432
+ createdAt DateTime @db.Date
433
+ updatedAt DateTime? @db.Date
434
+ }
435
+
436
+ model RoleCategory {
437
+ id String @id @default(auto()) @map("_id") @db.ObjectId
438
+ anchors String[]
439
+ title String @unique(map: "title_1")
440
+ deletedAt DateTime? @db.Date
441
+ group String?
442
+ talentCategoryIds String[]
443
+
444
+ @@map("roleCategories")
445
+ }
446
+
447
+ datasource db {
448
+ provider = "mongodb"
449
+ url = env("MONGODB_URL")
450
+ }
451
+
452
+ generator client {
453
+ provider = "prisma-client-js"
454
+ binaryTargets = ["native", "darwin", "darwin-arm64", "windows", "linux-musl-openssl-3.0.x"]
455
+ previewFeatures = ["prismaSchemaFolder"]
456
+ output = "../../src/client"
457
+ }
458
+
459
+ model TalentCategory {
460
+ id String @id @default(auto()) @map("_id") @db.ObjectId
461
+ textId String
462
+ name String
463
+ nodeType String
464
+ parentTalentCategoryIds String[]
465
+ aliases String[]
466
+ isProgrammingLanguage Boolean?
467
+ isVettingEligible Boolean?
468
+ deletedAt DateTime? @db.Date
469
+
470
+ @@map("talentCategories")
471
+ }
472
+
473
+ model TalentIndustry {
474
+ id String @id @default(auto()) @map("_id") @db.ObjectId
475
+ description String
476
+ name String
477
+ textId String @unique(map: "textId_1")
478
+
479
+ @@map("talentIndustries")
480
+ }
481
+
482
+ model User {
483
+ id String @id @default(auto()) @map("_id") @db.ObjectId
484
+ firstName String?
485
+ lastName String?
486
+ username String? @unique(map: "username_1")
487
+ email String? @unique(map: "email_1")
488
+ isAdmin Boolean @default(false)
489
+ createdMissionsModels Mission[] @relation("creator")
490
+ ownedMissionsModels Mission[] @relation("ownerModel")
491
+ type String
492
+ pictureURL String?
493
+ status String
494
+ createdAt DateTime @db.Date
495
+ titles String[]
496
+ scrubbed String?
497
+ authoredMissionSpecs MissionSpec[] @relation("author")
498
+ modifiedMissionSpecs MissionSpec[] @relation("lastModifier")
499
+
500
+ @@map("users")
501
+ }
@@ -0,0 +1 @@
1
+ export * from './index'