]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-16632 "green highlighting should not be applied to grading method in quiz respons...
authorjamiesensei <jamiesensei>
Wed, 24 Sep 2008 10:45:05 +0000 (10:45 +0000)
committerjamiesensei <jamiesensei>
Wed, 24 Sep 2008 10:45:05 +0000 (10:45 +0000)
Reverted earlier patch and instead using a different colour for highlighting graded grade. Now using light yellow with a darker yellow border instead of green which is used in reports to highlight the correct answer.

mod/quiz/report/reportlib.php

index 081b1dd475116626376c18c9d8dcea367f3424d6..ba77bd674dcaa573b977dac52cc0479bcc811432 100644 (file)
@@ -287,7 +287,7 @@ function quiz_report_grade_bands($bandwidth, $bands, $quizid, $userids=array()){
     unset($data[$bands]);
     return $data;
 }
-function quiz_report_highlighting_grading_method($quiz, $qmsubselect, $qmfilter, $highlight=true){
+function quiz_report_highlighting_grading_method($quiz, $qmsubselect, $qmfilter){
     if ($quiz->attempts == 1) {//only one attempt allowed on this quiz
         return "<p>".get_string('onlyoneattemptallowed', "quiz_overview")."</p>";
     } else if (!$qmsubselect){
@@ -295,11 +295,8 @@ function quiz_report_highlighting_grading_method($quiz, $qmsubselect, $qmfilter,
     } else if ($qmfilter){
         return "<p>".get_string('showinggraded', "quiz_overview")."</p>";
     }else {
-        $a = quiz_get_grading_option_name($quiz->grademethod);
-        if ($highlight){
-            $a = '<span class="highlight">'.$a.'</span>';
-        }
-        return "<p>".get_string('showinggradedandungraded', "quiz_overview", $a)."</p>";
+        return "<p>".get_string('showinggradedandungraded', "quiz_overview",
+                ('<span class="highlight">'.quiz_get_grading_option_name($quiz->grademethod).'</span>'))."</p>";
     }
 }