Add navigation bar and fix the bug of "too many values to unbound"
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
{% extends "templates/base.html" %}
|
||||
|
||||
{% block content %}
|
||||
<a href="/blog/{{ blog.id }}?page=0">Home</a> <a href="/category/{{ blog.id }}">Categories</a> <a href="/tag/{{ blog.id }}">Tags</a><br/><br/>
|
||||
{% if categories|length == 0 %}
|
||||
<b>Any category available</b><br/><br/>
|
||||
{% else %}
|
||||
|
||||
@@ -31,4 +31,8 @@
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
</table>
|
||||
<br/><br/>
|
||||
{% autoescape off %}
|
||||
<center>{{ navigation_bar }}</center>
|
||||
{% endautoescape %}
|
||||
{% endblock %}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
{% extends "templates/base.html" %}
|
||||
|
||||
{% block content %}
|
||||
<a href="/blog/{{ blog.id }}?page=0">Home</a> <a href="/category/{{ blog.id }}">Categories</a> <a href="/tag/{{ blog.id }}">Tags</a><br/><br/>
|
||||
{% if tags|length == 0 %}
|
||||
<b>Any tag available</b><br/><br/>
|
||||
{% else %}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{% extends "templates/base.html" %}
|
||||
|
||||
{% block content %}
|
||||
<a href="/blog/{{ blog.id }}">Home</a> <a href="/category/{{ blog.id }}">Categories</a> <a href="/tag/{{ blog.id }}">Tags</a>
|
||||
<a href="/blog/{{ blog.id }}?page=0">Home</a> <a href="/category/{{ blog.id }}">Categories</a> <a href="/tag/{{ blog.id }}">Tags</a>
|
||||
{% if user.is_superuser %}
|
||||
<form action="/blog/edit/{{ blog.id }}" method="post">
|
||||
{% csrf_token %}
|
||||
@@ -24,4 +24,8 @@
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
</table>
|
||||
<br/><br/>
|
||||
{% autoescape off %}
|
||||
<center>{{ navigation_bar }}</center>
|
||||
{% endautoescape %}
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user