@adaptware/eagles-db 0.4.36 → 0.4.37

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.
Files changed (86) hide show
  1. package/client/edge.js +874 -10
  2. package/client/index-browser.js +905 -40
  3. package/client/index.d.ts +81912 -27565
  4. package/client/index.js +874 -10
  5. package/client/libquery_engine-darwin.dylib.node +0 -0
  6. package/client/package.json +1 -1
  7. package/client/schema.prisma +1584 -108
  8. package/client/wasm.js +874 -10
  9. package/package.json +1 -1
  10. package/prisma/.DS_Store +0 -0
  11. package/prisma/migrations/20260519120000_migrate_shortlisted_to_selected/migration.sql +2 -0
  12. package/prisma/schema/.DS_Store +0 -0
  13. package/prisma/schema/CandidateQuestionResponse.prisma +1 -0
  14. package/prisma/schema/UserRole.prisma +1 -0
  15. package/prisma/schema/action.prisma +5 -0
  16. package/prisma/schema/activityEvent.prisma +138 -0
  17. package/prisma/schema/activityLog.prisma +3 -0
  18. package/prisma/schema/applicationAnalytics.prisma +87 -0
  19. package/prisma/schema/applications.prisma +12 -2
  20. package/prisma/schema/approval.prisma +2 -0
  21. package/prisma/schema/assessment.prisma +1 -0
  22. package/prisma/schema/assessmentLibrary.prisma +1 -0
  23. package/prisma/schema/assessmentQuestion.prisma +1 -0
  24. package/prisma/schema/assessmentRoundAnalytics.prisma +119 -0
  25. package/prisma/schema/assignment.prisma +3 -0
  26. package/prisma/schema/assignmentLibrary.prisma +1 -0
  27. package/prisma/schema/assignmentRoundAnalytics.prisma +109 -0
  28. package/prisma/schema/authModule.prisma +3 -0
  29. package/prisma/schema/budget.prisma +6 -0
  30. package/prisma/schema/calendly.prisma +2 -0
  31. package/prisma/schema/candidateProfile.prisma +2 -0
  32. package/prisma/schema/communication.prisma +11 -0
  33. package/prisma/schema/contactUs.prisma +2 -0
  34. package/prisma/schema/document.prisma +5 -4
  35. package/prisma/schema/evaluationPlan.prisma +35 -10
  36. package/prisma/schema/feedback.prisma +1 -0
  37. package/prisma/schema/fitCheck.prisma +3 -0
  38. package/prisma/schema/google.prisma +2 -0
  39. package/prisma/schema/integration.prisma +13 -0
  40. package/prisma/schema/interview.prisma +9 -0
  41. package/prisma/schema/interviewNotes.prisma +1 -0
  42. package/prisma/schema/interviewRoundAnalytics.prisma +140 -0
  43. package/prisma/schema/interviewerAnalytics.prisma +129 -0
  44. package/prisma/schema/jobApplicationFields.prisma +3 -0
  45. package/prisma/schema/jobApplicationResponse.prisma +1 -0
  46. package/prisma/schema/jobApplicationTemplate.prisma +3 -0
  47. package/prisma/schema/jobDescription.prisma +43 -35
  48. package/prisma/schema/jobDescriptionData.prisma +1 -0
  49. package/prisma/schema/jobProfile.prisma +3 -0
  50. package/prisma/schema/jobRoundAnalytics.prisma +101 -0
  51. package/prisma/schema/liveAnalysis.prisma +1 -0
  52. package/prisma/schema/message.prisma +2 -0
  53. package/prisma/schema/migrations/20260519120000_add_analytics_schema/migration.sql +84 -0
  54. package/prisma/schema/migrations/20260625120000_add_interviewer_analytics/migration.sql +26 -0
  55. package/prisma/schema/migrations/20260629120000_add_user_lifecycle_activity_events/migration.sql +13 -0
  56. package/prisma/schema/migrations/20260629140000_drop_organisation_org_code/migration.sql +2 -0
  57. package/prisma/schema/migrations/20260629160000_employee_codes_dual_interviewer_analytics/migration.sql +87 -0
  58. package/prisma/schema/migrations/20260630120000_add_application_sources/migration.sql +38 -0
  59. package/prisma/schema/migrations/20260701120000_add_source_effectiveness_analytics/migration.sql +40 -0
  60. package/prisma/schema/migrations/20260702120000_add_analytics_daily_tables/migration.sql +232 -0
  61. package/prisma/schema/migrations/{20260710120000_add_resume_rendered_export_fields → 20260706120000_add_resume_rendered_export}/migration.sql +5 -2
  62. package/prisma/schema/notes.prisma +1 -0
  63. package/prisma/schema/ongoingEvaluation.prisma +7 -0
  64. package/prisma/schema/openJobAnalytics.prisma +85 -0
  65. package/prisma/schema/organisation.prisma +39 -31
  66. package/prisma/schema/organisationConfig.prisma +1 -0
  67. package/prisma/schema/permission.prisma +1 -0
  68. package/prisma/schema/pipelineDistributionAnalytics.prisma +64 -0
  69. package/prisma/schema/promise.prisma +3 -0
  70. package/prisma/schema/questions.prisma +4 -0
  71. package/prisma/schema/refreshToken.prisma +2 -0
  72. package/prisma/schema/reportingOverviewJobAnalytics.prisma +49 -0
  73. package/prisma/schema/resume.prisma +5 -4
  74. package/prisma/schema/resumeData.prisma +1 -0
  75. package/prisma/schema/roundAnalytics.prisma +145 -0
  76. package/prisma/schema/schema.prisma +2 -0
  77. package/prisma/schema/source.prisma +36 -0
  78. package/prisma/schema/sourceEffectivenessAnalytics.prisma +79 -0
  79. package/prisma/schema/suggestion.prisma +1 -0
  80. package/prisma/schema/transcript.prisma +1 -0
  81. package/prisma/schema/user.prisma +10 -0
  82. package/prisma/schema/userProfile.prisma +2 -0
  83. package/prisma/schema/zoomMeeting.prisma +5 -0
  84. package/prisma/schema/migrations/20260522120000_ongoing_evaluation_record_kind/migration.sql +0 -25
  85. package/prisma/schema/migrations/20260523120000_replace_record_kind_with_is_committed/migration.sql +0 -24
  86. package/prisma/schema/migrations/20260528120000_drop_job_description_recommendation_config/migration.sql +0 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adaptware/eagles-db",
