Первая версия, написанная гопотой. Не работает нормально лента и поиск, сломана авторизация
This commit is contained in:
31
app/templates/mod.html
Normal file
31
app/templates/mod.html
Normal file
@@ -0,0 +1,31 @@
|
||||
{% extends "base.html" %}
|
||||
{% block title %}Модерация{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h2>Модерация — флаги</h2>
|
||||
{% if flags %}
|
||||
<table class="flags">
|
||||
<thead><tr><th>ID</th><th>Post</th><th>Reason</th><th>Created</th><th>Resolved</th><th>Action</th></tr></thead>
|
||||
<tbody>
|
||||
{% for f in flags %}
|
||||
<tr>
|
||||
<td>{{ f.id }}</td>
|
||||
<td><a href="{{ url_for('view_post', pid=f.post_id) }}">{{ f.title or ('#'+f.post_id|string) }}</a></td>
|
||||
<td>{{ f.reason }}</td>
|
||||
<td>{{ f.created_at }}</td>
|
||||
<td>{{ 'yes' if f.resolved else 'no' }}</td>
|
||||
<td>
|
||||
{% if not f.resolved %}
|
||||
<form action="{{ url_for('mod_resolve', fid=f.id) }}" method="post">
|
||||
<button type="submit">Resolve</button>
|
||||
</form>
|
||||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% else %}
|
||||
<p>Нет флагов.</p>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user