}
}
- var matching_correct = false;
+
var options_selected = $(this).find('option:selected');
if (options_selected.length > 0) {
- matching_correct = true
- }
- options_selected.each(function() {
- if ($(this).data('correct') == false) {
- matching_correct = false;
+ var matching_correct = true;
+ options_selected.each(function() {
+ if ($(this).data('correct') == false) {
+ matching_correct = false;
+ }
+ });
+ if (matching_correct) {
+ markQuestionCorrect($(this));
+ } else {
+ markQuestionIncorrect($(this));
}
- });
- if (matching_correct) {
- markQuestionCorrect($(this));
- } else {
- markQuestionIncorrect($(this));
}
-
});
});
}
name="group_{{ forloop.counter0 }}"
id="choice_{{ forloop.counter0 }}_false"
value="choice_{{ forloop.counter0 }}_false"
- data-correct="{% if question.false %}true{% else %}false{% endif %}" />
+ data-correct="{% if question.true %}false{% else %}true{% endif %}" />
<label for="choice_{{ forloop.counter0 }}_false">False</label>
</div>
{% endif %}