You are here

function recipe_entity_extra_field_info in Recipe 8.2

Implements hook_entity_extra_field_info().

File

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

Code

function recipe_entity_extra_field_info() {
  $extra = [];
  $extra['node']['recipe']['display']['recipe_total_time'] = [
    'label' => t('Total time'),
    'description' => t('The total time required to make the recipe.'),
    'weight' => 4,
    'visible' => TRUE,
  ];
  $extra['node']['recipe']['display']['recipe_yield'] = [
    'label' => t('Yield'),
    'description' => t('The amount of food produced by the recipe.'),
    'weight' => 1,
    'visible' => TRUE,
  ];
  return $extra;
}