123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- <?php
- require_once('api/tripal_natural_diversity.api.inc');
- require_once('includes/tripal_natural_diversity.schema.inc');
- function tripal_natural_diversity_views_api() {
- return array(
- 'api' => 2.0,
- );
- }
- function tripal_natural_diversity_theme() {
- return array(
- 'tripal_feature_genotype_experiments' => array(
- 'arguments' => array('node' => NULL),
- 'template' => 'tripal_feature-genotype_experiments',
- ),
- 'tripal_stock_genotype_experiments' => array(
- 'arguments' => array('node' => NULL),
- 'template' => 'tripal_feature-stock_experiments',
- ),
- );
- }
- function tripal_natural_diversity_nodeapi(&$node, $op, $teaser, $page) {
- switch ($op) {
- case 'view':
- if ($node->type == 'chado_feature') {
- $node->content['tripal_feature_genotype_experiments'] = array(
- '#value' => theme('tripal_feature_genotype_experiments', $node),
- );
- }
- elseif ($node->type == 'chado_stock') {
- $node->content['tripal_stock_genotype_experiments'] = array(
- '#value' => theme('tripal_stock_genotype_experiments', $node),
- );
- }
- }
- }
|