Skip to content

armgit / wger

Public Imported from GitHub
0

Self hosted FLOSS fitness/workout, nutrition and weight tracker

Show calories in nutrition plan overview

Roland Geiderbf0b0b09715f
diff --git a/wger/nutrition/templates/mobile/plan/overview.html b/wger/nutrition/templates/mobile/plan/overview.html
index 779197cf1..77e06e68c 100644
--- a/wger/nutrition/templates/mobile/plan/overview.html
+++ b/wger/nutrition/templates/mobile/plan/overview.html
@@ -11,7 +11,10 @@
<span class="glyphicon glyphicon-chevron-right pull-right"></span>
<h3 class="list-group-item-heading">{{plan}}</h3>
- <p class="list-group-item-text">{{ plan.creation_date }}</p>
+ <p class="list-group-item-text">
+ {{ plan.creation_date }} –
+ {{ plan.get_nutritional_values.total.energy|floatformat }} kcal
+ </p>
</a>
{% empty %}
<a href="{% url 'nutrition-add' %}" class="list-group-item wger-list-group-item">
diff --git a/wger/nutrition/templates/plan/overview.html b/wger/nutrition/templates/plan/overview.html
index bf02d89af..53a3b212e 100644
--- a/wger/nutrition/templates/plan/overview.html
+++ b/wger/nutrition/templates/plan/overview.html
@@ -12,6 +12,7 @@
<tr>
<th>{% trans "Description" %}</th>
<th>{% trans "Date" %}</th>
+ <th>{% trans "Energy" %}</th>
</tr>
</thead>
<tbody>
@@ -29,6 +30,9 @@
<td>
{{ plan.creation_date }}
</td>
+ <td>
+ {{ plan.get_nutritional_values.total.energy|floatformat }} kcal
+ </td>
</tr>
{% endfor %}
</tbody>