mirror of
https://github.com/moodle/moodle.git
synced 2025-04-25 10:26:17 +02:00
gradebook MDL-25112 made /grade/edit/outcome/edit.php set page context before trying to initialize an mform
This commit is contained in:
parent
0d731457f7
commit
6431268854
@ -95,6 +95,11 @@ if ($id) {
|
||||
$outcome_rec->courseid = 0;
|
||||
}
|
||||
|
||||
if (!$courseid) {
|
||||
require_once $CFG->libdir.'/adminlib.php';
|
||||
admin_externalpage_setup('scales');
|
||||
}
|
||||
|
||||
// default return url
|
||||
$gpr = new grade_plugin_return();
|
||||
$returnurl = $gpr->get_return_url('index.php?id='.$courseid);
|
||||
@ -148,8 +153,6 @@ if ($mform->is_cancelled()) {
|
||||
if ($courseid) {
|
||||
print_grade_page_head($courseid, 'outcome', 'edit', $heading);
|
||||
} else {
|
||||
require_once $CFG->libdir.'/adminlib.php';
|
||||
admin_externalpage_setup('outcomes');
|
||||
echo $OUTPUT->header();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user