function event_views_calendar_query_handler in Event Views 5.2
Same name and namespace in other branches
- 5 event_views.module \event_views_calendar_query_handler()
- 6.2 event_views.module \event_views_calendar_query_handler()
A handler to insert substitute date values into the calendar query
File
- ./
event_views.module, line 215 - Views-enables the event module.
Code
function event_views_calendar_query_handler(&$field, &$fieldinfo, &$query) {
$option = event_views_get_field($field['options']);
// make sure the table is joined into the query and have the selected field serve AS the calendar date
$query
->ensure_table($option['table']);
$query
->add_field($option['field'] . " AS " . $field[field] . "", $option['table']);
}