master
Aevann1 2021-11-23 02:22:28 +02:00
parent 0f9599851e
commit 2b3ceea310
2 changed files with 3 additions and 5 deletions

View File

@ -251,7 +251,7 @@ def post_rules(v):
def shadowbanned(v):
if not (v and v.admin_level > 1): abort(404)
users = [x for x in g.db.query(User).filter(User.shadowbanned != None).all()]
return render_template("banned.html", v=v, users=users)
return render_template("shadowbanned.html", v=v, users=users)
@app.get("/admin/agendaposters")

View File

@ -6,16 +6,14 @@
<tr>
<th style="font-weight:bold;">#</th>
<th style="font-weight:bold;">Name</th>
<th style="font-weight:bold;">Ban reason</th>
<th style="font-weight:bold;">Banned by</th>
<th style="font-weight:bold;">Shadowbanned by</th>
</tr>
</thead>
{% for user in users %}
<tr>
<td style="font-weight:bold;">{{users.index(user)+1}}</td>
<td><a style="color:#{{user.namecolor}}; font-weight:bold;" href="/@{{user.username}}"><img loading="lazy" src="/uid/{{user.id}}/pic" class="pp20"><span {% if user.patron %}class="patron" style="background-color:#{{user.namecolor}};"{% endif %}>{{user.username}}</span></a></td>
<td style="font-weight:bold;">{% if user.ban_reason %}{{user.ban_reason}}{% endif %}</td>
<td style="font-weight:bold;" href="/@{{user.banned_by.username}}"><img loading="lazy" src="/uid/{{user.banned_by.id}}/pic" class="pp20"><span {% if user.banned_by.patron %}class="patron" style="background-color:#{{user.banned_by.namecolor}};"{% endif %}>{{user.banned_by.username}}</span></a></td>
<td style="font-weight:bold;">{{user.shadowbanned}}</td>
</tr>
{% endfor %}
</table>