function forward_query_stats_recent_alter in Forward 7.3
Implements hook_query_TAG_alter().
Alter the EntityFieldQuery
File
- ./
forward.module, line 1367 - Allows forwarding of entities by email, and provides a record of how often each has been forwarded.
Code
function forward_query_stats_recent_alter(QueryAlterableInterface $query) {
// Most recently forwarded entities
$info = entity_get_info(variable_get('forward_block_entity_type', 'node'));
$join_clause = $info['base table'] . '.' . $info['entity keys']['id'] . ' = f.id';
$query
->join('forward_statistics', 'f', $join_clause);
$query
->orderBy('f.last_forward_timestamp', 'DESC');
}