From 09aed6db0be635d86c2bf7f9c9a989e6df1bceab Mon Sep 17 00:00:00 2001 From: prathamesh Date: Tue, 20 Jan 2015 17:30:48 +0530 Subject: View updated to take infinite quizzes. --- testapp/exam/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testapp/exam/views.py b/testapp/exam/views.py index ce1c62e..f94d383 100644 --- a/testapp/exam/views.py +++ b/testapp/exam/views.py @@ -189,7 +189,7 @@ def intro(request, questionpaper_id): 'attempt_no': already_attempted + 1} return my_render_to_response('exam/intro.html', context, context_instance=ci) - if already_attempted < attempt_number: + if already_attempted < attempt_number or attempt_number < 0: previous_attempt_day = attempted_papers[already_attempted-1].start_time today = datetime.datetime.today() days_after_attempt = (today - previous_attempt_day).days -- cgit