function crm_core_relationship_form_after_build in CRM Core 8.3
Same name and namespace in other branches
- 8 modules/crm_core_relationship_ui/crm_core_relationship_ui.pages.inc \crm_core_relationship_form_after_build()
- 8.2 modules/crm_core_relationship_ui/crm_core_relationship_ui.pages.inc \crm_core_relationship_form_after_build()
- 7 modules/crm_core_relationship_ui/crm_core_relationship_ui.pages.inc \crm_core_relationship_form_after_build()
After build callback for crm_activity_form.
Set proper page title.
1 string reference to 'crm_core_relationship_form_after_build'
- crm_core_relationship_form in modules/
crm_core_relationship_ui/ crm_core_relationship_ui.pages.inc - Form builder for CRM Activity forms.
File
- modules/
crm_core_relationship_ui/ crm_core_relationship_ui.pages.inc, line 187 - CRM Core Relationship UI Pages.
Code
function crm_core_relationship_form_after_build(&$form, &$form_state) {
if ($form_state['op'] == 'add') {
$relation = $form_state['relation'];
$relation_type = RelationType::load($relation->relation_type);
drupal_set_title(t('Add new relationship @label', [
'@label' => $relation_type
->label(),
]));
}
return $form;
}