MDL-26140 hide unfinished experimental DTL pages
[moodle.git] / admin / settings / mnet.php
CommitLineData
11b749ca 1<?php
134cacf1 2
d14383e0 3// This file defines settingpages and externalpages under the "mnet" category
4
a559f630 5if ($hassiteconfig) { // speedup for non-admins, add all caps used on this page
6
220a90c5 7$ADMIN->add('mnet', new admin_externalpage('net', get_string('settings', 'mnet'),
8 "$CFG->wwwroot/$CFG->admin/mnet/index.php",
20003335 9 'moodle/site:config'));
d14383e0 10
96bd2921
PL
11
12
13$ADMIN->add('mnet', new admin_externalpage('mnetpeers', get_string('managemnetpeers', 'mnet'),
220a90c5 14 "$CFG->wwwroot/$CFG->admin/mnet/peers.php",
20003335 15 'moodle/site:config'));
96bd2921
PL
16
17
18$ADMIN->add('mnet', new admin_category('mnetpeercat', get_string('mnetpeers', 'mnet')));
19
63eaea45 20if (isset($CFG->mnet_dispatcher_mode) and $CFG->mnet_dispatcher_mode !== 'off') {
536fc0b5
PS
21 require_once($CFG->dirroot.'/mnet/lib.php');
22
ae6b4634
PS
23 $hosts = mnet_get_hosts();
24 foreach ($hosts as $host) {
25 $ADMIN->add('mnetpeercat',
26 new admin_externalpage(
27 'mnetpeer' . $host->id,
28 $host->name,
29 $CFG->wwwroot . '/admin/mnet/peers.php?step=update&hostid=' . $host->id,
30 'moodle/site:config'
31 )
32 );
33 }
96bd2921
PL
34}
35
20003335 36$ADMIN->add('mnet', new admin_externalpage('ssoaccesscontrol', get_string('ssoaccesscontrol', 'mnet'),
220a90c5 37 "$CFG->wwwroot/$CFG->admin/mnet/access_control.php",
20003335 38 'moodle/site:config'));
fe73e935
DM
39$ADMIN->add('mnet', new admin_externalpage('mnetenrol', get_string('clientname', 'mnetservice_enrol'),
40 "$CFG->wwwroot/mnet/service/enrol/index.php",
0a127169 41 'moodle/site:config'));
220a90c5 42$ADMIN->add('mnet', new admin_externalpage('trustedhosts', get_string('trustedhosts', 'mnet'),
43 "$CFG->wwwroot/$CFG->admin/mnet/trustedhosts.php",
20003335 44 'moodle/site:config'));
96bd2921 45
536fc0b5
PS
46if (isset($CFG->mnet_dispatcher_mode) and $CFG->mnet_dispatcher_mode !== 'off') {
47 $profilefields = new admin_settingpage('mnetprofilefields', get_string('profilefields', 'mnet'),
48 'moodle/site:config');
49 $ADMIN->add('mnet', $profilefields);
96bd2921 50
536fc0b5
PS
51 $fields = mnet_profile_field_options();
52 $forced = implode(', ', $fields['forced']);
96bd2921 53
536fc0b5
PS
54 $profilefields->add(new admin_setting_configmultiselect('mnetprofileexportfields', get_string('profileexportfields', 'mnet'), get_string('profilefielddesc', 'mnet', $forced), $fields['legacy'], $fields['optional']));
55 $profilefields->add(new admin_setting_configmultiselect('mnetprofileimportfields', get_string('profileimportfields', 'mnet'), get_string('profilefielddesc', 'mnet', $forced), $fields['legacy'], $fields['optional']));
56}
96bd2921 57
a559f630 58
59} // end of speedup