@adaptware/eagles-db 0.1.31 → 0.1.33

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.
@@ -1,5 +1,5 @@
1
1
  {
2
- "name": "prisma-client-fea6de6cf6f7afdb8ba6d74b47dde52ae47cd5a41df339c317a9148acf3c08dd",
2
+ "name": "prisma-client-675e05db2d45a16056f5676b95f4480a6d1fab30c54000924e33d3d039b9b501",
3
3
  "main": "index.js",
4
4
  "types": "index.d.ts",
5
5
  "browser": "index-browser.js",
@@ -1121,22 +1121,20 @@ model User {
1121
1121
  calendly Calendly?
1122
1122
  google Google?
1123
1123
 
1124
- name String?
1125
- phone String?
1126
- description String?
1127
- date_of_birth DateTime?
1128
- designation String?
1129
- location String?
1130
- salary String?
1131
- work_experience Json?
1132
- education Json?
1133
- skills Json?
1134
- notice_period String?
1135
- preferred_work_mode String?
1136
- gender String?
1137
- ethnicity String?
1138
- veteran_status String?
1139
- disability_status String?
1124
+ name String?
1125
+ phone String?
1126
+ description String?
1127
+ date_of_birth DateTime?
1128
+ designation String?
1129
+ location String?
1130
+ salary String?
1131
+ work_experience Json?
1132
+ education Json?
1133
+ notice_period String?
1134
+ gender String?
1135
+ ethnicity String?
1136
+ veteran_status String?
1137
+ disability_status String?
1140
1138
 
1141
1139
  @@index([role_id])
1142
1140
  @@index([permission_id])
package/client/wasm.js CHANGED
@@ -705,9 +705,7 @@ exports.Prisma.UserScalarFieldEnum = {
705
705
  salary: 'salary',
706
706
  work_experience: 'work_experience',
707
707
  education: 'education',
708
- skills: 'skills',
709
708
  notice_period: 'notice_period',
710
- preferred_work_mode: 'preferred_work_mode',
711
709
  gender: 'gender',
712
710
  ethnicity: 'ethnicity',
713
711
  veteran_status: 'veteran_status',
package/dist/env.d.ts ADDED
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Centralized, type-safe environment parsing for the DB package.
3
+ * Consumers must provide DATABASE_URL in their environment.
4
+ */
5
+ import { z } from "zod";
6
+ declare const EnvSchema: z.ZodObject<{
7
+ DATABASE_URL: z.ZodString;
8
+ PRISMA_LOG_LEVEL: z.ZodOptional<z.ZodEnum<{
9
+ error: "error";
10
+ query: "query";
11
+ info: "info";
12
+ warn: "warn";
13
+ }>>;
14
+ }, z.core.$strip>;
15
+ export type Env = z.infer<typeof EnvSchema>;
16
+ export declare function loadEnv(): Env;
17
+ export {};
18
+ //# sourceMappingURL=env.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"env.d.ts","sourceRoot":"","sources":["../src/env.ts"],"names":[],"mappings":"AACA;;;GAGG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,QAAA,MAAM,SAAS;;;;;;;;iBAMb,CAAC;AAEH,MAAM,MAAM,GAAG,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,SAAS,CAAC,CAAC;AAI5C,wBAAgB,OAAO,IAAI,GAAG,CAgB7B"}
package/dist/env.js ADDED
@@ -0,0 +1,30 @@
1
+ // src/env.ts
2
+ /**
3
+ * Centralized, type-safe environment parsing for the DB package.
4
+ * Consumers must provide DATABASE_URL in their environment.
5
+ */
6
+ import { z } from "zod";
7
+ const EnvSchema = z.object({
8
+ DATABASE_URL: z.string().url("DATABASE_URL must be a valid URL"),
9
+ // Optional tuning knobs with defaults.
10
+ PRISMA_LOG_LEVEL: z
11
+ .enum(["query", "info", "warn", "error"])
12
+ .optional(),
13
+ });
14
+ let cached = null;
15
+ export function loadEnv() {
16
+ if (cached)
17
+ return cached;
18
+ const parsed = EnvSchema.safeParse({
19
+ DATABASE_URL: process.env.DATABASE_URL,
20
+ PRISMA_LOG_LEVEL: process.env.PRISMA_LOG_LEVEL
21
+ });
22
+ if (!parsed.success) {
23
+ // Surface a crisp error early.
24
+ const issues = parsed.error.issues.map(i => `${i.path.join(".")}: ${i.message}`).join("; ");
25
+ throw new Error(`[db] Invalid environment: ${issues}`);
26
+ }
27
+ cached = parsed.data;
28
+ return cached;
29
+ }
30
+ //# sourceMappingURL=env.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"env.js","sourceRoot":"","sources":["../src/env.ts"],"names":[],"mappings":"AAAA,aAAa;AACb;;;GAGG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,SAAS,GAAG,CAAC,CAAC,MAAM,CAAC;IACzB,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,kCAAkC,CAAC;IAChE,uCAAuC;IACvC,gBAAgB,EAAE,CAAC;SAChB,IAAI,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC;SACxC,QAAQ,EAAE;CACd,CAAC,CAAC;AAIH,IAAI,MAAM,GAAe,IAAI,CAAC;AAE9B,MAAM,UAAU,OAAO;IACrB,IAAI,MAAM;QAAE,OAAO,MAAM,CAAC;IAE1B,MAAM,MAAM,GAAG,SAAS,CAAC,SAAS,CAAC;QACjC,YAAY,EAAE,OAAO,CAAC,GAAG,CAAC,YAAY;QACtC,gBAAgB,EAAE,OAAO,CAAC,GAAG,CAAC,gBAAuB;KACtD,CAAC,CAAC;IAEH,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC;QACpB,+BAA+B;QAC/B,MAAM,MAAM,GAAG,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC5F,MAAM,IAAI,KAAK,CAAC,6BAA6B,MAAM,EAAE,CAAC,CAAC;IACzD,CAAC;IAED,MAAM,GAAG,MAAM,CAAC,IAAI,CAAC;IACrB,OAAO,MAAM,CAAC;AAChB,CAAC"}
@@ -0,0 +1,7 @@
1
+ import { PrismaClient } from "../client/index.js";
2
+ export declare const prisma: PrismaClient<{
3
+ log: ("error" | "query" | "warn")[];
4
+ }, "error" | "query" | "warn", import("../client/runtime/library.js").DefaultArgs>;
5
+ export type { PrismaClient } from "../client/index.js";
6
+ export * from "../client/index.js";
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAGlD,eAAO,MAAM,MAAM;;kFAKjB,CAAC;AAGH,YAAY,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAGvD,cAAc,oBAAoB,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,22 @@
1
+ import { PrismaClient } from "../client/index.js";
2
+ // Create a singleton instance of PrismaClient
3
+ export const prisma = new PrismaClient({
4
+ log: process.env.NODE_ENV === "development"
5
+ ? ["query", "error", "warn"]
6
+ : ["error"],
7
+ });
8
+ // Export all Prisma types
9
+ export * from "../client/index.js";
10
+ // Graceful shutdown
11
+ process.on("beforeExit", async () => {
12
+ await prisma.$disconnect();
13
+ });
14
+ process.on("SIGINT", async () => {
15
+ await prisma.$disconnect();
16
+ process.exit(0);
17
+ });
18
+ process.on("SIGTERM", async () => {
19
+ await prisma.$disconnect();
20
+ process.exit(0);
21
+ });
22
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD,8CAA8C;AAC9C,MAAM,CAAC,MAAM,MAAM,GAAG,IAAI,YAAY,CAAC;IACrC,GAAG,EACD,OAAO,CAAC,GAAG,CAAC,QAAQ,KAAK,aAAa;QACpC,CAAC,CAAC,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,CAAC;QAC5B,CAAC,CAAC,CAAC,OAAO,CAAC;CAChB,CAAC,CAAC;AAKH,0BAA0B;AAC1B,cAAc,oBAAoB,CAAC;AAEnC,oBAAoB;AACpB,OAAO,CAAC,EAAE,CAAC,YAAY,EAAE,KAAK,IAAI,EAAE;IAClC,MAAM,MAAM,CAAC,WAAW,EAAE,CAAC;AAC7B,CAAC,CAAC,CAAC;AAEH,OAAO,CAAC,EAAE,CAAC,QAAQ,EAAE,KAAK,IAAI,EAAE;IAC9B,MAAM,MAAM,CAAC,WAAW,EAAE,CAAC;IAC3B,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC;AAEH,OAAO,CAAC,EAAE,CAAC,SAAS,EAAE,KAAK,IAAI,EAAE;IAC/B,MAAM,MAAM,CAAC,WAAW,EAAE,CAAC;IAC3B,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adaptware/eagles-db",
3
- "version": "0.1.31",
3
+ "version": "0.1.33",
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
@@ -27,13 +27,15 @@ model FitCheck {
27
27
  fit Json[]
28
28
  fit_check_status FitCheckStatus?
29
29
  // Fields to be used now
30
-
31
- overall_score Float
32
- short_match_analysis Json[]
33
- candidate_analysis Json[]
34
- technical_analysis Json[]
35
- competency_analysis Json[]
36
- recommendation Json?
30
+ skills_analysis Json?
31
+ experience_analysis Json?
32
+ overall_score Float
33
+ // New Fields needs to be changed now
34
+ short_match_analysis Json[]
35
+ candidate_analysis Json[]
36
+ technical_analysis Json[]
37
+ competency_analysis Json[]
38
+ recommendation Json?
37
39
 
38
40
  /// Audit fields
39
41
  created_by String
@@ -18,6 +18,7 @@ model JobDescription {
18
18
  is_plan_published Boolean @default(false)
19
19
  is_posted Boolean @default(false)
20
20
  ai_insight Json?
21
+ fit_comparison Json?
21
22
  // Audit fields
22
23
  created_at DateTime @default(now())
23
24
  updated_at DateTime @updatedAt
@@ -0,0 +1,35 @@
1
+ enum AsyncOperationStatus {
2
+ PENDING
3
+ IN_PROGRESS
4
+ SUCCESS
5
+ FAILED
6
+ RETRYING
7
+ CANCELLED
8
+ }
9
+
10
+ model AsyncOperation {
11
+ id String @id @default(uuid())
12
+ // Identification
13
+ operation_name String
14
+ // Status tracking
15
+ status AsyncOperationStatus @default(PENDING)
16
+ started_at DateTime?
17
+ completed_at DateTime?
18
+ // Execution metadata
19
+ payload Json?
20
+ metadata Json?
21
+ // Tracing
22
+ correlationId String?
23
+ sourceService String?
24
+ // Error information
25
+ error_message String?
26
+ error_details String?
27
+ // Audit fields
28
+ created_at DateTime @default(now())
29
+ updated_at DateTime @updatedAt
30
+ is_active Boolean @default(true)
31
+
32
+ @@index([status])
33
+ @@index([operation_name])
34
+ @@index([correlationId])
35
+ }