Tidy up pages matching new menu items

Bug #1792263 reported by Robert Lyon
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Fix Released
High
Robert Lyon

Bug Description

This patch will fix up things that were missed by https://bugs.launchpad.net/mahara/+bug/1782954

To get it better ready for https://bugs.launchpad.net/mahara/+bug/1792252

Robert Lyon (robertl-9)
Changed in mahara:
milestone: none → 18.10.0
importance: Undecided → High
assignee: nobody → Robert Lyon (robertl-9)
status: New → In Progress
Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "master" branch: https://reviews.mahara.org/9130

Revision history for this message
Robert Lyon (robertl-9) wrote :

Includes converting the RESUME_SUBPAGE to more generic MENUITEM_SUBPAGE

And getting the group subnav to use the same MENUITEM_SUBPAGE structure rather than relying on matching MENUITEM path

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/9130
Committed: https://git.mahara.org/mahara/mahara/commit/b28387e55d68184665f26d3341f33dc21774524b
Submitter: Robert Lyon (<email address hidden>)
Branch: master

commit b28387e55d68184665f26d3341f33dc21774524b
Author: Robert Lyon <email address hidden>
Date: Thu Sep 13 13:40:01 2018 +1200

Bug 1792263: Fixing up some nav menu mapping

Includes converting the RESUME_SUBPAGE to MENUITEM_SUBPAGE

And getting the group subnav to use the same structure

behatnotneeded

Change-Id: Ia3bcb02030b5fe4deae47f20ff497dda55667d95
Signed-off-by: Robert Lyon <email address hidden>

Robert Lyon (robertl-9)
Changed in mahara:
status: In Progress → Fix Committed
Revision history for this message
Robert Lyon (robertl-9) wrote :

Now we have merged the patch it means the group arrow-bar menu items are handled slightly differently.

Before:
If on a group page that had for example:

define('MENUITEM', 'groups/members');

This would highlight the 'members' tab in the arrow bar by matching on the 'path' value of the groups menu by looking for path beginning with 'groups/'

But that wouldn't highlight the correct main nav submenu item

So, now we have 2 definitions:

define('MENUITEM', 'engage/mygroups');
define('MENUITEM_SUBPAGE', 'members');

so the group tab is highlighted based on 'MENUITEM_SUBPAGE' value and this matches to the key of the group menu to highlight arrow-bar tab

and now we can specify the correct main nav submenu to highlighted as well

This makes it more in line with how resume arrow-bar works

In case you have sites that call custom 'group_tabs()' functions just make sure the page it calls has

define('MENUITEM_SUBPAGE', 'keyname');

where 'keyname' matches the related key of the group menu item array

Changed in mahara:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.