3
- "version": "0.4.36",
3
+ "version": "0.4.37",
4
4
  "description": "A Prisma client package for Treadspace database operations",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
Binary file
@@ -0,0 +1,2 @@
1
+ -- Migrate legacy terminal-positive status to SELECTED (SHORTLISTED enum value retained but unused).
2
+ UPDATE applications SET status = 'SELECTED' WHERE status = 'SHORTLISTED';
Binary file
@@ -21,4 +21,5 @@ model CandidateQuestionResponse {
21
21
  @@unique([assessment_id, question_id, candidate_id])
22
22
  @@index([candidate_id])
23
23
  @@index([assessment_id])
24
+ @@schema("public")
24
25
  }
@@ -17,4 +17,5 @@ model UserRole {
17
17
  @@index([role, organisation_id])
18
18
  @@index([organisation_id])
19
19
  @@index([permission_id])
20
+ @@schema("public")
20
21
  }
@@ -2,12 +2,16 @@ enum ActionType {
2
2
  TAKE_INTERVIEW
3
3
  PROVIDE_FEEDBACK
4
4
  SCHEDULE_INTERVIEW
5
+
6
+ @@schema("public")
5
7
  }
6
8
 
7
9
  enum ActionStatus {
8
10
  PENDING
9
11
  COMPLETED
10
12
  CANCELLED
13
+
14
+ @@schema("public")
11
15
  }
12
16
 
