From cbdeb90a756832c71c80bac4dbe9ba1a3aceacb2 Mon Sep 17 00:00:00 2001 From: hardythe1 Date: Fri, 16 Jan 2015 16:47:43 +0530 Subject: added view, urls for assignment upload & changed the model --- testapp/exam/models.py | 1 - testapp/exam/templates/exam/question.html | 11 +++++++++++ testapp/exam/urls.py | 1 + testapp/exam/views.py | 16 ++++++++++++++++ 4 files changed, 28 insertions(+), 1 deletion(-) (limited to 'testapp/exam') diff --git a/testapp/exam/models.py b/testapp/exam/models.py index 2386cd2..1cafa89 100644 --- a/testapp/exam/models.py +++ b/testapp/exam/models.py @@ -389,6 +389,5 @@ class AnswerPaper(models.Model): ################################################################################ class AssignmentUpload(models.Model): user = models.ForeignKey(Profile) - assignment = models.ForeignKey(Quiz) assignmentQuestion = models.ForeignKey(Question) assignmentFile = models.FileField(upload_to=get_assignment_dir) diff --git a/testapp/exam/templates/exam/question.html b/testapp/exam/templates/exam/question.html index 855a29e..f8888b1 100644 --- a/testapp/exam/templates/exam/question.html +++ b/testapp/exam/templates/exam/question.html @@ -95,6 +95,17 @@ function setSnippetHeight() {% endif %}
+ + {% if question.type == "bash assignment" %} + + {% endif %} +