event-timeline/app/templates/index.html
2022-03-18 15:24:47 +00:00

39 lines
1.1 KiB
HTML

{% extends "base.html" %}
{% block title %}{{ settings.title }}{% endblock title %}
{% block main %}
<div class="index">
<div class="intro">
{{ intro.body | safe }}
</div>
<div class="events">
{% for event in events %}
<div class="event" {% if event.date %}data-date="{{ event.date }}"{% endif %} id="{{ event.slug }}">
<h2 class="{{ event.type }}">{{ event.title | safe }}</h2>
<div class="date">{{ event.date }}</div>
{% if event.media %}
<div class="side-by-side">
<div class="media">
{{ event.media_html | safe }}
</div>
<div class="text">
{{ event.body | safe }}
</div>
</div>
{% else %}
{{ event.body | safe }}
{% endif %}
{% if request.user.is_staff %}
<div class="menu">
[<a href="admin/event/event/{{ event.id }}/change/">edit</a>]
[<a href="timeline/#{{ event.slug }}" target="_blank">open on timeline</a>]
</div>
{% endif %}
</div>
{% endfor %}
</div>
<div class="postscript">
{{ postscript.body | safe }}
</div>
</div>
{% endblock %}