You are here

function activity_menu in Activity 7

Same name and namespace in other branches
  1. 5.4 activity.module \activity_menu()
  2. 5 activity.module \activity_menu()
  3. 5.2 activity.module \activity_menu()
  4. 5.3 activity.module \activity_menu()
  5. 6.2 activity.module \activity_menu()
  6. 6 activity.module \activity_menu()

Implements hook_menu().

File

./activity.module, line 22
Records Activity across the site and surfaces that to Views.

Code

function activity_menu() {
  $items['activity/%/delete'] = array(
    'title' => 'Delete',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'activity_delete_confirm',
      1,
    ),
    'access callback' => 'activity_delete_access',
    'access arguments' => array(
      1,
    ),
    'file' => 'activity.admin.inc',
    'type' => MENU_CALLBACK,
  );
  $items['admin/activity/weight'] = array(
    'title' => 'Fix Trigger weight',
    'page callback' => 'activity_fix_trigger_weight',
    'file' => 'activity.install',
    'access arguments' => array(
      'administer activity',
    ),
    'type' => MENU_CALLBACK,
  );
  $items['admin/structure/activity'] = array(
    'title' => 'Activity Templates',
    'description' => 'Modify how your activity messages will look',
    'page callback' => 'activity_admin_overview',
    'access arguments' => array(
      'administer activity',
    ),
    'file' => 'activity.admin.inc',
  );
  $items['admin/structure/activity/list'] = array(
    'title' => 'List',
    'type' => MENU_DEFAULT_LOCAL_TASK,
  );
  $items['admin/structure/activity/create'] = array(
    'title' => 'Create',
    'description' => 'Modify how your activity messages will look',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'activity_create_form',
    ),
    'access arguments' => array(
      'administer activity',
    ),
    'file' => 'activity.admin.inc',
    'type' => MENU_LOCAL_TASK,
    'weight' => 2,
  );
  $items['admin/config/content/activity'] = array(
    'title' => 'Activity',
    'description' => 'Modify the settings for how activity behaves',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'activity_settings_form',
    ),
    'access arguments' => array(
      'administer activity',
    ),
    'file' => 'activity.admin.inc',
    'type' => MENU_NORMAL_ITEM,
  );
  $items['admin/config/content/activity/settings'] = array(
    'title' => 'Settings',
    'type' => MENU_DEFAULT_LOCAL_TASK,
  );
  $items['admin/structure/activity/configure/%activity_handler'] = array(
    'title' => 'Edit',
    'description' => 'Modify how your activity messages will look',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'activity_configure_handler_form',
      4,
    ),
    'access arguments' => array(
      'administer activity',
    ),
    'file' => 'activity.admin.inc',
    'type' => MENU_CALLBACK,
  );
  $items['admin/structure/activity/recreate/%activity_handler_batchable/%'] = array(
    'title' => 'Recreate Messages',
    'description' => 'Recreate messages for the provided action',
    'page callback' => 'activity_admin_recreate',
    'page arguments' => array(
      4,
    ),
    'access callback' => 'activity_batch_access',
    'access arguments' => array(
      4,
      5,
    ),
    'file' => 'activity.admin.inc',
    'type' => MENU_CALLBACK,
  );
  $items['admin/structure/activity/delete/%actions'] = array(
    'title' => 'Delete',
    'description' => 'Remove an activity action and associated trigger assignment',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'activity_actions_delete_form',
      4,
    ),
    'access arguments' => array(
      'administer activity',
    ),
    'file' => 'activity.admin.inc',
    'type' => MENU_CALLBACK,
  );
  $items['admin/structure/activity/regenerate/%activity_handler_batchable/%'] = array(
    'title' => 'Create new Messages',
    'description' => 'Delete messages for the provided action and create new ones',
    'page callback' => 'activity_batch_regenerate',
    'page arguments' => array(
      4,
    ),
    'access callback' => 'activity_batch_access',
    'access arguments' => array(
      4,
      5,
    ),
    'file' => 'activity.admin.inc',
  );
  return $items;
}