diff --git a/atlas/templates/atlas/collection_scores.html b/atlas/templates/atlas/collection_scores.html index 6fefdb1f..abbec8a1 100644 --- a/atlas/templates/atlas/collection_scores.html +++ b/atlas/templates/atlas/collection_scores.html @@ -63,7 +63,7 @@ {% endfor %} {% endcomment %} {% for cid in cids %} {% with by_question|get_item:question|get_item:cid as ans_score %} - {{ans_score.0}} + {{ans_score.1}} {% endwith %} {% endfor %} diff --git a/atlas/views.py b/atlas/views.py index 73827367..e05529e6 100755 --- a/atlas/views.py +++ b/atlas/views.py @@ -1368,6 +1368,7 @@ def collection_case_view(request, pk, case_number): ) +# TODO: this needs a major cleanup @user_is_collection_author_or_atlas_editor def collection_scores_cid(request, pk): collection = get_object_or_404(CaseCollection, pk=pk) @@ -1409,7 +1410,7 @@ def collection_scores_cid(request, pk): s = cid_user_answer user_names[cid] = cid - q = cid_user_answer.question + q = cid_user_answer.question.case # if not s: # # skip if no answer @@ -1428,7 +1429,7 @@ def collection_scores_cid(request, pk): user_answers_marks[cid].append(answer_score) user_answers_and_marks[cid].append((ans, answer_score)) - by_question[q][cid] = (ans, answer_score) + by_question[q][cid] = (ans, answer_score, s.feedback) user_scores = {} user_scores_normalised = {}