Permalink
Browse files

Merge branch 'wip-MDL-36215-m23' of git://github.com/samhemelryk/mood…

…le into MOODLE_23_STABLE
  • Loading branch information...
2 parents 180e1b2 + 459bb94 commit c6014dccd99ce980fd1f10c5577795713890e618 @stronk7 stronk7 committed Mar 5, 2013
Showing with 4 additions and 1 deletion.
  1. +4 −1 lib/navigationlib.php
View
@@ -2602,16 +2602,19 @@ public function add_course_essentials($coursenode, stdClass $course) {
$participants = $coursenode->add(get_string('participants'), new moodle_url('/user/index.php?id='.$course->id), self::TYPE_CONTAINER, get_string('participants'), 'participants');
$currentgroup = groups_get_course_group($course, true);
if ($course->id == $SITE->id) {
+ $filtervar = 'courseid';
$filterselect = '';
} else if ($course->id && !$currentgroup) {
+ $filtervar = 'courseid';
$filterselect = $course->id;
} else {
+ $filtervar = 'groupid';
$filterselect = $currentgroup;
}
$filterselect = clean_param($filterselect, PARAM_INT);
if (($CFG->bloglevel == BLOG_GLOBAL_LEVEL or ($CFG->bloglevel == BLOG_SITE_LEVEL and (isloggedin() and !isguestuser())))
and has_capability('moodle/blog:view', get_context_instance(CONTEXT_SYSTEM))) {
- $blogsurls = new moodle_url('/blog/index.php', array('courseid' => $filterselect));
+ $blogsurls = new moodle_url('/blog/index.php', array($filtervar => $filterselect));
$participants->add(get_string('blogscourse','blog'), $blogsurls->out());
}
if (!empty($CFG->enablenotes) && (has_capability('moodle/notes:manage', $this->page->context) || has_capability('moodle/notes:view', $this->page->context))) {

0 comments on commit c6014dc

Please sign in to comment.