MDL-58439 admin: Ignore guest logins for all admin pages

This commit is contained in:
Brendan Heywood
2019-06-11 13:44:58 +10:00
parent f3507273e9
commit 1fc0c4bd4e
39 changed files with 48 additions and 73 deletions
+3 -1
View File
@@ -52,10 +52,12 @@ if ($return === 'manage') {
$returnurl = new moodle_url('/admin/roles/define.php', array('action'=>'view', 'roleid'=>$roleid));;
}
admin_externalpage_setup('defineroles', '', array('action' => $action, 'roleid' => $roleid),
new moodle_url('/admin/roles/define.php'));
// Check access permissions.
$systemcontext = context_system::instance();
require_capability('moodle/role:manage', $systemcontext);
admin_externalpage_setup('defineroles', '', array('action' => $action, 'roleid' => $roleid), new moodle_url('/admin/roles/define.php'));
// Export role.
if ($action === 'export') {