function domain_source_views_data_alter in Domain Access 8
Implements hook_views_data_alter().
File
- domain_source/
domain_source.module, line 225 - Domain-based path rewrites for content.
Code
function domain_source_views_data_alter(array &$data) {
$table = 'node__' . DomainSourceElementManagerInterface::DOMAIN_SOURCE_FIELD;
$data[$table][DomainSourceElementManagerInterface::DOMAIN_SOURCE_FIELD]['field']['id'] = 'domain_source';
$data[$table][DomainSourceElementManagerInterface::DOMAIN_SOURCE_FIELD . '_target_id']['filter']['id'] = 'domain_source';
// Since domains are not stored in the database, relationships cannot be used.
unset($data[$table][DomainSourceElementManagerInterface::DOMAIN_SOURCE_FIELD]['relationship']);
}