Skip to content

Commit 1836259

Browse files
authored
Merge pull request #61 from cagdas001/feature/role-intake
feat(job-processor): accept `roles` array
2 parents 1db6efc + f4e193d commit 1836259

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

src/bootstrap.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ global.Promise = require('bluebird')
1212
Joi.rateType = () => Joi.string().valid('hourly', 'daily', 'weekly', 'monthly')
1313
Joi.jobStatus = () => Joi.string().valid('sourcing', 'in-review', 'assigned', 'closed', 'cancelled')
1414
Joi.resourceBookingStatus = () => Joi.string().valid('placed', 'closed', 'cancelled')
15-
Joi.jobCandidateStatus = () => Joi.string().valid('open', 'placed', 'selected', 'client rejected - screening', 'client rejected - interview', 'rejected - other', 'cancelled', 'interview', 'topcoder-rejected','applied','rejected-pre-screen','skills-test','skills-test','phone-screen','job-closed','offered')
15+
Joi.jobCandidateStatus = () => Joi.string().valid('open', 'placed', 'selected', 'client rejected - screening', 'client rejected - interview', 'rejected - other', 'cancelled', 'interview', 'topcoder-rejected', 'applied', 'rejected-pre-screen', 'skills-test', 'skills-test', 'phone-screen', 'job-closed', 'offered')
1616
Joi.workload = () => Joi.string().valid('full-time', 'fractional')
1717
Joi.title = () => Joi.string().max(128)
1818
Joi.paymentStatus = () => Joi.string().valid('pending', 'partially-completed', 'completed', 'cancelled')

src/scripts/createIndex.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ async function createIndex () {
2626
rateType: { type: 'keyword' },
2727
workload: { type: 'keyword' },
2828
skills: { type: 'keyword' },
29+
roles: { type: 'keyword' },
2930
status: { type: 'keyword' },
3031
isApplicationPageActive: { type: 'boolean' },
3132
createdAt: { type: 'date' },

src/services/JobProcessorService.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ processCreate.schema = {
7878
rateType: Joi.rateType().allow(null),
7979
workload: Joi.workload().allow(null),
8080
skills: Joi.array().items(Joi.string().uuid()).required(),
81+
roles: Joi.array().items(Joi.string().uuid()).allow(null),
8182
createdAt: Joi.date().required(),
8283
createdBy: Joi.string().uuid().required(),
8384
updatedAt: Joi.date().allow(null),

0 commit comments

Comments
 (0)