function crm_core_relationship_ui_views_pre_render in CRM Core 7
Same name and namespace in other branches
- 8.3 modules/crm_core_relationship_ui/crm_core_relationship_ui.module \crm_core_relationship_ui_views_pre_render()
- 8 modules/crm_core_relationship_ui/crm_core_relationship_ui.module \crm_core_relationship_ui_views_pre_render()
- 8.2 modules/crm_core_relationship_ui/crm_core_relationship_ui.module \crm_core_relationship_ui_views_pre_render()
Implements hook_views_pre_render().
File
- modules/
crm_core_relationship_ui/ crm_core_relationship_ui.module, line 348
Code
function crm_core_relationship_ui_views_pre_render(&$view) {
if ($view->name == 'crm_relationships_by_contact') {
// Grabbing 1st view argument to avoid preview problems.
$contact_id = $view->args[0];
$contact = crm_core_contact_load($contact_id);
_crm_core_relationships_ui_breadcrmub($contact);
$view->build_info['title'] = t('Relationships for @contact_name', array(
'@contact_name' => $contact
->label(),
));
}
}