summaryrefslogtreecommitdiff
path: root/yaksh/models.py
diff options
context:
space:
mode:
authoradityacp2016-04-27 18:04:42 +0530
committeradityacp2016-05-04 22:47:34 +0530
commit51ad57a7ef8fa4cab7f4e590a260f18e3040ef74 (patch)
treebe7b10dc6b2d46f86df2821f23166367a6587ce8 /yaksh/models.py
parent94b449a10e8ba709f64aa56cb18640ba93642cee (diff)
downloadonline_test-51ad57a7ef8fa4cab7f4e590a260f18e3040ef74.tar.gz
online_test-51ad57a7ef8fa4cab7f4e590a260f18e3040ef74.tar.bz2
online_test-51ad57a7ef8fa4cab7f4e590a260f18e3040ef74.zip
rebase changes and function name changes
Diffstat (limited to 'yaksh/models.py')
-rw-r--r--yaksh/models.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/yaksh/models.py b/yaksh/models.py
index b7df67c..79db206 100644
--- a/yaksh/models.py
+++ b/yaksh/models.py
@@ -211,7 +211,7 @@ class Question(models.Model):
return json.dumps(question_info_dict)
- def dump_questions_into_json(self, user):
+ def dump_into_json(self, user):
questions = Question.objects.filter(user_id = user.id)
questions_dict = [{'summary': question.summary,
'description': question.description,
@@ -222,7 +222,7 @@ class Question(models.Model):
'snippet': question.snippet} for question in questions]
return json.dumps(questions_dict, indent=2)
- def load_questions_from_json(self, questions_list, user):
+ def load_from_json(self, questions_list, user):
questions = json.loads(questions_list)
for question in questions:
Question.objects.get_or_create(summary=question['summary'],