diff --git a/modules/groups/groups_reports/groups_reports.module b/modules/groups/groups_reports/groups_reports.module
index 9bc32fa..49d278d 100644
--- a/modules/groups/groups_reports/groups_reports.module
+++ b/modules/groups/groups_reports/groups_reports.module
@@ -499,7 +499,12 @@ function groups_reports_groups_status_report_form($form = array(), &$form_state)
module_load_include('inc', 'field_group_location', 'field_group_lookup');
$continents = _continent_get_predefined_list();
$rows = groups_reports_group_status_report();
+ $totals = new stdClass();
+ $totals->points = 0;
+ $totals->max = 0;
foreach ($rows as $row) {
+ $totals->points += $row->status_point;
+ $totals->max += $row->status_point_max;
$organizers = '';
foreach ($row->organizers as $organizer) {
$organizers .= l(sprintf('%s <%s>', $organizer['name'], $organizer['email']), 'user/'.$organizer['uid']).'
';
@@ -540,6 +545,12 @@ function groups_reports_groups_status_report_form($form = array(), &$form_state)
'class' => array('col-messages')),
);
}
+ $total_percents = (int)(($totals->points / $totals->max) * 100+.5);;
+ $form['totals'] = array(
+ '#prefix' => '