From 579bd91b14f8d2926f64aa6032b41145f90b46fe Mon Sep 17 00:00:00 2001 From: Aurélien Bompard Date: Fri, 12 Jul 2013 11:13:54 +0200 Subject: Revive the 'discussions by category' widget on the overview page --- hyperkitty/templates/recent_activities.html | 25 +++++++++++------------- hyperkitty/templates/threads/summary_thread.html | 17 +++++----------- 2 files changed, 16 insertions(+), 26 deletions(-) (limited to 'hyperkitty/templates') diff --git a/hyperkitty/templates/recent_activities.html b/hyperkitty/templates/recent_activities.html index 3a475e4..64d3db8 100644 --- a/hyperkitty/templates/recent_activities.html +++ b/hyperkitty/templates/recent_activities.html @@ -119,20 +119,17 @@
- {% if threads_per_category %} -
-

Discussion by topic the last 30 days

- {% for category, thread in threads_per_category.items %} -
-

{{category}}

-
    - {% for email in thread %} -
  • - {{email.title}} -
  • - {% endfor %} -
-
+ {% if threads_by_category %} +
+

Discussion by category

+ {% for category, threads in threads_by_category.items %} +

{{ category.name|upper }} +

+ {% for thread in threads %} + {% include "threads/summary_thread.html" %} + {% endfor %} {% endfor %}
{% endif %} diff --git a/hyperkitty/templates/threads/summary_thread.html b/hyperkitty/templates/threads/summary_thread.html index 87a5433..82c9398 100644 --- a/hyperkitty/templates/threads/summary_thread.html +++ b/hyperkitty/templates/threads/summary_thread.html @@ -3,23 +3,16 @@ {% load storm %}
- #{{counter}} + {% if counter %}#{{counter}}{% endif %} {{ thread.subject|strip_subject:mlist }} -
+
    - {% if thread.category_tag %} -
  • - {{thread.category}} -
  • - {% endif %} {% if thread.category %} -
  • - {{thread.category}} -
  • + + {{ thread.category.name|upper }} + {% endif %}
  • {{ thread.participants|length }} -- cgit