public function biblio_handler_field::pre_render in Bibliography Module 7
Same name and namespace in other branches
- 6.2 views/biblio_handler_field.inc \biblio_handler_field::pre_render()
- 6 views/biblio_handler_field.inc \biblio_handler_field::pre_render()
- 7.2 views/biblio_handler_field.inc \biblio_handler_field::pre_render()
Run before any fields are rendered.
This gives the handlers some time to set up before any handler has been rendered.
Parameters
array $values: An array of all objects returned from the query.
Overrides views_handler_field::pre_render
File
- views/
biblio_handler_field.inc, line 84
Class
Code
public function pre_render(&$values) {
foreach ($values as $result) {
// This converts values like 9999 or 9998 to "Submitted" and "In Press".
foreach (array(
'biblio_biblio_year',
'node_field_data_field_biblio__biblio_biblio_year',
) as $field) {
if (!empty($result->{$field})) {
$result->{$field} = _biblio_text_year($result->{$field});
}
}
}
return $values;
}