kopia lustrzana https://github.com/glidernet/ogn-python
Better logbook date
rodzic
7658f7dd69
commit
096126e765
|
@ -47,6 +47,7 @@
|
|||
<theader>
|
||||
<tr>
|
||||
<th>Nr.</th>
|
||||
<th>Date</th>
|
||||
<th colspan="2">Airport</th>
|
||||
<th colspan="2">Time UTC</th>
|
||||
<th>Duration</th>
|
||||
|
@ -54,6 +55,7 @@
|
|||
</tr>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th></th>
|
||||
<th>Takeoff</th>
|
||||
<th>Landing</th>
|
||||
<th>Takeoff</th>
|
||||
|
@ -63,11 +65,13 @@
|
|||
</tr>
|
||||
</theader>
|
||||
<tbody>
|
||||
{% set date = none %}
|
||||
{% for entry in device.logbook %}
|
||||
<tr>
|
||||
<td>{{ loop.index }}</td>
|
||||
<td>{% if entry.takeoff_airport is not none %} {{ entry.takeoff_airport.name }} {% endif %}</td>
|
||||
<td>{% if entry.landing_airport is not none %} {{ entry.landing_airport.name }} {% endif %}</td>
|
||||
<td>{% if date != entry.takeoff_timestamp.strftime('%Y-%m-%d') %}{{ entry.takeoff_timestamp.strftime('%Y-%m-%d') }}{% endif %}</td>
|
||||
<td>{% if entry.takeoff_airport is not none %}<a href="{{ url_for('main.airport_detail', airport=entry.takeoff_airport.id) }}">{{ entry.takeoff_airport.name }}</a>{% endif %}</td>
|
||||
<td>{% if entry.landing_airport is not none %}<a href="{{ url_for('main.airport_detail', airport=entry.landing_airport.id) }}">{{ entry.landing_airport.name }}</a>{% endif %}</td>
|
||||
<td>{% if entry.takeoff_timestamp is not none %} {{ entry.takeoff_timestamp.strftime('%H:%M') }} {% endif %}</td>
|
||||
<td>{% if entry.landing_timestamp is not none %} {{ entry.landing_timestamp.strftime('%H:%M') }} {% endif %}</td>
|
||||
<td>{% if entry.duration is not none %}{{ entry.duration }}{% endif %}</td>
|
||||
|
|
Ładowanie…
Reference in New Issue