You are here

function cer_entity_info in Corresponding Entity References 7.3

Implements hook_entity_info().

1 call to cer_entity_info()
cer_menu in ./cer.module
Implements hook_menu().

File

./cer.module, line 6

Code

function cer_entity_info() {
  $info = array(
    'cer' => array(
      'label' => t('CER Preset'),
      'entity class' => 'CerPreset',
      'controller class' => 'CerPresetController',
      'base table' => 'cer_preset',
      'label callback' => 'entity_class_label',
      'module' => 'cer',
      'fieldable' => TRUE,
      'entity keys' => array(
        'id' => 'pid',
        'name' => 'identifier',
        // This is the automatically generated export key.
        'label' => 'identifier',
      ),
      'admin ui' => array(
        'path' => 'admin/config/content/cer',
        'file' => 'cer.admin.inc',
        'controller class' => 'CerUIController',
      ),
      'exportable' => TRUE,
      'features controller class' => 'CerPresetFeaturesController',
      'access callback' => 'cer_access',
    ),
  );
  if (variable_get('cer_enable_field_ui', FALSE)) {
    $info['cer']['bundles']['cer']['admin']['path'] = $info['cer']['admin ui']['path'];
  }
  return $info;
}