If you check any of the available admin page of the taxonomy term group (taxonomy/term/%tid/group) - "Add people", "People", "Permissions" or "Roles", then you can see that a breadcrumb item "Group" has a broken path - "taxonomy_term/%tid/group" instead of "taxonomy/term/%tid/group". The reason is in wrong path functionality which is currently working fine for nodes and users but not for taxonomy terms - "$group_type/$gid/group".
Here is a patch which correct a breadcrumbs functionality and should work for all entity types

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

RoySegall’s picture

There white spaces in your path so i rolled it. I can approve this but would like that others to review it.

NofarG’s picture

Issue summary: View changes
Status: Needs review » Reviewed & tested by the community

@RoySegall 's patch (#1) - reviewed, tested and looks great.

amitaibu’s picture

  1. +++ b/og_ui/og_ui.admin.inc
    @@ -277,11 +279,14 @@ function og_ui_add_users_submit($form, &$form_state) {
    +  ¶
    

    Trailing spaces.

  2. +++ b/og_ui/og_ui.admin.inc
    @@ -366,7 +371,9 @@ function og_ui_edit_membership_submit($form, &$form_state) {
    +  $group = entity_load_single($group_type, $gid);
    +  $group_uri = entity_uri($group_type, $group);
    +  og_set_breadcrumb($group_type, $gid, array(l(t('Group'), "{$group_uri['path']}/group")));
    

    If we repeat this several times, why not move logic into og_set_breadcrumb()?

NofarG’s picture

Assigned: Unassigned » NofarG
Status: Reviewed & tested by the community » Needs review
FileSize
780 bytes

Here's a new patch, modifying og_set_breadcrumb() instead of modifying everything else.

Dimitrius’s picture

The patch from the #4 doesn't work for me when an alias for the "taxonomy/term/%tid" is used. Seems that it could work only with a Sub-path URL Aliases module, as for a taxonomy term group I'm getting a link with a term page alias which doesn't work - "%term_alias/group".

jacob.embree’s picture

Assigned: NofarG » Unassigned

#4 indeed breaks down when taxonomy term paths are aliased. In og_ui_menu() taxonomy terms are treated specially, so I make taxonomy terms a special case in this patch.

jacob.embree’s picture