aboutsummaryrefslogtreecommitdiff
path: root/templates/weblog.html
diff options
context:
space:
mode:
authorYaroslav <contact@yaroslavps.com>2020-03-11 02:26:54 +0300
committerYaroslav <contact@yaroslavps.com>2020-03-11 02:26:54 +0300
commitda4917f8c673a16ba757b3b911cf5ce36895d74e (patch)
treeeb36d2c213917359b50efe2b9c5bc00c2fa55543 /templates/weblog.html
downloadyaroslavps.com-da4917f8c673a16ba757b3b911cf5ce36895d74e.tar.gz
yaroslavps.com-da4917f8c673a16ba757b3b911cf5ce36895d74e.zip
initial commit
Diffstat (limited to 'templates/weblog.html')
-rw-r--r--templates/weblog.html27
1 files changed, 27 insertions, 0 deletions
diff --git a/templates/weblog.html b/templates/weblog.html
new file mode 100644
index 0000000..11c0d2a
--- /dev/null
+++ b/templates/weblog.html
@@ -0,0 +1,27 @@
+{% extends "base.html" %}
+{% block content %}
+<div class="posts-list">
+ {% for post in paginator.pages %}
+ <div class="post-preview">
+ <h2><a href="{{ post.permalink }}">{{ post.title }}</a></h2>
+ {% if post.summary %}
+ {{ post.summary | safe }}
+ {% endif %}
+ </div>
+ {% endfor %}
+</div>
+{% if paginator %}
+{% if paginator.number_pagers > 1 %}
+<div class="paginator">
+ {% if paginator.previous %}
+ <a href="{{ paginator.first }}">First</a>
+ <a href="{{ paginator.previous }}">Previous page: {{ paginator.current_index - 1 }}</a>
+ {% endif %}
+ {% if paginator.next %}
+ <a href="{{ paginator.next }}">Next page: {{ paginator.current_index + 1 }}</a>
+ <a href="{{ paginator.last }}">Last</a>
+ {% endif %}
+</div>
+{% endif %}
+{% endif %}
+{% endblock %}