Show a geodesic line from LHR to the conference venue if no travel booked
Closes: #111
This commit is contained in:
parent
322b65237d
commit
1e9ae2091e
|
@ -191,7 +191,21 @@ def get_trip_routes(trip: Trip) -> list[StrDict]:
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
return routes
|
if routes:
|
||||||
|
return routes
|
||||||
|
|
||||||
|
lhr = (51.4775, -0.461389)
|
||||||
|
|
||||||
|
return [
|
||||||
|
{
|
||||||
|
"type": "flight",
|
||||||
|
"key": f'LHR_{item["location"]}_{item["country"]}',
|
||||||
|
"from": lhr,
|
||||||
|
"to": latlon_tuple(item),
|
||||||
|
}
|
||||||
|
for item in trip.conferences
|
||||||
|
if "latitude" in item and "longitude" in item and item["country"] != "gb"
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
def get_coordinates_and_routes(
|
def get_coordinates_and_routes(
|
||||||
|
|
Loading…
Reference in a new issue