function _civicrm_entity_link_addformatters in CiviCRM Entity 7.2
Utility function to provide fields with a link formatter
Parameters
$entity_type:
$link_fields:
$fields:
1 call to _civicrm_entity_link_addformatters()
- civicrm_entity_ds_fields_info in ./
civicrm_entity.module - Implements hook_ds_fields_info().
File
- ./
civicrm_entity.ds.inc, line 126
Code
function _civicrm_entity_link_addformatters($entity_type, $link_fields, &$fields) {
foreach ($link_fields as $link_field) {
$fields[$entity_type][$link_field['link_field']]['properties']['formatters'] = array(
'default' => 'Default',
'civicrm_link' => 'Link',
);
$fields[$entity_type][$link_field['link_field']]['properties']['link_entity'] = $link_field['target'];
}
}