function taxonomy_workbench_access_info in Workbench Access 7
Implements hook_workbench_access_info().
Defines the default handler for access controls.
File
- modules/
taxonomy.workbench_access.inc, line 13 - Taxonomy integration for Workbench Access.
Code
function taxonomy_workbench_access_info() {
return array(
'taxonomy' => array(
'access_scheme' => 'taxonomy',
'name' => t('Taxonomy'),
'access_type' => 'taxonomy',
'access_type_id' => array_filter(variable_get('workbench_access_taxonomy', array())),
'description' => t('Uses taxonomy vocabularies for assigning hierarchical access control.'),
'configuration' => 'taxonomy_workbench_access_configuration',
'form_field' => NULL,
'storage_column' => 'tid',
'translatable' => TRUE,
'query_field' => 'access_id',
'field_table' => 'workbench_access_node',
'adjust_join' => array(
'taxonomy_term_data' => array(
'original_table' => 'taxonomy_index',
'original_field' => 'tid',
'new_table' => 'workbench_access_node',
'new_field' => 'access_id',
),
),
'sort' => array(
array(
'table' => 'taxonomy_term_hierarchy',
'field' => 'parent',
),
array(
'table' => 'taxonomy_term_data',
'field' => 'weight',
'order' => 'ASC',
),
array(
'table' => 'taxonomy_term_data',
'field' => 'name',
'order' => 'ASC',
),
),
),
);
}