Mercurial > public > sg101
comparison gpp/templates/forums/index.html @ 84:9e5e52556d5b
Forums: added a last_post_info template tag. Still need to add a go to last post icon for it.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sat, 29 Aug 2009 22:01:40 +0000 |
parents | e356ea79a7a2 |
children | 806399f3b950 |
comparison
equal
deleted
inserted
replaced
83:5b4c812b448e | 84:9e5e52556d5b |
---|---|
1 {% extends 'base.html' %} | 1 {% extends 'base.html' %} |
2 {% load forum_tags %} | |
2 {% block title %}Forums{% endblock %} | 3 {% block title %}Forums{% endblock %} |
3 {% block content %} | 4 {% block content %} |
4 <h2>Forums</h2> | 5 <h2>Forums</h2> |
5 | 6 |
6 <div class="forum-block"> | 7 <div class="forum-block"> |
20 <tr> | 21 <tr> |
21 <td><h4><a href="{{ forum.get_absolute_url }}">{{ forum.name }}</a></h4> | 22 <td><h4><a href="{{ forum.get_absolute_url }}">{{ forum.name }}</a></h4> |
22 <p>{{ forum.description }}</p></td> | 23 <p>{{ forum.description }}</p></td> |
23 <td class="forum-topics">{{ forum.topic_count }}</td> | 24 <td class="forum-topics">{{ forum.topic_count }}</td> |
24 <td class="forum-posts">{{ forum.post_count }}</td> | 25 <td class="forum-posts">{{ forum.post_count }}</td> |
25 <td class="forum-last_post"> | 26 <td class="forum-last_post">{% last_post_info forum.last_post %}</td> |
26 {% if forum.last_post %} | |
27 {{ forum.last_post.update_date|date }}<br /> | |
28 {{ forum.last_post.user.username }} | |
29 {% else %} | |
30 <i>No Posts</i> | |
31 {% endif %} | |
32 </td> | |
33 </tr> | 27 </tr> |
34 {% endfor %} | 28 {% endfor %} |
35 </tbody> | 29 </tbody> |
36 </table> | 30 </table> |
37 {% endfor %} | 31 {% endfor %} |