You are here

function ref_field_field_formatter_settings_summary in (Entity)Reference Field Synchronization 7

Implements hook_field_formatter_settings_summary().

File

./ref_field.module, line 319

Code

function ref_field_field_formatter_settings_summary($field, $instance, $view_mode) {
  $display = $instance['display'][$view_mode];
  $settings = $display['settings'];
  $summary = '';
  switch ($display['type']) {
    case 'ref_field_id':
    case 'ref_field_title':
      if ($display['settings']['linked']) {
        $summary .= t('Linked to content');
      }
      else {
        $summary .= t('Not linked to content');
      }
      break;
  }
  return $summary;
}