Skip to content
Snippets Groups Projects
Commit 00f28a27 authored by angel.h's avatar angel.h Committed by Chris Leppanen
Browse files

Issue #2500185 by angel.h, MegaChriz: Error when having an entity without base table

parent f82a9668
No related branches found
No related tags found
No related merge requests found
......@@ -167,17 +167,19 @@ function feeds_views_data() {
// Add a relationship for each entity type relating the entity's base table
// to the feeds_item table whre feeds_item.entity_type = 'entity_type'.
foreach (entity_get_info() as $entity_type => $info) {
$data['feeds_item']['table']['join'][$info['base table']] = array(
'left_field' => $info['entity keys']['id'],
'field' => 'entity_id',
'type' => 'LEFT',
'extra' => array(
array(
'field' => 'entity_type',
'value' => $entity_type,
if (!empty($info['base table'])) {
$data['feeds_item']['table']['join'][$info['base table']] = array(
'left_field' => $info['entity keys']['id'],
'field' => 'entity_id',
'type' => 'LEFT',
'extra' => array(
array(
'field' => 'entity_type',
'value' => $entity_type,
),
),
),
);
);
}
}
/**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment