templateend hats, marseys, apps, notifications, etc

master
justcool393 2022-10-05 23:56:37 -07:00
parent d04e5a188c
commit 9b8a3f21ab
6 changed files with 8 additions and 8 deletions

View File

@ -490,7 +490,7 @@
<button id="ban-{{c.id}}" class="dropdown-item list-inline-item d-none {% if not c.author.is_suspended %}d-md-block{% endif %} text-danger" data-bs-toggle="modal" data-bs-target="#banModal" onclick="banModal('/comment/{{c.id}}', '{{c.author.id}}', '{{c.author_name}}')"><i class="fas fa-user-slash text-danger fa-fw"></i>Ban user</button> <button id="ban-{{c.id}}" class="dropdown-item list-inline-item d-none {% if not c.author.is_suspended %}d-md-block{% endif %} text-danger" data-bs-toggle="modal" data-bs-target="#banModal" onclick="banModal('/comment/{{c.id}}', '{{c.author.id}}', '{{c.author_name}}')"><i class="fas fa-user-slash text-danger fa-fw"></i>Ban user</button>
{% endif %} {% endif %}
{% if v.admin_level > 1 and c.oauth_app %} {% if v.admin_level >= PERMS['APPS_MODERATE'] and c.oauth_app %}
<a href="{{c.oauth_app.permalink}}/comments" class="dropdown-item list-inline-item d-none d-md-block text-primary"><i class="fas fa-code text-primary fa-fw"></i>API App</a> <a href="{{c.oauth_app.permalink}}/comments" class="dropdown-item list-inline-item d-none d-md-block text-primary"><i class="fas fa-code text-primary fa-fw"></i>API App</a>
{% endif %} {% endif %}
</ul> </ul>
@ -567,7 +567,7 @@
</div> </div>
{% if request.path.startswith('/notifications') and c.level == 1 and c.sentto and not c.parent_submission and c.author_id != AUTOJANNY_ID %} {% if request.path.startswith('/notifications') and c.level == 1 and c.sentto and not c.parent_submission and c.author_id != AUTOJANNY_ID %}
{% if (v and v.admin_level >= 2) and (c.sentto == 2) and not c.author.is_muted %} {% if (v and v.admin_level >= PERMS['USER_BAN']) and (c.sentto == 2) and not c.author.is_muted %}
<a class="btn btn-primary" role="button" id="mute-user-{{c.id}}" onclick="adminMuteUser({{c.author_id}}, 1, {{c.id}})">Mute</a> <a class="btn btn-primary" role="button" id="mute-user-{{c.id}}" onclick="adminMuteUser({{c.author_id}}, 1, {{c.id}})">Mute</a>
{% endif %} {% endif %}
@ -720,7 +720,7 @@
<a id="approve2-{{c.id}}" class="{% if not c.is_banned %}d-none{% endif %} list-group-item text-success" role="button" onclick="approveComment2('{{c.id}}','approve2-{{c.id}}','remove2-{{c.id}}')" data-bs-dismiss="modal"><i class="fas fa-check text-success mr-2"></i>Approve</a> <a id="approve2-{{c.id}}" class="{% if not c.is_banned %}d-none{% endif %} list-group-item text-success" role="button" onclick="approveComment2('{{c.id}}','approve2-{{c.id}}','remove2-{{c.id}}')" data-bs-dismiss="modal"><i class="fas fa-check text-success mr-2"></i>Approve</a>
{% endif %} {% endif %}
{% if c.oauth_app %} {% if c.oauth_app and v.admin_level >= PERMS['APPS_MODERATE'] %}
<a href="{{c.oauth_app.permalink}}/comments" class="list-group-item text-info"><i class="fas fa-code text-info mr-2"></i>API App</a> <a href="{{c.oauth_app.permalink}}/comments" class="list-group-item text-info"><i class="fas fa-code text-info mr-2"></i>API App</a>
{% endif %} {% endif %}
</ul> </ul>

View File

