You are here

function _efq_views_copy_data in EntityFieldQuery Views Backend 7

Parameters

array $data:

string $entity_type:

string $key:

array $entity_data:

Return value

bool

1 call to _efq_views_copy_data()
efq_views_views_data in ./efq_views.views.inc
Implements hook_views_data().

File

./efq_views.views.inc, line 69

Code

function _efq_views_copy_data(&$data, &$entity_type, $key, $entity_data) {
  $return = FALSE;
  if (substr($key, 0, 7) == 'entity_') {
    $return = TRUE;
    $entity_type = substr($key, 7);
  }
  elseif (substr($key, 0, 13) == 'views_entity_') {
    $entity_type = substr($key, 13);
  }
  if (!isset($data['efq_' . $entity_type])) {
    $data['efq_' . $entity_type] = array();
  }
  $data['efq_' . $entity_type] += $entity_data;
  return $return;
}