13
17
  model Action {
@@ -32,4 +36,5 @@ model Action {
32
36
  @@index([assignee_id, action_type])
33
37
  @@index([status])
34
38
  @@index([due_date])
39
+ @@schema("public")
35
40
  }
@@ -0,0 +1,138 @@
1
+ enum ActivityEventType {
2
+ APPLICATION_CREATED
3
+ APPLICATION_STARTED
4
+ APPLICATION_REJECTED
5
+ APPLICATION_SHORTLISTED
6
+
7
+ FIT_CHECK_COMPLETED
8
+
9
+ ROUND_ASSIGNED
10
+ ROUND_COMPLETED
11
+ ROUND_PASSED
12
+ ROUND_FAILED
13
+
14
+ INTERVIEW_CREATED
15
+ INTERVIEW_SCHEDULED
16
+ INTERVIEW_RESCHEDULED
17
+ INTERVIEW_CANCELLED
18
+ INTERVIEW_STARTED
19
+ INTERVIEW_COMPLETED
20
+ INTERVIEW_NO_SHOW
21
+ INTERVIEW_EVALUATION_PENDING
22
+ INTERVIEW_EVALUATED
23
+
24
+ FEEDBACK_SUBMITTED
25
+
26
+ ASSIGNMENT_CREATED
27
+ ASSIGNMENT_STARTED
28
+ ASSIGNMENT_COMPLETED
29
+ ASSIGNMENT_CANCELLED
30
+ ASSIGNMENT_EVALUATED
31
+
32
+ ASSESSMENT_CREATED
33
+ ASSESSMENT_STARTED
34
+ ASSESSMENT_COMPLETED
35
+ ASSESSMENT_CANCELLED
36
+ ASSESSMENT_EVALUATED
37
+
38
+ JOB_CREATED
39
+ JOB_PUBLISHED
40
+ JOB_CLOSED
41
+ JOB_DEACTIVATED
42
+
43
+ USER_INVITED
44
+ USER_INVITATION_RESENT
45
+ USER_CREATED
46
+ USER_INVITATION_ACCEPTED
47
+ USER_INVITATION_EXPIRED
48
+ USER_DEACTIVATED
49
+ USER_REACTIVATED
50
+ USER_ROLE_CHANGED
51
+ USER_PROFILE_COMPLETED
52
+
53
+ CANDIDATE_REGISTERED
54
+ CANDIDATE_CREATED
55
+ CANDIDATE_PROFILE_COMPLETED
56
+
57
+ EVALUATION_PLAN_CREATED
58
+ EVALUATION_PLAN_PUBLISHED
59
+ EVALUATION_PLAN_DELETED
60
+ EVALUATION_PLAN_UPDATED
61
+ STATUS_CHANGED
62
+
63
+ CUSTOM
64
+
65
+ @@schema("public")
66
+ }
67
+
68
+ enum ActivityEntityType {
69
+ APPLICATION
70
+
71
+ CANDIDATE
72
+
73
+ JOB
74
+
75
+ ONGOING_EVALUATION
76
+
77
+ EVALUATION_PLAN
78
+
79
+ INTERVIEW
80
+
81
+ ASSIGNMENT
82
+
83
+ ASSESSMENT
84
+
85
+ ORGANISATION
86
+
87
+ USER
88
+
89
+ @@schema("public")
90
+ }
91
+
92
+ enum ActivityEntityActorType {
93
+ USER
94
+
95
+ SYSTEM
96
+
97
+ AI_AGENT
98
+
99
+ WEBHOOK
100
+
101
+ @@schema("public")
102
+ }
103
+
104
+ model ActivityEvent {
105
+ id String @id @default(uuid())
106
+
107
+ organisation_id String?
108
+
109
+ event_type ActivityEventType
110
+
111
+ entity_type ActivityEntityType
112
+ entity_id String
113
+
114
+ actor_id String?
115
+ actor_type ActivityEntityActorType
116
+
117
+ related_entities Json?
118
+
119
+ snapshot Json?
120
+
121
+ payload Json?
122
+
123
+ schema_version Int @default(1)
124
+
125
+ occurred_at DateTime
126
+
127
+ created_at DateTime @default(now())
128
+
129
+ organisation Organisation? @relation(fields: [organisation_id], references: [id])
130
+
131
+ @@index([organisation_id, occurred_at])
132
+ @@index([organisation_id, event_type])
133
+ @@index([entity_type, entity_id])
134
+ @@index([actor_id])
135
+ @@index([occurred_at])
136
+ @@map("activity_events")
137
+ @@schema("public")
138
+ }
@@ -2,6 +2,8 @@ enum ActivityActorType {
2
2
  USER
3
3
  AI
4
4
  SYSTEM
5
+
6
+ @@schema("public")
5
7
  }
6
8
 
7
9
  model ActivityLog {
@@ -19,4 +21,5 @@ model ActivityLog {
19
21
  application Application @relation(fields: [application_id], references: [id], onDelete: Cascade, onUpdate: Cascade)
20
22
 
21
23
  @@index([application_id])
24
+ @@schema("public")
22
25
  }
@@ -0,0 +1,87 @@
1
+ model ApplicationAnalytics {
2
+ id String @id @default(uuid())
3
+
4
+ organisation_id String
5
+ application_id String @unique
6
+ job_description_id String
7
+ candidate_id String
8
+
9
+ source_id String?
10
+ source_name String?
11
+ source_category SourceCategory?
12
+ source_colour String?
13
+
14
+ job_code String?
15
+ job_number Int?
16
+ role_title String?
17
+ hiring_manager_id String?
18
+
19
+ candidate_name String?
20
+ recruiter_id String?
21
+
22
+ applied_at DateTime
23
+ status_updated_at DateTime?
24
+
25
+ status ApplicationStatus?
26
+ fit_check_score Float?
27
+
28
+ is_screened Boolean @default(false)
29
+ is_evaluated Boolean @default(false)
30
+ is_rejected Boolean @default(false)
31
+ is_shortlisted Boolean @default(false)
32
+ has_committed_evaluation Boolean @default(false)
33
+
34
+ updated_at DateTime @updatedAt
35
+
36
+ @@index([organisation_id, applied_at])
37
+ @@index([organisation_id, source_id, applied_at])
38
+ @@index([job_description_id, applied_at])
39
+ @@index([organisation_id, hiring_manager_id])
40
+ @@map("application_analytics")
41
+ @@schema("analytics")
42
+ }
43
+
44
+ model ApplicationAnalyticsDaily {
45
+ id String @id @default(uuid())
46
+
47
+ snapshot_date DateTime @db.Date
48
+
49
+ organisation_id String
50
+ application_id String
51
+ job_description_id String
52
+ candidate_id String
53
+
54
+ source_id String?
55
+ source_name String?
56
+ source_category SourceCategory?
57
+ source_colour String?
58
+
59
+ job_code String?
60
+ job_number Int?
61
+ role_title String?
62
+ hiring_manager_id String?
63
+
64
+ candidate_name String?
65
+ recruiter_id String?
66
+
67
+ applied_at DateTime
68
+ status_updated_at DateTime?
69
+
70
+ status ApplicationStatus?
71
+ fit_check_score Float?
72
+
73
+ is_screened Boolean @default(false)
74
+ is_evaluated Boolean @default(false)
75
+ is_rejected Boolean @default(false)
76
+ is_shortlisted Boolean @default(false)
77
+ has_committed_evaluation Boolean @default(false)
78
+
79
+ @@unique([snapshot_date, application_id])
80
+ @@index([snapshot_date], map: "aad_snapshot_date_idx")
81
+ @@index([snapshot_date, organisation_id], map: "aad_snapshot_org_idx")
82
+ @@index([snapshot_date, organisation_id, source_id], map: "aad_snapshot_org_source_idx")
83
+ @@index([snapshot_date, organisation_id, applied_at], map: "aad_snapshot_org_applied_idx")
84
+ @@index([snapshot_date, job_description_id], map: "aad_snapshot_job_idx")
85
+ @@map("application_analytics_daily")
86
+ @@schema("analytics")
87
+ }
@@ -2,9 +2,12 @@
2
2
  enum ApplicationStatus {
3
3
  PENDING
4
4
  IN_PROGRESS
5
- SHORTLISTED
6
5
  SELECTED
6
+ SHORTLISTED
7
7
  REJECTED
8
+ ON_HOLD
9
+
10
+ @@schema("public")
8
11
  }
9
12
 
10
13
  model Application {
@@ -17,8 +20,11 @@ model Application {
17
20
  applied_at DateTime @default(now())
18
21
  evaluation_plan_id String?
19
22
  fit_check_id String? @unique
23
+ recruiter_id String?
24
+ source_id String?
20
25
  round_no Int @default(0)
21
26
  is_jaf_completed Boolean @default(false)
27
+ proceed_to_next_round Boolean? @default(false)
22
28
  //Screening fields
23
29
  on_notice_period Boolean @default(false)
24
30
  expected_joining_date DateTime?
@@ -36,14 +42,16 @@ model Application {
36
42
  resume Resume @relation(fields: [resume_id], references: [id], onDelete: Cascade, onUpdate: Cascade)
37
43
  job_description JobDescription @relation(fields: [job_description_id], references: [id], onDelete: Cascade, onUpdate: Cascade)
38
44
  fit_check FitCheck? @relation(fields: [fit_check_id], references: [id], onDelete: Cascade, onUpdate: Cascade)
45
+ recruiter User? @relation("ApplicationRecruiter", fields: [recruiter_id], references: [id])
46
+ source Source? @relation(fields: [source_id], references: [id], onDelete: SetNull)
39
47
  interviews Interview[]
40
48
  assignments Assignment[]
41
49
  ongoing_evaluations OngoingEvaluation[]
42
50
  activity_logs ActivityLog[]
43
51
  notes Notes[]
44
- job_application_responses JobApplicationResponse[]
45
52
  conversations Conversation[]
46
53
  communication_messages CommunicationMessage[]
54
+ job_application_responses JobApplicationResponse[]
47
55
  // Audit fields
48
56
  created_at DateTime @default(now())
49
57
  updated_at DateTime @updatedAt
@@ -54,4 +62,6 @@ model Application {
54
62
  @@unique([candidate_id, job_description_id]) // Ensures candidate applies only once per job
55
63
  @@index([candidate_id])
56
64
  @@index([job_description_id])
65
+ @@index([source_id])
66
+ @@schema("public")
57
67
  }
@@ -11,4 +11,6 @@ model Approval {
11
11
  job_description JobDescription @relation(fields: [job_description_id], references: [id], onDelete: Cascade, onUpdate: Cascade)
12
12
  user User @relation(fields: [user_id], references: [id], onDelete: Cascade, onUpdate: Cascade)
13
13
  organisation Organisation @relation(fields: [organisaton_id], references: [id], onDelete: Cascade, onUpdate: Cascade)
14
+
15
+ @@schema("public")
14
16
  }
@@ -36,4 +36,5 @@ model Assessment {
36
36
  @@unique([assessment_library_id, candidate_id])
37
37
  @@index([assessment_library_id])
38
38
  @@index([candidate_id])
39
+ @@schema("public")
39
40
  }
@@ -18,4 +18,5 @@ model AssessmentLibrary {
18
18
  evaluation_Plans EvaluationPlan[]
19
19
 
20
20
  @@index([organisation_id])
21
+ @@schema("public")
21
22
  }
@@ -14,4 +14,5 @@ model AssessmentQuestion {
14
14
  updated_at DateTime @updatedAt
15
15
 
16
16
  @@id([assessment_id, question_id])
17
+ @@schema("public")
17
18
  }
@@ -0,0 +1,119 @@
1
+ enum AssessmentRoundStatus {
2
+ SCHEDULED
3
+ IN_PROGRESS
4
+ COMPLETED
5
+ EVALUATED
6
+ CANCELLED
7
+
8
+ @@schema("analytics")
9
+ }
10
+
11
+ model AssessmentRoundAnalytics {
12
+ id String @id @default(uuid())
13
+
14
+ organisation_id String
15
+ round_id String @unique
16
+ assessment_id String @unique
17
+ application_id String?
18
+ candidate_id String
19
+ job_description_id String
20
+ evaluation_plan_id String
21
+
22
+ job_code String?
23
+ job_number Int?
24
+ role_title String?
25
+ hiring_manager_id String?
26
+ department String?
27
+ location String?
28
+
29
+ round_name String?
30
+ evaluation_category EvaluationCategory?
31
+ round_type RoundType?
32
+ round_format EvaluationRoundFormat?
33
+ plan_order_no Int?
34
+ plan_type EvaluationPlanType?
35
+ is_custom Boolean @default(false)
36
+
37
+ reviewer_id String?
38
+ reviewer_employee_id String?
39
+ reviewer_name String?
40
+
41
+ candidate_name String?
42
+
43
+ evaluation_type EvaluationType?
44
+
45
+ scheduled_start_at DateTime?
46
+ scheduled_end_at DateTime?
47
+ actual_start_at DateTime?
48
+ actual_end_at DateTime?
49
+ attempt_expires_at DateTime?
50
+ evaluated_at DateTime?
51
+
52
+ score Float?
53
+ status AssessmentRoundStatus?
54
+ round_result RoundResult?
55
+
56
+ updated_at DateTime @updatedAt
57
+
58
+ @@index([organisation_id, evaluated_at])
59
+ @@index([organisation_id, reviewer_id])
60
+ @@index([job_description_id])
61
+ @@index([application_id])
62
+ @@map("assessment_round_analytics")
63
+ @@schema("analytics")
64
+ }
65
+
66
+ model AssessmentRoundAnalyticsDaily {
67
+ id String @id @default(uuid())
68
+
69
+ snapshot_date DateTime @db.Date
70
+
71
+ organisation_id String
72
+ round_id String
73
+ assessment_id String
74
+ application_id String?
75
+ candidate_id String
76
+ job_description_id String
77
+ evaluation_plan_id String
78
+
79
+ job_code String?
80
+ job_number Int?
81
+ role_title String?
82
+ hiring_manager_id String?
83
+ department String?
84
+ location String?
85
+
86
+ round_name String?
87
+ evaluation_category EvaluationCategory?
88
+ round_type RoundType?
89
+ round_format EvaluationRoundFormat?
90
+ plan_order_no Int?
91
+ plan_type EvaluationPlanType?
92
+ is_custom Boolean @default(false)
93
+
94
+ reviewer_id String?
95
+ reviewer_employee_id String?
96
+ reviewer_name String?
97
+
98
+ candidate_name String?
99
+
100
+ evaluation_type EvaluationType?
101
+
102
+ scheduled_start_at DateTime?
103
+ scheduled_end_at DateTime?
104
+ actual_start_at DateTime?
105
+ actual_end_at DateTime?
106
+ attempt_expires_at DateTime?
107
+ evaluated_at DateTime?
108
+
109
+ score Float?
110
+ status AssessmentRoundStatus?
111
+ round_result RoundResult?
112
+
113
+ @@unique([snapshot_date, assessment_id])
114
+ @@index([snapshot_date], map: "asrad_snapshot_date_idx")
115
+ @@index([snapshot_date, organisation_id], map: "asrad_snapshot_org_idx")
116
+ @@index([snapshot_date, job_description_id], map: "asrad_snapshot_job_idx")
117
+ @@map("assessment_round_analytics_daily")
118
+ @@schema("analytics")
119
+ }
@@ -2,6 +2,8 @@ enum AssignmentStatus {
2
2
  AVAILABLE
3
3
  SCHEDULED
4
4
  CANCELLED
5
+
6
+ @@schema("public")
5
7
  }
6
8
 
7
9
  model Assignment {
@@ -45,4 +47,5 @@ model Assignment {
45
47
  @@index([candidate_id])
46
48
  @@index([reviewer_id])
47
49
  @@index([job_description_id])
50
+ @@schema("public")
48
51
  }
@@ -17,4 +17,5 @@ model AssignmentLibrary {
17
17
  assignments Assignment[]
18
18
 
19
19
  @@index([job_description_id])
20
+ @@schema("public")
20
21
  }
@@ -0,0 +1,109 @@
1
+ model AssignmentRoundAnalytics {
2
+ id String @id @default(uuid())
3
+
4
+ organisation_id String
5
+ round_id String @unique
6
+ assignment_id String @unique
7
+ application_id String?
8
+ candidate_id String
9
+ job_description_id String
10
+ evaluation_plan_id String
11
+
12
+ job_code String?
13
+ job_number Int?
14
+ role_title String?
15
+ hiring_manager_id String?
16
+ department String?
17
+ location String?
18
+
19
+ round_name String?
20
+ evaluation_category EvaluationCategory?
21
+ round_type RoundType?
22
+ round_format EvaluationRoundFormat?
23
+ plan_order_no Int?
24
+ plan_type EvaluationPlanType?
25
+ is_custom Boolean @default(false)
26
+
27
+ reviewer_id String?
28
+ reviewer_employee_id String?
29
+ reviewer_name String?
30
+
31
+ candidate_name String?
32
+
33
+ evaluation_type EvaluationType?
34
+
35
+ scheduled_start_at DateTime?
36
+ scheduled_end_at DateTime?
37
+ completed_at DateTime?
38
+ evaluated_at DateTime?
39
+ cancelled_at DateTime?
40
+
41
+ status AssignmentStatus?
42
+ overall_score Int?
43
+ cancel_reason String?
44
+ round_result RoundResult?
45
+
46
+ updated_at DateTime @updatedAt
47
+
48
+ @@index([organisation_id, evaluated_at])
49
+ @@index([organisation_id, reviewer_id])
50
+ @@index([job_description_id])
51
+ @@index([application_id])
52
+ @@map("assignment_round_analytics")
53
+ @@schema("analytics")
54
+ }
55
+
56
+ model AssignmentRoundAnalyticsDaily {
57
+ id String @id @default(uuid())
58
+
59
+ snapshot_date DateTime @db.Date
60
+
61
+ organisation_id String
62
+ round_id String
63
+ assignment_id String
64
+ application_id String?
65
+ candidate_id String
66
+ job_description_id String
67
+ evaluation_plan_id String
68
+
69
+ job_code String?
70
+ job_number Int?
71
+ role_title String?
72
+ hiring_manager_id String?
73
+ department String?
74
+ location String?
75
+
76
+ round_name String?
77
+ evaluation_category EvaluationCategory?
78
+ round_type RoundType?
79
+ round_format EvaluationRoundFormat?
80
+ plan_order_no Int?
81
+ plan_type EvaluationPlanType?
82
+ is_custom Boolean @default(false)
83
+
84
+ reviewer_id String?
85
+ reviewer_employee_id String?
86
+ reviewer_name String?
87
+
88
+ candidate_name String?
89
+
90
+ evaluation_type EvaluationType?
91
+
92
+ scheduled_start_at DateTime?
93
+ scheduled_end_at DateTime?
94
+ completed_at DateTime?
95
+ evaluated_at DateTime?
96
+ cancelled_at DateTime?
97
+
98
+ status AssignmentStatus?
99
+ overall_score Int?
100
+ cancel_reason String?
101
+ round_result RoundResult?
102
+
103
+ @@unique([snapshot_date, assignment_id])
104
+ @@index([snapshot_date], map: "arad_snapshot_date_idx")
105
+ @@index([snapshot_date, organisation_id], map: "arad_snapshot_org_idx")
106
+ @@index([snapshot_date, job_description_id], map: "arad_snapshot_job_idx")
107
+ @@map("assignment_round_analytics_daily")
108
+ @@schema("analytics")
109
+ }
@@ -3,6 +3,8 @@ enum AuthProvider {
3
3
  MICROSOFT
4
4
  ZOOM
5
5
  CALENDLY
6
+
7
+ @@schema("public")
6
8
  }
7
9
 
8
10
  model AuthModule {
@@ -33,4 +35,5 @@ model AuthModule {
33
35
  @@unique([user_id, provider])
34
36
  @@unique([provider, provider_account_id])
35
37
  @@index([user_id])
38
+ @@schema("public")
36
39
  }
@@ -4,6 +4,8 @@ enum JobType {
4
4
  Contract
5
5
  Internship
6
6
  Temporary
7
+
8
+ @@schema("public")
7
9
  }
8
10
 
9
11
  enum JDCreationType {
@@ -11,6 +13,8 @@ enum JDCreationType {
11
13
  Upload_JD
12
14
  Create_New
13
15
  Create_From_Profile
16
+
17
+ @@schema("public")
14
18
  }
15
19
 
16
20
  model Budget {
@@ -35,4 +39,6 @@ model Budget {
35
39
  created_by String
36
40
  updated_by String
37
41
  is_active Boolean @default(true)
42
+
43
+ @@schema("public")
38
44
  }
@@ -15,4 +15,6 @@ model Calendly {
15
15
  created_by String
16
16
  updated_by String
17
17
  is_active Boolean @default(true)
18
+
19
+ @@schema("public")
18
20
  }
@@ -23,4 +23,6 @@ model CandidateProfile {
23
23
  veteran_status String?
24
24
  disability_status String?
25
25
  is_active Boolean @default(true)
26
+
27
+ @@schema("public")
26
28
  }