function tripal_views_handler_field_aggregate::init
1.x tripal_views_handler_field_aggregate.inc | tripal_views_handler_field_aggregate::init(&$view, $options) |
init the handler with necessary data.
Parameters
$view: The $view object this handler is attached to.
$options: The item from the database; the actual contents of this will vary based upon the type of handler.
Overrides chado_views_handler_field::init
File
- tripal_views/
views/ handlers/ tripal_views_handler_field_aggregate.inc, line 13 - A chado wrapper for the views_handler_field.
Class
- tripal_views_handler_field_aggregate
- @file A chado wrapper for the views_handler_field.
Code
function init(&$view, $options) {
parent::init($view, $options);
if (!isset($this->chado_table_description)) {
$this->chado_table_description = tripal_core_get_chado_table_schema($this->table);
foreach ($this->chado_table_description['foreign keys'] as $defn) {
if ($defn['table'] != $this->view->base_table) {
$join_table = tripal_core_get_chado_table_schema($defn['table']);
foreach ($join_table['fields'] as $fname => $f) {
$this->chado_table_description['fields'][$defn['table'] . '_' . $fname] = $f;
}
}
}
}
}