This commit is contained in:
Ross
2021-02-01 12:41:46 +00:00
parent 1493408a69
commit 5854601eb8
+3 -3
View File
@@ -924,14 +924,14 @@ def exam_scores_cid(request, pk):
# Get user answer
s = q.cid_user_answers.filter(cid=cid).first()
if s.normal:
ans = "Normal"
elif not s:
if not s:
# skip if no answer
user_answers_marks[cid].append(0)
user_answers[cid].append("")
by_question[q].append(("", 0))
continue
elif s.normal:
ans = "Normal"
else:
ans = s.answer
answer_score = s.get_answer_score()