activity_enable == 'no') {
return true;
}
$group = $vars['entity'];
if (!$group) {
return true;
}
$all_link = elgg_view('output/url', array(
'href' => "groups/activity/$group->guid",
'text' => elgg_echo('link:view:all'),
));
$header = "$all_link";
$header .= '
' . elgg_echo('groups:activity') . '
';
elgg_push_context('widgets');
$db_prefix = elgg_get_config('dbprefix');
$content = elgg_list_river(array(
'limit' => 4,
'pagination' => false,
'joins' => array("join {$db_prefix}entities e1 on e1.guid = rv.object_guid"),
'wheres' => array("(e1.container_guid = $group->guid)"),
));
elgg_pop_context();
if (!$content) {
$content = '' . elgg_echo('groups:activity:none') . '
';
}
echo elgg_view_module('info', '', $content, array('header' => $header));