MDL-27855 navigation - only display participants link with permissions
This commit is contained in:
committed by
Sam Hemelryk
parent
668a9eb90b
commit
a35be2f5ef
@@ -1626,7 +1626,9 @@ class global_navigation extends navigation_node {
|
||||
} else {
|
||||
// This is the site so add a users node to the root branch
|
||||
$usersnode = $this->rootnodes['users'];
|
||||
$usersnode->action = new moodle_url('/user/index.php', array('id'=>$course->id));
|
||||
if (has_capability('moodle/course:viewparticipants', $coursecontext)) {
|
||||
$usersnode->action = new moodle_url('/user/index.php', array('id'=>$course->id));
|
||||
}
|
||||
$userviewurl = new moodle_url('/user/profile.php', $baseargs);
|
||||
}
|
||||
if (!$usersnode) {
|
||||
|
||||
Reference in New Issue
Block a user