MDL-74205 navigation: Don't show participants link to user if he has no permission.
This commit is contained in:
@@ -2939,8 +2939,8 @@ class global_navigation extends navigation_node {
|
||||
if ($navoptions->notes) {
|
||||
$participants->add(get_string('notes', 'notes'), new moodle_url('/notes/index.php', array('filtertype' => 'course', 'filterselect' => $course->id)), self::TYPE_SETTING, null, 'currentcoursenotes');
|
||||
}
|
||||
} else if (count($this->extendforuser) > 0 || $this->page->course->id == $course->id) {
|
||||
$participants = $coursenode->add(get_string('participants'), null, self::TYPE_CONTAINER, get_string('participants'), 'participants');
|
||||
} else if (count($this->extendforuser) > 0) {
|
||||
$coursenode->add(get_string('participants'), null, self::TYPE_CONTAINER, get_string('participants'), 'participants');
|
||||
}
|
||||
|
||||
// Badges.
|
||||
|
||||
Reference in New Issue
Block a user