class ContentTypeGroupUIController in Content type groups 7.2
UI controller for Content Type Group.
Hierarchy
- class \EntityDefaultUIController
- class \ContentTypeGroupUIController
Expanded class hierarchy of ContentTypeGroupUIController
1 string reference to 'ContentTypeGroupUIController'
- content_type_groups_entity_info in ./
content_type_groups.module - Implements hook_entity_info().
File
- ./
content_type_groups.controller.inc, line 10 - Contains controllers and entity hooks for the content_type_group entity.
View source
class ContentTypeGroupUIController extends EntityDefaultUIController {
/**
* Overrides hook_menu() defaults.
*/
public function hook_menu() {
$items = parent::hook_menu();
$wildcard = '%content_type_group';
// List of all CTGs
$items[$this->path] = array(
'title' => 'Content type groups',
'description' => 'Manage content type groups',
'page callback' => 'content_type_groups_admin',
'file' => 'content_type_groups.admin.inc',
'file path' => drupal_get_path('module', $this->entityInfo['module']),
'access arguments' => array(
'administer content types',
),
// This permission is good enough for now. Does it really need a separate permission, honestly?
'type' => MENU_LOCAL_ACTION,
);
// Add new CTG
$items[$this->path . '/add'] = array(
'title' => 'Add content type group',
'description' => 'Add a new content type group',
'page callback' => 'content_type_groups_admin_add_page',
'file' => 'content_type_groups.admin.inc',
'file path' => drupal_get_path('module', $this->entityInfo['module']),
'type' => MENU_LOCAL_ACTION,
'access arguments' => array(
'administer content types',
),
);
// Edit existing CTG
$items[$this->path . '/' . $wildcard . '/edit'] = array(
'title' => 'Edit content type group',
'description' => 'Edit an existing content type group',
'load arguments' => array(
TRUE,
),
'page callback' => 'entity_ui_get_form',
'page arguments' => array(
'content_type_group',
4,
),
'file' => 'content_type_groups.admin.inc',
'file path' => drupal_get_path('module', $this->entityInfo['module']),
'access arguments' => array(
'administer content types',
),
);
// Delete existing CTG
$items[$this->path . '/' . $wildcard . '/delete'] = array(
'title' => 'Delete content type group',
'description' => 'Delete an existing content type group',
'load arguments' => array(
TRUE,
),
'page callback' => 'drupal_get_form',
'page arguments' => array(
'content_type_group_form_delete_confirm',
4,
),
'file' => 'content_type_groups.admin.inc',
'file path' => drupal_get_path('module', $this->entityInfo['module']),
'access arguments' => array(
'administer content types',
),
);
return $items;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ContentTypeGroupUIController:: |
public | function |
Overrides hook_menu() defaults. Overrides EntityDefaultUIController:: |
|
EntityDefaultUIController:: |
protected | property | ||
EntityDefaultUIController:: |
protected | property | ||
EntityDefaultUIController:: |
protected | property | ||
EntityDefaultUIController:: |
public | property | Defines the number of entries to show per page in overview table. | |
EntityDefaultUIController:: |
public | function | Applies an operation to the given entity. | |
EntityDefaultUIController:: |
public | function | Entity submit builder invoked via entity_ui_form_submit_build_entity(). | |
EntityDefaultUIController:: |
public | function | Provides definitions for implementing hook_forms(). | |
EntityDefaultUIController:: |
protected | function | Returns the operation count for calculating colspans. | |
EntityDefaultUIController:: |
public | function | Builds the operation form. | |
EntityDefaultUIController:: |
public | function | Operation form submit callback. | 1 |
EntityDefaultUIController:: |
public | function | Operation form validation callback. | |
EntityDefaultUIController:: |
public | function | Builds the entity overview form. | |
EntityDefaultUIController:: |
public | function | Overview form submit callback. | |
EntityDefaultUIController:: |
public | function | Overview form validation callback. | |
EntityDefaultUIController:: |
public | function | Generates the render array for a overview table for arbitrary entities matching the given conditions. | |
EntityDefaultUIController:: |
protected | function | Generates the table headers for the overview table. | |
EntityDefaultUIController:: |
protected | function | Generates the row for the passed entity and may be overridden in order to customize the rows. | |
EntityDefaultUIController:: |
public | function |