fnp
/
edumed.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
c756f35
)
fix sciezki kopernika test form
author
Jan Szejko
<janek37@gmail.com>
Tue, 4 Jul 2017 10:46:29 +0000
(12:46 +0200)
committer
Jan Szejko
<janek37@gmail.com>
Tue, 4 Jul 2017 10:46:29 +0000
(12:46 +0200)
edumed/contact_forms.py
patch
|
blob
|
history
diff --git
a/edumed/contact_forms.py
b/edumed/contact_forms.py
index
6a53fad
..
d0b38a2
100644
(file)
--- a/
edumed/contact_forms.py
+++ b/
edumed/contact_forms.py
@@
-1707,7
+1707,7
@@
class SciezkiKopernikaTestForm(ContactForm):
'comment': mark_safe(markdown.convert(cls.ANSWER_COMMENTS[i-1][chosen_idx])),
'answers': [(text, a_score == score, a_score == 2) for a_score, text in choices],
}
'comment': mark_safe(markdown.convert(cls.ANSWER_COMMENTS[i-1][chosen_idx])),
'answers': [(text, a_score == score, a_score == 2) for a_score, text in choices],
}
- question_count = len(fields) -
1
+ question_count = len(fields) -
2
questions = [question_data(i) for i in xrange(1, question_count + 1)]
points = sum(question['score'] for question in questions)
return {'questions': questions, 'points': points/2., 'total': question_count}
questions = [question_data(i) for i in xrange(1, question_count + 1)]
points = sum(question['score'] for question in questions)
return {'questions': questions, 'points': points/2., 'total': question_count}