MDL-69993 output: correct navigation node type for user reports.
authorPaul Holden <paulh@moodle.com>
Fri, 23 Oct 2020 07:04:44 +0000 (08:04 +0100)
committerPaul Holden <paulh@moodle.com>
Fri, 23 Oct 2020 07:04:44 +0000 (08:04 +0100)
lib/pagelib.php

index 8378da8..6e5f3aa 100644 (file)
@@ -2051,7 +2051,8 @@ class moodle_page {
             $reportnode = $myprofilenode->add(get_string('reports'));
         }
         // Finally add the report to the navigation tree.
-        $reportnode->add($nodeinfo['name'], $nodeinfo['url'], navigation_node::TYPE_COURSE);
+        $reportnode->add($nodeinfo['name'], $nodeinfo['url'], navigation_node::TYPE_CUSTOM, null, null,
+            new pix_icon('i/report', $nodeinfo['name']));
     }
 
     /**