From 04684f6c636ed827a8ff029a8c0d9b7755096599 Mon Sep 17 00:00:00 2001 From: prathamesh Date: Wed, 24 Mar 2021 15:52:35 +0530 Subject: Modify upload question UI and change NullBooleanField to BooleanField --- yaksh/models.py | 2 +- yaksh/templates/yaksh/question.html | 44 ++++++++++++++++++++++--------------- 2 files changed, 27 insertions(+), 19 deletions(-) (limited to 'yaksh') diff --git a/yaksh/models.py b/yaksh/models.py index 9f34ade..8f9f051 100644 --- a/yaksh/models.py +++ b/yaksh/models.py @@ -2269,7 +2269,7 @@ class AnswerPaper(models.Model): percent = models.FloatField(null=True, default=0.0) # Result of the quiz, True if student passes the exam. - passed = models.NullBooleanField() + passed = models.BooleanField(null=True) # Status of the quiz attempt status = models.CharField( diff --git a/yaksh/templates/yaksh/question.html b/yaksh/templates/yaksh/question.html index 17305b6..f8f0c46 100644 --- a/yaksh/templates/yaksh/question.html +++ b/yaksh/templates/yaksh/question.html @@ -270,15 +270,6 @@ question_type = "{{ question.type }}"; {% if question.type == "upload" %} -

Upload assignment file for the said question

-

-
- -
-
-
{% if assignment_files %}
{% endif %} -
- {% if qrcode %} - - {% else %} -
- Generate QR Code - {% endif %} -

+
+
+
+

Upload assignment file for the said question. +
+ + You can upload using the file browser below or via the QR code. + +

+
+
+ +
+
+
+
+ {% if qrcode %} + + {% else %} + Generate QR Code + {% endif %} +
+
{% endif %} -- cgit