@ -37,7 +37,7 @@
</a> </a>
</li> </li>
{% endif %} {% endif %}
{% if v.admin_level >= 2 %} {% if v.admin_level >= PERMS['VIEW_MODMAIL'] %}
<li class="nav-item"> <li class="nav-item">
<a class="nav-link py-3{% if request.path == '/notifications/modmail' %} active{% endif %}" href="/notifications/modmail"> <a class="nav-link py-3{% if request.path == '/notifications/modmail' %} active{% endif %}" href="/notifications/modmail">
Modmail Modmail

View File

@ -34,7 +34,7 @@
<button id="approve2-{{p.id}}" class="{% if not p.is_banned %}d-none{% endif %} nobackground btn btn-link btn-block btn-lg text-success text-left" role="button" onclick="post_toast(this,'/approve_post/{{p.id}}','remove2-{{p.id}}','approve2-{{p.id}}','d-none')" data-bs-dismiss="modal"><i class="far fa-check text-center mr-2"></i>Approve</button> <button id="approve2-{{p.id}}" class="{% if not p.is_banned %}d-none{% endif %} nobackground btn btn-link btn-block btn-lg text-success text-left" role="button" onclick="post_toast(this,'/approve_post/{{p.id}}','remove2-{{p.id}}','approve2-{{p.id}}','d-none')" data-bs-dismiss="modal"><i class="far fa-check text-center mr-2"></i>Approve</button>
{% endif %} {% endif %}
{% if p.oauth_app %} {% if p.oauth_app and v.admin_level >= PERMS['APPS_MODERATE'] %}
<a href="{{p.oauth_app.permalink}}"><button class="nobackground btn btn-link btn-block btn-lg text-muted text-left"><i class="far fa-code text-center text-info mr-2"></i>API App</button></a> <a href="{{p.oauth_app.permalink}}"><button class="nobackground btn btn-link btn-block btn-lg text-muted text-left"><i class="far fa-code text-center text-info mr-2"></i>API App</button></a>
{% endif %} {% endif %}

View File

@ -590,7 +590,7 @@
</div> </div>
{% endif %} {% endif %}
{% if v and v.admin_level > 1 %} {% if v and v.admin_level >= PERMS['POST_COMMENT_MODERATION'] %}
{% include "post_admin_actions_mobile.html" %} {% include "post_admin_actions_mobile.html" %}
{% endif %} {% endif %}

View File

@ -184,7 +184,7 @@
</div> </div>
<div class="d-flex my-4 mx-3"> <div class="d-flex my-4 mx-3">
<a role="button" class="btn btn-primary ml-auto" onclick="remove_hat(this, '{{hat.name}}')">Remove</a> <a role="button" class="btn btn-primary ml-auto" onclick="remove_hat(this, '{{hat.name}}')">Remove</a>
{% if v.admin_level > 2 %} {% if v.admin_level >= PERMS['MODERATE_PENDING_SUBMITTED_HATS'] %}
<a role="button" class="btn btn-primary ml-3" onclick="approve_hat(this, '{{hat.name}}')">Approve</a> <a role="button" class="btn btn-primary ml-3" onclick="approve_hat(this, '{{hat.name}}')">Approve</a>
{% endif %} {% endif %}
</div> </div>

View File

@ -182,7 +182,7 @@
</div> </div>
<div class="d-flex my-4 mx-3"> <div class="d-flex my-4 mx-3">
<a role="button" class="btn btn-primary ml-auto" onclick="remove_marsey(this, '{{marsey.name}}')">Remove</a> <a role="button" class="btn btn-primary ml-auto" onclick="remove_marsey(this, '{{marsey.name}}')">Remove</a>
{% if v.admin_level > 2 %} {% if v.admin_level >= PERMS['MODERATE_PENDING_SUBMITTED_MARSEYS'] %}
<a role="button" class="btn btn-primary ml-3" onclick="approve_marsey(this, '{{marsey.name}}')">Approve</a> <a role="button" class="btn btn-primary ml-3" onclick="approve_marsey(this, '{{marsey.name}}')">Approve</a>
{% endif %} {% endif %}
</div> </div>