You are here

function flipping_book_reference_field_info in Flipping Book 7

Implements hook_field_info().

File

./flipping_book_reference.module, line 26
Defines a field type for referencing one flipping_book from a node.

Code

function flipping_book_reference_field_info() {
  return array(
    'flipping_book_reference' => array(
      'label' => t('Flipping Book reference'),
      'description' => t('This field stores the ID of a related flipping_book as an integer value.'),
      'settings' => array(
        'referenceable_types' => array(),
        'view' => array(
          'view_name' => '',
          'display_name' => '',
          'args' => array(),
        ),
      ),
      // It probably make more sense to have the referenceable types be
      // per-field than per-instance
      // 'instance settings' => array('referenceable_types' => array()),
      'default_widget' => 'options_select',
      'default_formatter' => 'flipping_book_reference_default',
      // Support hook_entity_property_info() from contrib "Entity API".
      'property_type' => 'node',
      // Support default token formatter for field tokens.
      'default_token_formatter' => 'flipping_book_reference_plain',
    ),
  );
}