]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-19028 Hiding hidden category from student report instead of grade items. See...
authornicolasconnault <nicolasconnault>
Thu, 30 Apr 2009 08:40:22 +0000 (08:40 +0000)
committernicolasconnault <nicolasconnault>
Thu, 30 Apr 2009 08:40:22 +0000 (08:40 +0000)
grade/report/user/lib.php

index f508bd25f230dacb6bcd2b49c3b94ac4d99f1107..a261d5b179745f3bfee44738f858ccccc45a8d2b 100644 (file)
@@ -206,8 +206,8 @@ class grade_report_user extends grade_report {
         $excluded = '';
         $class = '';
 
-        // If this is a hidden grade item, hide it completely from the user. showhiddenitems: 0 = hide all, 1 = show only hidden until, 2 = show all
-        if ($grade_object->is_hidden() && !$this->canviewhidden && (
+        // If this is a hidden grade category, hide it completely from the user. showhiddenitems: 0 = hide all, 1 = show only hidden until, 2 = show all
+        if ($type == 'category' && $grade_object->is_hidden() && !$this->canviewhidden && (
                 $this->showhiddenitems == 0 ||
                 ($this->showhiddenitems == 1 && !$grade_object->is_hiddenuntil()))) {
             return false;