-
Bug
-
Resolution: Won't Fix
-
Major
-
None
-
1.9
-
None
-
MOODLE_19_STABLE
While the pull-down menu to get to new gradebook forms in 1.9 show that flexible, the tabs of earlier version were intuitive and went to what was important and common. I recommend adding them back and here is the patch:
1. Create /grade/tabs.php with this content:
<?php
$row = $tabs = array();
$tabcontext = get_context_instance(CONTEXT_COURSE, $COURSE->id);
if (has_capability('moodle/grade:manage',$tabcontext ) ||
has_capability('moodle/grade:edit', $tabcontext) ||
has_capability('gradereport/grader:view', $tabcontext))
?>
2. After print_heading(get_string('categoriesedit', 'grades')); in /grade/edit/tree/index.php, add:
$currenttab = 'categoriesanditems';
include($CFG->dirroot.'/grade/tabs.php');
3. Replace the line require('tabs.php'); in grade/report/grader/index.php with
$currenttab = 'graderreport';
include($CFG->dirroot.'/grade/tabs.php');
4. Replace line include('tab.php'); in grade/report/grader/preference.php with
$currenttab = 'preferences';
include($CFG->dirroot.'/grade/tabs.php');
5. After print_grade_plugin_selector($courseid, 'report', 'user'); in /grade/report/user/index.php add
// Add tabs
$currenttab = 'report';
include($CFG->dirroot.'/grade/tabs.php');
Note that I use include rather than require because it does not give a fatal error when tabs.php fails to load.
- will help resolve
-
MDL-18004 Tabs navigation for gradebook
-
- Closed
-