summaryrefslogtreecommitdiff
path: root/yaksh/views.py
diff options
context:
space:
mode:
authoradityacp2016-08-26 11:31:33 +0530
committeradityacp2016-08-26 11:31:33 +0530
commit74745309a065399f6bd33544de8705f0004edf30 (patch)
treef3e72c2dc8c752efe31c7393a158bb995328d9f7 /yaksh/views.py
parentc231dcb006c7dc6db4dc0312f53447971776635f (diff)
downloadonline_test-74745309a065399f6bd33544de8705f0004edf30.tar.gz
online_test-74745309a065399f6bd33544de8705f0004edf30.tar.bz2
online_test-74745309a065399f6bd33544de8705f0004edf30.zip
changed models and views questions dump and load
Diffstat (limited to 'yaksh/views.py')
-rw-r--r--yaksh/views.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/yaksh/views.py b/yaksh/views.py
index 87e6005..616c3cc 100644
--- a/yaksh/views.py
+++ b/yaksh/views.py
@@ -94,7 +94,7 @@ def read_json(json_file, user):
if os.path.exists(json_file):
with open(json_file, 'r') as q_file:
questions_list = q_file.read()
- question.load_from_json(questions_list, user)
+ question.load_questions(questions_list, user)
os.remove(json_file)
@@ -901,7 +901,7 @@ def show_all_questions(request):
question_ids = request.POST.getlist('question')
if question_ids:
question = Question()
- zip_file = question.dump_into_json(question_ids, user)
+ zip_file = question.dump_questions(question_ids, user)
response = HttpResponse(content_type='application/zip')
response['Content-Disposition'] = '''attachment;\
filename={0}_questions.zip'''.format(user)