1 |
efrain |
1 |
<?php
|
|
|
2 |
// This file is part of Moodle - http://moodle.org/
|
|
|
3 |
//
|
|
|
4 |
// Moodle is free software: you can redistribute it and/or modify
|
|
|
5 |
// it under the terms of the GNU General Public License as published by
|
|
|
6 |
// the Free Software Foundation, either version 3 of the License, or
|
|
|
7 |
// (at your option) any later version.
|
|
|
8 |
//
|
|
|
9 |
// Moodle is distributed in the hope that it will be useful,
|
|
|
10 |
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
11 |
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
12 |
// GNU General Public License for more details.
|
|
|
13 |
//
|
|
|
14 |
// You should have received a copy of the GNU General Public License
|
|
|
15 |
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
|
|
16 |
|
|
|
17 |
/**
|
|
|
18 |
* Defines the dashboard and settings page. put them into the nav-tree
|
|
|
19 |
*
|
|
|
20 |
*/
|
|
|
21 |
defined('MOODLE_INTERNAL') || die();
|
|
|
22 |
if (has_capability('report/training:managesettings', context_system::instance())) {
|
|
|
23 |
$ADMIN->add('reports',
|
|
|
24 |
new admin_category(
|
|
|
25 |
'report_training',
|
|
|
26 |
get_string('pluginname', 'report_training')
|
|
|
27 |
)
|
|
|
28 |
);
|
|
|
29 |
$ADMIN->add('report_training',
|
|
|
30 |
new admin_externalpage(
|
|
|
31 |
'report_training_dashboard',
|
|
|
32 |
get_string('dashboard_name', 'report_training'),
|
|
|
33 |
new moodle_url('/report/training/admin/dashboard.php')
|
|
|
34 |
)
|
|
|
35 |
);
|
|
|
36 |
$ADMIN->add('report_training',
|
|
|
37 |
new admin_externalpage(
|
|
|
38 |
'report_training_settings',
|
|
|
39 |
get_string('settings_name', 'report_training'),
|
|
|
40 |
new moodle_url('/report/training/admin/settings.php')
|
|
|
41 |
)
|
|
|
42 |
);$ADMIN->add('report_training',
|
|
|
43 |
new admin_externalpage(
|
|
|
44 |
'report_training_userdata',
|
|
|
45 |
get_string('userdata_name', 'report_training'),
|
|
|
46 |
new moodle_url('/report/training/admin/userdata.php')
|
|
|
47 |
)
|
|
|
48 |
);
|
|
|
49 |
}
|
|
|
50 |
$settings = null;
|