function views_related_content_handler_filter_field_reference::_get_entityreferences_settings in Views Related Content 7
1 call to views_related_content_handler_filter_field_reference::_get_entityreferences_settings()
- views_related_content_handler_filter_field_reference::get_value_options in views/
views_related_content_handler_filter_field_reference.inc - Child classes should be used to override this function and set the 'value options', unless 'options callback' is defined as a valid function or static public method to generate these values.
File
- views/
views_related_content_handler_filter_field_reference.inc, line 40
Class
Code
function _get_entityreferences_settings() {
$child_ids = $field_names = $settings = array();
// Get all entityreference field names
$query = db_select('field_config', 'f');
$query
->fields('f', array(
'field_name',
));
$query
->condition('f.type', 'entityreference');
$query
->distinct();
$rows = $query
->execute();
foreach ($rows as $row) {
$field_name = $row->field_name;
$field_names[$field_name] = $this
->_field_alias($field_name);
}
return $field_names;
}