function tripal_phylogeny_menu

2.x tripal_phylogeny.module tripal_phylogeny_menu()
3.x tripal_phylogeny.module tripal_phylogeny_menu()

Implements hook_menu().

Menu items are automatically added for the new node types created by this module to the 'Create Content' Navigation menu item. This function adds more menu items needed for this module.

Related topics

File

legacy/tripal_phylogeny/tripal_phylogeny.module, line 53
Integrates the Chado Phylotree module with Drupal Nodes & Views

Code

function tripal_phylogeny_menu() {
  $items = array();

  $items['taxonomy_view'] = array(
    'title' => 'Taxonomy',
    'description' => 'Taxonomic view of the species available on this site.',
    'page callback' => 'tripal_phylogeny_taxonomy_view',
    'access arguments' => array('access taxonomy content'),
    'file' => '/includes/tripal_phylogeny.taxonomy.inc',
    'type' => MENU_NORMAL_ITEM,
  );

  // administration landing page. currently has no content but is
  // apparently required for the Sync and Help links to work.
  $items['admin/tripal/legacy/tripal_phylogeny'] = array(
    'title' => 'Phylogeny and Taxonomy',
    'description' => 'Phylogenetic and taxonomic trees.',
    'page callback' => 'tripal_phylogeny_admin_phylotrees_listing',
    'access arguments' => array('administer tripal phylotree'),
    'type' => MENU_NORMAL_ITEM,
  );

  // help menu
  $items['admin/tripal/legacy/tripal_phylogeny/help'] = array(
    'title' => 'Help',
    'description' => 'Basic Description of Tripal Phylotree Module Functionality',
    'page callback' => 'theme',
    'page arguments' => array('tripal_phylogeny_help'),
    'access arguments' => array('administer tripal phylotree'),
    'type' => MENU_LOCAL_TASK,
    'weight' => 10
  );

  // configuration menu item
  $items['admin/tripal/legacy/tripal_phylogeny/configuration'] = array(
    'title' => 'Settings',
    'description' => 'Configure the Tripal Phylotree module',
    'page callback' => 'drupal_get_form',
    'page arguments' => array('tripal_phylogeny_admin'),
    'access arguments' => array('administer tripal phylotree'),
    'type' => MENU_LOCAL_TASK,
    'weight' => 1
  );

  // sync menu item (will be rendered as a tab by tripal)
  $items['admin/tripal/legacy/tripal_phylogeny/sync'] = array(
    'title' => ' Sync',
    'description' => 'Create pages on this site for phylotrees stored in Chado',
    'page callback' => 'drupal_get_form',
    'page arguments' => array('chado_node_sync_form', 'tripal_phylogeny', 'chado_phylotree'),
    'access arguments' => array('administer tripal phylotree'),
    'type' => MENU_LOCAL_TASK,
    'weight' => 3
  );

  // Enable admin view
  $items['admin/tripal/legacy/tripal_phylogeny/views/phylotree/enable'] = array(
    'title' => 'Enable Phylotree Administrative View',
    'page callback' => 'tripal_enable_view',
    'page arguments' => array('tripal_phylogeny_admin_phylotree', 'admin/tripal/legacy/tripal_phylogeny'),
    'access arguments' => array('administer tripal phylotree'),
    'type' => MENU_CALLBACK,
  );

  // create a route for viewing json of all phylonodes having this phylotree_id
  $items['ajax/chado_phylotree/%/json'] = array(
    'page callback' => 'tripal_phylogeny_ajax_get_tree_json',
    'page arguments' => array(2),
    // allow all anonymous http clients
    'access callback' => TRUE
  );

  return $items;
}