You are here

protected function og_CrumbsMultiPlugin_groups_overview::getGroupsOverviewPath in Crumbs, the Breadcrumbs suite 7.2

Same name and namespace in other branches
  1. 7 plugins/crumbs.og.2.inc \og_CrumbsMultiPlugin_groups_overview::getGroupsOverviewPath()

Overridable helper method to actually find the parent path, once we know it is a group node.

Parameters

stdClass $group_node: The node at this path, of which we know it is a group node.

Return value

array

1 call to og_CrumbsMultiPlugin_groups_overview::getGroupsOverviewPath()
og_CrumbsMultiPlugin_groups_overview::findParent__node_x in plugins/crumbs.og.2.inc
Find a parent path for node/%, if that node is a group.

File

plugins/crumbs.og.2.inc, line 184

Class

og_CrumbsMultiPlugin_groups_overview
Make $groups_overview_path the parent path for group nodes. The priorities can be configured per group node type.

Code

protected function getGroupsOverviewPath($group_node) {
  if (is_array($this->groupsOverviewPaths)) {
    if (isset($this->groupsOverviewPaths[$group_node->type])) {
      return array(
        $group_node->type => $this->groupsOverviewPaths[$group_node->type],
      );
    }

    // If the node type is not in the array, we return nothing!
  }
  else {
    return array(
      $group_node->type => $this->groupsOverviewPaths,
    );
  }
  return NULL;
}