MDL-15402 Fixed up the user personal repositories page so it fits in with user profile better (tabs, heading location etc)
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
$delete = optional_param('delete', 0, PARAM_INT);
|
||||
$sure = optional_param('sure', '', PARAM_ALPHA);
|
||||
$contextid = optional_param('contextid', 0, PARAM_INT);
|
||||
$usercourseid = optional_param('usercourseid', SITEID, PARAM_INT); // Extra: used for user context only
|
||||
|
||||
if ($edit){
|
||||
$pagename = 'repositoryinstanceedit';
|
||||
@@ -89,6 +90,15 @@
|
||||
|
||||
/// Display page header
|
||||
print_header($title, $fullname, $navigation);
|
||||
|
||||
if ($context->contextlevel == CONTEXT_USER) {
|
||||
if ( !$course = $DB->get_record('course', array('id'=>$usercourseid))) {
|
||||
print_error('invalidcourseid');
|
||||
}
|
||||
$currenttab = 'repositories';
|
||||
include($CFG->dirroot.'/user/tabs.php');
|
||||
}
|
||||
|
||||
print_heading($pagename);
|
||||
|
||||
$return = true;
|
||||
|
||||
Reference in New Issue
Block a user