From 9386fe8c132944d001884630ed4e931e37c828c4 Mon Sep 17 00:00:00 2001 From: Harald Eilertsen Date: Fri, 5 Jun 2020 11:25:07 +0200 Subject: Add section template. Also move most content to the section templates, leave only section descriptions and the latest posts in each for the index page. --- templates/section.html | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 templates/section.html (limited to 'templates/section.html') diff --git a/templates/section.html b/templates/section.html new file mode 100644 index 0000000..b65fdf1 --- /dev/null +++ b/templates/section.html @@ -0,0 +1,44 @@ +{% extends "base.html" %} +{% block content %} +

{{ section.title }}

+ +{{ section.description }} + +
+ {% for post in section.pages | reverse %} +
+
+ +

+ + {{ post.title }} + +

+
+
+ {% if post.summary %} + {{ post.summary | safe }} + {% else %} + {{ post.content | safe }} + {% endif %} +
+ +
+ {% endfor %} +
+{% endblock content %} -- cgit v1.2.3