parent
5ee0dc9c8d
commit
c3be926ff7
|
@ -39,7 +39,7 @@
|
|||
} %}
|
||||
|
||||
|
||||
{% from "macros.html" import trip_link, display_date_no_year with context %}
|
||||
{% from "macros.html" import trip_link, display_date_no_year, trip_item with context %}
|
||||
|
||||
{% from "navbar.html" import navbar with context %}
|
||||
<body>
|
||||
|
@ -81,15 +81,9 @@
|
|||
{% endfor %}
|
||||
|
||||
{% if current_trip %}
|
||||
{% set end = current_trip.end %}
|
||||
<div>
|
||||
<div>Current trip: {{ trip_link(current_trip) }}</div>
|
||||
{% if end %}
|
||||
<div>Dates: {{ display_date_no_year(current_trip.start) }} to {{ display_date_no_year(end) }}</div>
|
||||
{% else %}
|
||||
<div>Start: {{ display_date_no_year(current_trip.start) }} (end date missing)</div>
|
||||
{% endif %}
|
||||
|
||||
<h3>Current trip</h3>
|
||||
{{ trip_item(current_trip) }}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
|
|
|
@ -102,7 +102,8 @@ async def index() -> str:
|
|||
"event_list.html",
|
||||
today=today,
|
||||
events=events,
|
||||
current_trip=get_current_trip(now.date()),
|
||||
get_country=agenda.get_country,
|
||||
current_trip=get_current_trip(today),
|
||||
fullcalendar_events=calendar.build_events(events),
|
||||
start_event_list=date.today() - timedelta(days=1),
|
||||
end_event_list=date.today() + timedelta(days=365 * 2),
|
||||
|
|
Loading…
Reference in a new issue