You are here

function recipe_field_settings_form in Recipe 7.2

Implements hook_field_settings_form().

File

./recipe.module, line 435
Contains functions for Recipe node CRUD and display.

Code

function recipe_field_settings_form($field, $instance, $has_data) {
  $settings = $field['settings'];
  $form = array();
  switch ($field['type']) {
    case 'ingredient_reference':
      $form['ingredient_name_normalize'] = array(
        '#type' => 'radios',
        '#title' => t('Ingredient name normalization'),
        '#default_value' => $settings['ingredient_name_normalize'],
        '#options' => array(
          t('Leave as entered'),
          t('Convert to lowercase'),
        ),
        '#description' => t('When recipes are entered, should ingredient names be converted to lowercase?'),
        '#required' => TRUE,
      );
      break;
  }
  return $form;
}