You are here

function user_relationships_menu in User Relationships 7

Same name and namespace in other branches
  1. 5 user_relationships_hooks.inc \user_relationships_menu()
  2. 5.2 user_relationships_hooks.inc \user_relationships_menu()

Implements hook_menu().

File

./user_relationships.module, line 21
User Relationships API. Module shell.

Code

function user_relationships_menu() {
  $items['admin/config/people/relationships'] = array(
    'title' => 'Relationships',
    'description' => 'Create relationship types',
    'access arguments' => array(
      'administer user relationships',
    ),
    'page callback' => 'user_relationships_admin_types_list_page',
    'file' => 'user_relationships.admin.inc',
  );
  $items['admin/config/people/relationships/list'] = array(
    'title' => 'List',
    'type' => MENU_DEFAULT_LOCAL_TASK,
    'page callback' => 'user_relationships_admin_types_list_page',
    'access arguments' => array(
      'administer user relationships',
    ),
    'file' => 'user_relationships.admin.inc',
  );
  $items['admin/config/people/relationships/add'] = array(
    'title' => 'Add relationship type',
    'type' => MENU_LOCAL_ACTION,
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'user_relationships_admin_type_edit',
    ),
    'access arguments' => array(
      'administer user relationships',
    ),
    'file' => 'user_relationships.admin.inc',
  );
  $items['admin/config/people/relationships/%user_relationships_type/edit'] = array(
    'title' => 'Edit type',
    'type' => MENU_LOCAL_TASK,
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'user_relationships_admin_type_edit',
      4,
    ),
    'access arguments' => array(
      'administer user relationships',
    ),
    'file' => 'user_relationships.admin.inc',
    'weight' => 5,
  );
  $items['admin/config/people/relationships/%user_relationships_type/delete'] = array(
    'title' => 'Delete type',
    'type' => MENU_LOCAL_TASK,
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'user_relationships_admin_type_delete',
      4,
    ),
    'access arguments' => array(
      'administer user relationships',
    ),
    'file' => 'user_relationships.admin.inc',
    'weight' => 15,
  );
  $items['admin/config/people/relationships/settings'] = array(
    'title' => 'Settings',
    'type' => MENU_LOCAL_TASK,
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'user_relationships_admin_settings',
    ),
    'access arguments' => array(
      'administer user relationships',
    ),
    'file' => 'user_relationships.admin.inc',
    'weight' => 20,
  );
  $items['admin/user_relationships/autocomplete/types'] = array(
    'title' => 'User Relationships Types Autocomplete',
    'type' => MENU_CALLBACK,
    'page callback' => 'user_relationships_autocomplete_types',
    'access callback' => 'user_access',
    'access arguments' => array(
      'administer user relationships',
    ),
  );
  return $items;
}