Procházet zdrojové kódy

Renamed 'Search Biological Data' to 'Search Data' and added the publication search to the 'Search Data' menu

Stephen Ficklin před 11 roky
rodič
revize
0ac768318a

+ 1 - 1
tripal_analysis/theme/tripal_analysis_help.tpl.php

@@ -33,6 +33,6 @@
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/analyses') ?> is provided for
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/analyses') ?> is provided for
     finding analyses. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     finding analyses. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     which must be installed to see the search tool.  Look for it in the navigation menu under the item
     which must be installed to see the search tool.  Look for it in the navigation menu under the item
-    "Search Biological Data". </p></li>
+    "Search Data". </p></li>
 </ul>
 </ul>
 
 

+ 1 - 1
tripal_analysis/tripal_analysis.module

@@ -87,7 +87,7 @@ function tripal_analysis_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_analysis_search_biological_data_views() {
 function tripal_analysis_search_biological_data_views() {
   return array(
   return array(

+ 1 - 1
tripal_contact/theme/tripal_contact_help.tpl.php

@@ -26,5 +26,5 @@
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/contacts') ?> is provided for 
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/contacts') ?> is provided for 
     finding contacts. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     finding contacts. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     which must be installed to see the search tool.  Look for it in the navigation menu under the item 
     which must be installed to see the search tool.  Look for it in the navigation menu under the item 
-    "Search Biological Data". </p></li>
+    "Search Data". </p></li>
 </ul>
 </ul>

+ 1 - 1
tripal_contact/tripal_contact.module

@@ -105,7 +105,7 @@ function tripal_contact_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_contact_search_biological_data_views() {
 function tripal_contact_search_biological_data_views() {
   return array(
   return array(

+ 1 - 1
tripal_feature/theme/tripal_feature_help.tpl.php

@@ -115,7 +115,7 @@
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/features') ?> is provided for 
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/features') ?> is provided for 
     finding features. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     finding features. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     which must be installed to see the search tool.  Look for it in the navigation menu under the item 
     which must be installed to see the search tool.  Look for it in the navigation menu under the item 
-    "Search Biological Data". </p></li>
+    "Search Data". </p></li>
 
 
     <li><p><b>Delete Features</b>: You can  <a href="<?php print url('admin/tripal/tripal_feature/delete') ?>">bulk delete features</a>
     <li><p><b>Delete Features</b>: You can  <a href="<?php print url('admin/tripal/tripal_feature/delete') ?>">bulk delete features</a>
     by providing a list of feature names, or for a specific organism or for a specific feature type. Be sure you have
     by providing a list of feature names, or for a specific organism or for a specific feature type. Be sure you have

+ 1 - 1
tripal_feature/tripal_feature.module

@@ -215,7 +215,7 @@ function tripal_feature_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_feature_search_biological_data_views() {
 function tripal_feature_search_biological_data_views() {
   return array(
   return array(

+ 1 - 1
tripal_featuremap/theme/tripal_featuremap_help.tpl.php

@@ -32,5 +32,5 @@
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/featuremaps') ?> is provided for 
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/featuremaps') ?> is provided for 
     finding maps. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     finding maps. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     which must be installed to see the search tool.  Look for it in the navigation menu under the item 
     which must be installed to see the search tool.  Look for it in the navigation menu under the item 
-    "Search Biological Data". </p></li>
+    "Search Data". </p></li>
 </ul>
 </ul>

+ 1 - 1
tripal_featuremap/tripal_featuremap.module

@@ -151,7 +151,7 @@ function tripal_featuremap_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_featuremap_search_biological_data_views() {
 function tripal_featuremap_search_biological_data_views() {
   return array(
   return array(

+ 1 - 1
tripal_genetic/tripal_genetic.module

@@ -78,7 +78,7 @@ function tripal_genetic_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_genetic_search_biological_data_views() {
 function tripal_genetic_search_biological_data_views() {
   return array(
   return array(

+ 1 - 1
tripal_library/theme/tripal_library_help.tpl.php

@@ -24,5 +24,5 @@
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/libraries') ?> is provided for 
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/libraries') ?> is provided for 
     finding libraries. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     finding libraries. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     which must be installed to see the search tool.  Look for it in the navigation menu under the item 
     which must be installed to see the search tool.  Look for it in the navigation menu under the item 
-    "Search Biological Data". </p></li>
+    "Search Data". </p></li>
 </ul>
 </ul>

+ 1 - 1
tripal_library/tripal_library.module

@@ -116,7 +116,7 @@ function tripal_library_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_library_search_biological_data_views() {
 function tripal_library_search_biological_data_views() {
   return array(
   return array(

+ 1 - 1
tripal_organism/theme/tripal_organism_help.tpl.php

@@ -35,5 +35,5 @@
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/organisms') ?> is provided for
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/organisms') ?> is provided for
     finding organisms. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     finding organisms. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     which must be installed to see the search tool.  Look for it in the navigation menu under the item
     which must be installed to see the search tool.  Look for it in the navigation menu under the item
-    "Search Biological Data". </p></li>
+    "Search Data". </p></li>
             </ul>
             </ul>

+ 1 - 1
tripal_organism/tripal_organism.module

@@ -121,7 +121,7 @@ function tripal_organism_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_organism_search_biological_data_views() {
 function tripal_organism_search_biological_data_views() {
   return array(
   return array(

+ 1 - 1
tripal_phenotype/tripal_phenotype.module

@@ -73,7 +73,7 @@ function tripal_phenotype_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_phenotype_search_biological_data_views() {
 function tripal_phenotype_search_biological_data_views() {
   return array(
   return array(

+ 1 - 1
tripal_project/theme/tripal_project_help.tpl.php

@@ -22,6 +22,6 @@
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/projects') ?> is provided for
     <li><p><b>Simple Search Tool</b>: A <?php print l('simple search tool','chado/projects') ?> is provided for
     finding projects. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     finding projects. This tool relies on Drupal Views.  <a href="http://drupal.org/project/views">Drupal Views</a>
     which must be installed to see the search tool.  Look for it in the navigation menu under the item
     which must be installed to see the search tool.  Look for it in the navigation menu under the item
-    "Search Biological Data". </p></li>
+    "Search Data". </p></li>
 
 
 </ul>
 </ul>

+ 1 - 1
tripal_project/tripal_project.module

@@ -91,7 +91,7 @@ function tripal_project_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_project_search_biological_data_views() {
 function tripal_project_search_biological_data_views() {
   return array(
   return array(

+ 27 - 0
tripal_pub/tripal_pub.module

@@ -46,7 +46,18 @@ require_once 'includes/importers/tripal_pub.AGL.inc';
 function tripal_pub_menu() {
 function tripal_pub_menu() {
   $items = array();
   $items = array();
 
 
+  // because the publication search is not views we need to manually add
+  // it to the Search Data list in the navigation menu
+  $items['chado/publication' ]= array(
+    'title' => 'Publications',
+    'description' => ('Publications such as journal articles, conference proceedings, or other media.'),
+    'page callback' => 'tripal_pub_search_page',
+    'access arguments' => array('access chado_pub content'),
+    'type' => MENU_NORMAL_ITEM
+  );
 
 
+  // for backwards compatibility the same chado/publications is also found
+  // at find/publications
   $items['find/publications' ]= array(
   $items['find/publications' ]= array(
     'title' => 'Publication Search',
     'title' => 'Publication Search',
     'description' => ('Search for publications'),
     'description' => ('Search for publications'),
@@ -54,6 +65,8 @@ function tripal_pub_menu() {
     'access arguments' => array('access chado_pub content'),
     'access arguments' => array('access chado_pub content'),
     'type' => MENU_CALLBACK
     'type' => MENU_CALLBACK
   );
   );
+  
+
 
 
   $items['find/publications/criteria/%/%'] = array(
   $items['find/publications/criteria/%/%'] = array(
     'page callback' => 'tripal_pub_search_page_update_criteria',
     'page callback' => 'tripal_pub_search_page_update_criteria',
@@ -434,4 +447,18 @@ function tripal_get_remote_pub_raw_page($dbxref) {
     return $page;
     return $page;
   }
   }
   return "Cound not find the requested publication ($dbxref)";
   return "Cound not find the requested publication ($dbxref)";
+}
+
+/**
+ * 
+ */
+function tripal_pub_search_biological_data_views() {
+  return array(
+    'publications' => array(
+      'machine_name' => 'publications',
+      'human_name'   => 'Publications',
+      'description'  => 'Publications such as journal articles, conference proceedings, or other media.',
+      'link'         => 'find/publications'
+    ),
+  );
 }
 }

+ 1 - 1
tripal_stock/tripal_stock.module

@@ -96,7 +96,7 @@ function tripal_stock_menu() {
 /**
 /**
  * Implements hook_search_biological_data_views().
  * Implements hook_search_biological_data_views().
  *
  *
- * Adds the described views to the "Search Biological Data" Page created by Tripal Views
+ * Adds the described views to the "Search Data" Page created by Tripal Views
  */
  */
 function tripal_stock_search_biological_data_views() {
 function tripal_stock_search_biological_data_views() {
   return array(
   return array(

+ 2 - 1
tripal_views/theme/tripal_views_search_biological_content.tpl.php

@@ -28,7 +28,8 @@ print tripal_set_message(
 
 
 // Tell Tripal admin how to add views to this list
 // Tell Tripal admin how to add views to this list
 print tripal_set_message(
 print tripal_set_message(
-  "In order to add views to the above list you need to implement hook_search_biological_data_views().
+  "Developers: To add a view or other search tool to the above list you need to 
+    implement hook_search_biological_data_views() in your custom module.
     This hook should return an array as follows: <code><pre>array(
     This hook should return an array as follows: <code><pre>array(
     '[view-machine-name]' => array(
     '[view-machine-name]' => array(
       'machine_name' => '[view-machine-name]',
       'machine_name' => '[view-machine-name]',

+ 1 - 1
tripal_views/tripal_views.module

@@ -31,7 +31,7 @@ function tripal_views_menu() {
   $items = array();
   $items = array();
 
 
   $items['chado'] = array(
   $items['chado'] = array(
-    'title' => 'Search Biological Data',
+    'title' => 'Search Data',
     'description' => 'Listings of the various biological data available categorized by type.',
     'description' => 'Listings of the various biological data available categorized by type.',
     'page callback' => 'theme',
     'page callback' => 'theme',
     'page arguments' => array('tripal_views_search_biological_content'),
     'page arguments' => array('tripal_views_search_biological_content'),