MDL-54698 message: add preferences pages to breadcrumbs

This commit is contained in:
Ryan Wyllie 2016-08-16 07:03:58 +00:00 committed by Mark Nelson
parent 8c125526f1
commit 14501b1c13
2 changed files with 5 additions and 3 deletions

View File

@ -4535,8 +4535,10 @@ class settings_navigation extends navigation_node {
// Messaging.
if (($currentuser && has_capability('moodle/user:editownmessageprofile', $systemcontext)) || (!isguestuser($user) &&
has_capability('moodle/user:editmessageprofile', $usercontext) && !is_primary_admin($user->id))) {
$url = new moodle_url('/message/edit.php', array('id'=>$user->id));
$useraccount->add(get_string('messaging', 'message'), $url, self::TYPE_SETTING);
$messagingurl = new moodle_url('/message/edit.php', array('id' => $user->id));
$notificationsurl = new moodle_url('/message/notificationpreferences.php', array('id' => $user->id));
$useraccount->add(get_string('messagepreferences', 'message'), $messagingurl, self::TYPE_SETTING);
$useraccount->add(get_string('notificationpreferences', 'message'), $notificationsurl, self::TYPE_SETTING);
}
// Blogs.

View File

@ -73,7 +73,7 @@ if ($user->id == $USER->id) {
}
/// Display page header
$strmessaging = get_string('messaging', 'message');
$strmessaging = get_string('messagepreferences', 'message');
$PAGE->set_title($strmessaging);
$PAGE->set_heading(fullname($user));