summaryrefslogtreecommitdiff
path: root/yaksh/models.py
diff options
context:
space:
mode:
authoradityacp2020-09-30 08:56:36 +0530
committeradityacp2020-09-30 08:56:36 +0530
commit2dcaa3847c4faefd14ee88b9a2370e1d83e747f0 (patch)
treed5e05823f9b6524469a78073e60857841dba07aa /yaksh/models.py
parent4ab3353b4a6dc28764c8536e6b089f7feb65f015 (diff)
parented81054c05ff297ea241ce08664e0d2323da115c (diff)
downloadonline_test-2dcaa3847c4faefd14ee88b9a2370e1d83e747f0.tar.gz
online_test-2dcaa3847c4faefd14ee88b9a2370e1d83e747f0.tar.bz2
online_test-2dcaa3847c4faefd14ee88b9a2370e1d83e747f0.zip
Resolve Conflicts
Diffstat (limited to 'yaksh/models.py')
-rw-r--r--yaksh/models.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/yaksh/models.py b/yaksh/models.py
index 7757951..0c5a6f5 100644
--- a/yaksh/models.py
+++ b/yaksh/models.py
@@ -1784,6 +1784,8 @@ class QuestionPaper(models.Model):
for question in questions:
marks += question.points
for question_set in self.random_questions.all():
+ question_set.marks = question_set.questions.first().points
+ question_set.save()
marks += question_set.marks * question_set.num_questions
self.total_marks = marks
self.save()