protected function views_aggregator_plugin_style_table::set_aggregated_group_values in Views Aggregator Plus 7
Write the aggregated results back into the View's rendered results.
Parameters
array $groups: An array of groups, indexed by group name.
array $values: An array of value arrays, indexed by field name first and group second.
1 call to views_aggregator_plugin_style_table::set_aggregated_group_values()
- views_aggregator_plugin_style_table::pre_render in views/
views_aggregator_plugin_style_table.inc - Overrides pre_render().
File
Class
- views_aggregator_plugin_style_table
- Style plugin to render each item as a row in a table.
Code
protected function set_aggregated_group_values($groups, $values) {
$field_handlers = $this->view->field;
foreach ($this->options['info'] as $field_name => $options) {
foreach ($groups as $group => $rows) {
if ($group != 'column' && isset($values[$field_name][$group])) {
foreach ($rows as $num => $row) {
$separator = $this->options['info'][$field_name]['aggr_par'];
$this
->set_cell($field_handlers[$field_name], $num, $values[$field_name][$group], $separator);
// Only need to set on the first member of the group.
break;
}
}
}
}
}