Skip to content

Commit

Permalink
MDL-72154 calendar: Add manage subscription to export page breadcrumbs
Browse files Browse the repository at this point in the history
  • Loading branch information
mickhawkins committed Jul 21, 2021
1 parent 45fc997 commit dffe445
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions calendar/export.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,13 +89,18 @@
require_login($course, false);

$url = new moodle_url('/calendar/export.php', array('time' => $time));
$managesubscriptionsurl = new moodle_url('/calendar/managesubscriptions.php');

if ($action !== '') {
$url->param('action', $action);
}

if ($course !== NULL) {
$url->param('course', $course->id);

if ($course->id != SITEID) {
$managesubscriptionsurl->param('course', $course->id);
}
}
$PAGE->set_url($url);

Expand All @@ -110,6 +115,7 @@
}
$link = new moodle_url(CALENDAR_URL.'view.php', array('view'=>'upcoming', 'course'=>$calendar->courseid));
$PAGE->navbar->add(get_string('calendar', 'calendar'), calendar_get_link_href($link, 0, 0, 0, $time));
$PAGE->navbar->add(get_string('managesubscriptions', 'calendar'), $managesubscriptionsurl);
$PAGE->navbar->add($pagetitle);

$PAGE->set_title($course->shortname.': '.get_string('calendar', 'calendar').': '.$pagetitle);
Expand Down

0 comments on commit dffe445

Please sign in to comment.