You are here

function elasticsearch_watchdog_menu in Elasticsearch Connector 7

Same name and namespace in other branches
  1. 7.5 modules/elasticsearch_watchdog/elasticsearch_watchdog.module \elasticsearch_watchdog_menu()
  2. 7.2 modules/elasticsearch_watchdog/elasticsearch_watchdog.module \elasticsearch_watchdog_menu()

Implements hook_menu().

File

modules/elasticsearch_watchdog/elasticsearch_watchdog.module, line 32
Created on Jan 06, 2014

Code

function elasticsearch_watchdog_menu() {
  $settings_path = elasticsearch_connector_main_settings_path();
  $items[$settings_path . '/watchdog'] = array(
    'title' => 'Elasticsearch Watchdog Settings',
    'description' => 'Showing all available clusters',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'elasticsearch_watchdog_settings',
    ),
    'access arguments' => array(
      'administer elasticsearch connector',
    ),
    'file' => 'elasticsearch_watchdog.admin.inc',
  );
  $items['admin/reports/elasticlog'] = array(
    'title' => 'Recent log messages',
    'description' => 'View events that have recently been logged.',
    'page callback' => 'elasticsearch_watchdog_overview',
    'access arguments' => array(
      'access site reports',
    ),
    'file' => 'elasticsearch_watchdog.admin.inc',
  );
  $items['admin/reports/elastic-page-not-found'] = array(
    'title' => "Top 100 'page not found' errors",
    'description' => "View 'page not found' errors (404s).",
    'page callback' => 'elasticsearch_watchdog_top',
    'page arguments' => array(
      'page not found',
    ),
    'access arguments' => array(
      'access site reports',
    ),
    'file' => 'elasticsearch_watchdog.admin.inc',
  );
  $items['admin/reports/elastic-access-denied'] = array(
    'title' => "Top 100 'access denied' errors",
    'description' => "View 'access denied' errors (403s).",
    'page callback' => 'elasticsearch_watchdog_top',
    'page arguments' => array(
      'access denied',
    ),
    'access arguments' => array(
      'access site reports',
    ),
    'file' => 'elasticsearch_watchdog.admin.inc',
  );
  $items['admin/reports/elasticlog/elastic-message/%'] = array(
    'title' => 'Details',
    'page callback' => 'elasticsearch_watchdog_event',
    'page arguments' => array(
      4,
    ),
    'access arguments' => array(
      'access site reports',
    ),
    'file' => 'elasticsearch_watchdog.admin.inc',
  );
  $items['admin/reports/elasticlog/delete-filter'] = array(
    'title' => 'Delete log by filter',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'elasticsearch_watchdog_filter_delete_confirm',
    ),
    'access arguments' => array(
      'access site reports',
    ),
    'file' => 'elasticsearch_watchdog.admin.inc',
  );
  return $items;
}