From 8deefb90354f13e55b0d1789bddf9e8f96887746 Mon Sep 17 00:00:00 2001 From: Vivek Santayana Date: Thu, 2 Feb 2023 22:44:19 +0000 Subject: [PATCH] Bugfix: displaying scores for incomplete entries --- ref-test/app/admin/templates/admin/index.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ref-test/app/admin/templates/admin/index.html b/ref-test/app/admin/templates/admin/index.html index 4b355ec..79e4990 100644 --- a/ref-test/app/admin/templates/admin/index.html +++ b/ref-test/app/admin/templates/admin/index.html @@ -75,7 +75,11 @@ {{ result.end_time.strftime('%d %b %Y %H:%M') if result.end_time else None }} - {{ (100*result.result['score']/result.result['max'])|round|int }}% ({{ result.result.grade }}) + {% if result.result %} + {{ (100*result.result['score']/result.result['max'])|round|int }}% ({{ result.result.grade }}) + {% else %} + Incomplete + {% endif %} {% endfor %}