You are here

function popup_onload_entity_info in Popup On Load 7

Implements hook_entity_info().

File

./popup_onload.module, line 325
Contains main popup_onload hooks and functions.

Code

function popup_onload_entity_info() {
  $info['popup_onload'] = [
    'label' => 'Popup On Load',
    'entity class' => 'PopupOnLoad',
    'controller class' => 'PopupOnLoadController',
    'base table' => 'popup_onload',
    'fieldable' => TRUE,
    'entity keys' => [
      'id' => 'popup_id',
      'bundle' => 'bundle_type',
      'label' => 'name',
      'language' => 'language',
    ],
    'bundle keys' => [
      'bundle' => 'bundle_type',
    ],
    'bundles' => [
      'popup_onload_basic' => [
        'label' => 'Popup On Load',
        'admin' => [
          'path' => 'admin/structure/popup_onload/manage',
          'access arguments' => [
            'administer popup_onload entities',
          ],
        ],
      ],
    ],
    'view modes' => [
      'full' => [
        'label' => t('Full content'),
        'custom settings' => TRUE,
      ],
    ],
    'access callback' => 'popup_onload_access',
    'module' => 'popup_onload',
    'admin ui' => [
      'path' => 'admin/content/popup_onload',
      'file' => 'popup_onload.admin.inc',
    ],
  ];
  return $info;
}