master
kek7198 2021-12-27 21:23:21 -06:00
parent 0a3aa942bd
commit 57c22bfb09
1 changed files with 29 additions and 1 deletions

View File

@ -45,9 +45,37 @@
Danger Zone
</h2>
<ul class="flex flex-col mt-3 mb-0 space-y-4">
{% if u.is_suspended %}
<form id="sidebar-unban" action="/unban_user/{{u.id}}" method="post">
<input type="hidden" name="formkey", value="{{v.formkey}}">
<input type="hidden" name="redir" value="true">
<div class="custom-control custom-checkbox">
<input type="checkbox" id="sidebar-alts" class="w-5 h-5" name="alts" value="1">
<label class="label mb-0" for="verify">Include alts</label>
</div>
<button form="sidebar-unban" type="submit" class="btn btn-green w-full">
<i class="fas fa-user-slash fa-sm fa-fw mr-2"></i>
Revoke Admin Permissions
</button>
</form>
{% else %}
<form action="/ban_user/{{u.id}}/" method="post">
<input type="hidden" name="formkey" value="{{v.formkey}}">
<input type="hidden" name="redir" value="true">
<input style="font-size:11px;" type="text" class="form-input" name="reason" placeholder="Ban Reason" onchange="document.getElementById('user-ban-submit2').disabled=false">
<input style="font-size:11px;" type="number" step="any" class="form-input" name="days" placeholder="Days (blank = permanent)">
<br >
<div class="custom-control custom-checkbox">
<input type="checkbox" id="alts-2-mobile" class="custom-control-input" name="alts" value="1">
<label class="custom-control-label" for="alts-2-mobile">Include alts</label>
</div>
<br >
<input id="user-ban-submit2" type="submit" class="btn btn-red" value="Ban user" disabled>
</form>
{% endif %}
{% if v.admin_level > 2 %}
<li class="flex space-x-2">
<button class="btn btn-red" onclick="postToast('/@{{u.username}}/remove_admin'); this.disabled = true">
<button class="btn btn-red w-full" onclick="postToast('/@{{u.username}}/remove_admin'); this.disabled = true">
<i class="fas fa-user-slash fa-sm fa-fw mr-2"></i>
Revoke Admin Permissions
</button>