bgneal@82: {% extends 'base.html' %}
bgneal@84: {% load forum_tags %}
bgneal@82: {% block title %}Forums: {{ forum.name }}{% endblock %}
bgneal@82: {% block content %}
bgneal@82: <h2>Forums: {{ forum.name }}</h2>
bgneal@82: 
bgneal@82: <h3>
bgneal@82:    <a href="{% url forums-index %}">SurfGuitar101 Forum Index</a> &raquo;
bgneal@82:    <a href="{% url forums-forum_index slug=forum.slug %}">{{ forum.name }}</a>
bgneal@82: </h3>
bgneal@82: 
bgneal@82: <div class="forum-block">
bgneal@113: {% if user.is_authenticated %}
bgneal@113: <a href="{% url forums-new_topic slug=forum.slug %}">New Topic</a> &bull;
bgneal@194: <form action="{% url forums-catchup slug=forum.slug %}" method="post" style="display:inline">{% csrf_token %}
bgneal@113:    <input type="submit" value="Mark All Topics Read" />
bgneal@113: </form>
bgneal@113: {% endif %}
bgneal@97: {{ page_nav }}
bgneal@82: <table class="forum-index-table">
bgneal@82:    <thead>
bgneal@82:       <tr>
bgneal@82:          <th class="forum-index_title">Topics</th>
bgneal@82:          <th class="forum-index_replies">Replies</th>
bgneal@82:          <th class="forum-index_author">Author</th>
bgneal@82:          <th class="forum-index_views">Views</th>
bgneal@82:          <th class="forum-index_last_post">Last Post</th>
bgneal@82:       </tr>
bgneal@82:    </thead>
bgneal@82:    <tbody>
bgneal@93:    {% for topic in page.object_list %}
bgneal@93:       <tr class="{% cycle 'odd' 'even' %}">
bgneal@114:          <td>
bgneal@167:             {% topic_icons topic %}
bgneal@161:             <h4><a href="{{ topic.get_absolute_url }}">{{ topic.name }}</a></h4>
bgneal@161:             {% if topic.page_range %}
bgneal@167:                {% topic_page_range topic %}
bgneal@161:             {% endif %}
bgneal@161:          </td>
bgneal@83:          <td class="forum-index_replies">{{ topic.reply_count }}</td>
bgneal@85:          <td class="forum-index_author"><a href="{% url bio-view_profile username=topic.user.username %}" title="View profile for {{ topic.user.username }}">{{ topic.user.username }}</a></td>
bgneal@82:          <td class="forum-index_views">{{ topic.view_count }}</td>
bgneal@82:          <td class="forum-index_last_post">
bgneal@120:             {% last_post_info topic.last_post %}
bgneal@82:          </td>
bgneal@82:       </tr>
bgneal@82:    {% empty %}
bgneal@82:       <tr>
bgneal@111:          <td colspan="5">
bgneal@82:             <i>No topics available.</i>
bgneal@82:          </td>
bgneal@82:       </tr>
bgneal@82:    {% endfor %}
bgneal@82:    </tbody>
bgneal@82: </table>
bgneal@97: {{ page_nav }}
bgneal@113: {% if user.is_authenticated %}
bgneal@113: <a href="{% url forums-new_topic slug=forum.slug %}">New Topic</a> &bull;
bgneal@194: <form action="{% url forums-catchup slug=forum.slug %}" method="post" style="display:inline">{% csrf_token %}
bgneal@113:    <input type="submit" value="Mark All Topics Read" />
bgneal@113: </form>
bgneal@113: {% endif %}
bgneal@113: {% if can_moderate %}
bgneal@111: <p><a href="{% url forums-mod_forum slug=forum.slug %}">Moderate this forum</a></p>
bgneal@113: {% endif %}
bgneal@120: {% current_forum_time user %}
bgneal@82: </div>
bgneal@82: {% endblock %}