Gap page to show trips

Closes: #90
Closes: #97
This commit is contained in:
Edward Betts 2024-01-23 15:58:01 +00:00
parent d6ebd86232
commit 6c1c638104
3 changed files with 66 additions and 7 deletions

View file

@ -86,8 +86,9 @@ def launch_list() -> str:
async def gaps_page() -> str:
"""List of available gaps."""
now = datetime.now()
data = await agenda.data.get_data(now, app.config)
return flask.render_template("gaps.html", today=now.date(), gaps=data["gaps"])
trip_list = agenda.trip.build_trip_list()
gaps = agenda.data.gap_list(now.date(), app.config, trip_list)
return flask.render_template("gaps.html", today=now.date(), gaps=gaps)
@app.route("/travel")