From eaa76ae7584d0938db0298714303e2c23b3eacfd Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Thu, 9 Sep 2010 13:36:41 -0500 Subject: Improve todo list view page Add total package count and incomplete package count columns. Also reduce the number of total queries by killing the query per row that was happening before. Signed-off-by: Dan McGee --- templates/todolists/list.html | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'templates') diff --git a/templates/todolists/list.html b/templates/todolists/list.html index 29829ca..2e75bda 100644 --- a/templates/todolists/list.html +++ b/templates/todolists/list.html @@ -20,6 +20,8 @@ Creation Date Creator Description + Package Count + Incomplete Count Status @@ -31,8 +33,10 @@ {{ list.date_added }} {{ list.creator.get_full_name }} {{ list.description|safe }} - {% if list.complete %}Complete - {% else %}Incomplete{% endif %} + {{ list.pkg_count }} + {{ list.incomplete_count }} + {% ifequal list.incomplete_count 0 %}Complete + {% else %}Incomplete{% endifequal %} {% endfor %} @@ -42,7 +46,10 @@ {% endblock %} -- cgit v1.2.3-24-g4f1b