You are here

public function EntityLegalDocumentUIController::hook_menu in Entity Legal 7.2

Same name and namespace in other branches
  1. 7 entity_legal.entity_admin.inc \EntityLegalDocumentUIController::hook_menu()

Provides definitions for implementing hook_menu().

Overrides EntityDefaultUIController::hook_menu

File

./entity_legal.entity_admin.inc, line 14
Admin ui controllers for entity_legal entities.

Class

EntityLegalDocumentUIController
Legal Document entity ui controller.

Code

public function hook_menu() {
  $items = parent::hook_menu();

  // Remove title callbacks that cause bundle notices.
  foreach ($items as &$item) {
    if (isset($item['title callback']) && $item['title callback'] == 'entity_ui_get_action_title') {
      unset($item['title callback']);
      $item['title'] = ucfirst($item['title arguments'][0]);
    }
  }
  return $items;
}