Restyle forums a bit
This commit is contained in:
@@ -1,16 +1,21 @@
|
||||
{% load mptt_tags %}
|
||||
{% load minecraft %}
|
||||
{% if forums %}
|
||||
<table>
|
||||
<table class="forum">
|
||||
<tr class="header">
|
||||
<th>Name</th>
|
||||
<th>Topics</th>
|
||||
<th>Last Post</th>
|
||||
</tr>
|
||||
{% for f in forums %}
|
||||
<tr class="{% cycle 'even' 'odd' %}">
|
||||
<tr class="{% cycle 'even' 'odd' %} subforum">
|
||||
<td><a href="{{ f.get_absolute_url }}">{{ f.name }}</a></td>
|
||||
<td>{{ f.topicCount }}</td>
|
||||
<td><a href="{{f.latestTopic.get_absolute_url}}">{{f.latestTopic.title}}</a> by {{f.latestTopic.rootPost.user}}</td>
|
||||
{% if f.latestTopic %}
|
||||
<td><a href="{{f.latestTopic.get_absolute_url}}">{{f.latestTopic.title}}</a> {% include 'common/user_tile.html' with user=f.latestTopic.lastPost.user %}</td>
|
||||
{% else %}
|
||||
<td><em>No posts...</em></td>
|
||||
{% endif %}
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
|
@@ -1,18 +1,19 @@
|
||||
{% load markup %}
|
||||
{% load minecraft %}
|
||||
|
||||
<div class="post">
|
||||
<a name="reply-{{post.id}}"></a>
|
||||
<div class="forum-post-user">
|
||||
<div class="byline">
|
||||
{%avatar post.user%}
|
||||
{{post.user}}
|
||||
</div>
|
||||
<div class="dateline">
|
||||
{{post.created}}
|
||||
</div>
|
||||
<div class="dateline">
|
||||
Posted {{post.created}}
|
||||
</div>
|
||||
<div class="forum-post-content">
|
||||
{{post.body|markdown:"safe"}}
|
||||
<br style="clear:both"/>
|
||||
<a href="{%url forums.views.reply post.id%}">Reply »</a>
|
||||
</div>
|
||||
</div>
|
||||
<a href="{%url forums.views.reply post.id%}">Reply</a>
|
||||
|
@@ -1,4 +1,5 @@
|
||||
{% extends "forum_base.html" %}
|
||||
{% load minecraft %}
|
||||
|
||||
{% block breadcrumb %}
|
||||
<a href="{% url forums.views.index%}">Forums</a>
|
||||
@@ -12,18 +13,16 @@
|
||||
<h2>{{ forum.name }}</h2>
|
||||
<h3>Subforums</h3>
|
||||
{%include "forums/_forum_table.html" with forums=forum.children.all %}
|
||||
<table>
|
||||
<table class="forum">
|
||||
<tr class="header">
|
||||
<th>Title</th>
|
||||
<th>Posted</th>
|
||||
<th>Latest Activity</th>
|
||||
<th>Topic</th>
|
||||
<th>Last Post</th>
|
||||
</tr>
|
||||
{% if topics %}
|
||||
{% for topic in topics %}
|
||||
<tr class="{%cycle 'even' 'odd' %} {% if topic.sticky %}sticky{% endif %}">
|
||||
<td><a href="{{topic.get_absolute_url}}">{{ topic.title }}</a></td>
|
||||
<td>{{ topic.created }} </td>
|
||||
<td>{{topic.lastPost.created}} by {{ topic.lastPost.user }} </td>
|
||||
<tr class="{%cycle 'even' 'odd' %} {% if topic.sticky %}sticky{% endif %} topic">
|
||||
<td class="topic-link"><ul><li><a href="{{topic.get_absolute_url}}">{{ topic.title }}</a></li><li>Started by {{topic.rootPost.user}} on {{topic.created}}</li></ul></td>
|
||||
<td class="author-info"><div class="avatar">{% avatar topic.lastPost.user 32 %}</div><ul><li>{{topic.lastPost.user}}</li><li>{{topic.created}}</li></ul></td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
|
@@ -1,4 +1,5 @@
|
||||
{% extends "forum_base.html" %}
|
||||
{% load minecraft %}
|
||||
{% load mptt_tags %}
|
||||
{%block title %}{{topic.title}}{%endblock%}
|
||||
|
||||
@@ -12,6 +13,11 @@
|
||||
{%endblock%}
|
||||
|
||||
{%block content %}
|
||||
<div class="topic">
|
||||
<div class="avatar">{% avatar topic.rootPost.user 32 %}</div>
|
||||
<h2>{{topic.title}}</h2>
|
||||
<div class="byline">Started by <span itemprop="author">{{topic.rootPost.user}}</span> {{ topic.created }}</div>
|
||||
<br style="clear:both;"/>
|
||||
{% include "forums/_post.html" with post=topic.rootPost %}
|
||||
</div>
|
||||
{%endblock%}
|
||||
|
Reference in New Issue
Block a user