You are here

function merci_inventory_entity_info in MERCI (Manage Equipment Reservations, Checkout and Inventory) 7.3

Implements hook_entity_info().

File

merci_inventory/merci_inventory.module, line 102

Code

function merci_inventory_entity_info() {
  $info['merci_inventory'] = array(
    'label' => t('Merci inventory'),
    'plural label' => t('Merci inventory'),
    'description' => t('An entity type used to inventory MERCI resources.'),
    //'entity_class' => 'MerciInventoryEntity',
    'entity_class' => 'Entity',
    'controller class' => 'EntityAPIController',
    'base table' => 'merci_inventory',
    'fieldable' => TRUE,
    'access callback' => 'merci_inventory_access_callback',
    'entity keys' => array(
      'id' => 'inventory_id',
    ),
    //'label callback' => 'entity_class_label',

    //'uri callback' => 'entity_class_uri',
    'admin ui' => array(
      'path' => MERCI_INVENTORY_TYPE_PATH,
      'controller class' => 'EntityDefaultUIController',
    ),
    'bundles' => array(
      'merci_inventory' => array(
        'label' => t('Merci inventory'),
        // Provide a default administration path for Field UI, but not if 'admin'
        // has been explicitly set to NULL.
        'admin' => array(
          'path' => MERCI_INVENTORY_TYPE_PATH,
        ),
      ),
    ),
    //'exportable' => TRUE,
    'module' => 'merci_inventory',
  );
  return $info;
}