|
Moodle
2.2.1
http://www.collinsharper.com
|
00001 <?php 00002 00003 // This is the first file read by the lib/adminlib.php script 00004 // We use it to create the categories in correct order, 00005 // since they need to exist *before* settingpages and externalpages 00006 // are added to them. 00007 00008 $systemcontext = get_context_instance(CONTEXT_SYSTEM); 00009 $hassiteconfig = has_capability('moodle/site:config', $systemcontext); 00010 00011 $ADMIN->add('root', new admin_externalpage('adminnotifications', get_string('notifications'), "$CFG->wwwroot/$CFG->admin/index.php")); 00012 00013 $ADMIN->add('root', new admin_externalpage('registrationindex', get_string('registration','admin'), 00014 "$CFG->wwwroot/$CFG->admin/registration/index.php")); 00015 $ADMIN->add('root', new admin_externalpage('registration', get_string('registeron','hub'), 00016 "$CFG->wwwroot/$CFG->admin/registration/register.php", 'moodle/site:config', true)); 00017 $ADMIN->add('root', new admin_externalpage('registrationselector', get_string('registeron','hub'), 00018 "$CFG->wwwroot/$CFG->admin/registration/hubselector.php", 'moodle/site:config', true)); 00019 $ADMIN->add('root', new admin_externalpage('siteregistrationconfirmed', 00020 get_string('registrationconfirmed', 'hub'), 00021 $CFG->wwwroot."/".$CFG->admin."/registration/confirmregistration.php", 'moodle/site:config', true)); 00022 // hidden upgrade script 00023 $ADMIN->add('root', new admin_externalpage('upgradesettings', get_string('upgradesettings', 'admin'), "$CFG->wwwroot/$CFG->admin/upgradesettings.php", 'moodle/site:config', true)); 00024 00025 if ($hassiteconfig) { 00026 $optionalsubsystems = new admin_settingpage('optionalsubsystems', get_string('advancedfeatures', 'admin')); 00027 $ADMIN->add('root', $optionalsubsystems); 00028 } 00029 00030 $ADMIN->add('root', new admin_category('users', get_string('users','admin'))); 00031 $ADMIN->add('root', new admin_category('courses', get_string('courses','admin'))); 00032 $ADMIN->add('root', new admin_category('grades', get_string('grades'))); 00033 $ADMIN->add('root', new admin_category('location', get_string('location','admin'))); 00034 $ADMIN->add('root', new admin_category('language', get_string('language'))); 00035 $ADMIN->add('root', new admin_category('modules', get_string('plugins', 'admin'))); 00036 $ADMIN->add('root', new admin_category('security', get_string('security','admin'))); 00037 $ADMIN->add('root', new admin_category('appearance', get_string('appearance','admin'))); 00038 $ADMIN->add('root', new admin_category('frontpage', get_string('frontpage','admin'))); 00039 $ADMIN->add('root', new admin_category('server', get_string('server','admin'))); 00040 $ADMIN->add('root', new admin_category('mnet', get_string('net','mnet'), (isset($CFG->mnet_dispatcher_mode) and $CFG->mnet_dispatcher_mode === 'off'))); 00041 $ADMIN->add('root', new admin_category('reports', get_string('reports'))); 00042 $ADMIN->add('root', new admin_category('development', get_string('development', 'admin'))); 00043 00044 // hidden unsupported category 00045 $ADMIN->add('root', new admin_category('unsupported', get_string('unsupported', 'admin'), true)); 00046 00047 // hidden search script 00048 $ADMIN->add('root', new admin_externalpage('search', get_string('searchresults'), "$CFG->wwwroot/$CFG->admin/search.php", 'moodle/site:config', true));