You are here

function queue_ui_menu in Queue UI 7.2

Same name and namespace in other branches
  1. 6 queue_ui.module \queue_ui_menu()
  2. 7 queue_ui.module \queue_ui_menu()

Implements hook_menu().

File

./queue_ui.module, line 24
queue_ui.module

Code

function queue_ui_menu() {
  $items[QUEUE_UI_BASE] = array(
    'title' => 'Queue manager',
    'description' => 'View and manage queues',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'queue_ui_page',
    ),
    'access arguments' => array(
      'admin queue_ui',
    ),
    'file' => 'queue_ui.pages.inc',
  );
  $items[QUEUE_UI_BASE . '/inspect/%'] = array(
    'title' => 'View Queue: @name',
    'title arguments' => array(
      '@name' => 5,
    ),
    'page callback' => 'queue_ui_view_queue',
    'page arguments' => array(
      5,
    ),
    'access arguments' => array(
      'admin queue_ui',
    ),
    'type' => MENU_NORMAL_ITEM,
    'file' => 'queue_ui.forms.inc',
  );

  // View item callback for Queue UI.
  $items[QUEUE_UI_BASE . '/%/view/%queue_ui_queue_item'] = array(
    'title' => 'View Queue Item',
    'description' => 'View the details of an individual queue item',
    'page callback' => 'queue_ui_view_queue_item',
    'page arguments' => array(
      4,
      6,
    ),
    'access arguments' => array(
      'admin queue_ui',
    ),
    'type' => MENU_NORMAL_ITEM,
    'file' => 'queue_ui.forms.inc',
  );

  // Release item callback for Queue UI.
  $items[QUEUE_UI_BASE . '/%/release/%queue_ui_queue_item'] = array(
    'title' => 'Release items',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'queue_ui_release_item_form',
      4,
      6,
    ),
    'access arguments' => array(
      'admin queue_ui',
    ),
    'file' => 'queue_ui.forms.inc',
  );

  // Delete item callback for Queue UI.
  $items[QUEUE_UI_BASE . '/%/delete/%queue_ui_queue_item'] = array(
    'title' => 'Delete items',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'queue_ui_delete_item_form',
      4,
      6,
    ),
    'access arguments' => array(
      'admin queue_ui',
    ),
    'file' => 'queue_ui.forms.inc',
  );
  return $items;
}