1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798 |
- {% extends "layout.html" %}
- {% block content %}
- <ol class="breadcrumb">
- <li><a href="{{ url_for('forum.index') }}">Forum</a></li>
- </ol>
- {% for category in categories.iteritems() %}
- <table class="table table-bordered">
- <thead class="categoryhead">
- <tr>
- <td colspan="5">
- <div><strong><a href="{{ url_for('forum.view_category', category_id=category[0].id) }}">{{ category[0].title }}</a></strong></div>
- </td>
- </tr>
- </thead>
- <tbody class="forumbody">
- <tr class="forum_stats">
- <td colspan="2"><strong>Forum</strong></td>
- <td width="85" align="center" style="white-space: nowrap"><strong>Topics</strong></td>
- <td width="85" align="center" style="white-space: nowrap"><strong>Posts</strong></td>
- <td width="200" align="center" style="white-space: nowrap"><strong>Last Post</strong></td>
- </tr>
- {% for forum in category[1] %}
- <tr>
- <td align="center" valign="center" width="4%">
- {% if forum[0]|forum_is_unread(forum[1], current_user) %}
- <span class="fa fa-comments" style="font-size: 2em"></span>
- {% else %}
- <span class="fa fa-comments-o" style="font-size: 2em"></span>
- {% endif %}
- </td>
- <td valign="top">
- <strong><a href="{{ url_for('forum.view_forum', forum_id=forum[0].id) }}">{{ forum[0].title }}</a></strong>
- <div class="forum-description">
- {% autoescape false %}
- {{ forum[0].description|markup }}
- {% endautoescape %}
- </div>
- </td>
- <td valign="top" align="center" style="white-space: nowrap">{{ forum[0].topic_count }}</td>
- <td valign="top" align="center" style="white-space: nowrap">{{ forum[0].post_count }}</td>
- <td valign="top" align="right" style="white-space: nowrap">
- {% if forum[0].last_post_id %}
- <a href="{{ url_for('forum.view_post', post_id=forum[0].last_post_id) }}" title="{{ forum[0].last_post.topic.title }}">
- <strong>{{ forum[0].last_post.topic.title|crop_title }}</strong>
- </a>
- <br />
- {{ forum[0].last_post.date_created|time_since }}<br />
- by <a href="{{ url_for('user.profile', username=forum[0].last_post.user.username) }}">{{ forum[0].last_post.user.username }}</a>
- {% else %}
- No posts
- {% endif %}
- </td>
- </tr>
- {% endfor %}
- </tbody>
- </table>
- {% endfor %}
- <!-- Forum Stats -->
- <table class="table table-bordered">
- <thead>
- <tr>
- <td colspan="2">
- <strong>Board Statistics</strong>
- [<a href="{{ url_for('forum.who_is_online') }}" onclick="window.open(this.href, 'wio_window','width=500,height=500'); return false;">Who is online?</a>]
- </td>
- </tr>
- </thead>
- <tbody>
- <tr>
- <td>
- Total number of registered users: <strong>{{ user_count }}</strong> <br />
- Total number of topics: <strong>{{ topic_count }}</strong> <br />
- Total number of posts: <strong>{{ post_count }}</strong> <br />
- </td>
- <td>
- Newest registered user: {% if newest_user %}<a href="{{ url_for('user.profile', username=newest_user.username) }}">{{ newest_user.username }}</a>{% else %}No users{% endif %}<br />
- Registered users online: <strong>{{ online_users }}</strong> <br />
- {% if config["REDIS_ENABLED"] %}
- Guests online: <strong>{{ online_guests }}</strong> <br />
- {% endif %}
- </td>
- </tr>
- </tbody>
- </table>
- {% endblock %}
|