Add translator/editors buttons
This commit is contained in:
@@ -82,6 +82,9 @@ module.exports = function (options) {
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
association: db.TranslationArtifactVersion.TranslationArtifactVersionEditor,
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}).then(translationArtifactVersion => {
|
}).then(translationArtifactVersion => {
|
||||||
@@ -103,6 +106,15 @@ module.exports = function (options) {
|
|||||||
.get(function(request, response, next) {
|
.get(function(request, response, next) {
|
||||||
db.TranslationChapter.findByPk(request.params.chapterId, {
|
db.TranslationChapter.findByPk(request.params.chapterId, {
|
||||||
include: [
|
include: [
|
||||||
|
{
|
||||||
|
association: db.TranslationChapter.Chapter,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
association: db.TranslationChapter.TranslationChapterTranslators,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
association: db.TranslationChapter.TranslationChapterProofReaders,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
association: db.TranslationChapter.TranslationChunks,
|
association: db.TranslationChapter.TranslationChunks,
|
||||||
include: [
|
include: [
|
||||||
@@ -132,6 +144,9 @@ module.exports = function (options) {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
association: db.TranslationArtifactVersion.BackTranslationFrom
|
association: db.TranslationArtifactVersion.BackTranslationFrom
|
||||||
|
},
|
||||||
|
{
|
||||||
|
association: db.TranslationArtifactVersion.TranslationArtifactVersionEditor,
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ block content
|
|||||||
label
|
label
|
||||||
input#overview-checkbox(type="checkbox")
|
input#overview-checkbox(type="checkbox")
|
||||||
span
|
span
|
||||||
th Title Text
|
th Name
|
||||||
th
|
th
|
||||||
a.dropdown-trigger language ▼
|
a.dropdown-trigger language ▼
|
||||||
th Artifact
|
th Artifact
|
||||||
@@ -45,14 +45,14 @@ block content
|
|||||||
a.dropdown-trigger editor ▼
|
a.dropdown-trigger editor ▼
|
||||||
tbody
|
tbody
|
||||||
each translationChapter in translationChapters.sort((a, b) => a.index - b.index)
|
each translationChapter in translationChapters.sort((a, b) => a.index - b.index)
|
||||||
tr(onclick=`window.location='/projects/${project.id}/tracker/${translationChapter.id}'`)
|
tr(onclick=`window.location='/translate/${translationChapter.translationArtifactVersion.id}/chapter/${translationChapter.id}'`)
|
||||||
//- TODO: link to the translationChapter...
|
//- TODO: link to the translationChapter...
|
||||||
td
|
td
|
||||||
p
|
p
|
||||||
label
|
label
|
||||||
input(type="checkbox")
|
input(type="checkbox")
|
||||||
span
|
span
|
||||||
td(title=translationChapter.chapter.name)= translationChapter.chapter.name
|
td.truncate(title=translationChapter.chapter.name)= translationChapter.chapter.name
|
||||||
td
|
td
|
||||||
a(href=`/projects/${project.id}/tracker?dialectId=${translationChapter.translationArtifactVersion.dialect.id}`)= translationChapter.translationArtifactVersion.dialect.name
|
a(href=`/projects/${project.id}/tracker?dialectId=${translationChapter.translationArtifactVersion.dialect.id}`)= translationChapter.translationArtifactVersion.dialect.name
|
||||||
td #{translationChapter.translationArtifactVersion.artifactVersion.artifact.name} - #{translationChapter.translationArtifactVersion.artifactVersion.tag}
|
td #{translationChapter.translationArtifactVersion.artifactVersion.artifact.name} - #{translationChapter.translationArtifactVersion.artifactVersion.tag}
|
||||||
|
|||||||
@@ -6,6 +6,32 @@ block content
|
|||||||
h1= translationChapter.translationArtifactVersion.name
|
h1= translationChapter.translationArtifactVersion.name
|
||||||
h2= translationChapter.translationArtifactVersion.artifactVersion.artifact.name
|
h2= translationChapter.translationArtifactVersion.artifactVersion.artifact.name
|
||||||
|
|
||||||
|
p.flow-text
|
||||||
|
span.chip #{translationChapter.chapter.wordCount.toLocaleString()} words
|
||||||
|
|
||||||
|
.row
|
||||||
|
.col.s12.m4
|
||||||
|
|
||||||
|
p.flow-text
|
||||||
|
a.btn-flat.waves-effect Translator ▼
|
||||||
|
if translationChapter.translationChapterTranslators.length > 0
|
||||||
|
span With #{translationChapter.translationChapterTranslators.length} translator(s) assigned
|
||||||
|
else
|
||||||
|
span No translators assigned yet
|
||||||
|
.col.s12.m4
|
||||||
|
p.flow-text
|
||||||
|
a.btn-flat.waves-effect Editor ▼
|
||||||
|
if translationChapter.translationArtifactVersion.translationArtifactVersionEditor
|
||||||
|
span= translationChapter.translationArtifactVersion.translationArtifactVersionEditor.id
|
||||||
|
else
|
||||||
|
span No editors assigned yet
|
||||||
|
.col.s12.m4
|
||||||
|
p.flow-text
|
||||||
|
a.btn-flat.waves-effect Proof Reader ▼
|
||||||
|
if translationChapter.translationChapterProofReaders.length > 0
|
||||||
|
span With #{translationChapter.translationChapterProofReaders.length} proof reader(s) assigned
|
||||||
|
else
|
||||||
|
span No proof reader assigned yet
|
||||||
//- TODO: List translationChunks in the chapter
|
//- TODO: List translationChunks in the chapter
|
||||||
.row
|
.row
|
||||||
.col.s12
|
.col.s12
|
||||||
|
|||||||
@@ -42,6 +42,15 @@ block content
|
|||||||
form(action=`/fork/t/${translationArtifactVersion.id}`, method="post")
|
form(action=`/fork/t/${translationArtifactVersion.id}`, method="post")
|
||||||
button.btn.black(type="submit") fork
|
button.btn.black(type="submit") fork
|
||||||
|
|
||||||
|
.row
|
||||||
|
.col.s12
|
||||||
|
p.flow-text
|
||||||
|
a.btn-flat.waves-effect Editor ▼
|
||||||
|
if translationArtifactVersion.translationArtifactVersionEditor
|
||||||
|
span= translationArtifactVersion.translationArtifactVersionEditor.id
|
||||||
|
else
|
||||||
|
span No editors assigned yet
|
||||||
|
|
||||||
if isOwnedByUser
|
if isOwnedByUser
|
||||||
//- TODO: Check required conditions to start back translation...
|
//- TODO: Check required conditions to start back translation...
|
||||||
.row
|
.row
|
||||||
|
|||||||
Reference in New Issue
Block a user