123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899 |
- <?php
- function retrieve_chado_feature_views_data () {
- global $db_url;
- $data = array();
-
-
-
-
- if(is_array($db_url) and array_key_exists('chado',$db_url)){
-
- return $data;
- }
-
- $data['chado_feature']['table'] = array(
- 'field' => 'nid',
- 'group' => 'Chado Feature'
- );
-
- $data['chado_feature']['nid'] = array(
- 'title' => t('Feature Node ID'),
- 'help' => t('The node ID for this feature'),
- 'field' => array(
- 'handler' => 'views_handler_field_numeric',
- 'click sortable' => TRUE,
- ),
- 'filter' => array(
- 'handler' => 'views_handler_filter_numeric',
- ),
- 'sort' => array(
- 'handler' => 'views_handler_sort',
- ),
- );
-
-
-
- $data['chado_feature']['table']['join']['feature'] = array(
- 'left_field' => 'feature_id',
- 'field' => 'feature_id',
- );
-
-
- $data['node']['table']['join']['chado_feature'] = array(
- 'left_field' => 'nid',
- 'field' => 'nid',
- );
-
-
- $data['node']['table']['join']['feature'] = array(
- 'left_table' => 'chado_feature',
- 'left_field' => 'nid',
- 'field' => 'nid',
- );
-
-
- $data['chado_feature']['feature_nid'] = array(
- 'group' => 'Feature',
- 'title' => 'Feature Node',
- 'help' => 'Links Chado Feature Fields/Data to the Nodes in the current View.',
- 'real field' => 'feature_id',
- 'relationship' => array(
- 'handler' => 'views_handler_relationship',
- 'title' => t('Chado => Feature'),
- 'label' => t('Chado => Feature'),
- 'real field' => 'feature_id',
- 'base' => 'feature',
- 'base field' => 'feature_id'
- ),
- );
-
- $data['chado_feature']['feature_chado_nid'] = array(
- 'group' => 'Feature',
- 'title' => 'Feature Node',
- 'help' => 'Links Chado Feature Fields/Data to the Nodes in the current View.',
- 'real field' => 'nid',
- 'relationship' => array(
- 'handler' => 'views_handler_relationship',
- 'title' => t('Chado => Node'),
- 'label' => t('Chado => Node'),
- 'real field' => 'nid',
- 'base' => 'node',
- 'base field' => 'nid'
- ),
- );
- return $data;
- }
|