@zyacreatives/shared 2.0.13 → 2.0.15
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/dist/schemas/job.d.ts +55 -37
- package/dist/schemas/job.js +30 -16
- package/package.json +1 -1
- package/src/schemas/job.ts +34 -16
package/dist/schemas/job.d.ts
CHANGED
|
@@ -42,6 +42,9 @@ export declare const BaseJobEntitySchema: z.ZodObject<{
|
|
|
42
42
|
EMEA: "EMEA";
|
|
43
43
|
"Asia Pacific": "Asia Pacific";
|
|
44
44
|
}>;
|
|
45
|
+
jobSections: z.ZodDefault<z.ZodArray<z.ZodEnum<{
|
|
46
|
+
[x: string]: string;
|
|
47
|
+
}>>>;
|
|
45
48
|
createdAt: z.ZodDate;
|
|
46
49
|
updatedAt: z.ZodDate;
|
|
47
50
|
}, z.core.$strip>;
|
|
@@ -93,6 +96,9 @@ export declare const JobEntitySchema: z.ZodObject<{
|
|
|
93
96
|
EMEA: "EMEA";
|
|
94
97
|
"Asia Pacific": "Asia Pacific";
|
|
95
98
|
}>;
|
|
99
|
+
jobSections: z.ZodDefault<z.ZodArray<z.ZodEnum<{
|
|
100
|
+
[x: string]: string;
|
|
101
|
+
}>>>;
|
|
96
102
|
createdAt: z.ZodDate;
|
|
97
103
|
updatedAt: z.ZodDate;
|
|
98
104
|
}, z.core.$strip>;
|
|
@@ -100,10 +106,10 @@ export declare const GigJobEntitySchema: z.ZodObject<{
|
|
|
100
106
|
id: z.ZodCUID2;
|
|
101
107
|
jobType: z.ZodLiteral<"GIG">;
|
|
102
108
|
overview: z.ZodString;
|
|
103
|
-
deliverables: z.
|
|
104
|
-
employeeRequirements: z.ZodOptional<z.
|
|
109
|
+
deliverables: z.ZodString;
|
|
110
|
+
employeeRequirements: z.ZodOptional<z.ZodString>;
|
|
105
111
|
aboutCompany: z.ZodOptional<z.ZodString>;
|
|
106
|
-
requiredSkills: z.
|
|
112
|
+
requiredSkills: z.ZodString;
|
|
107
113
|
wagesMin: z.ZodOptional<z.ZodNumber>;
|
|
108
114
|
wagesMax: z.ZodOptional<z.ZodNumber>;
|
|
109
115
|
wagesCurrency: z.ZodOptional<z.ZodEnum<{
|
|
@@ -166,15 +172,18 @@ export declare const JobWithGigDetailsEntitySchema: z.ZodObject<{
|
|
|
166
172
|
EMEA: "EMEA";
|
|
167
173
|
"Asia Pacific": "Asia Pacific";
|
|
168
174
|
}>;
|
|
175
|
+
jobSections: z.ZodDefault<z.ZodArray<z.ZodEnum<{
|
|
176
|
+
[x: string]: string;
|
|
177
|
+
}>>>;
|
|
169
178
|
createdAt: z.ZodDate;
|
|
170
179
|
updatedAt: z.ZodDate;
|
|
171
180
|
id: z.ZodCUID2;
|
|
172
181
|
jobType: z.ZodLiteral<"GIG">;
|
|
173
182
|
overview: z.ZodString;
|
|
174
|
-
deliverables: z.
|
|
175
|
-
employeeRequirements: z.ZodOptional<z.
|
|
183
|
+
deliverables: z.ZodString;
|
|
184
|
+
employeeRequirements: z.ZodOptional<z.ZodString>;
|
|
176
185
|
aboutCompany: z.ZodOptional<z.ZodString>;
|
|
177
|
-
requiredSkills: z.
|
|
186
|
+
requiredSkills: z.ZodString;
|
|
178
187
|
wagesMin: z.ZodOptional<z.ZodNumber>;
|
|
179
188
|
wagesMax: z.ZodOptional<z.ZodNumber>;
|
|
180
189
|
wagesCurrency: z.ZodOptional<z.ZodEnum<{
|
|
@@ -207,10 +216,10 @@ export declare const RoleJobEntitySchema: z.ZodObject<{
|
|
|
207
216
|
"5+ years": "5+ years";
|
|
208
217
|
}>;
|
|
209
218
|
overview: z.ZodString;
|
|
210
|
-
keyResponsibilities: z.
|
|
211
|
-
requiredSkills: z.
|
|
212
|
-
employeeRequirements: z.ZodOptional<z.
|
|
213
|
-
companyBenefits: z.ZodOptional<z.
|
|
219
|
+
keyResponsibilities: z.ZodString;
|
|
220
|
+
requiredSkills: z.ZodString;
|
|
221
|
+
employeeRequirements: z.ZodOptional<z.ZodString>;
|
|
222
|
+
companyBenefits: z.ZodOptional<z.ZodString>;
|
|
214
223
|
wagesMin: z.ZodOptional<z.ZodNumber>;
|
|
215
224
|
wagesMax: z.ZodOptional<z.ZodNumber>;
|
|
216
225
|
wagesCurrency: z.ZodOptional<z.ZodEnum<{
|
|
@@ -273,6 +282,9 @@ export declare const JobWithRoleDetailsEntitySchema: z.ZodObject<{
|
|
|
273
282
|
EMEA: "EMEA";
|
|
274
283
|
"Asia Pacific": "Asia Pacific";
|
|
275
284
|
}>;
|
|
285
|
+
jobSections: z.ZodDefault<z.ZodArray<z.ZodEnum<{
|
|
286
|
+
[x: string]: string;
|
|
287
|
+
}>>>;
|
|
276
288
|
createdAt: z.ZodDate;
|
|
277
289
|
updatedAt: z.ZodDate;
|
|
278
290
|
id: z.ZodCUID2;
|
|
@@ -284,10 +296,10 @@ export declare const JobWithRoleDetailsEntitySchema: z.ZodObject<{
|
|
|
284
296
|
"5+ years": "5+ years";
|
|
285
297
|
}>;
|
|
286
298
|
overview: z.ZodString;
|
|
287
|
-
keyResponsibilities: z.
|
|
288
|
-
requiredSkills: z.
|
|
289
|
-
employeeRequirements: z.ZodOptional<z.
|
|
290
|
-
companyBenefits: z.ZodOptional<z.
|
|
299
|
+
keyResponsibilities: z.ZodString;
|
|
300
|
+
requiredSkills: z.ZodString;
|
|
301
|
+
employeeRequirements: z.ZodOptional<z.ZodString>;
|
|
302
|
+
companyBenefits: z.ZodOptional<z.ZodString>;
|
|
291
303
|
wagesMin: z.ZodOptional<z.ZodNumber>;
|
|
292
304
|
wagesMax: z.ZodOptional<z.ZodNumber>;
|
|
293
305
|
wagesCurrency: z.ZodOptional<z.ZodEnum<{
|
|
@@ -359,10 +371,10 @@ export declare const CreateRoleJobInputSchema: z.ZodObject<{
|
|
|
359
371
|
"5+ years": "5+ years";
|
|
360
372
|
}>;
|
|
361
373
|
overview: z.ZodString;
|
|
362
|
-
keyResponsibilities: z.
|
|
363
|
-
requiredSkills: z.
|
|
364
|
-
employeeRequirements: z.ZodOptional<z.
|
|
365
|
-
companyBenefits: z.ZodOptional<z.
|
|
374
|
+
keyResponsibilities: z.ZodString;
|
|
375
|
+
requiredSkills: z.ZodString;
|
|
376
|
+
employeeRequirements: z.ZodOptional<z.ZodString>;
|
|
377
|
+
companyBenefits: z.ZodOptional<z.ZodString>;
|
|
366
378
|
wagesMin: z.ZodOptional<z.ZodNumber>;
|
|
367
379
|
wagesMax: z.ZodOptional<z.ZodNumber>;
|
|
368
380
|
wagesCurrency: z.ZodOptional<z.ZodEnum<{
|
|
@@ -388,10 +400,10 @@ export declare const CreateRoleJobInputSchema: z.ZodObject<{
|
|
|
388
400
|
export declare const CreateGigJobInputSchema: z.ZodObject<{
|
|
389
401
|
id: z.ZodCUID2;
|
|
390
402
|
overview: z.ZodString;
|
|
391
|
-
deliverables: z.
|
|
392
|
-
employeeRequirements: z.ZodOptional<z.
|
|
403
|
+
deliverables: z.ZodString;
|
|
404
|
+
employeeRequirements: z.ZodOptional<z.ZodString>;
|
|
393
405
|
aboutCompany: z.ZodOptional<z.ZodString>;
|
|
394
|
-
requiredSkills: z.
|
|
406
|
+
requiredSkills: z.ZodString;
|
|
395
407
|
wagesMin: z.ZodOptional<z.ZodNumber>;
|
|
396
408
|
wagesMax: z.ZodOptional<z.ZodNumber>;
|
|
397
409
|
wagesCurrency: z.ZodOptional<z.ZodEnum<{
|
|
@@ -415,7 +427,7 @@ export declare const CreateGigJobInputSchema: z.ZodObject<{
|
|
|
415
427
|
}>>;
|
|
416
428
|
}, z.core.$strip>;
|
|
417
429
|
export declare const UpdateRoleJobInputSchema: z.ZodObject<{
|
|
418
|
-
id: z.ZodOptional<z.ZodCUID2
|
|
430
|
+
id: z.ZodNonOptional<z.ZodOptional<z.ZodCUID2>>;
|
|
419
431
|
experienceLevel: z.ZodOptional<z.ZodEnum<{
|
|
420
432
|
"0-1 year": "0-1 year";
|
|
421
433
|
"1-3 years": "1-3 years";
|
|
@@ -423,10 +435,10 @@ export declare const UpdateRoleJobInputSchema: z.ZodObject<{
|
|
|
423
435
|
"5+ years": "5+ years";
|
|
424
436
|
}>>;
|
|
425
437
|
overview: z.ZodOptional<z.ZodString>;
|
|
426
|
-
keyResponsibilities: z.ZodOptional<z.
|
|
427
|
-
requiredSkills: z.ZodOptional<z.
|
|
428
|
-
employeeRequirements: z.ZodOptional<z.ZodOptional<z.
|
|
429
|
-
companyBenefits: z.ZodOptional<z.ZodOptional<z.
|
|
438
|
+
keyResponsibilities: z.ZodOptional<z.ZodString>;
|
|
439
|
+
requiredSkills: z.ZodOptional<z.ZodString>;
|
|
440
|
+
employeeRequirements: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
441
|
+
companyBenefits: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
430
442
|
wagesMin: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
431
443
|
wagesMax: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
432
444
|
wagesCurrency: z.ZodOptional<z.ZodOptional<z.ZodEnum<{
|
|
@@ -450,12 +462,12 @@ export declare const UpdateRoleJobInputSchema: z.ZodObject<{
|
|
|
450
462
|
}>>>;
|
|
451
463
|
}, z.core.$strip>;
|
|
452
464
|
export declare const UpdateGigJobInputSchema: z.ZodObject<{
|
|
453
|
-
id: z.ZodOptional<z.ZodCUID2
|
|
465
|
+
id: z.ZodNonOptional<z.ZodOptional<z.ZodCUID2>>;
|
|
454
466
|
overview: z.ZodOptional<z.ZodString>;
|
|
455
|
-
deliverables: z.ZodOptional<z.
|
|
456
|
-
employeeRequirements: z.ZodOptional<z.ZodOptional<z.
|
|
467
|
+
deliverables: z.ZodOptional<z.ZodString>;
|
|
468
|
+
employeeRequirements: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
457
469
|
aboutCompany: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
458
|
-
requiredSkills: z.ZodOptional<z.
|
|
470
|
+
requiredSkills: z.ZodOptional<z.ZodString>;
|
|
459
471
|
wagesMin: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
460
472
|
wagesMax: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
|
|
461
473
|
wagesCurrency: z.ZodOptional<z.ZodOptional<z.ZodEnum<{
|
|
@@ -559,15 +571,18 @@ export declare const NormalizedJobOutputSchema: z.ZodDiscriminatedUnion<[z.ZodOb
|
|
|
559
571
|
EMEA: "EMEA";
|
|
560
572
|
"Asia Pacific": "Asia Pacific";
|
|
561
573
|
}>;
|
|
574
|
+
jobSections: z.ZodDefault<z.ZodArray<z.ZodEnum<{
|
|
575
|
+
[x: string]: string;
|
|
576
|
+
}>>>;
|
|
562
577
|
createdAt: z.ZodDate;
|
|
563
578
|
updatedAt: z.ZodDate;
|
|
564
579
|
id: z.ZodCUID2;
|
|
565
580
|
jobType: z.ZodLiteral<"GIG">;
|
|
566
581
|
overview: z.ZodString;
|
|
567
|
-
deliverables: z.
|
|
568
|
-
employeeRequirements: z.ZodOptional<z.
|
|
582
|
+
deliverables: z.ZodString;
|
|
583
|
+
employeeRequirements: z.ZodOptional<z.ZodString>;
|
|
569
584
|
aboutCompany: z.ZodOptional<z.ZodString>;
|
|
570
|
-
requiredSkills: z.
|
|
585
|
+
requiredSkills: z.ZodString;
|
|
571
586
|
wagesMin: z.ZodOptional<z.ZodNumber>;
|
|
572
587
|
wagesMax: z.ZodOptional<z.ZodNumber>;
|
|
573
588
|
wagesCurrency: z.ZodOptional<z.ZodEnum<{
|
|
@@ -629,6 +644,9 @@ export declare const NormalizedJobOutputSchema: z.ZodDiscriminatedUnion<[z.ZodOb
|
|
|
629
644
|
EMEA: "EMEA";
|
|
630
645
|
"Asia Pacific": "Asia Pacific";
|
|
631
646
|
}>;
|
|
647
|
+
jobSections: z.ZodDefault<z.ZodArray<z.ZodEnum<{
|
|
648
|
+
[x: string]: string;
|
|
649
|
+
}>>>;
|
|
632
650
|
createdAt: z.ZodDate;
|
|
633
651
|
updatedAt: z.ZodDate;
|
|
634
652
|
id: z.ZodCUID2;
|
|
@@ -640,10 +658,10 @@ export declare const NormalizedJobOutputSchema: z.ZodDiscriminatedUnion<[z.ZodOb
|
|
|
640
658
|
"5+ years": "5+ years";
|
|
641
659
|
}>;
|
|
642
660
|
overview: z.ZodString;
|
|
643
|
-
keyResponsibilities: z.
|
|
644
|
-
requiredSkills: z.
|
|
645
|
-
employeeRequirements: z.ZodOptional<z.
|
|
646
|
-
companyBenefits: z.ZodOptional<z.
|
|
661
|
+
keyResponsibilities: z.ZodString;
|
|
662
|
+
requiredSkills: z.ZodString;
|
|
663
|
+
employeeRequirements: z.ZodOptional<z.ZodString>;
|
|
664
|
+
companyBenefits: z.ZodOptional<z.ZodString>;
|
|
647
665
|
wagesMin: z.ZodOptional<z.ZodNumber>;
|
|
648
666
|
wagesMax: z.ZodOptional<z.ZodNumber>;
|
|
649
667
|
wagesCurrency: z.ZodOptional<z.ZodEnum<{
|
package/dist/schemas/job.js
CHANGED
|
@@ -18,6 +18,13 @@ exports.BaseJobEntitySchema = zod_1.z.object({
|
|
|
18
18
|
.enum(Object.values(constants_1.GIG_TYPE))
|
|
19
19
|
.optional(),
|
|
20
20
|
location: zod_1.z.enum(Object.values(constants_1.JOB_LOCATIONS)),
|
|
21
|
+
jobSections: zod_1.z
|
|
22
|
+
.array(JobSectionEnum)
|
|
23
|
+
.default([
|
|
24
|
+
constants_1.JOB_SECTIONS.PERSONAL_INFORMATION,
|
|
25
|
+
constants_1.JOB_SECTIONS.PROFESSIONAL_INFORMATION,
|
|
26
|
+
constants_1.JOB_SECTIONS.RESUME,
|
|
27
|
+
]),
|
|
21
28
|
createdAt: zod_1.z.date(),
|
|
22
29
|
updatedAt: zod_1.z.date(),
|
|
23
30
|
});
|
|
@@ -40,6 +47,13 @@ exports.JobEntitySchema = zod_1.z.object({
|
|
|
40
47
|
.enum(Object.values(constants_1.GIG_TYPE))
|
|
41
48
|
.optional(),
|
|
42
49
|
location: zod_1.z.enum(Object.values(constants_1.JOB_LOCATIONS)),
|
|
50
|
+
jobSections: zod_1.z
|
|
51
|
+
.array(JobSectionEnum)
|
|
52
|
+
.default([
|
|
53
|
+
constants_1.JOB_SECTIONS.PERSONAL_INFORMATION,
|
|
54
|
+
constants_1.JOB_SECTIONS.PROFESSIONAL_INFORMATION,
|
|
55
|
+
constants_1.JOB_SECTIONS.RESUME,
|
|
56
|
+
]),
|
|
43
57
|
createdAt: zod_1.z.date(),
|
|
44
58
|
updatedAt: zod_1.z.date(),
|
|
45
59
|
});
|
|
@@ -47,10 +61,10 @@ exports.GigJobEntitySchema = zod_1.z.object({
|
|
|
47
61
|
id: zod_1.z.cuid2(),
|
|
48
62
|
jobType: zod_1.z.literal(constants_1.JOB_TYPE.GIG),
|
|
49
63
|
overview: zod_1.z.string(),
|
|
50
|
-
deliverables: zod_1.z.
|
|
51
|
-
employeeRequirements: zod_1.z.
|
|
64
|
+
deliverables: zod_1.z.string(),
|
|
65
|
+
employeeRequirements: zod_1.z.string().optional(),
|
|
52
66
|
aboutCompany: zod_1.z.string().optional(),
|
|
53
|
-
requiredSkills: zod_1.z.
|
|
67
|
+
requiredSkills: zod_1.z.string(),
|
|
54
68
|
wagesMin: zod_1.z.number().optional(),
|
|
55
69
|
wagesMax: zod_1.z.number().optional(),
|
|
56
70
|
wagesCurrency: zod_1.z
|
|
@@ -66,10 +80,10 @@ exports.RoleJobEntitySchema = zod_1.z.object({
|
|
|
66
80
|
jobType: zod_1.z.literal(constants_1.JOB_TYPE.ROLE),
|
|
67
81
|
experienceLevel: zod_1.z.enum(Object.values(constants_1.EXPERIENCE_LEVELS)),
|
|
68
82
|
overview: zod_1.z.string(),
|
|
69
|
-
keyResponsibilities: zod_1.z.
|
|
70
|
-
requiredSkills: zod_1.z.
|
|
71
|
-
employeeRequirements: zod_1.z.
|
|
72
|
-
companyBenefits: zod_1.z.
|
|
83
|
+
keyResponsibilities: zod_1.z.string(),
|
|
84
|
+
requiredSkills: zod_1.z.string(),
|
|
85
|
+
employeeRequirements: zod_1.z.string().optional(),
|
|
86
|
+
companyBenefits: zod_1.z.string().optional(),
|
|
73
87
|
wagesMin: zod_1.z.number().optional(),
|
|
74
88
|
wagesMax: zod_1.z.number().optional(),
|
|
75
89
|
wagesCurrency: zod_1.z
|
|
@@ -146,10 +160,10 @@ exports.CreateRoleJobInputSchema = zod_1.z.object({
|
|
|
146
160
|
id: zod_1.z.cuid2(),
|
|
147
161
|
experienceLevel: zod_1.z.enum(Object.values(constants_1.EXPERIENCE_LEVELS)),
|
|
148
162
|
overview: zod_1.z.string(),
|
|
149
|
-
keyResponsibilities: zod_1.z.
|
|
150
|
-
requiredSkills: zod_1.z.
|
|
151
|
-
employeeRequirements: zod_1.z.
|
|
152
|
-
companyBenefits: zod_1.z.
|
|
163
|
+
keyResponsibilities: zod_1.z.string(),
|
|
164
|
+
requiredSkills: zod_1.z.string(),
|
|
165
|
+
employeeRequirements: zod_1.z.string().optional(),
|
|
166
|
+
companyBenefits: zod_1.z.string().optional(),
|
|
153
167
|
wagesMin: zod_1.z.number().optional(),
|
|
154
168
|
wagesMax: zod_1.z.number().optional(),
|
|
155
169
|
wagesCurrency: zod_1.z
|
|
@@ -162,10 +176,10 @@ exports.CreateRoleJobInputSchema = zod_1.z.object({
|
|
|
162
176
|
exports.CreateGigJobInputSchema = zod_1.z.object({
|
|
163
177
|
id: zod_1.z.cuid2(),
|
|
164
178
|
overview: zod_1.z.string(),
|
|
165
|
-
deliverables: zod_1.z.
|
|
166
|
-
employeeRequirements: zod_1.z.
|
|
179
|
+
deliverables: zod_1.z.string(),
|
|
180
|
+
employeeRequirements: zod_1.z.string().optional(),
|
|
167
181
|
aboutCompany: zod_1.z.string().optional(),
|
|
168
|
-
requiredSkills: zod_1.z.
|
|
182
|
+
requiredSkills: zod_1.z.string(),
|
|
169
183
|
wagesMin: zod_1.z.number().optional(),
|
|
170
184
|
wagesMax: zod_1.z.number().optional(),
|
|
171
185
|
wagesCurrency: zod_1.z
|
|
@@ -175,8 +189,8 @@ exports.CreateGigJobInputSchema = zod_1.z.object({
|
|
|
175
189
|
.enum(Object.values(constants_1.WAGE_TYPES))
|
|
176
190
|
.optional(),
|
|
177
191
|
});
|
|
178
|
-
exports.UpdateRoleJobInputSchema = exports.CreateRoleJobInputSchema.partial();
|
|
179
|
-
exports.UpdateGigJobInputSchema = exports.CreateGigJobInputSchema.partial();
|
|
192
|
+
exports.UpdateRoleJobInputSchema = exports.CreateRoleJobInputSchema.partial().required({ id: true });
|
|
193
|
+
exports.UpdateGigJobInputSchema = exports.CreateGigJobInputSchema.partial().required({ id: true });
|
|
180
194
|
exports.UpdateJobInputSchema = exports.CreateJobInputSchema.partial().extend({
|
|
181
195
|
id: zod_1.z.cuid2(),
|
|
182
196
|
});
|
package/package.json
CHANGED
package/src/schemas/job.ts
CHANGED
|
@@ -45,6 +45,13 @@ export const BaseJobEntitySchema = z.object({
|
|
|
45
45
|
location: z.enum(
|
|
46
46
|
Object.values(JOB_LOCATIONS) as [JobLocation, ...JobLocation[]]
|
|
47
47
|
),
|
|
48
|
+
jobSections: z
|
|
49
|
+
.array(JobSectionEnum)
|
|
50
|
+
.default([
|
|
51
|
+
JOB_SECTIONS.PERSONAL_INFORMATION,
|
|
52
|
+
JOB_SECTIONS.PROFESSIONAL_INFORMATION,
|
|
53
|
+
JOB_SECTIONS.RESUME,
|
|
54
|
+
]),
|
|
48
55
|
createdAt: z.date(),
|
|
49
56
|
updatedAt: z.date(),
|
|
50
57
|
});
|
|
@@ -73,7 +80,15 @@ export const JobEntitySchema = z.object({
|
|
|
73
80
|
location: z.enum(
|
|
74
81
|
Object.values(JOB_LOCATIONS) as [JobLocation, ...JobLocation[]]
|
|
75
82
|
),
|
|
83
|
+
jobSections: z
|
|
84
|
+
.array(JobSectionEnum)
|
|
85
|
+
.default([
|
|
86
|
+
JOB_SECTIONS.PERSONAL_INFORMATION,
|
|
87
|
+
JOB_SECTIONS.PROFESSIONAL_INFORMATION,
|
|
88
|
+
JOB_SECTIONS.RESUME,
|
|
89
|
+
]),
|
|
76
90
|
createdAt: z.date(),
|
|
91
|
+
|
|
77
92
|
updatedAt: z.date(),
|
|
78
93
|
});
|
|
79
94
|
|
|
@@ -81,10 +96,10 @@ export const GigJobEntitySchema = z.object({
|
|
|
81
96
|
id: z.cuid2(),
|
|
82
97
|
jobType: z.literal(JOB_TYPE.GIG),
|
|
83
98
|
overview: z.string(),
|
|
84
|
-
deliverables: z.
|
|
85
|
-
employeeRequirements: z.
|
|
99
|
+
deliverables: z.string(),
|
|
100
|
+
employeeRequirements: z.string().optional(),
|
|
86
101
|
aboutCompany: z.string().optional(),
|
|
87
|
-
requiredSkills: z.
|
|
102
|
+
requiredSkills: z.string(),
|
|
88
103
|
wagesMin: z.number().optional(),
|
|
89
104
|
wagesMax: z.number().optional(),
|
|
90
105
|
wagesCurrency: z
|
|
@@ -106,10 +121,10 @@ export const RoleJobEntitySchema = z.object({
|
|
|
106
121
|
Object.values(EXPERIENCE_LEVELS) as [ExperienceLevel, ...ExperienceLevel[]]
|
|
107
122
|
),
|
|
108
123
|
overview: z.string(),
|
|
109
|
-
keyResponsibilities: z.
|
|
110
|
-
requiredSkills: z.
|
|
111
|
-
employeeRequirements: z.
|
|
112
|
-
companyBenefits: z.
|
|
124
|
+
keyResponsibilities: z.string(),
|
|
125
|
+
requiredSkills: z.string(),
|
|
126
|
+
employeeRequirements: z.string().optional(),
|
|
127
|
+
companyBenefits: z.string().optional(),
|
|
113
128
|
wagesMin: z.number().optional(),
|
|
114
129
|
wagesMax: z.number().optional(),
|
|
115
130
|
wagesCurrency: z
|
|
@@ -201,10 +216,10 @@ export const CreateRoleJobInputSchema = z.object({
|
|
|
201
216
|
Object.values(EXPERIENCE_LEVELS) as [ExperienceLevel, ...ExperienceLevel[]]
|
|
202
217
|
),
|
|
203
218
|
overview: z.string(),
|
|
204
|
-
keyResponsibilities: z.
|
|
205
|
-
requiredSkills: z.
|
|
206
|
-
employeeRequirements: z.
|
|
207
|
-
companyBenefits: z.
|
|
219
|
+
keyResponsibilities: z.string(),
|
|
220
|
+
requiredSkills: z.string(),
|
|
221
|
+
employeeRequirements: z.string().optional(),
|
|
222
|
+
companyBenefits: z.string().optional(),
|
|
208
223
|
wagesMin: z.number().optional(),
|
|
209
224
|
wagesMax: z.number().optional(),
|
|
210
225
|
wagesCurrency: z
|
|
@@ -218,10 +233,10 @@ export const CreateRoleJobInputSchema = z.object({
|
|
|
218
233
|
export const CreateGigJobInputSchema = z.object({
|
|
219
234
|
id: z.cuid2(),
|
|
220
235
|
overview: z.string(),
|
|
221
|
-
deliverables: z.
|
|
222
|
-
employeeRequirements: z.
|
|
236
|
+
deliverables: z.string(),
|
|
237
|
+
employeeRequirements: z.string().optional(),
|
|
223
238
|
aboutCompany: z.string().optional(),
|
|
224
|
-
requiredSkills: z.
|
|
239
|
+
requiredSkills: z.string(),
|
|
225
240
|
wagesMin: z.number().optional(),
|
|
226
241
|
wagesMax: z.number().optional(),
|
|
227
242
|
wagesCurrency: z
|
|
@@ -232,8 +247,11 @@ export const CreateGigJobInputSchema = z.object({
|
|
|
232
247
|
.optional(),
|
|
233
248
|
});
|
|
234
249
|
|
|
235
|
-
export const UpdateRoleJobInputSchema =
|
|
236
|
-
|
|
250
|
+
export const UpdateRoleJobInputSchema =
|
|
251
|
+
CreateRoleJobInputSchema.partial().required({ id: true });
|
|
252
|
+
|
|
253
|
+
export const UpdateGigJobInputSchema =
|
|
254
|
+
CreateGigJobInputSchema.partial().required({ id: true });
|
|
237
255
|
|
|
238
256
|
export const UpdateJobInputSchema = CreateJobInputSchema.partial().extend({
|
|
239
257
|
id: z.cuid2(),
|