started working on services

This commit is contained in:
joachim lusiardi
2015-03-16 22:06:59 +01:00
parent e479bc24ac
commit 73b2ccc195
9 changed files with 231 additions and 86 deletions

View File

@@ -0,0 +1,60 @@
{% extends "layout.html" %}
{% block navigation %}
<li><a href='{{ url_for('create_pit_stop_form') }}'>Create Pitstop</a></li>
<li><a href='{{ url_for('get_statistics') }}' class="active">Statistics</a></li>
<li><a href='{{ url_for('get_services') }}' class="active">Services</a></li>
{% endblock %}
{% block body %}
{{ service_warning() }}
<div class="table-responsive">
<table class="table table-striped table-bordered table-condensed">
<tr>
<th>
Odometer<br />
(planned)
</th>
<th>
Odometer<br />
(done)
</th>
<th>
Date<br />
(done)
</th>
<th>
Tasks
</th>
</tr>
{% for service in data['services'] %}
<tr class='pitstop'>
<td>
{{service.odometer_planned}} km
</td>
<td>
{% if service.odometer_done %}
{{service.odometer_done}} km
{% else %}
-- km
{% endif %}
</td>
<td>
{% if service.date %}
{{service.date}}
{% else %}
--
{% endif %}
</td>
<td>
{% for task in service.tasks.split(',') %}
{{task}} <br />
{% endfor %}
</td>
</tr>
{% endfor %}
</table>
</div>
{% endblock %}