Display units

This commit is contained in:
Gabriel Augendre 2018-03-13 09:28:41 +01:00
parent 9475578a07
commit 0dc4504d48
2 changed files with 11 additions and 6 deletions

View file

@ -82,7 +82,7 @@
<ul class="list-group">
{% for round in rounds %}
<a href="{% url 'round-edit' round.pk %}" class="list-group-item">{{ round.repetition_number }} répétitions
&times; {{ round.chosen_weight }}</a>
&times; {{ round.chosen_weight }} {{ equipment.unit }}</a>
{% endfor %}
</ul>
{% else %}

View file

@ -35,11 +35,16 @@
<div class="row">
<div class="col-12">
<h2>Séries</h2>
<ul class="list-group">
{% for round in session.rounds.all %}
<a href="#" class="list-group-item">{{ round.equipment.name }} &ndash; {{ round.repetition_number }} répétitions &times; {{ round.chosen_weight }}</a>
{% endfor %}
</ul>
{% if session.rounds.all %}
<ul class="list-group">
{% for round in session.rounds.all %}
<a href="#" class="list-group-item">{{ round.equipment.name }}
&ndash; {{ round.repetition_number }} répétitions &times; {{ round.chosen_weight }} {{ round.equipment.unit }}</a>
{% endfor %}
</ul>
{% else %}
<p>Pas encore de série pour cette séance. Au boulot !</p>
{% endif %}
</div>
</div>
{% endblock %}