From 66e3ed2c34a8e751eb200b9c8e3c593208a2afa2 Mon Sep 17 00:00:00 2001 From: luxagraf Date: Fri, 10 Jul 2015 11:23:31 +0000 Subject: fixed some bugs in enable_comments --- design/templates/details/entry.html | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'design/templates/details/entry.html') diff --git a/design/templates/details/entry.html b/design/templates/details/entry.html index 1641ace..ce71987 100644 --- a/design/templates/details/entry.html +++ b/design/templates/details/entry.html @@ -71,22 +71,26 @@ class="{%if t == 0 or t == 2 %}single{%endif%}{%if t == 1 or t == 3 %}double{%en {% include 'mailing_list.html' %} {% endcomment %} - -{% get_comment_count for object as comment_count %}. + {% if object.enable_comments %} +{% get_comment_count for object as comment_count %} {%if comment_count > 0 %}

{{comment_count}} Comment{{ comment_count|pluralize }}

{% render_comment_list for object %} {%endif%} {% render_comment_form for object %} +{% else %} +

Sorry, comments have been disabled for this post.

+{%endif%} {% endblock %} {% block js %} {% with object.get_template_name_display as t %}{%if t == "single" or t == "single-dark" %} {%endif%}{%endwith%} -