diff --git a/migrations/elasticsearch_sync.js b/migrations/elasticsearch_sync.js index cd38357..3db1741 100644 --- a/migrations/elasticsearch_sync.js +++ b/migrations/elasticsearch_sync.js @@ -304,7 +304,10 @@ function getRequestBody (indexName) { index: 'not_analyzed' }, terms: { - type: 'integer' + type: 'string' + }, + groups: { + type: 'string' }, type: { type: 'string', diff --git a/src/services/ProcessorServiceProject.js b/src/services/ProcessorServiceProject.js index 5beba35..bfbe8cc 100644 --- a/src/services/ProcessorServiceProject.js +++ b/src/services/ProcessorServiceProject.js @@ -30,7 +30,8 @@ function createSchema () { id: Joi.number().integer().positive().required(), createdAt: Joi.date().required(), updatedAt: Joi.date().required(), - terms: Joi.array().items(Joi.number().positive()).optional(), + terms: Joi.array().items(Joi.string()).optional(), + groups: Joi.array().items(Joi.string()).optional(), name: Joi.string().required(), description: Joi.string().allow(null).allow('').optional(), type: Joi.string().max(45).required(),