MDL-21695 Replaced grade/showranges.html
[moodle.git] / grade / report / grader / settings.php
1 <?php
3 // This file is part of Moodle - http://moodle.org/
4 //
5 // Moodle is free software: you can redistribute it and/or modify
6 // it under the terms of the GNU General Public License as published by
7 // the Free Software Foundation, either version 3 of the License, or
8 // (at your option) any later version.
9 //
10 // Moodle is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 // GNU General Public License for more details.
14 //
15 // You should have received a copy of the GNU General Public License
16 // along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
18 $strinherit             = get_string('inherit', 'grades');
19 $strpercentage          = get_string('percentage', 'grades');
20 $strreal                = get_string('real', 'grades');
21 $strletter              = get_string('letter', 'grades');
23 /// Add settings for this module to the $settings object (it's already defined)
24 $settings->add(new admin_setting_configtext('grade_report_studentsperpage', get_string('studentsperpage', 'grades'),
25                                         get_string('configstudentsperpage', 'grades'), 100));
27 $settings->add(new admin_setting_configcheckbox('grade_report_quickgrading', get_string('quickgrading', 'grades'),
28                                             get_string('quickgrading_help', 'grades'), 1));
30 $settings->add(new admin_setting_configcheckbox('grade_report_showquickfeedback', get_string('quickfeedback', 'grades'),
31                                             get_string('showquickfeedback_help', 'grades'), 0));
33 $settings->add(new admin_setting_configcheckbox('grade_report_fixedstudents', get_string('fixedstudents', 'grades'),
34                                             get_string('configfixedstudents', 'grades'), 0));
36 $settings->add(new admin_setting_configselect('grade_report_meanselection', get_string('meanselection', 'grades'),
37                                           get_string('meanselection_help', 'grades'), GRADE_REPORT_MEAN_GRADED,
38                                           array(GRADE_REPORT_MEAN_ALL => get_string('meanall', 'grades'),
39                                                 GRADE_REPORT_MEAN_GRADED => get_string('meangraded', 'grades'))));
41 $settings->add(new admin_setting_configcheckbox('grade_report_enableajax', get_string('enableajax', 'grades'),
42                                             get_string('enableajax_help', 'grades'), 0));
44 $settings->add(new admin_setting_configcheckbox('grade_report_showcalculations', get_string('showcalculations', 'grades'),
45                                             get_string('showcalculations_help', 'grades'), 0));
47 $settings->add(new admin_setting_configcheckbox('grade_report_showeyecons', get_string('showeyecons', 'grades'),
48                                             get_string('showeyecons_help', 'grades'), 0));
50 $settings->add(new admin_setting_configcheckbox('grade_report_showaverages', get_string('showaverages', 'grades'),
51                                             get_string('showaverages_help', 'grades'), 1));
53 $settings->add(new admin_setting_configcheckbox('grade_report_showlocks', get_string('showlocks', 'grades'),
54                                             get_string('showlocks_help', 'grades'), 0));
56 $settings->add(new admin_setting_configcheckbox('grade_report_showranges', get_string('showranges', 'grades'),
57                                             get_string('showranges_help', 'grades'), 0));
59 $settings->add(new admin_setting_configcheckbox('grade_report_showuserimage', get_string('showuserimage', 'grades'),
60                                             get_string('configshowuserimage', 'grades'), 1));
62 $settings->add(new admin_setting_configcheckbox('grade_report_showuseridnumber', get_string('showuseridnumber', 'grades'),
63                                             get_string('configshowuseridnumber', 'grades'), 0));
65 $settings->add(new admin_setting_configcheckbox('grade_report_showactivityicons', get_string('showactivityicons', 'grades'),
66                                             get_string('showactivityicons_help', 'grades'), 1));
68 $settings->add(new admin_setting_configcheckbox('grade_report_shownumberofgrades', get_string('shownumberofgrades', 'grades'),
69                                             get_string('shownumberofgrades_help', 'grades'), 0));
71 $settings->add(new admin_setting_configselect('grade_report_averagesdisplaytype', get_string('averagesdisplaytype', 'grades'),
72                                           get_string('averagesdisplaytype_help', 'grades'), GRADE_REPORT_PREFERENCE_INHERIT,
73                                           array(GRADE_REPORT_PREFERENCE_INHERIT => $strinherit,
74                                                 GRADE_DISPLAY_TYPE_REAL => $strreal,
75                                                 GRADE_DISPLAY_TYPE_PERCENTAGE => $strpercentage,
76                                                 GRADE_DISPLAY_TYPE_LETTER => $strletter)));
78 $settings->add(new admin_setting_configselect('grade_report_rangesdisplaytype', get_string('rangesdisplaytype', 'grades'),
79                                           get_string('rangesdisplaytype_help', 'grades'), GRADE_REPORT_PREFERENCE_INHERIT,
80                                           array(GRADE_REPORT_PREFERENCE_INHERIT => $strinherit,
81                                                 GRADE_DISPLAY_TYPE_REAL => $strreal,
82                                                 GRADE_DISPLAY_TYPE_PERCENTAGE => $strpercentage,
83                                                 GRADE_DISPLAY_TYPE_LETTER => $strletter)));
85 $settings->add(new admin_setting_configselect('grade_report_averagesdecimalpoints', get_string('averagesdecimalpoints', 'grades'),
86                                           get_string('averagesdecimalpoints_help', 'grades'), GRADE_REPORT_PREFERENCE_INHERIT,
87                                           array(GRADE_REPORT_PREFERENCE_INHERIT => $strinherit,
88                                                  '0' => '0',
89                                                  '1' => '1',
90                                                  '2' => '2',
91                                                  '3' => '3',
92                                                  '4' => '4',
93                                                  '5' => '5')));
94 $settings->add(new admin_setting_configselect('grade_report_rangesdecimalpoints', get_string('rangesdecimalpoints', 'grades'),
95                                           get_string('rangesdecimalpoints_help', 'grades'), GRADE_REPORT_PREFERENCE_INHERIT,
96                                           array(GRADE_REPORT_PREFERENCE_INHERIT => $strinherit,
97                                                  '0' => '0',
98                                                  '1' => '1',
99                                                  '2' => '2',
100                                                  '3' => '3',
101                                                  '4' => '4',
102                                                  '5' => '5')));