|
@@ 73-87 (lines=15) @@
|
| 70 |
|
$collections = get_data($query); |
| 71 |
|
} |
| 72 |
|
|
| 73 |
|
if (!empty($collections)) { |
| 74 |
|
|
| 75 |
|
// iterate through collections and add tabs as necessary |
| 76 |
|
foreach ($collections as $collection) { |
| 77 |
|
// we need to create a tab |
| 78 |
|
$tab = array( |
| 79 |
|
'name' => "collection:$collection->id", |
| 80 |
|
'text' => $collection->name, |
| 81 |
|
'href' => "activity_tabs/collection/{$collection->id}/" . elgg_get_friendly_title($collection->name), |
| 82 |
|
'selected' => $filter_context == 'collection_' . $collection->id, |
| 83 |
|
'priority' => $priority + (int) $tabs['collection']["$collection->id"]['priority'], |
| 84 |
|
); |
| 85 |
|
elgg_register_menu_item('filter', $tab); |
| 86 |
|
} |
| 87 |
|
} |
| 88 |
|
|
| 89 |
|
if (!empty($group_ids)) { |
| 90 |
|
$group_ids_in = implode(',', $group_ids); |
|
@@ 97-108 (lines=12) @@
|
| 94 |
|
$groups = get_data($query); |
| 95 |
|
} |
| 96 |
|
|
| 97 |
|
if (!empty($groups)) { |
| 98 |
|
foreach ($groups as $group) { |
| 99 |
|
$tab = array( |
| 100 |
|
'name' => "group:$group->guid", |
| 101 |
|
'text' => $group->name, |
| 102 |
|
'href' => "activity_tabs/group/{$group->guid}/" . elgg_get_friendly_title($group->name), |
| 103 |
|
'selected' => $filter_context == 'group_' . $group->guid, |
| 104 |
|
'priority' => $priority + (int) $tabs['group']["$group->guid"]['priority'], |
| 105 |
|
); |
| 106 |
|
} |
| 107 |
|
elgg_register_menu_item('filter', $tab); |
| 108 |
|
} |
| 109 |
|
|
| 110 |
|
if( strpos(elgg_get_site_entity()->name, 'collab') == false ){ |
| 111 |
|
$tab = array( |