You are here

function icon_field_feeds_processor_targets_alter in Icon API 7

Same name and namespace in other branches
  1. 8 modules/icon_field/icon_field.feeds.inc \icon_field_feeds_processor_targets_alter()

Implements hook_feeds_processor_targets_alter().

File

modules/icon_field/icon_field.feeds.inc, line 11
icon_field.feeds.inc Feeds mapping implementation for the Icon Field module.

Code

function icon_field_feeds_processor_targets_alter(&$targets, $entity_type, $bundle) {
  foreach (field_info_instances($entity_type, $bundle) as $name => $instance) {
    $info = field_info_field($name);
    if ($info['type'] == 'icon_field') {
      $targets[$name] = array(
        'name' => $instance['label'],
        'callback' => 'icon_field_feeds_set_target',
        'description' => $instance['description'],
        'summary_callback' => 'icon_field_feeds_summary_callback',
        'form_callback' => 'icon_field_feeds_form_callback',
      );
    }
  }
}