Fix airport field row being inserted and check against airport ID

This commit is contained in:
Nabeel Shahzad
2018-03-23 12:27:28 -05:00
parent c6f423087d
commit 1161106d9c
3 changed files with 11 additions and 2 deletions

View File

@@ -40,6 +40,12 @@ class FlightExporter extends ImportExport
$ret['airline'] = $ret['airline']->icao;
$ret['distance'] = $ret['distance']->toNumber();
$ret['dpt_airport'] = $flight->dpt_airport_id;
$ret['arr_airport'] = $flight->arr_airport_id;
if($flight->alt_airport) {
$ret['alt_airport'] = $flight->alt_airport_id;
}
$ret['days'] = $this->getDays($flight);
$ret['flight_type'] = FlightType::convertToCode($ret['flight_type']);