]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-13437 Grader report: Showing idnumber column shifts controls into wrong columns...
authorskodak <skodak>
Sun, 17 Feb 2008 14:56:30 +0000 (14:56 +0000)
committerskodak <skodak>
Sun, 17 Feb 2008 14:56:30 +0000 (14:56 +0000)
grade/report/grader/lib.php

index 3d3bc0fc084064fd7e3059dba23e60c57137e6c4..26f8ee91998bcb9bf6a57fb67eebd56870f1472b 100644 (file)
@@ -1128,10 +1128,15 @@ class grade_report_grader extends grade_report {
         global $USER;
 
         $iconshtml = '';
-            if ($USER->gradeediting[$this->courseid]) {
+        if ($USER->gradeediting[$this->courseid]) {
+
+            $colspan='';
+            if ($this->get_pref('showuseridnumber')) {
+                $colspan = 'colspan="2" ';
+            }
 
             $iconshtml = '<tr class="r'.$this->rowcount++.'">'
-                       . '<th class="header c0 range" scope="row">'.$this->get_lang_string('controls','grades').'</th>';
+                       . '<th class="header c0 range" scope="row" '.$colspan.'>'.$this->get_lang_string('controls','grades').'</th>';
 
             $columncount = 1;
             foreach ($this->gtree->items as $itemid=>$unused) {