You are here

function recipe_content_extra_fields in Recipe 6

Implementation of hook_content_extra_fields(). Allow the meta tags fields to be sorted in the node edit forms.

1 call to recipe_content_extra_fields()
recipe_content_extra_field_weight in ./recipe.module

File

./recipe.module, line 1757
recipe.module - share recipes

Code

function recipe_content_extra_fields($type_name) {
  if ($type_name != 'recipe') {
    return;
  }
  $extra = array();
  $extra['summary_box'] = array(
    'label' => t('Summary Box'),
    'description' => t('Recipe module form.'),
    'weight' => -6,
  );
  $extra['body'] = array(
    'label' => t('Description'),
    'description' => t('Recipe module form.'),
    'weight' => -5,
  );
  $extra['yield'] = array(
    'label' => t('Yield'),
    'description' => t('Recipe module form.'),
    'weight' => -4,
  );
  $extra['yield_unit'] = array(
    'label' => t('Yield units'),
    'description' => t('Recipe module form.'),
    'weight' => -4,
  );
  $extra['ingredients'] = array(
    'label' => t('Ingredients'),
    'description' => t('Recipe module form.'),
    'weight' => -3,
  );
  $extra['instructions'] = array(
    'label' => t('Instructions'),
    'description' => t('Recipe module form.'),
    'weight' => -2,
  );
  $extra['notes'] = array(
    'label' => t('Additional notes'),
    'description' => t('Recipe module form.'),
    'weight' => -2,
  );
  $extra["source"] = array(
    'label' => t('Source'),
    'description' => t('Recipe module form.'),
    'weight' => -2,
  );
  $extra['preptime'] = array(
    'label' => t('Preparation time'),
    'description' => t('Recipe module form.'),
    'weight' => -1,
  );
  return $extra;
}