2020-07-20 22:33:59 +00:00
|
|
|
{% extends 'cards/base.html' %}
|
|
|
|
{% load duration i18n %}
|
|
|
|
|
2021-08-04 20:36:00 +00:00
|
|
|
{% block header %}
|
|
|
|
<a href="{% url "core:feeding-list" %}">
|
|
|
|
{% trans "Today's Feeding" %}
|
|
|
|
</a>
|
|
|
|
{% endblock %}
|
2020-07-20 22:33:59 +00:00
|
|
|
|
|
|
|
{% block title %}
|
2022-05-31 02:43:42 +00:00
|
|
|
{% if feedings|length > 0 %}
|
|
|
|
<div id="feeding-days-carousel" class="carousel slide" data-interval="false">
|
|
|
|
<div class="carousel-inner">
|
|
|
|
{% for feeding in feedings %}
|
|
|
|
<div class="carousel-item{% if forloop.counter == 1 %} active{% endif %}">
|
|
|
|
<div class="last-feeding-method text-center">
|
|
|
|
{% if feeding.total %}
|
2023-02-07 19:16:53 +00:00
|
|
|
{{ feeding.total|floatformat }}
|
2022-05-31 02:43:42 +00:00
|
|
|
{% else %}
|
|
|
|
{% trans "None" %}
|
|
|
|
{% endif %}
|
|
|
|
</div>
|
|
|
|
<div class="text-center small">
|
2022-06-05 13:34:52 +00:00
|
|
|
{% if feeding.count > 0 %}
|
|
|
|
{% blocktrans trimmed count counter=feeding.count %}
|
|
|
|
{{ counter }} feeding
|
|
|
|
{% plural %}
|
|
|
|
{{ counter }} feedings
|
|
|
|
{% endblocktrans %}
|
|
|
|
{% endif %}
|
2022-05-31 02:43:42 +00:00
|
|
|
</div>
|
|
|
|
{% blocktrans trimmed with since=feeding.date.date|dayssince %}
|
|
|
|
<div class="text-center small text-muted">
|
|
|
|
{{ since }}
|
|
|
|
</div>
|
|
|
|
{% endblocktrans %}
|
|
|
|
</div>
|
|
|
|
{% endfor %}
|
|
|
|
</div>
|
|
|
|
{% if feedings|length > 1 %}
|
|
|
|
<a class="carousel-control-prev" href="#feeding-days-carousel" role="button" data-slide="prev">
|
|
|
|
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
|
|
|
|
<span class="sr-only">{% trans "Previous" %}</span>
|
|
|
|
</a>
|
|
|
|
<a class="carousel-control-next" href="#feeding-days-carousel" role="button" data-slide="next">
|
|
|
|
<span class="carousel-control-next-icon" aria-hidden="true"></span>
|
|
|
|
<span class="sr-only">{% trans "Next" %}</span>
|
|
|
|
</a>
|
2020-07-20 22:33:59 +00:00
|
|
|
{% endif %}
|
2022-05-31 02:43:42 +00:00
|
|
|
</div>
|
|
|
|
{% else %}
|
|
|
|
{% trans "None" %}
|
|
|
|
{% endif %}
|
2020-07-20 22:33:59 +00:00
|
|
|
|
2022-05-31 02:43:42 +00:00
|
|
|
{% endblock %}
|