MDL-55533 qtype_multianswer: fix feedback for multiresponse
authorDavo Smith <git@davosmith.co.uk>
Thu, 11 Aug 2016 13:13:58 +0000 (14:13 +0100)
committerDavo Smith <git@davosmith.co.uk>
Thu, 11 Aug 2016 13:13:58 +0000 (14:13 +0100)
question/type/multianswer/renderer.php

index 7d54c58..748bcec 100644 (file)
@@ -593,7 +593,7 @@ class qtype_multianswer_multiresponse_vertical_renderer extends qtype_multianswe
         if ($options->rightanswer) {
             $correct = [];
             foreach ($subq->answers as $ans) {
         if ($options->rightanswer) {
             $correct = [];
             foreach ($subq->answers as $ans) {
-                if (question_state::graded_state_for_fraction($ans->fraction) == question_state::$gradedpartial) {
+                if (question_state::graded_state_for_fraction($ans->fraction) != question_state::$gradedwrong) {
                     $correct[] = $subq->format_text($ans->answer, $ans->answerformat, $qa, 'question', 'answer', $ans->id);
                 }
             }
                     $correct[] = $subq->format_text($ans->answer, $ans->answerformat, $qa, 'question', 'answer', $ans->id);
                 }
             }