From 7cac4db2c68c9060e75cd77d4c114cbd607cb91f Mon Sep 17 00:00:00 2001 From: Ross Date: Sun, 12 Dec 2021 21:41:30 +0000 Subject: [PATCH] . --- physics/models.py | 3 +++ templates/cid_scores.html | 8 +++----- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/physics/models.py b/physics/models.py index 694f1c4c..4b852dbe 100644 --- a/physics/models.py +++ b/physics/models.py @@ -156,6 +156,9 @@ class Exam(ExamBase): valid_users = models.ManyToManyField(CidUser, blank=True, related_name="physics_exams") + def get_take_url(self): + return reverse("physics:exam_start", kwargs={"pk": self.pk}) + @reversion.register class CidUserAnswer(models.Model): diff --git a/templates/cid_scores.html b/templates/cid_scores.html index aa453d5f..03b96fa2 100644 --- a/templates/cid_scores.html +++ b/templates/cid_scores.html @@ -3,9 +3,7 @@ {% block content %}

CID: {{ cid }}

-

Exams to take

- - +

Available exams

{% for t, exams in available_exams %}

{{t}}

{% endfor %} -

Taken Exams

- The following exams have been found (click to view answers and scores): +

Exam results

+ The following exam results been found (click to view answers and scores): {% if physics_exams %}

Physics