Browse Source

Merge branch '6.x-1.x' of git.drupal.org:sandbox/spficklin/1337878 into 6.x-1.x

spficklin 11 years ago
parent
commit
0f672bcbbb
1 changed files with 18 additions and 0 deletions
  1. 18 0
      tripal_feature/tripal_feature.module

+ 18 - 0
tripal_feature/tripal_feature.module

@@ -285,6 +285,10 @@ function tripal_feature_theme() {
        'arguments' => array('node' => NULL),
        'template' => 'tripal_feature_sequence',
     ),
+    'tripal_feature_proteins' => array(
+       'arguments' => array('node' => NULL),
+       'template' => 'tripal_feature_proteins',
+    ),
     'tripal_feature_synonyms' => array(
        'arguments' => array('node' => NULL),
        'template' => 'tripal_feature_synonyms',
@@ -1853,6 +1857,20 @@ function tripal_feature_preprocess_tripal_feature_relationships(&$variables) {
     $feature->all_relationships = tripal_feature_get_feature_relationships($feature);
   }
 }
+
+/**
+ *
+ *
+ * @ingroup tripal_feature
+ */
+function tripal_feature_preprocess_tripal_feature_proteins(&$variables) {
+  // we want to provide a new variable that contains the matched features.
+  $feature = $variables['node']->feature;
+
+  if (!$feature->all_relationships) {
+    $feature->all_relationships = tripal_feature_get_feature_relationships($feature);
+  }
+}
 /**
  *
  *