remove people no longer coming from travel report
This commit is contained in:
@@ -453,9 +453,13 @@ function booking_report_travel() {
|
||||
//get travel info from database
|
||||
$query = db_select('booking_person', 'p');
|
||||
$query->leftJoin('booking_travel', 't', 'p.nid = t.booking_person_nid');
|
||||
$query->condition('p.booking_eventid', $event->eid, '=')
|
||||
->fields('p')
|
||||
->fields('t');
|
||||
//include people either booked in or on the waiting list or hosts, that belong to the current event id
|
||||
$db_or = db_or();
|
||||
$db_or->condition('p.booking_status', 1, '=');
|
||||
$db_or->condition('p.booking_status', 2, '=');
|
||||
$db_or->condition('p.booking_status', 5, '=');
|
||||
$db_and = db_and()->condition($db_or)->condition('p.booking_eventid', $event->eid, '=');
|
||||
$query->fields('p')->fields('t');
|
||||
//allow user to sort columns
|
||||
$table_sort = $query->extend('TableSort')->orderbyHeader($header);
|
||||
$result = $table_sort->execute();
|
||||
@@ -475,7 +479,7 @@ function booking_report_travel() {
|
||||
//$travel_link = l(t('Travel'), t('node/!id/edit', array('!id' => $person->tid)));
|
||||
$this_row[] = t('!transport', array('!transport' => $person->booking_transport_type));
|
||||
$this_row[] = t('!train', array('!train' => $person->booking_transport_from_morriset_reqd == 1 ? 'Yes' : 'No'));
|
||||
$this_row[] = t('!inflightnum', array('!transport' => $person->booking_flightnum_inbound));
|
||||
$this_row[] = t('!inflightnum', array('!inflightnum' => $person->booking_flightnum_inbound));
|
||||
$this_row[] = t('!inflighttime', array('!inflighttime' =>
|
||||
$person->booking_flight_datetime_inbound == 0 ? '' : format_date($person->booking_flight_datetime_inbound, 'custom', 'd/m/Y H:i')));
|
||||
$this_row[] = t('!outflightnum', array('!outflightnum' => $person->booking_flightnum_outbound));
|
||||
|
Reference in New Issue
Block a user