2021-08-29 20:50:22 +00:00
|
|
|
{% load i18n %}
|
|
|
|
|
|
|
|
<h3 class="text-center">
|
|
|
|
{% if date_previous %}
|
|
|
|
<a class="btn btn-sm btn-default" href="?date={{ date_previous|date:"Y-m-d" }}" aria-label="{% trans "Previous" %}">
|
2021-08-30 11:29:53 +00:00
|
|
|
<i class="icon-2x icon-angle-circled-left" aria-hidden="true"></i>
|
2021-08-29 20:50:22 +00:00
|
|
|
<span class="sr-only">{% trans "Previous" %}</span>
|
|
|
|
</a>
|
|
|
|
{% endif %}
|
|
|
|
{{ date|date }}
|
|
|
|
{% if date_next %}
|
|
|
|
<a class="btn btn-sm btn-default" href="?date={{ date_next|date:"Y-m-d" }}" aria-label="{% trans "Next" %}">
|
2021-08-30 11:29:53 +00:00
|
|
|
<i class="icon-2x icon-angle-circled-right" aria-hidden="true"></i>
|
2021-08-29 20:50:22 +00:00
|
|
|
<span class="sr-only">{% trans "Next" %}</span>
|
|
|
|
</a>
|
|
|
|
{% endif %}
|
|
|
|
</h3>
|
|
|
|
{% if timeline_objects %}
|
|
|
|
<ul class="timeline m-auto">
|
2022-01-12 08:24:20 +00:00
|
|
|
{% regroup timeline_objects by time as timeline_moments %}
|
|
|
|
|
|
|
|
{% for moment_objects in timeline_moments %}
|
|
|
|
{% for object in moment_objects.list|dictsort:"type" %}
|
|
|
|
<li{% cycle "" ' class="timeline-inverted"' %}>
|
|
|
|
<div class="timeline-badge {% if object.type == "start" %}bg-success{% elif object.type == "end" %}bg-danger{% else %}bg-info{% endif %}">
|
|
|
|
<i class="icon-{{ object.model_name }}"></i>
|
2021-08-29 20:50:22 +00:00
|
|
|
</div>
|
2022-01-12 08:24:20 +00:00
|
|
|
<div class="card text-right">
|
|
|
|
<div class="card-body">
|
|
|
|
{{ object.event }}
|
|
|
|
{% for detail in object.details %}
|
|
|
|
<div><small>{{ detail }}</small></div>
|
|
|
|
{% endfor %}
|
|
|
|
</div>
|
|
|
|
<div class="card-footer text-muted">
|
|
|
|
{% blocktrans trimmed with since=object.time|timesince time=object.time|time %}
|
|
|
|
{{ since }} ago ({{ time }})
|
|
|
|
{% endblocktrans %}
|
|
|
|
{% if object.duration %}
|
|
|
|
<div>
|
|
|
|
<small>
|
|
|
|
{% blocktrans trimmed with duration=object.duration %}
|
|
|
|
Duration: {{ duration }}
|
|
|
|
{% endblocktrans %}
|
|
|
|
</small>
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
{% if object.time_since_prev %}
|
|
|
|
<div>
|
|
|
|
<small>
|
|
|
|
{% blocktrans trimmed with since=object.time_since_prev %}
|
|
|
|
{{ since }} since previous
|
|
|
|
{% endblocktrans %}
|
|
|
|
</small>
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
{% if object.edit_link %}
|
|
|
|
<div>
|
|
|
|
<small><a href="{{ object.edit_link }}">{% trans "Edit" %}</a></small>
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
</div>
|
2021-08-29 20:50:22 +00:00
|
|
|
</div>
|
2022-01-12 08:24:20 +00:00
|
|
|
</li>
|
|
|
|
{% endfor %}
|
2021-08-29 20:50:22 +00:00
|
|
|
{% endfor %}
|
|
|
|
</ul>
|
|
|
|
<h3 class="text-center">
|
|
|
|
{% if date_previous %}
|
|
|
|
<a class="btn btn-sm btn-default" href="?date={{ date_previous|date:"Y-m-d" }}" aria-label="{% trans "Previous" %}">
|
2021-08-30 11:29:53 +00:00
|
|
|
<i class="icon-2x icon-angle-circled-left" aria-hidden="true"></i>
|
2021-08-29 20:50:22 +00:00
|
|
|
<span class="sr-only">{% trans "Previous" %}</span>
|
|
|
|
</a>
|
|
|
|
{% endif %}
|
|
|
|
{{ date|date }}
|
|
|
|
{% if date_next %}
|
|
|
|
<a class="btn btn-sm btn-default" href="?date={{ date_next|date:"Y-m-d" }}" aria-label="{% trans "Next" %}">
|
2021-08-30 11:29:53 +00:00
|
|
|
<i class="icon-2x icon-angle-circled-right" aria-hidden="true"></i>
|
2021-08-29 20:50:22 +00:00
|
|
|
<span class="sr-only">{% trans "Next" %}</span>
|
|
|
|
</a>
|
|
|
|
{% endif %}
|
|
|
|
</h3>
|
|
|
|
{% else %}
|
2021-12-18 18:45:05 +00:00
|
|
|
<div class="text-center">{% trans "No events" %}</div>
|
2022-01-12 08:24:20 +00:00
|
|
|
{% endif %}
|