public function FeedsEntityProcessor::configForm in Feeds entity processor 7
Overrides parent::configForm().
File
- src/
FeedsEntityProcessor.inc, line 202 - Contains FeedsEntityProcessor.
Class
- FeedsEntityProcessor
- Creates entities from feed items.
Code
public function configForm(&$form_state) {
$form = parent::configForm($form_state);
$form['bundle']['#title'] = $this
->bundleLabel();
$form['values'] = array(
'#type' => 'fieldset',
'#title' => t('Default values'),
'#tree' => TRUE,
'#description' => t('Most of the values below can be overriden by mapping a value.'),
);
$entity_info = $this
->entityInfo();
$label_plural = $entity_info['label plural'];
$form['input_format']['#description'] = t('Select the default input format for the %entity to be created.', array(
'%entity' => $label_plural,
));
foreach ($this
->entityProperties() as $name => $property) {
$default = isset($this->config['values'][$name]) ? $this->config['values'][$name] : NULL;
$plugin = feeds_entity_processor_plugin($name, $property, $this
->entityWrapper(), $this);
$form['values'][$name] = $plugin
->getFormField($form, $form_state, $default);
}
return $form;
}