frontend: when a justification is valid, check the MCQ box

This commit is contained in:
nemunaire 2018-11-28 07:09:05 +01:00
parent ad6fe0394f
commit 69a866bbbf
2 changed files with 14 additions and 1 deletions

View file

@ -259,7 +259,7 @@ angular.module("FICApp", ["ngRoute", "ngSanitize"])
value: mcq["checks_solved"] !== undefined && mcq["checks_solved"][cid] !== undefined && mcq["checks_solved"][cid] > 0
};
if (mcq["checks_solved"] !== undefined) {
this[cid].disabled = true;
this[cid].disabled = mcq["checks_solved"][cid] === undefined || mcq["checks_solved"][cid] >= 0;
this[cid].solved = mcq["checks_solved"][cid] !== undefined && mcq["checks_solved"][cid] >= 2;
}
}, mcq["choices"]);