summaryrefslogtreecommitdiffstats
path: root/templates/flatpage.html
diff options
context:
space:
mode:
authorSam Wenham <sam@wenhams.co.uk>2019-02-23 15:30:58 +0000
committerSam Wenham <sam@wenhams.co.uk>2019-02-23 15:30:58 +0000
commita1f02e575f6c379fd1a66cbfdefe8b9f29800297 (patch)
tree5f9f1791ea31f765974087ae879f248f3a3c18be /templates/flatpage.html
parentf58b1db9208b5a7509699b2a34f70fb275fb8b65 (diff)
downloadtroggle-a1f02e575f6c379fd1a66cbfdefe8b9f29800297.tar.gz
troggle-a1f02e575f6c379fd1a66cbfdefe8b9f29800297.tar.bz2
troggle-a1f02e575f6c379fd1a66cbfdefe8b9f29800297.zip
Prevent troggle adding the menu if there is one in the file
Add a Docker compose file to bring up a dev troggle easily Various PEP improvments
Diffstat (limited to 'templates/flatpage.html')
-rw-r--r--templates/flatpage.html10
1 files changed, 9 insertions, 1 deletions
diff --git a/templates/flatpage.html b/templates/flatpage.html
index 2376159..73be1b2 100644
--- a/templates/flatpage.html
+++ b/templates/flatpage.html
@@ -3,5 +3,13 @@
{% block bodyattrs %}{% if homepage %} id="homepage"{% endif %}{% endblock %}
{% block body %}
{{ body|safe }}
-{% if homepage %}{% if editable %}<a href="{% url "editflatpage" path %}">Edit</a>{% endif %}{%else %}{% include "menu.html" %}{% endif %}
+{% if homepage %}
+ {% if editable %}
+ <a href="{% url "editflatpage" path %}">Edit</a>
+ {% endif %}
+ {%else %}
+ {% if not has_menu %}
+ {% include "menu.html" %}
+ {% endif %}
+ {% endif %}
{% endblock %}