@a_team/prisma 1.0.6 → 1.0.8
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/.env.sample +4 -0
- package/README.md +18 -0
- package/package.json +5 -2
- package/playground/missionSpec.ts +21 -0
- package/prisma/schema/account.prisma +21 -20
- package/prisma/schema/clientCompany.prisma +13 -12
- package/prisma/schema/common.prisma +9 -0
- package/prisma/schema/enrichableCompany.prisma +5 -5
- package/prisma/schema/mission.prisma +128 -146
- package/prisma/schema/missionSpec.prisma +105 -0
- package/prisma/schema/roleCategory.prisma +7 -7
- package/prisma/schema/schema.prisma +5 -5
- package/prisma/schema/talentCategory.prisma +10 -10
- package/prisma/schema/talentIndustry.prisma +8 -0
- package/prisma/schema/user.prisma +16 -14
- package/tsconfig.json +9 -0
- package/package-lock.json +0 -100
package/.env.sample
ADDED
package/README.md
CHANGED
|
@@ -23,6 +23,24 @@ import { PrismaClient } from "@prisma/client";
|
|
|
23
23
|
const prisma = new PrismaClient();
|
|
24
24
|
```
|
|
25
25
|
|
|
26
|
+
## Playground
|
|
27
|
+
|
|
28
|
+
The playground is a dedicated space where you can test and experiment with the Prisma client and schema. It contains various scripts that demonstrate how to interact with your database models.
|
|
29
|
+
|
|
30
|
+
Before running any playground scripts, make sure to set up your environment variables. First, copy the `.env.sample` file to `.env`:
|
|
31
|
+
|
|
32
|
+
```sh
|
|
33
|
+
cp .env.sample .env
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Then, fill in the required environment variables in the `.env` file.
|
|
37
|
+
|
|
38
|
+
To run a playground script, use the following command:
|
|
39
|
+
|
|
40
|
+
```sh
|
|
41
|
+
npx ts-node playground/missionSpec.ts
|
|
42
|
+
```
|
|
43
|
+
|
|
26
44
|
## Publishing
|
|
27
45
|
|
|
28
46
|
To publish updates to this package, use the following command:
|
package/package.json
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@a_team/prisma",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.8",
|
|
4
4
|
"keywords": [],
|
|
5
5
|
"scripts": {
|
|
6
6
|
"generate": "npx prisma generate",
|
|
7
|
+
"format": "npx prisma format",
|
|
7
8
|
"postinstall": "npm run generate"
|
|
8
9
|
},
|
|
9
10
|
"repository": {
|
|
@@ -14,7 +15,9 @@
|
|
|
14
15
|
"license": "ISC",
|
|
15
16
|
"devDependencies": {
|
|
16
17
|
"@prisma/client": "^5.17.0",
|
|
17
|
-
"prisma": "^5.17.0"
|
|
18
|
+
"prisma": "^5.17.0",
|
|
19
|
+
"ts-node": "^10.9.2",
|
|
20
|
+
"typescript": "^5.5.4"
|
|
18
21
|
},
|
|
19
22
|
"peerDependencies": {
|
|
20
23
|
"@prisma/client": ">=5"
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// npx ts-node playground/missionSpec.ts
|
|
2
|
+
|
|
3
|
+
import { PrismaClient } from "@prisma/client";
|
|
4
|
+
|
|
5
|
+
const prisma = new PrismaClient();
|
|
6
|
+
|
|
7
|
+
async function main() {
|
|
8
|
+
const missionSpec = await prisma.missionSpec.findMany({
|
|
9
|
+
take: 5,
|
|
10
|
+
});
|
|
11
|
+
console.log(missionSpec);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
main()
|
|
15
|
+
.then(async () => {
|
|
16
|
+
await prisma.$disconnect();
|
|
17
|
+
})
|
|
18
|
+
.catch(async (e) => {
|
|
19
|
+
console.error(e);
|
|
20
|
+
await prisma.$disconnect();
|
|
21
|
+
});
|
|
@@ -1,29 +1,30 @@
|
|
|
1
1
|
type AccountsMember {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
user String @db.ObjectId
|
|
3
|
+
accessLevel String?
|
|
4
|
+
invitedAt DateTime? @db.Date
|
|
5
5
|
}
|
|
6
6
|
|
|
7
7
|
type AccountsWorkspace {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
name String
|
|
9
|
+
description String?
|
|
10
|
+
logo String?
|
|
11
|
+
website String?
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
model Account {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
15
|
+
id String @id @default(auto()) @map("_id") @db.ObjectId
|
|
16
|
+
clientCompany String? @db.ObjectId
|
|
17
|
+
clientCompanyModel ClientCompany? @relation(fields: [clientCompany], references: [id])
|
|
18
|
+
company EnrichableCompany[]
|
|
19
|
+
members AccountsMember[]
|
|
20
|
+
workspace AccountsWorkspace?
|
|
21
|
+
billingAccount String? @db.ObjectId
|
|
22
|
+
createdAt DateTime? @db.Date
|
|
23
|
+
updatedAt DateTime? @db.Date
|
|
24
|
+
deletedAt DateTime? @db.Date
|
|
25
|
+
migrations String[]
|
|
26
|
+
missions Mission[]
|
|
27
|
+
missionSpecs MissionSpec[]
|
|
27
28
|
|
|
28
|
-
|
|
29
|
+
@@map("accounts")
|
|
29
30
|
}
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
model ClientCompany {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
2
|
+
id String @id @default(auto()) @map("_id") @db.ObjectId
|
|
3
|
+
createdAt DateTime? @db.Date
|
|
4
|
+
author String? @db.ObjectId
|
|
5
|
+
name String
|
|
6
|
+
slug String?
|
|
7
|
+
product String?
|
|
8
|
+
website String?
|
|
9
|
+
size String?
|
|
10
|
+
description String?
|
|
11
|
+
logo String?
|
|
12
|
+
accounts Account[]
|
|
13
|
+
missionSpecs MissionSpec[]
|
|
13
14
|
|
|
14
|
-
|
|
15
|
+
@@map("clientCompanies")
|
|
15
16
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
model EnrichableCompany {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
2
|
+
id String @id @default(auto()) @map("_id") @db.ObjectId
|
|
3
|
+
name String
|
|
4
|
+
accountId String? @db.ObjectId
|
|
5
|
+
accountModel Account? @relation(fields: [accountId], references: [id])
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
@@map("companiesV2")
|
|
8
8
|
}
|
|
@@ -1,190 +1,172 @@
|
|
|
1
1
|
type MissionRoleAvailability {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
date DateTime? @db.Date
|
|
3
|
+
scheduledEndDate DateTime? @db.Date
|
|
4
|
+
weeklyHoursAvailable Float
|
|
5
5
|
}
|
|
6
6
|
|
|
7
7
|
type MissionRoleCustomQuestion {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
8
|
+
id String @map("_id") @db.ObjectId
|
|
9
|
+
createdAt DateTime? @db.Date
|
|
10
|
+
isRequired Boolean?
|
|
11
|
+
isVisible Boolean
|
|
12
|
+
text String
|
|
13
|
+
updatedAt DateTime? @db.Date
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
type MissionRolePreferredSkill {
|
|
17
|
-
|
|
18
|
-
|
|
17
|
+
rating Int?
|
|
18
|
+
talentSkillId String @db.ObjectId
|
|
19
19
|
}
|
|
20
20
|
|
|
21
21
|
type MissionRoleRequiredSkill {
|
|
22
|
-
|
|
23
|
-
|
|
22
|
+
rating Int?
|
|
23
|
+
talentSkillId String @db.ObjectId
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
type MissionRoleUtcOffsetRange {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
type TimezoneObject {
|
|
32
|
-
name String
|
|
33
|
-
utcOffset Int
|
|
27
|
+
from TimezoneObject?
|
|
28
|
+
to TimezoneObject?
|
|
34
29
|
}
|
|
35
30
|
|
|
36
31
|
type MissionRoleVisibility {
|
|
37
|
-
|
|
32
|
+
visibilityStatus String
|
|
38
33
|
}
|
|
39
34
|
|
|
40
35
|
type MissionRoleWorkingHours {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
type LocalHourRange {
|
|
51
|
-
endTime Int?
|
|
52
|
-
startTime Int?
|
|
36
|
+
id String? @map("_id") @db.ObjectId
|
|
37
|
+
daily LocalHourRange[]
|
|
38
|
+
name String?
|
|
39
|
+
numberOfMinutesOverlap Int?
|
|
40
|
+
utcDaylightHours LocalHourRange[]
|
|
41
|
+
utcOffset Int?
|
|
42
|
+
utcStandardHours LocalHourRange[]
|
|
53
43
|
}
|
|
54
44
|
|
|
55
45
|
type MissionRole {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
46
|
+
id String @map("_id") @db.ObjectId
|
|
47
|
+
availability MissionRoleAvailability?
|
|
48
|
+
builderRateMax Float?
|
|
49
|
+
builderRateMin Float?
|
|
50
|
+
category String @db.ObjectId
|
|
51
|
+
createdAt DateTime? @db.Date
|
|
52
|
+
customQuestions MissionRoleCustomQuestion[]
|
|
53
|
+
description String?
|
|
54
|
+
fullName String?
|
|
55
|
+
hasPerformanceIssue Boolean?
|
|
56
|
+
headline String?
|
|
57
|
+
hourlyRate Float?
|
|
58
|
+
monthlyRate Float?
|
|
59
|
+
isBadPerformance Boolean?
|
|
60
|
+
isLead Boolean?
|
|
61
|
+
locations String[]
|
|
62
|
+
lookingForApplications Boolean?
|
|
63
|
+
marginVAT Float?
|
|
64
|
+
preferredSkills MissionRolePreferredSkill[]
|
|
65
|
+
requiredSkills MissionRoleRequiredSkill[]
|
|
66
|
+
setAsScheduledToEndAt DateTime? @db.Date
|
|
67
|
+
showRateRangeToBuilders Boolean?
|
|
68
|
+
status String?
|
|
69
|
+
updatedAt DateTime? @db.Date
|
|
70
|
+
user String? @db.ObjectId
|
|
71
|
+
userAssignedAt DateTime? @db.Date
|
|
72
|
+
utcOffsetRange MissionRoleUtcOffsetRange?
|
|
73
|
+
visibility MissionRoleVisibility?
|
|
74
|
+
workingHours MissionRoleWorkingHours?
|
|
75
|
+
builderMonthlyRateMin Float?
|
|
76
|
+
builderMonthlyRateMax Float?
|
|
77
|
+
collectMonthlyRate Boolean?
|
|
78
|
+
isFullTimeRetainer Boolean?
|
|
89
79
|
}
|
|
90
80
|
|
|
91
81
|
type MissionsManager {
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
82
|
+
id String @map("_id") @db.ObjectId
|
|
83
|
+
accessMode String
|
|
84
|
+
excludeFromInvoiceEmails Boolean?
|
|
85
|
+
excludeFromTeamPulseEmails Boolean?
|
|
96
86
|
}
|
|
97
87
|
|
|
98
88
|
type MissionsAttachedLink {
|
|
99
|
-
|
|
100
|
-
|
|
89
|
+
URL String
|
|
90
|
+
title String
|
|
101
91
|
}
|
|
102
92
|
|
|
103
93
|
type MissionsCompanyRequest {
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
94
|
+
companyName String
|
|
95
|
+
description String
|
|
96
|
+
email String
|
|
97
|
+
fullName String
|
|
98
|
+
notes String?
|
|
99
|
+
phoneNumber String
|
|
100
|
+
role String
|
|
101
|
+
websiteURL String
|
|
112
102
|
}
|
|
113
103
|
|
|
114
104
|
type MissionsInvoicing {
|
|
115
|
-
|
|
105
|
+
purchaseOrderNumber String?
|
|
116
106
|
}
|
|
117
107
|
|
|
118
108
|
type MissionsTesting {
|
|
119
|
-
|
|
120
|
-
|
|
109
|
+
expiresAt DateTime @db.Date
|
|
110
|
+
type String
|
|
121
111
|
}
|
|
122
112
|
|
|
123
113
|
type WorkingHoursSchema {
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
model TalentIndustry {
|
|
132
|
-
id String @id @default(auto()) @map("_id") @db.ObjectId
|
|
133
|
-
description String
|
|
134
|
-
name String
|
|
135
|
-
textId String @unique(map: "textId_1")
|
|
136
|
-
|
|
137
|
-
@@map("talentIndustries")
|
|
114
|
+
name String
|
|
115
|
+
utcOffset Int
|
|
116
|
+
daily LocalHourRange[]
|
|
117
|
+
utcStandardHours LocalHourRange[]
|
|
118
|
+
utcDaylightHours LocalHourRange[]
|
|
138
119
|
}
|
|
139
120
|
|
|
140
121
|
model Mission {
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
122
|
+
mid String @id @default(auto()) @map("_id") @db.ObjectId
|
|
123
|
+
accountId String? @db.ObjectId
|
|
124
|
+
accountModel Account? @relation(fields: [accountId], references: [id])
|
|
125
|
+
applyStatus String?
|
|
126
|
+
attachedLinks MissionsAttachedLink[]
|
|
127
|
+
automatedStatusesDisabled Boolean?
|
|
128
|
+
automaticInvoicingPeriod String?
|
|
129
|
+
bdOwners String[]
|
|
130
|
+
billingPeriod String?
|
|
131
|
+
clientMargin Float?
|
|
132
|
+
companyRequest MissionsCompanyRequest?
|
|
133
|
+
companyStory String?
|
|
134
|
+
createdAt DateTime? @db.Date
|
|
135
|
+
creatorUser String? @db.ObjectId
|
|
136
|
+
creatorModel User? @relation("creator", fields: [creatorUser], references: [id])
|
|
137
|
+
description String?
|
|
138
|
+
expectedDurationMonths Int?
|
|
139
|
+
hidden Boolean?
|
|
140
|
+
hubspotDealId String?
|
|
141
|
+
internalDescription String?
|
|
142
|
+
internalMission Boolean?
|
|
143
|
+
invoiceEmailGreeting String?
|
|
144
|
+
invoicing MissionsInvoicing?
|
|
145
|
+
lastDeployedAt DateTime? @db.Date
|
|
146
|
+
logoURL String?
|
|
147
|
+
mainManagerUserId String?
|
|
148
|
+
managers MissionsManager[]
|
|
149
|
+
migrations String[]
|
|
150
|
+
missionSpecId String @unique @db.ObjectId
|
|
151
|
+
missionSpec MissionSpec @relation(fields: [missionSpecId], references: [id])
|
|
152
|
+
owner String? @db.ObjectId
|
|
153
|
+
ownerModel User? @relation("ownerModel", fields: [owner], references: [id])
|
|
154
|
+
promotedTags String[]
|
|
155
|
+
publishedAt DateTime? @db.Date
|
|
156
|
+
publisherUser String? @db.ObjectId
|
|
157
|
+
roles MissionRole[]
|
|
158
|
+
rolesMargin Float?
|
|
159
|
+
setAsScheduledToEndAt DateTime? @db.Date
|
|
160
|
+
shortCompanyDescription String?
|
|
161
|
+
skipContracts Boolean?
|
|
162
|
+
status String
|
|
163
|
+
talentIndustries String[]
|
|
164
|
+
testing MissionsTesting?
|
|
165
|
+
title String
|
|
166
|
+
updatedAt DateTime? @db.Date
|
|
167
|
+
videoURL String?
|
|
168
|
+
website String?
|
|
169
|
+
|
|
170
|
+
@@unique([roles.id], map: "roles._id_1")
|
|
171
|
+
@@map("missions")
|
|
190
172
|
}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
model MissionSpec {
|
|
2
|
+
id String @id @default(auto()) @map("_id") @db.ObjectId
|
|
3
|
+
account Account? @relation(fields: [accountId], references: [id])
|
|
4
|
+
accountId String? @db.ObjectId
|
|
5
|
+
attachedLinks AttachedLink[]
|
|
6
|
+
author User? @relation(fields: [authorId], references: [id], name: "author")
|
|
7
|
+
authorId String? @map("author") @db.ObjectId
|
|
8
|
+
clientCompany ClientCompany? @relation(fields: [clientCompanyId], references: [id])
|
|
9
|
+
clientCompanyId String? @map("clientCompany") @db.ObjectId
|
|
10
|
+
clientConfirmed Boolean?
|
|
11
|
+
collaborators String[] @db.ObjectId
|
|
12
|
+
companyDescription String?
|
|
13
|
+
createdAt DateTime? @db.Date
|
|
14
|
+
deletedAt DateTime? @db.Date
|
|
15
|
+
description String?
|
|
16
|
+
icon String?
|
|
17
|
+
lastModifier User? @relation(fields: [lastModifierId], references: [id], name: "lastModifier")
|
|
18
|
+
lastModifierId String? @map("lastModifier") @db.ObjectId
|
|
19
|
+
logo String?
|
|
20
|
+
metadata Metadata?
|
|
21
|
+
mission Mission?
|
|
22
|
+
platformId String? @db.ObjectId
|
|
23
|
+
roles MissionSpecRole[]
|
|
24
|
+
startDate DateTime? @db.Date
|
|
25
|
+
status MissionSpecStatus
|
|
26
|
+
statusChangedAt StatusTime?
|
|
27
|
+
title String
|
|
28
|
+
updatedAt DateTime? @db.Date
|
|
29
|
+
v Int @map("__v")
|
|
30
|
+
videoURL String?
|
|
31
|
+
workingHours WorkingHours?
|
|
32
|
+
workingHoursNumberOfMinutesOverlap Int?
|
|
33
|
+
|
|
34
|
+
@@index([accountId], map: "accountId_1")
|
|
35
|
+
@@index([authorId, deletedAt, platformId, createdAt], map: "author_1_deletedAt_1_platformId_1_createdAt_1")
|
|
36
|
+
@@index([accountId, deletedAt, platformId, createdAt], map: "accountId_1_deletedAt_1_platformId_1_createdAt_1")
|
|
37
|
+
@@map("missionSpecs")
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
type MissionSpecRole {
|
|
41
|
+
id String @map("_id") @db.ObjectId
|
|
42
|
+
builderRateMax Int?
|
|
43
|
+
builderRateMin Int?
|
|
44
|
+
category String? @db.ObjectId
|
|
45
|
+
createdAt DateTime? @default(now()) @db.Date
|
|
46
|
+
createdBy String? @db.ObjectId
|
|
47
|
+
customQuestions ClientRoleQuestion[]
|
|
48
|
+
description String?
|
|
49
|
+
isLead Boolean @default(false)
|
|
50
|
+
locations String[]
|
|
51
|
+
minimumCommitment Int?
|
|
52
|
+
preferredSkills String[] @db.ObjectId
|
|
53
|
+
requiredSkills String[] @db.ObjectId
|
|
54
|
+
typicalHourlyRate Int?
|
|
55
|
+
user String? @db.ObjectId
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
type AttachedLink {
|
|
59
|
+
URL String
|
|
60
|
+
title String
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
type Metadata {
|
|
64
|
+
lastGeneratedAiDescriptionAt DateTime? @db.Date
|
|
65
|
+
lastGeneratedAiDescription String?
|
|
66
|
+
generatedFromGongCallAt DateTime? @db.Date
|
|
67
|
+
landbotCustomerId String?
|
|
68
|
+
bridgeType String?
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
enum MissionSpecStatus {
|
|
72
|
+
spec
|
|
73
|
+
formation
|
|
74
|
+
proposal
|
|
75
|
+
confirmed
|
|
76
|
+
declined
|
|
77
|
+
published
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
type StatusTime {
|
|
81
|
+
spec DateTime? @db.Date
|
|
82
|
+
formation DateTime? @db.Date
|
|
83
|
+
proposal DateTime? @db.Date
|
|
84
|
+
confirmed DateTime? @db.Date
|
|
85
|
+
declined DateTime? @db.Date
|
|
86
|
+
published DateTime? @db.Date
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
type WorkingHours {
|
|
90
|
+
name String
|
|
91
|
+
utcOffset Int
|
|
92
|
+
daily LocalHourRange[]
|
|
93
|
+
utcStandardHours LocalHourRange[]
|
|
94
|
+
utcDaylightHours LocalHourRange[]
|
|
95
|
+
numberOfMinutesOverlap Int?
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
type ClientRoleQuestion {
|
|
99
|
+
id String? @map("_id") @db.ObjectId
|
|
100
|
+
text String
|
|
101
|
+
isRequired Boolean?
|
|
102
|
+
isVisible Boolean?
|
|
103
|
+
createdAt DateTime @db.Date
|
|
104
|
+
updatedAt DateTime? @db.Date
|
|
105
|
+
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
model RoleCategory {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
2
|
+
id String @id @default(auto()) @map("_id") @db.ObjectId
|
|
3
|
+
anchors String[]
|
|
4
|
+
title String @unique(map: "title_1")
|
|
5
|
+
deletedAt DateTime? @db.Date
|
|
6
|
+
group String?
|
|
7
|
+
talentCategoryIds String[]
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
@@map("roleCategories")
|
|
10
10
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
datasource db {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
provider = "mongodb"
|
|
3
|
+
url = env("MONGODB_URL")
|
|
4
4
|
}
|
|
5
5
|
|
|
6
6
|
generator client {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
provider = "prisma-client-js"
|
|
8
|
+
binaryTargets = ["native", "darwin"]
|
|
9
|
+
previewFeatures = ["prismaSchemaFolder"]
|
|
10
10
|
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
model TalentCategory {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
2
|
+
id String @id @default(auto()) @map("_id") @db.ObjectId
|
|
3
|
+
textId String
|
|
4
|
+
name String
|
|
5
|
+
nodeType String
|
|
6
|
+
parentTalentCategoryIds String[]
|
|
7
|
+
aliases String[]
|
|
8
|
+
isProgrammingLanguage Boolean?
|
|
9
|
+
isVettingEligible Boolean?
|
|
10
|
+
deletedAt DateTime? @db.Date
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
@@map("talentCategories")
|
|
13
13
|
}
|
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
model User {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
2
|
+
id String @id @default(auto()) @map("_id") @db.ObjectId
|
|
3
|
+
firstName String?
|
|
4
|
+
lastName String?
|
|
5
|
+
username String? @unique(map: "username_1")
|
|
6
|
+
email String? @unique(map: "email_1")
|
|
7
|
+
createdMissionsModels Mission[] @relation("creator")
|
|
8
|
+
ownedMissionsModels Mission[] @relation("ownerModel")
|
|
9
|
+
type String
|
|
10
|
+
pictureURL String?
|
|
11
|
+
status String
|
|
12
|
+
createdAt DateTime @db.Date
|
|
13
|
+
titles String[]
|
|
14
|
+
scrubbed String?
|
|
15
|
+
authoredMissionSpecs MissionSpec[] @relation("author")
|
|
16
|
+
modifiedMissionSpecs MissionSpec[] @relation("lastModifier")
|
|
15
17
|
|
|
16
|
-
|
|
18
|
+
@@map("users")
|
|
17
19
|
}
|
package/tsconfig.json
ADDED
package/package-lock.json
DELETED
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@a_team/prisma",
|
|
3
|
-
"version": "1.0.5",
|
|
4
|
-
"lockfileVersion": 3,
|
|
5
|
-
"requires": true,
|
|
6
|
-
"packages": {
|
|
7
|
-
"": {
|
|
8
|
-
"name": "@a_team/prisma",
|
|
9
|
-
"version": "1.0.5",
|
|
10
|
-
"hasInstallScript": true,
|
|
11
|
-
"license": "ISC",
|
|
12
|
-
"devDependencies": {
|
|
13
|
-
"@prisma/client": "^5.17.0",
|
|
14
|
-
"prisma": "^5.17.0"
|
|
15
|
-
},
|
|
16
|
-
"peerDependencies": {
|
|
17
|
-
"@prisma/client": ">=5"
|
|
18
|
-
}
|
|
19
|
-
},
|
|
20
|
-
"node_modules/@prisma/client": {
|
|
21
|
-
"version": "5.17.0",
|
|
22
|
-
"resolved": "https://registry.npmjs.org/@prisma/client/-/client-5.17.0.tgz",
|
|
23
|
-
"integrity": "sha512-N2tnyKayT0Zf7mHjwEyE8iG7FwTmXDHFZ1GnNhQp0pJUObsuel4ZZ1XwfuAYkq5mRIiC/Kot0kt0tGCfLJ70Jw==",
|
|
24
|
-
"dev": true,
|
|
25
|
-
"hasInstallScript": true,
|
|
26
|
-
"engines": {
|
|
27
|
-
"node": ">=16.13"
|
|
28
|
-
},
|
|
29
|
-
"peerDependencies": {
|
|
30
|
-
"prisma": "*"
|
|
31
|
-
},
|
|
32
|
-
"peerDependenciesMeta": {
|
|
33
|
-
"prisma": {
|
|
34
|
-
"optional": true
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
},
|
|
38
|
-
"node_modules/@prisma/debug": {
|
|
39
|
-
"version": "5.17.0",
|
|
40
|
-
"resolved": "https://registry.npmjs.org/@prisma/debug/-/debug-5.17.0.tgz",
|
|
41
|
-
"integrity": "sha512-l7+AteR3P8FXiYyo496zkuoiJ5r9jLQEdUuxIxNCN1ud8rdbH3GTxm+f+dCyaSv9l9WY+29L9czaVRXz9mULfg==",
|
|
42
|
-
"dev": true
|
|
43
|
-
},
|
|
44
|
-
"node_modules/@prisma/engines": {
|
|
45
|
-
"version": "5.17.0",
|
|
46
|
-
"resolved": "https://registry.npmjs.org/@prisma/engines/-/engines-5.17.0.tgz",
|
|
47
|
-
"integrity": "sha512-+r+Nf+JP210Jur+/X8SIPLtz+uW9YA4QO5IXA+KcSOBe/shT47bCcRMTYCbOESw3FFYFTwe7vU6KTWHKPiwvtg==",
|
|
48
|
-
"dev": true,
|
|
49
|
-
"hasInstallScript": true,
|
|
50
|
-
"dependencies": {
|
|
51
|
-
"@prisma/debug": "5.17.0",
|
|
52
|
-
"@prisma/engines-version": "5.17.0-31.393aa359c9ad4a4bb28630fb5613f9c281cde053",
|
|
53
|
-
"@prisma/fetch-engine": "5.17.0",
|
|
54
|
-
"@prisma/get-platform": "5.17.0"
|
|
55
|
-
}
|
|
56
|
-
},
|
|
57
|
-
"node_modules/@prisma/engines-version": {
|
|
58
|
-
"version": "5.17.0-31.393aa359c9ad4a4bb28630fb5613f9c281cde053",
|
|
59
|
-
"resolved": "https://registry.npmjs.org/@prisma/engines-version/-/engines-version-5.17.0-31.393aa359c9ad4a4bb28630fb5613f9c281cde053.tgz",
|
|
60
|
-
"integrity": "sha512-tUuxZZysZDcrk5oaNOdrBnnkoTtmNQPkzINFDjz7eG6vcs9AVDmA/F6K5Plsb2aQc/l5M2EnFqn3htng9FA4hg==",
|
|
61
|
-
"dev": true
|
|
62
|
-
},
|
|
63
|
-
"node_modules/@prisma/fetch-engine": {
|
|
64
|
-
"version": "5.17.0",
|
|
65
|
-
"resolved": "https://registry.npmjs.org/@prisma/fetch-engine/-/fetch-engine-5.17.0.tgz",
|
|
66
|
-
"integrity": "sha512-ESxiOaHuC488ilLPnrv/tM2KrPhQB5TRris/IeIV4ZvUuKeaicCl4Xj/JCQeG9IlxqOgf1cCg5h5vAzlewN91Q==",
|
|
67
|
-
"dev": true,
|
|
68
|
-
"dependencies": {
|
|
69
|
-
"@prisma/debug": "5.17.0",
|
|
70
|
-
"@prisma/engines-version": "5.17.0-31.393aa359c9ad4a4bb28630fb5613f9c281cde053",
|
|
71
|
-
"@prisma/get-platform": "5.17.0"
|
|
72
|
-
}
|
|
73
|
-
},
|
|
74
|
-
"node_modules/@prisma/get-platform": {
|
|
75
|
-
"version": "5.17.0",
|
|
76
|
-
"resolved": "https://registry.npmjs.org/@prisma/get-platform/-/get-platform-5.17.0.tgz",
|
|
77
|
-
"integrity": "sha512-UlDgbRozCP1rfJ5Tlkf3Cnftb6srGrEQ4Nm3og+1Se2gWmCZ0hmPIi+tQikGDUVLlvOWx3Gyi9LzgRP+HTXV9w==",
|
|
78
|
-
"dev": true,
|
|
79
|
-
"dependencies": {
|
|
80
|
-
"@prisma/debug": "5.17.0"
|
|
81
|
-
}
|
|
82
|
-
},
|
|
83
|
-
"node_modules/prisma": {
|
|
84
|
-
"version": "5.17.0",
|
|
85
|
-
"resolved": "https://registry.npmjs.org/prisma/-/prisma-5.17.0.tgz",
|
|
86
|
-
"integrity": "sha512-m4UWkN5lBE6yevqeOxEvmepnL5cNPEjzMw2IqDB59AcEV6w7D8vGljDLd1gPFH+W6gUxw9x7/RmN5dCS/WTPxA==",
|
|
87
|
-
"dev": true,
|
|
88
|
-
"hasInstallScript": true,
|
|
89
|
-
"dependencies": {
|
|
90
|
-
"@prisma/engines": "5.17.0"
|
|
91
|
-
},
|
|
92
|
-
"bin": {
|
|
93
|
-
"prisma": "build/index.js"
|
|
94
|
-
},
|
|
95
|
-
"engines": {
|
|
96
|
-
"node": ">=16.13"
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
}
|