Commit ca46a0af authored by Richard Mansfield's avatar Richard Mansfield
Browse files

Use string keys in menu array to make it easily hackable by local_main_nav_update function


Signed-off-by: default avatarRichard Mansfield <richard.mansfield@catalyst.net.nz>
parent 4f98e0aa
......@@ -61,7 +61,7 @@ class PluginArtefactBlog extends PluginArtefact {
$tab['url'] = 'artefact/blog/view/';
$tab['title'] = get_string('blog', 'artefact.blog');
}
return array($tab);
return array('content/blogs' => $tab);
}
public static function get_cron() {
......
......@@ -49,13 +49,13 @@ class PluginArtefactFile extends PluginArtefact {
public static function menu_items() {
return array(
array(
'content/files' => array(
'path' => 'content/files',
'url' => 'artefact/file/',
'title' => get_string('Files', 'artefact.file'),
'weight' => 30,
),
array(
'content/profileicons' => array(
'path' => 'content/profileicons',
'url' => 'artefact/file/profileicons.php',
'title' => get_string('profileicons', 'artefact.file'),
......
......@@ -92,7 +92,7 @@ class PluginArtefactInternal extends PluginArtefact {
public static function menu_items() {
return array(
array(
'content/profile' => array(
'path' => 'content/profile',
'url' => 'artefact/internal/',
'title' => get_string('profile', 'artefact.internal'),
......
......@@ -45,7 +45,7 @@ class PluginArtefactPlans extends PluginArtefact {
public static function menu_items() {
return array(
array(
'content/plans' => array(
'path' => 'content/plans',
'url' => 'artefact/plans/',
'title' => get_string('Plans', 'artefact.plans'),
......
......@@ -59,7 +59,7 @@ class PluginArtefactResume extends Plugin {
public static function menu_items() {
return array(
array(
'content/resume' => array(
'path' => 'content/resume',
'title' => get_string('resume', 'artefact.resume'),
'url' => 'artefact/resume/',
......
......@@ -378,7 +378,7 @@ EOF;
public static function menu_items() {
return array(
array(
'groups/topics' => array(
'path' => 'groups/topics',
'url' => 'group/topics.php',
'title' => get_string('Topics', 'interaction.forum'),
......
......@@ -1951,83 +1951,83 @@ function institutional_admin_nav() {
function mahara_standard_nav() {
$exportenabled = plugins_installed('export');
$menu = array(
array(
'home' => array(
'path' => '',
'url' => '',
'title' => get_string('dashboard', 'view'),
'weight' => 10,
'accesskey' => 'h',
),
array(
'content' => array(
'path' => 'content',
'url' => 'artefact/internal/', // @todo possibly do path aliasing and dispatch?
'title' => get_string('mycontent'),
'weight' => 20,
),
array(
'myportfolio' => array(
'path' => 'myportfolio',
'url' => 'view/',
'title' => get_string('myportfolio'),
'weight' => 30,
'accesskey' => 'v',
),
array(
'myportfolio/views' => array(
'path' => 'myportfolio/views',
'url' => 'view/',
'title' => get_string('Views', 'view'),
'weight' => 10,
),
array(
'myportfolio/share' => array(
'path' => 'myportfolio/share',
'url' => 'view/share.php',
'title' => get_string('share', 'view'),
'weight' => 30,
),
array(
'myportfolio/export' => array(
'path' => 'myportfolio/export',
'url' => 'export/',
'title' => get_string('Export', 'export'),
'weight' => 70,
'ignore' => !$exportenabled,
),
array(
'myportfolio/collection' => array(
'path' => 'myportfolio/collection',
'url' => 'collection/',
'title' => get_string('Collections', 'collection'),
'weight' => 20,
),
array(
'groups' => array(
'path' => 'groups',
'url' => 'group/mygroups.php',
'title' => get_string('groups'),
'weight' => 40,
'accesskey' => 'g',
),
array(
'groups/mygroups' => array(
'path' => 'groups/mygroups',
'url' => 'group/mygroups.php',
'title' => get_string('mygroups'),
'weight' => 10,
),
array(
'groups/find' => array(
'path' => 'groups/find',
'url' => 'group/find.php',
'title' => get_string('findgroups'),
'weight' => 20,
),
array(
'groups/myfriends' => array(
'path' => 'groups/myfriends',
'url' => 'user/myfriends.php',
'title' => get_string('myfriends'),
'weight' => 30,
),
array(
'groups/findfriends' => array(
'path' => 'groups/findfriends',
'url' => 'user/find.php',
'title' => get_string('findfriends'),
'weight' => 40,
),
array(
'groups/views' => array(
'path' => 'groups/views',
'url' => 'view/sharedviews.php',
'title' => get_string('sharedviews', 'view'),
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment