diff --git a/package-lock.json b/package-lock.json index 5f539c8..898e00f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1426,7 +1426,7 @@ }, "node_modules/mantra-db-models": { "version": "0.0.10", - "resolved": "git+https://code.sigidli.com/mantra/mantra-db-models.git#6f0fd52b8fbbff5cbc446b814de070ace3cd1c4f", + "resolved": "git+https://code.sigidli.com/mantra/mantra-db-models.git#40423458f5e549406ebf5433073d135497d7ec79", "license": "ISC", "dependencies": { "bcrypt": "^5.0.1", @@ -4011,7 +4011,7 @@ } }, "mantra-db-models": { - "version": "git+https://code.sigidli.com/mantra/mantra-db-models.git#6f0fd52b8fbbff5cbc446b814de070ace3cd1c4f", + "version": "git+https://code.sigidli.com/mantra/mantra-db-models.git#40423458f5e549406ebf5433073d135497d7ec79", "from": "mantra-db-models@git+https://code.sigidli.com/mantra/mantra-db-models.git", "requires": { "bcrypt": "^5.0.1", diff --git a/server/router/projects/index.js b/server/router/projects/index.js index c0b9685..55dbb16 100644 --- a/server/router/projects/index.js +++ b/server/router/projects/index.js @@ -1162,6 +1162,12 @@ module.exports = function (options) { } ] }, + { + association: db.TranslationChapter.TranslationChapterTranslators, + }, + { + association: db.TranslationChapter.TranslationChapterProofReaders, + }, { association: db.TranslationChapter.TranslationArtifactVersion, required: true, @@ -1197,8 +1203,16 @@ module.exports = function (options) { } } : { association: db.TranslationArtifactVersion.Dialect, + }, + request.query.editorId ? { + association: db.TranslationArtifactVersion.TranslationArtifactVersionEditor, + required: true, + where: { + userId: request.query.editorId + } + } : { + association: db.TranslationArtifactVersion.TranslationArtifactVersionEditor, } - , ] } ]