event-timeline/app/templates/index.html

50 lines
1.4 KiB
HTML
Raw Normal View History

2021-11-12 16:49:35 +00:00
{% extends "base.html" %}
2021-11-12 16:58:31 +00:00
{% block title %}{{ settings.title }}{% endblock title %}
2021-11-12 16:49:35 +00:00
{% block main %}
<div class="index">
<div class="intro">
{{ intro.body | safe }}
</div>
2022-03-18 15:56:06 +00:00
{% if request.user.is_staff %}
<div class="menu">
[<a href="admin/page/page/{{ intro.id }}/change/">edit</a>]
</div>
{% endif %}
2021-11-12 16:49:35 +00:00
<div class="events">
{% for event in events %}
<div class="event" {% if event.date %}data-date="{{ event.date }}"{% endif %} id="{{ event.slug }}">
2021-11-12 16:58:31 +00:00
<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">
2021-11-19 14:31:23 +00:00
{{ event.media_html | safe }}
2021-11-12 16:58:31 +00:00
</div>
<div class="text">
{{ event.body | safe }}
</div>
</div>
{% else %}
{{ event.body | safe }}
{% endif %}
2021-11-12 16:49:35 +00:00
{% if request.user.is_staff %}
2021-11-12 16:58:31 +00:00
<div class="menu">
2021-11-12 16:49:35 +00:00
[<a href="admin/event/event/{{ event.id }}/change/">edit</a>]
2022-03-18 15:24:47 +00:00
[<a href="timeline/#{{ event.slug }}" target="_blank">open on timeline</a>]
2021-11-12 16:58:31 +00:00
</div>
2021-11-12 16:49:35 +00:00
{% endif %}
</div>
{% endfor %}
</div>
<div class="postscript">
{{ postscript.body | safe }}
</div>
2022-03-18 15:56:06 +00:00
{% if request.user.is_staff %}
<div class="menu">
[<a href="admin/page/page/{{ postscript.id }}/change/">edit</a>]
</div>
{% endif %}
2021-11-12 16:49:35 +00:00
</div>
{% endblock %}