|
|
@ -84,6 +84,9 @@ model Company {
|
|
|
|
logoUrl String?
|
|
|
|
logoUrl String?
|
|
|
|
createdAt DateTime @default(now())
|
|
|
|
createdAt DateTime @default(now())
|
|
|
|
updatedAt DateTime @updatedAt
|
|
|
|
updatedAt DateTime @updatedAt
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
OffersExperience OffersExperience[]
|
|
|
|
|
|
|
|
OffersOffer OffersOffer[]
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Start of Resumes project models.
|
|
|
|
// Start of Resumes project models.
|
|
|
@ -156,18 +159,20 @@ model ResumesCommentVote {
|
|
|
|
// across all models in this file.
|
|
|
|
// across all models in this file.
|
|
|
|
|
|
|
|
|
|
|
|
model OffersProfile {
|
|
|
|
model OffersProfile {
|
|
|
|
id String @id @default(cuid())
|
|
|
|
id String @id @default(cuid())
|
|
|
|
|
|
|
|
profileName String
|
|
|
|
|
|
|
|
createdAt DateTime @default(now())
|
|
|
|
|
|
|
|
|
|
|
|
background OffersBackground?
|
|
|
|
background OffersBackground?
|
|
|
|
|
|
|
|
|
|
|
|
editToken String
|
|
|
|
editToken String
|
|
|
|
|
|
|
|
|
|
|
|
replies OffersReply[]
|
|
|
|
discussion OffersReply[]
|
|
|
|
|
|
|
|
|
|
|
|
offers OffersOffer[]
|
|
|
|
offers OffersOffer[]
|
|
|
|
|
|
|
|
|
|
|
|
user User @relation(fields: [userId], references: [id])
|
|
|
|
user User? @relation(fields: [userId], references: [id])
|
|
|
|
userId String
|
|
|
|
userId String?
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
model OffersBackground {
|
|
|
|
model OffersBackground {
|
|
|
@ -200,35 +205,55 @@ model OffersExperience {
|
|
|
|
company Company? @relation(fields: [companyId], references: [id])
|
|
|
|
company Company? @relation(fields: [companyId], references: [id])
|
|
|
|
companyId String?
|
|
|
|
companyId String?
|
|
|
|
|
|
|
|
|
|
|
|
jobType JobType?
|
|
|
|
jobType JobType?
|
|
|
|
title String?
|
|
|
|
title String?
|
|
|
|
currency String?
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Add more fields
|
|
|
|
// Add more fields
|
|
|
|
durationInMonths Int?
|
|
|
|
durationInMonths Int?
|
|
|
|
specialization String?
|
|
|
|
specialization String?
|
|
|
|
|
|
|
|
|
|
|
|
// FULLTIME fields
|
|
|
|
// FULLTIME fields
|
|
|
|
level String?
|
|
|
|
level String?
|
|
|
|
totalCompensation BigInt?
|
|
|
|
totalCompensation OffersCurrency? @relation("ExperienceTotalCompensation", fields: [totalCompensationId], references: [id])
|
|
|
|
|
|
|
|
totalCompensationId String? @unique
|
|
|
|
|
|
|
|
|
|
|
|
// INTERN fields
|
|
|
|
// INTERN fields
|
|
|
|
monthlySalary BigInt?
|
|
|
|
monthlySalary OffersCurrency? @relation("ExperienceMonthlySalary", fields: [monthlySalaryId], references: [id])
|
|
|
|
|
|
|
|
monthlySalaryId String? @unique
|
|
|
|
|
|
|
|
|
|
|
|
background OffersBackground @relation(fields: [backgroundId], references: [id])
|
|
|
|
background OffersBackground @relation(fields: [backgroundId], references: [id])
|
|
|
|
backgroundId String
|
|
|
|
backgroundId String
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
model OffersCurrency {
|
|
|
|
|
|
|
|
id String @id @default(cuid())
|
|
|
|
|
|
|
|
value Int
|
|
|
|
|
|
|
|
currency String
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Experience
|
|
|
|
|
|
|
|
OffersExperienceTotalCompensation OffersExperience? @relation("ExperienceTotalCompensation")
|
|
|
|
|
|
|
|
OffersExperienceMonthlySalary OffersExperience? @relation("ExperienceMonthlySalary")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Full Time
|
|
|
|
|
|
|
|
OffersTotalCompensation OffersFullTime? @relation("OfferTotalCompensation")
|
|
|
|
|
|
|
|
OffersBaseSalary OffersFullTime? @relation("OfferBaseSalary")
|
|
|
|
|
|
|
|
OffersBonus OffersFullTime? @relation("OfferBonus")
|
|
|
|
|
|
|
|
OffersStocks OffersFullTime? @relation("OfferStocks")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Intern
|
|
|
|
|
|
|
|
OffersMonthlySalary OffersIntern?
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
enum JobType {
|
|
|
|
enum JobType {
|
|
|
|
INTERN
|
|
|
|
INTERN
|
|
|
|
FULLTIME
|
|
|
|
FULLTIME
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
model OffersEducation {
|
|
|
|
model OffersEducation {
|
|
|
|
id String @id @default(cuid())
|
|
|
|
id String @id @default(cuid())
|
|
|
|
type String?
|
|
|
|
type String?
|
|
|
|
field String?
|
|
|
|
field String?
|
|
|
|
attending Boolean?
|
|
|
|
isAttending Boolean?
|
|
|
|
|
|
|
|
|
|
|
|
// Add more fields
|
|
|
|
// Add more fields
|
|
|
|
school String?
|
|
|
|
school String?
|
|
|
@ -240,14 +265,14 @@ model OffersEducation {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
model OffersReply {
|
|
|
|
model OffersReply {
|
|
|
|
id String @id @default(cuid())
|
|
|
|
id String @id @default(cuid())
|
|
|
|
|
|
|
|
creator String
|
|
|
|
message String
|
|
|
|
createdAt DateTime @default(now())
|
|
|
|
upvotes Int // CHECK: Need log in to upvote?
|
|
|
|
message String
|
|
|
|
|
|
|
|
|
|
|
|
parentReplyId String?
|
|
|
|
replyingToId String?
|
|
|
|
parentReply OffersReply? @relation("ReplyThread", fields: [parentReplyId], references: [id])
|
|
|
|
replyingTo OffersReply? @relation("ReplyThread", fields: [replyingToId], references: [id])
|
|
|
|
replies OffersReply[] @relation("ReplyThread")
|
|
|
|
replies OffersReply[] @relation("ReplyThread")
|
|
|
|
|
|
|
|
|
|
|
|
profile OffersProfile @relation(fields: [profileId], references: [id])
|
|
|
|
profile OffersProfile @relation(fields: [profileId], references: [id])
|
|
|
|
profileId String
|
|
|
|
profileId String
|
|
|
@ -259,11 +284,9 @@ model OffersOffer {
|
|
|
|
profile OffersProfile @relation(fields: [profileId], references: [id])
|
|
|
|
profile OffersProfile @relation(fields: [profileId], references: [id])
|
|
|
|
profileId String
|
|
|
|
profileId String
|
|
|
|
|
|
|
|
|
|
|
|
company OffersCompany @relation(fields: [companyId], references: [id])
|
|
|
|
company Company @relation(fields: [companyId], references: [id])
|
|
|
|
companyId String
|
|
|
|
companyId String
|
|
|
|
|
|
|
|
|
|
|
|
title String
|
|
|
|
|
|
|
|
specialization String
|
|
|
|
|
|
|
|
monthYearReceived DateTime
|
|
|
|
monthYearReceived DateTime
|
|
|
|
location String
|
|
|
|
location String
|
|
|
|
negotiationStrategy String?
|
|
|
|
negotiationStrategy String?
|
|
|
@ -279,22 +302,29 @@ model OffersIntern {
|
|
|
|
offerId String @id
|
|
|
|
offerId String @id
|
|
|
|
offer OffersOffer @relation(fields: [offerId], references: [id])
|
|
|
|
offer OffersOffer @relation(fields: [offerId], references: [id])
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
title String
|
|
|
|
|
|
|
|
specialization String
|
|
|
|
internshipCycle String
|
|
|
|
internshipCycle String
|
|
|
|
startYear Int
|
|
|
|
startYear Int
|
|
|
|
monthlySalary BigInt
|
|
|
|
monthlySalary OffersCurrency @relation(fields: [monthlySalaryId], references: [id])
|
|
|
|
currency String
|
|
|
|
monthlySalaryId String @unique
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
model OffersFullTime {
|
|
|
|
model OffersFullTime {
|
|
|
|
offerId String @id
|
|
|
|
offerId String @id
|
|
|
|
offer OffersOffer @relation(fields: [offerId], references: [id])
|
|
|
|
offer OffersOffer @relation(fields: [offerId], references: [id])
|
|
|
|
|
|
|
|
|
|
|
|
level String
|
|
|
|
title String
|
|
|
|
totalCompensation BigInt
|
|
|
|
specialization String
|
|
|
|
baseSalary BigInt
|
|
|
|
level String
|
|
|
|
bonus BigInt
|
|
|
|
totalCompensation OffersCurrency @relation("OfferTotalCompensation", fields: [totalCompensationId], references: [id])
|
|
|
|
stocks BigInt // CHECK: What to store stocks as? String or Int
|
|
|
|
totalCompensationId String @unique
|
|
|
|
currency String
|
|
|
|
baseSalary OffersCurrency @relation("OfferBaseSalary", fields: [baseSalaryId], references: [id])
|
|
|
|
|
|
|
|
baseSalaryId String @unique
|
|
|
|
|
|
|
|
bonus OffersCurrency @relation("OfferBonus", fields: [bonusId], references: [id])
|
|
|
|
|
|
|
|
bonusId String @unique
|
|
|
|
|
|
|
|
stocks OffersCurrency @relation("OfferStocks", fields: [stocksId], references: [id])
|
|
|
|
|
|
|
|
stocksId String @unique
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// End of Offers project models.
|
|
|
|
// End of Offers project models.
|
|
|
|