Fixed import groups page layout and navigation

While working on MDL-26252, I realized that group/import.php page had
issues with layout. Side blocks were missing and the breadcrumb navigation
broken (leading to a non-existing script and having the link to the
current course duplicated).

This patch sets the standard layout for the page so that block are
displayed, fixes the page position in the navigation tree and the
breadcrumb navigation.
This commit is contained in:
David Mudrak 2011-02-03 12:28:28 +01:00
parent b74ceb3ff5
commit f672d6a0f5

View file

@ -41,13 +41,11 @@ require_capability('moodle/course:managegroups', $context);
$strimportgroups = get_string('importgroups', 'core_group');
/// Print the header
$PAGE->navbar->add($course->shortname, new moodle_url('/course/view.php', array('id'=>$course->id)));
$PAGE->navbar->add(get_string('import'), new moodle_url('/course/import.php', array('id'=>$course->id)));
$PAGE->navbar->add($strimportgroups);
navigation_node::override_active_url(new moodle_url('/group/index.php', array('id' => $course->id)));
$PAGE->set_title("$course->shortname: $strimportgroups");
$PAGE->set_heading($course->fullname);
$PAGE->set_pagelayout('standard');
$returnurl = new moodle_url('/group/index.php', array('id'=>$id));