@adaptware/eagles-db 0.4.34 → 0.4.36
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/client/edge.js +11 -869
- package/client/index-browser.js +42 -901
- package/client/index.d.ts +27423 -80978
- package/client/index.js +11 -869
- package/client/package.json +1 -1
- package/client/schema.prisma +128 -1594
- package/client/wasm.js +11 -869
- package/package.json +1 -1
- package/prisma/schema/CandidateQuestionResponse.prisma +0 -1
- package/prisma/schema/UserRole.prisma +0 -1
- package/prisma/schema/action.prisma +0 -5
- package/prisma/schema/activityLog.prisma +0 -3
- package/prisma/schema/applications.prisma +2 -12
- package/prisma/schema/approval.prisma +0 -2
- package/prisma/schema/assessment.prisma +0 -1
- package/prisma/schema/assessmentLibrary.prisma +0 -1
- package/prisma/schema/assessmentQuestion.prisma +0 -1
- package/prisma/schema/assignment.prisma +0 -3
- package/prisma/schema/assignmentLibrary.prisma +0 -1
- package/prisma/schema/authModule.prisma +0 -3
- package/prisma/schema/budget.prisma +0 -6
- package/prisma/schema/calendly.prisma +0 -2
- package/prisma/schema/candidateProfile.prisma +0 -2
- package/prisma/schema/communication.prisma +0 -11
- package/prisma/schema/contactUs.prisma +0 -2
- package/prisma/schema/document.prisma +1 -1
- package/prisma/schema/evaluationPlan.prisma +10 -35
- package/prisma/schema/feedback.prisma +0 -1
- package/prisma/schema/fitCheck.prisma +0 -3
- package/prisma/schema/google.prisma +0 -2
- package/prisma/schema/integration.prisma +0 -13
- package/prisma/schema/interview.prisma +0 -9
- package/prisma/schema/interviewNotes.prisma +0 -1
- package/prisma/schema/jobApplicationFields.prisma +0 -3
- package/prisma/schema/jobApplicationResponse.prisma +0 -1
- package/prisma/schema/jobApplicationTemplate.prisma +0 -3
- package/prisma/schema/jobDescription.prisma +35 -43
- package/prisma/schema/jobDescriptionData.prisma +0 -1
- package/prisma/schema/jobProfile.prisma +0 -3
- package/prisma/schema/liveAnalysis.prisma +0 -1
- package/prisma/schema/message.prisma +0 -2
- package/prisma/schema/migrations/20260522120000_ongoing_evaluation_record_kind/migration.sql +25 -0
- package/prisma/schema/migrations/20260523120000_replace_record_kind_with_is_committed/migration.sql +24 -0
- package/prisma/schema/migrations/20260528120000_drop_job_description_recommendation_config/migration.sql +2 -0
- package/prisma/schema/migrations/20260710120000_add_resume_rendered_export_fields/migration.sql +9 -0
- package/prisma/schema/notes.prisma +0 -1
- package/prisma/schema/ongoingEvaluation.prisma +0 -7
- package/prisma/schema/organisation.prisma +31 -39
- package/prisma/schema/organisationConfig.prisma +0 -1
- package/prisma/schema/permission.prisma +0 -1
- package/prisma/schema/promise.prisma +0 -3
- package/prisma/schema/questions.prisma +0 -4
- package/prisma/schema/refreshToken.prisma +0 -2
- package/prisma/schema/resume.prisma +5 -1
- package/prisma/schema/resumeData.prisma +0 -1
- package/prisma/schema/schema.prisma +0 -2
- package/prisma/schema/suggestion.prisma +0 -1
- package/prisma/schema/transcript.prisma +0 -1
- package/prisma/schema/user.prisma +0 -10
- package/prisma/schema/userProfile.prisma +0 -2
- package/prisma/schema/zoomMeeting.prisma +0 -5
- package/client/libquery_engine-darwin.dylib.node +0 -0
- package/prisma/.DS_Store +0 -0
- package/prisma/migrations/20260519120000_migrate_shortlisted_to_selected/migration.sql +0 -2
- package/prisma/schema/.DS_Store +0 -0
- package/prisma/schema/activityEvent.prisma +0 -138
- package/prisma/schema/applicationAnalytics.prisma +0 -87
- package/prisma/schema/assessmentRoundAnalytics.prisma +0 -119
- package/prisma/schema/assignmentRoundAnalytics.prisma +0 -109
- package/prisma/schema/interviewRoundAnalytics.prisma +0 -140
- package/prisma/schema/interviewerAnalytics.prisma +0 -129
- package/prisma/schema/jobRoundAnalytics.prisma +0 -101
- package/prisma/schema/migrations/20260519120000_add_analytics_schema/migration.sql +0 -84
- package/prisma/schema/migrations/20260625120000_add_interviewer_analytics/migration.sql +0 -26
- package/prisma/schema/migrations/20260629120000_add_user_lifecycle_activity_events/migration.sql +0 -13
- package/prisma/schema/migrations/20260629140000_drop_organisation_org_code/migration.sql +0 -2
- package/prisma/schema/migrations/20260629160000_employee_codes_dual_interviewer_analytics/migration.sql +0 -87
- package/prisma/schema/migrations/20260630120000_add_application_sources/migration.sql +0 -38
- package/prisma/schema/migrations/20260701120000_add_source_effectiveness_analytics/migration.sql +0 -40
- package/prisma/schema/migrations/20260702120000_add_analytics_daily_tables/migration.sql +0 -232
- package/prisma/schema/openJobAnalytics.prisma +0 -85
- package/prisma/schema/pipelineDistributionAnalytics.prisma +0 -64
- package/prisma/schema/reportingOverviewJobAnalytics.prisma +0 -49
- package/prisma/schema/roundAnalytics.prisma +0 -145
- package/prisma/schema/source.prisma +0 -36
- package/prisma/schema/sourceEffectivenessAnalytics.prisma +0 -79
|
@@ -4,64 +4,56 @@ enum JobDescriptionStatus {
|
|
|
4
4
|
ACTIVE
|
|
5
5
|
DEACTIVATED
|
|
6
6
|
CLOSED
|
|
7
|
-
|
|
8
|
-
@@schema("public")
|
|
9
7
|
}
|
|
10
8
|
|
|
11
9
|
model JobDescription {
|
|
12
|
-
id String
|
|
10
|
+
id String @id @default(uuid())
|
|
13
11
|
organisation_id String
|
|
14
12
|
hiring_manager_id String?
|
|
15
|
-
status JobDescriptionStatus
|
|
13
|
+
status JobDescriptionStatus @default(DRAFT)
|
|
16
14
|
screeningQuestions String[]
|
|
17
15
|
recommendedQuestions Json[]
|
|
18
16
|
/// @deprecated Prefer `source_document_id` + `Document` (type JOB_DESCRIPTION).
|
|
19
17
|
uploaded_job_description_path String?
|
|
20
|
-
source_document_id String?
|
|
21
|
-
rendered_jd_document_id String?
|
|
22
|
-
rendered_jd_document
|
|
23
|
-
is_plan_published Boolean
|
|
24
|
-
is_posted Boolean
|
|
18
|
+
source_document_id String? @unique
|
|
19
|
+
rendered_jd_document_id String? @unique
|
|
20
|
+
rendered_jd_document Document? @relation("RenderedJdDocument", fields: [rendered_jd_document_id], references: [id], onDelete: SetNull)
|
|
21
|
+
is_plan_published Boolean @default(false)
|
|
22
|
+
is_posted Boolean @default(false)
|
|
25
23
|
summary Json?
|
|
26
24
|
ai_insight Json?
|
|
27
25
|
job_fit_comparison Json?
|
|
28
|
-
target_closing_date DateTime?
|
|
29
|
-
closing_date DateTime?
|
|
30
|
-
|
|
31
|
-
job_number Int?
|
|
32
|
-
job_code String? @unique
|
|
33
26
|
// Audit fields
|
|
34
|
-
created_at
|
|
35
|
-
updated_at
|
|
36
|
-
created_by
|
|
37
|
-
updated_by
|
|
38
|
-
is_active
|
|
39
|
-
openings
|
|
40
|
-
job_profile_id
|
|
41
|
-
job_profile
|
|
42
|
-
organisation
|
|
43
|
-
source_document
|
|
44
|
-
applications
|
|
45
|
-
interviews
|
|
46
|
-
assignments
|
|
47
|
-
fit_check
|
|
48
|
-
job_description_data
|
|
49
|
-
evaluationPlan
|
|
50
|
-
ongoing_evaluations
|
|
51
|
-
assignment_library
|
|
52
|
-
approvals
|
|
53
|
-
resumes
|
|
54
|
-
budget
|
|
55
|
-
hiring_manager
|
|
56
|
-
recruiters
|
|
57
|
-
transcripts
|
|
58
|
-
integration_job_syncs
|
|
59
|
-
job_application_template
|
|
60
|
-
conversations
|
|
61
|
-
communication_messages
|
|
27
|
+
created_at DateTime @default(now())
|
|
28
|
+
updated_at DateTime @updatedAt
|
|
29
|
+
created_by String
|
|
30
|
+
updated_by String
|
|
31
|
+
is_active Boolean @default(true)
|
|
32
|
+
openings Int @default(1)
|
|
33
|
+
job_profile_id String?
|
|
34
|
+
job_profile JobProfile? @relation(fields: [job_profile_id], references: [id], onDelete: SetNull, onUpdate: Cascade)
|
|
35
|
+
organisation Organisation @relation(fields: [organisation_id], references: [id], onDelete: Cascade, onUpdate: Cascade)
|
|
36
|
+
source_document Document? @relation("SourceDocument", fields: [source_document_id], references: [id], onDelete: SetNull, onUpdate: Cascade)
|
|
37
|
+
applications Application[]
|
|
38
|
+
interviews Interview[]
|
|
39
|
+
assignments Assignment[]
|
|
40
|
+
fit_check FitCheck[] // one-to-many link
|
|
41
|
+
job_description_data JobDescriptionData[] // one-to-many link
|
|
42
|
+
evaluationPlan EvaluationPlan[] // relation to evaluation methods
|
|
43
|
+
ongoing_evaluations OngoingEvaluation[] // optional one-to-many
|
|
44
|
+
assignment_library AssignmentLibrary[]
|
|
45
|
+
approvals Approval[] // one-to-many relation
|
|
46
|
+
resumes Resume[] // one-to-many link
|
|
47
|
+
budget Budget?
|
|
48
|
+
hiring_manager User? @relation("HiringManager", fields: [hiring_manager_id], references: [id], onDelete: SetNull, onUpdate: Cascade)
|
|
49
|
+
recruiters User[]
|
|
50
|
+
transcripts Transcript[]
|
|
51
|
+
integration_job_syncs IntegrationJobSync[]
|
|
52
|
+
job_application_template JobApplicationTemplate?
|
|
53
|
+
conversations Conversation[]
|
|
54
|
+
communication_messages CommunicationMessage[]
|
|
62
55
|
|
|
63
56
|
@@index([organisation_id])
|
|
64
57
|
@@index([hiring_manager_id])
|
|
65
58
|
@@index([job_profile_id])
|
|
66
|
-
@@schema("public")
|
|
67
59
|
}
|
|
@@ -3,8 +3,6 @@ enum JobProfileStatus {
|
|
|
3
3
|
INTAKE_SENT
|
|
4
4
|
INTAKE_IN_PROGRESS
|
|
5
5
|
COMPLETE
|
|
6
|
-
|
|
7
|
-
@@schema("public")
|
|
8
6
|
}
|
|
9
7
|
|
|
10
8
|
model JobProfile {
|
|
@@ -55,5 +53,4 @@ model JobProfile {
|
|
|
55
53
|
@@index([hiring_manager_id])
|
|
56
54
|
@@index([assigned_to])
|
|
57
55
|
@@index([created_by])
|
|
58
|
-
@@schema("public")
|
|
59
56
|
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
-- Safe to re-run: adds record_kind without breaking existing ongoing evaluations.
|
|
2
|
+
|
|
3
|
+
DO $$ BEGIN
|
|
4
|
+
CREATE TYPE "OngoingEvaluationRecordKind" AS ENUM (
|
|
5
|
+
'AI_RECOMMENDED',
|
|
6
|
+
'PLAN_SELECTED',
|
|
7
|
+
'COMMITTED'
|
|
8
|
+
);
|
|
9
|
+
EXCEPTION
|
|
10
|
+
WHEN duplicate_object THEN NULL;
|
|
11
|
+
END $$;
|
|
12
|
+
|
|
13
|
+
ALTER TABLE "OngoingEvaluation"
|
|
14
|
+
ADD COLUMN IF NOT EXISTS "record_kind" "OngoingEvaluationRecordKind";
|
|
15
|
+
|
|
16
|
+
ALTER TABLE "OngoingEvaluation"
|
|
17
|
+
ALTER COLUMN "evaluation_plan_id" DROP NOT NULL;
|
|
18
|
+
|
|
19
|
+
-- All existing rows are real pipeline rounds — not pre-Proceed drafts.
|
|
20
|
+
UPDATE "OngoingEvaluation"
|
|
21
|
+
SET "record_kind" = 'COMMITTED'
|
|
22
|
+
WHERE "record_kind" IS NULL;
|
|
23
|
+
|
|
24
|
+
CREATE INDEX IF NOT EXISTS "OngoingEvaluation_application_id_record_kind_idx"
|
|
25
|
+
ON "OngoingEvaluation"("application_id", "record_kind");
|
package/prisma/schema/migrations/20260523120000_replace_record_kind_with_is_committed/migration.sql
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
-- Replace record_kind enum with is_committed (null = legacy, false = draft, true = committed).
|
|
2
|
+
|
|
3
|
+
ALTER TABLE "OngoingEvaluation"
|
|
4
|
+
ADD COLUMN IF NOT EXISTS "is_committed" BOOLEAN;
|
|
5
|
+
|
|
6
|
+
UPDATE "OngoingEvaluation"
|
|
7
|
+
SET "is_committed" = false
|
|
8
|
+
WHERE "record_kind" IN ('AI_RECOMMENDED', 'PLAN_SELECTED');
|
|
9
|
+
|
|
10
|
+
UPDATE "OngoingEvaluation"
|
|
11
|
+
SET "is_committed" = true
|
|
12
|
+
WHERE "record_kind" = 'COMMITTED';
|
|
13
|
+
|
|
14
|
+
-- Legacy rows without record_kind stay null (treated as committed in app queries).
|
|
15
|
+
|
|
16
|
+
DROP INDEX IF EXISTS "OngoingEvaluation_application_id_record_kind_idx";
|
|
17
|
+
|
|
18
|
+
ALTER TABLE "OngoingEvaluation"
|
|
19
|
+
DROP COLUMN IF EXISTS "record_kind";
|
|
20
|
+
|
|
21
|
+
DROP TYPE IF EXISTS "OngoingEvaluationRecordKind";
|
|
22
|
+
|
|
23
|
+
CREATE INDEX IF NOT EXISTS "OngoingEvaluation_application_id_is_committed_idx"
|
|
24
|
+
ON "OngoingEvaluation"("application_id", "is_committed");
|
package/prisma/schema/migrations/20260710120000_add_resume_rendered_export_fields/migration.sql
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
-- AlterTable
|
|
2
|
+
ALTER TABLE "Resume" ADD COLUMN "rendered_export_document_id" TEXT,
|
|
3
|
+
ADD COLUMN "resume_template_id" TEXT;
|
|
4
|
+
|
|
5
|
+
-- CreateIndex
|
|
6
|
+
CREATE UNIQUE INDEX "Resume_rendered_export_document_id_key" ON "Resume"("rendered_export_document_id");
|
|
7
|
+
|
|
8
|
+
-- AddForeignKey
|
|
9
|
+
ALTER TABLE "Resume" ADD CONSTRAINT "Resume_rendered_export_document_id_fkey" FOREIGN KEY ("rendered_export_document_id") REFERENCES "Document"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
|
@@ -4,8 +4,6 @@ enum OngoingEvaluationState {
|
|
|
4
4
|
CLEARED
|
|
5
5
|
SKIPPED
|
|
6
6
|
NOT_CLEARED
|
|
7
|
-
|
|
8
|
-
@@schema("public")
|
|
9
7
|
}
|
|
10
8
|
|
|
11
9
|
enum OngoingEvaluationRoundStatus {
|
|
@@ -15,8 +13,6 @@ enum OngoingEvaluationRoundStatus {
|
|
|
15
13
|
IN_PROGRESS
|
|
16
14
|
PENDING_EVALUATION
|
|
17
15
|
EVALUATED
|
|
18
|
-
|
|
19
|
-
@@schema("public")
|
|
20
16
|
}
|
|
21
17
|
|
|
22
18
|
model OngoingEvaluation {
|
|
@@ -43,7 +39,6 @@ model OngoingEvaluation {
|
|
|
43
39
|
description String?
|
|
44
40
|
order_no Int?
|
|
45
41
|
format EvaluationRoundFormat?
|
|
46
|
-
round_purpose String?
|
|
47
42
|
topics String[]
|
|
48
43
|
assignee String?
|
|
49
44
|
elimination_round Boolean? @default(false)
|
|
@@ -53,7 +48,6 @@ model OngoingEvaluation {
|
|
|
53
48
|
deadline Int?
|
|
54
49
|
duration_unit DurationUnit?
|
|
55
50
|
details Json?
|
|
56
|
-
category EvaluationCategory?
|
|
57
51
|
// Audit Fields
|
|
58
52
|
created_at DateTime @default(now())
|
|
59
53
|
updated_at DateTime @updatedAt
|
|
@@ -75,5 +69,4 @@ model OngoingEvaluation {
|
|
|
75
69
|
@@unique([application_id, evaluation_plan_id])
|
|
76
70
|
@@index([application_id])
|
|
77
71
|
@@index([evaluation_plan_id])
|
|
78
|
-
@@schema("public")
|
|
79
72
|
}
|
|
@@ -4,8 +4,6 @@ enum OrganisationSize {
|
|
|
4
4
|
FIFTY_ONE_TO_TWO_HUNDRED @map("51-200")
|
|
5
5
|
TWO_HUNDRED_ONE_TO_FIVE_HUNDRED @map("201-500")
|
|
6
6
|
FIVE_HUNDRED_PLUS @map("500+")
|
|
7
|
-
|
|
8
|
-
@@schema("public")
|
|
9
7
|
}
|
|
10
8
|
|
|
11
9
|
model Organisation {
|
|
@@ -20,46 +18,40 @@ model Organisation {
|
|
|
20
18
|
company_values Json[]
|
|
21
19
|
allowed_email_domains String[]
|
|
22
20
|
|
|
23
|
-
interviewers
|
|
24
|
-
created_at
|
|
25
|
-
updated_at
|
|
26
|
-
created_by
|
|
27
|
-
updated_by
|
|
28
|
-
is_active
|
|
29
|
-
alias
|
|
30
|
-
logo
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
timezone String @default("Asia/Kolkata")
|
|
51
|
-
organisation_configs OrganisationConfig[]
|
|
52
|
-
activity_events ActivityEvent[]
|
|
53
|
-
|
|
54
|
-
channel_provider_configs ChannelProviderConfig[]
|
|
55
|
-
conversations Conversation[]
|
|
56
|
-
communication_messages CommunicationMessage[]
|
|
21
|
+
interviewers User[]
|
|
22
|
+
created_at DateTime @default(now())
|
|
23
|
+
updated_at DateTime @updatedAt
|
|
24
|
+
created_by String
|
|
25
|
+
updated_by String
|
|
26
|
+
is_active Boolean @default(true)
|
|
27
|
+
alias String? @unique
|
|
28
|
+
logo String?
|
|
29
|
+
applications Application[]
|
|
30
|
+
user_roles UserRole[]
|
|
31
|
+
job_descriptions JobDescription[]
|
|
32
|
+
job_profiles JobProfile[]
|
|
33
|
+
assessment_library AssessmentLibrary[]
|
|
34
|
+
assignment_library AssignmentLibrary[]
|
|
35
|
+
interviews Interview[]
|
|
36
|
+
assignments Assignment[]
|
|
37
|
+
fit_check FitCheck[] // one-to-many link
|
|
38
|
+
resumes Resume[] // one-to-many link
|
|
39
|
+
approvals Approval[] // one-to-many link
|
|
40
|
+
suggestions Suggestion[]
|
|
41
|
+
ongoing_evaluations OngoingEvaluation[] // optional one-to-many
|
|
42
|
+
actions Action[]
|
|
43
|
+
integration_credentials IntegrationCredential[]
|
|
44
|
+
zoho_sync_mappings ZohoSyncMapping[]
|
|
45
|
+
assessments Assessment[]
|
|
46
|
+
timezone String @default("Asia/Kolkata")
|
|
47
|
+
organisation_configs OrganisationConfig[]
|
|
57
48
|
job_application_fields JobApplicationField[]
|
|
58
49
|
documents Document[]
|
|
59
50
|
job_application_templates JobApplicationTemplate[]
|
|
60
|
-
|
|
61
|
-
|
|
51
|
+
|
|
52
|
+
channel_provider_configs ChannelProviderConfig[]
|
|
53
|
+
conversations Conversation[]
|
|
54
|
+
communication_messages CommunicationMessage[]
|
|
62
55
|
|
|
63
56
|
@@index([name])
|
|
64
|
-
@@schema("public")
|
|
65
57
|
}
|
|
@@ -5,8 +5,6 @@ enum AsyncOperationStatus {
|
|
|
5
5
|
FAILED
|
|
6
6
|
RETRYING
|
|
7
7
|
CANCELLED
|
|
8
|
-
|
|
9
|
-
@@schema("public")
|
|
10
8
|
}
|
|
11
9
|
|
|
12
10
|
model AsyncOperation {
|
|
@@ -38,5 +36,4 @@ model AsyncOperation {
|
|
|
38
36
|
@@index([status])
|
|
39
37
|
@@index([operation_name])
|
|
40
38
|
@@index([correlationId])
|
|
41
|
-
@@schema("public")
|
|
42
39
|
}
|
|
@@ -2,8 +2,6 @@ enum Difficulty {
|
|
|
2
2
|
EASY // simple/basic questions
|
|
3
3
|
MEDIUM // moderate difficulty
|
|
4
4
|
HARD // challenging questions
|
|
5
|
-
|
|
6
|
-
@@schema("public")
|
|
7
5
|
}
|
|
8
6
|
|
|
9
7
|
model Question {
|
|
@@ -27,6 +25,4 @@ model Question {
|
|
|
27
25
|
assessmentLibrary AssessmentLibrary? @relation(fields: [assessment_library_id], references: [id], onDelete: Cascade)
|
|
28
26
|
evaluationPlan EvaluationPlan? @relation(fields: [evaluation_plan_id], references: [id], onDelete: SetNull)
|
|
29
27
|
candidateResponse CandidateQuestionResponse[]
|
|
30
|
-
|
|
31
|
-
@@schema("public")
|
|
32
28
|
}
|
|
@@ -6,6 +6,10 @@ model Resume {
|
|
|
6
6
|
/// @deprecated Prefer `document_id` + `Document`. Kept until backfill completes.
|
|
7
7
|
uploaded_resume_path String?
|
|
8
8
|
document_id String? @unique
|
|
9
|
+
/// Latest rendered ATS export document (PDF/DOCX). Mirrors JD `rendered_jd_document_id`.
|
|
10
|
+
rendered_export_document_id String? @unique
|
|
11
|
+
/// Last template id used for the linked rendered export (cache key with fingerprints).
|
|
12
|
+
resume_template_id String?
|
|
9
13
|
/// @deprecated Prefer `Document.file_hash`. Kept for legacy read fallback.
|
|
10
14
|
file_hash String?
|
|
11
15
|
summary Json?
|
|
@@ -19,6 +23,7 @@ model Resume {
|
|
|
19
23
|
organisation Organisation? @relation(fields: [organisation_id], references: [id], onDelete: SetNull, onUpdate: Cascade)
|
|
20
24
|
job_description JobDescription? @relation(fields: [job_description_id], references: [id], onDelete: SetNull, onUpdate: Cascade)
|
|
21
25
|
document Document? @relation(fields: [document_id], references: [id], onDelete: SetNull, onUpdate: Cascade)
|
|
26
|
+
rendered_export_document Document? @relation("RenderedResumeExportDocument", fields: [rendered_export_document_id], references: [id], onDelete: SetNull)
|
|
22
27
|
applications Application[]
|
|
23
28
|
interviews Interview[]
|
|
24
29
|
ongoing_evaluations OngoingEvaluation[] // optional one-to-many
|
|
@@ -31,5 +36,4 @@ model Resume {
|
|
|
31
36
|
|
|
32
37
|
@@index([user_id])
|
|
33
38
|
@@index([file_hash])
|
|
34
|
-
@@schema("public")
|
|
35
39
|
}
|
|
@@ -1,16 +1,12 @@
|
|
|
1
1
|
enum FirstLoginStatus {
|
|
2
2
|
PENDING
|
|
3
3
|
COMPLETED
|
|
4
|
-
|
|
5
|
-
@@schema("public")
|
|
6
4
|
}
|
|
7
5
|
|
|
8
6
|
enum UserInvitationStatus {
|
|
9
7
|
INVITED
|
|
10
8
|
ACCEPTED
|
|
11
9
|
EXPIRED
|
|
12
|
-
|
|
13
|
-
@@schema("public")
|
|
14
10
|
}
|
|
15
11
|
|
|
16
12
|
model User {
|
|
@@ -71,7 +67,6 @@ model User {
|
|
|
71
67
|
refresh_token_auth RefreshToken[] @relation("TokenRefresh")
|
|
72
68
|
zoom_meeting_participants ZoomMeetingParticipant[]
|
|
73
69
|
notes Notes[]
|
|
74
|
-
recruiter_applications Application[] @relation("ApplicationRecruiter")
|
|
75
70
|
|
|
76
71
|
name String?
|
|
77
72
|
phone String?
|
|
@@ -92,12 +87,7 @@ model User {
|
|
|
92
87
|
professional_expertise String?
|
|
93
88
|
documents Document[]
|
|
94
89
|
|
|
95
|
-
employee_number Int?
|
|
96
|
-
employee_code String? @unique
|
|
97
|
-
|
|
98
90
|
@@index([role_id])
|
|
99
91
|
@@index([permission_id])
|
|
100
92
|
@@index([organisation_id])
|
|
101
|
-
@@index([organisation_id, employee_number])
|
|
102
|
-
@@schema("public")
|
|
103
93
|
}
|
|
@@ -2,8 +2,6 @@
|
|
|
2
2
|
enum ZoomMeetingParticipantRole {
|
|
3
3
|
CANDIDATE
|
|
4
4
|
INTERVIEWER
|
|
5
|
-
|
|
6
|
-
@@schema("public")
|
|
7
5
|
}
|
|
8
6
|
|
|
9
7
|
/// Zoom meeting linked 1:1 to an interview; Zoom REST host is `zoom_host_user_id`.
|
|
@@ -42,7 +40,6 @@ model ZoomMeeting {
|
|
|
42
40
|
@@index([interview_id])
|
|
43
41
|
@@index([zoom_meeting_id])
|
|
44
42
|
@@index([zoom_meeting_uuid])
|
|
45
|
-
@@schema("public")
|
|
46
43
|
}
|
|
47
44
|
|
|
48
45
|
/// Expected participants for a `ZoomMeeting`: links to `User` (candidate / interviewer). Replaced on each meeting upsert.
|
|
@@ -66,7 +63,6 @@ model ZoomMeetingParticipant {
|
|
|
66
63
|
@@index([zoom_meeting_row_id])
|
|
67
64
|
@@index([user_id])
|
|
68
65
|
@@index([zoom_participant_id])
|
|
69
|
-
@@schema("public")
|
|
70
66
|
}
|
|
71
67
|
|
|
72
68
|
/// Ledger of processed Zoom webhook deliveries: one row per `dedupe_key` (request id or body hash).
|
|
@@ -80,5 +76,4 @@ model ZoomWebhookEvent {
|
|
|
80
76
|
|
|
81
77
|
@@index([event])
|
|
82
78
|
@@index([created_at])
|
|
83
|
-
@@schema("public")
|
|
84
79
|
}
|
|
Binary file
|
package/prisma/.DS_Store
DELETED
|
Binary file
|
package/prisma/schema/.DS_Store
DELETED
|
Binary file
|