let question = this.quiz.data.questions[questionIndex];
let a = [];
- let ok = true;
+ let ok = 'ok';
let count = question.count_for_score;
let log = {
'count': count,
let min_score = 0;
let this_score = 0;
if (userAnswers === undefined || userAnswers === null) {
- ok = null;
+ ok = 'not answered';
} else {
let $this = this;
if (question.type === 'multiple') {
}
}
}
- ok = this_score >= min_score;
+ ok = this_score >= min_score ? 'ok' : 'nok';
log.answer = a;
} else {
}
}
+ if (!count) {
+ ok = 'ok';
+ }
+
this.questionStatus[questionIndex] = {
ok: ok,
answers: answersStatus,
if (count) {
this.maxScore++;
- if (ok) {
+ if (ok == 'ok') {
this.score++;
log.score = 1;
} else {