<!DOCTYPE html>
{% extends "base.html" %}
{% load humanize %}
{% block content %}
    <h3>Welcome to the Member's Area</h3>
		
    <p>
        Here is where you can receive and view announcements, let us know feedback as it comes to mind, provide prayer requests for the prayer box, and enjoy conversation with other members if you'd like.
    </p>
    <p>
        This exists as a way to garner a bit more community, should you desire such, as well as being relatively private to the members to prevent outsider abuse; or a place for those who are little less vocal about their faith in online spaces.
    </p>
    <p>
        The conversation thread will be up as trial for 6 months. Please enjoy and aim to act in good faith; there are no rules besides the ones you read in order to join the ring.
    </p>

    {% for category, thread in threads.items %}
        <div class="forum-category">{{ category }} Forum</div>
	<div style="overflow-x:auto;">

	<table>
		<tr>
			<th>Thread</th>
			<th>Posts</th>
			<th>Last Post</th>
		</tr>
		{% for t in thread %}
		<tr>
			<td>
				<a href="{% url 'thread' t.id %}">{{ t.title }}</a>
				<small>
					<a href="{% url 'thread' t.id %}?page=last">&gt;&gt;</a>
				</small>
				<br>
				<small>{{ t.description }}</small>
			</td>
			<td>{{ t.post_count }}</td>
			<td>
				{% if t.most_recent_poster_id != '#' %}
				by <a href="{% url 'user' t.most_recent_poster_id %}">{{ t.most_recent_poster }}</a> ({{ t.most_recent_post_date|naturaltime }})
				{% else %}
				by {{ t.most_recent_poster }} ({{ t.most_recent_post_date|naturaltime }})
				{% endif %}
			</td>
		</tr>
		{% endfor %}
	</table>
</div>
    {% endfor %}
{% endblock %}
