54 lines
2.2 KiB
HTML
54 lines
2.2 KiB
HTML
{% extends "base.html" %}
|
||
|
||
{% block title %}Форум Клуба Любителей ЖПЧХ{% endblock %}
|
||
|
||
{% block content %}
|
||
<div style="display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px;">
|
||
<h1>ОФИЦИАЛЬНЫЙ ФОРУМ КЛУБА ЖПЧХ</h1>
|
||
{% if current_user %}
|
||
<a href="{{ url_for('new_topic') }}" class="btn btn-primary">+ Создать новую тему</a>
|
||
{% endif %}
|
||
</div>
|
||
|
||
<p>
|
||
Здесь участники сообщества обсуждают технику съёмки, делятся опытом полевых вылазок, консультируются
|
||
с Основателями (<b>MatrixHasYou</b>, <b>PitKa</b>) и обсуждают клубные инициативы.
|
||
</p>
|
||
|
||
{% for cat in categories %}
|
||
<h2>{{ cat.title }}</h2>
|
||
<p style="font-size: 12px; color: #555555; margin-bottom: 6px;">{{ cat.description }}</p>
|
||
|
||
<table class="table-forum">
|
||
<thead>
|
||
<tr>
|
||
<th>Название темы</th>
|
||
<th style="width: 140px;">Автор темы</th>
|
||
<th style="width: 70px; text-align: center;">Ответов</th>
|
||
<th style="width: 80px; text-align: center;">Просмотров</th>
|
||
<th style="width: 160px;">Последняя активность</th>
|
||
</tr>
|
||
</thead>
|
||
<tbody>
|
||
{% set topics = topics_by_cat[cat.id] %}
|
||
{% if topics %}
|
||
{% for t in topics %}
|
||
<tr>
|
||
<td>
|
||
<a href="{{ url_for('topic', topic_id=t.id) }}"><b>{{ t.title }}</b></a>
|
||
</td>
|
||
<td>{{ t.username }}</td>
|
||
<td style="text-align: center;">{{ t.posts_count }}</td>
|
||
<td style="text-align: center;">{{ t.views }}</td>
|
||
<td style="font-size: 11px;">{{ t.last_post_time or t.created_at }}</td>
|
||
</tr>
|
||
{% endfor %}
|
||
{% else %}
|
||
<tr>
|
||
<td colspan="5" style="text-align: center; color: #777777;">В этом разделе пока нет тем.</td>
|
||
</tr>
|
||
{% endif %}
|
||
</tbody>
|
||
</table>
|
||
{% endfor %}
|
||
{% endblock %}
|