diff --git a/todo/templates/todo/task_detail.html b/todo/templates/todo/task_detail.html index c6983db..e09dde3 100644 --- a/todo/templates/todo/task_detail.html +++ b/todo/templates/todo/task_detail.html @@ -6,18 +6,6 @@ {% block content %} - -

{{ task }}

@@ -106,20 +94,35 @@
-

Comments on this task

-
- {% for comment in comment_list %} -

- {{ comment.author.first_name }} - {{ comment.author.last_name }}, - {{ comment.date|date:"F d Y P" }} - -

- {{ comment.body|safe|urlize|linebreaks }} - {% empty %} -

No Comments

- {% endfor %} + {% if comment_list %} +

Comments on this task

+ {% for comment in comment_list %} +

+ {{ comment.author.first_name }} + {{ comment.author.last_name }}, + {{ comment.date|date:"F d Y P" }} + +

+ {{ comment.body|safe|urlize|linebreaks }} + {% endfor %} + {% else %} +

No comments (yet).

+ {% endif %}
-{% endblock %} \ No newline at end of file +{% endblock %} + +{% block extra_js %} + +{% endblock extra_js %} diff --git a/todo/views.py b/todo/views.py index a54e8f2..2476661 100644 --- a/todo/views.py +++ b/todo/views.py @@ -96,7 +96,7 @@ def list_detail(request, list_id=None, list_slug=None, view_completed=False): raise PermissionDenied if request.POST: - # Process completed and deleted requests on each POST + # Process completed and deleted items on each POST toggle_done(request, request.POST.getlist('toggle_done_tasks')) toggle_deleted(request, request.POST.getlist('toggle_deleted_tasks'))