.
This commit is contained in:
@@ -162,12 +162,10 @@
|
||||
}
|
||||
|
||||
.physics-answer-list input:checked::after {
|
||||
transform: translateY(-20px);
|
||||
margin-left: 20px;
|
||||
content: "True"
|
||||
}
|
||||
.physics-answer-list input:not(:checked)::after {
|
||||
margin-top: -5px;
|
||||
margin-left: 20px;
|
||||
content: "False"
|
||||
}
|
||||
|
||||
+3
-3
@@ -94,7 +94,7 @@ def exam_scores_cid(request, pk):
|
||||
questions = exam.exam_questions.all()
|
||||
|
||||
cids = (
|
||||
CidUserAnswer.objects.filter(question__in=questions)
|
||||
CidUserAnswer.objects.filter(question__in=questions, exam__id=pk)
|
||||
.order_by("cid")
|
||||
.values_list("cid", flat=True)
|
||||
.distinct()
|
||||
@@ -114,7 +114,7 @@ def exam_scores_cid(request, pk):
|
||||
user_names[cid] = cid
|
||||
for q in questions:
|
||||
# Get user answer
|
||||
s = q.cid_user_answers.filter(cid=cid).first()
|
||||
s = q.cid_user_answers.filter(cid=cid, exam__id=pk).first()
|
||||
if not s:
|
||||
# skip if no answer
|
||||
user_answers_marks[cid].append(0)
|
||||
@@ -207,7 +207,7 @@ def exam_scores_cid_user(request, pk, sk):
|
||||
|
||||
for q in questions:
|
||||
# Get user answer
|
||||
user_answer = q.cid_user_answers.filter(cid=cid).first()
|
||||
user_answer = q.cid_user_answers.filter(cid=cid, exam__id=pk).first()
|
||||
|
||||
ans = user_answer.get_answers()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user