'extra' field in hook_views_data()?
Posted by somebodysysop on March 20, 2009 at 8:56am
In hook_views_tables, I used the 'extra' field to make sure that when my table was used in a view,it ony used records which matched the current group. i.e.:
<?php
$tables['og_users_roles'] = array(
'name' => 'og_users_roles',
'provider' => 'internal', // won't show up in external list.
'join' => array(
'left' => array(
'table' => 'node',
'field' => 'uid'
),
'right' => array(
'field' => 'uid'
),
'extra' => array(
'gid' => '<strong><em>CURRENT_GID</em></strong>'
),
),
?>