2022-05-04 23:09:46 +00:00
{% extends "default.html" %}
2022-11-21 08:52:22 +00:00
{% block pagetitle %}Banned Domains{% endblock %}
2022-05-04 23:09:46 +00:00
{% block content %}
2023-03-17 14:22:29 +00:00
< script defer src = "{{'js/admin/banned_domains.js' | asset}}" > < / script >
2022-10-20 22:14:25 +00:00
2022-10-29 00:38:39 +00:00
< div class = "overflow-x-auto mt-2" >
2022-10-20 22:14:25 +00:00
< table class = "table table-striped mb-5" id = "domains-table" >
< thead class = "bg-primary text-white" >
< tr >
< th > Domain< / th >
< th > Ban reason< / th >
2023-02-24 21:55:01 +00:00
< th class = "disable-sort-click" > < / th >
2022-10-20 22:14:25 +00:00
< / tr >
< / thead >
< tbody >
{% for domain in banned_domains %}
< tr >
< td > {{domain.domain}}< / td >
< td > {{domain.reason}}< / td >
< td >
2022-12-30 12:14:18 +00:00
< button type = "button" class = "btn btn-danger" data-nonce = "{{g.nonce}}" data-onclick = "unbanDomain(this, '{{domain.domain}}')" > Unban< / button >
2022-10-20 22:14:25 +00:00
< / td >
< / tr >
{% endfor %}
< / tbody >
< / table >
2023-08-11 21:50:23 +00:00
< form action = "/admin/ban_domain" method = "post" data-nonce = "{{g.nonce}}" data-onsubmit = "sendFormXHRReload(this)" >
2023-01-24 05:10:16 +00:00
< input hidden name = "formkey" value = "{{v|formkey}}" >
2022-10-20 22:14:25 +00:00
< input autocomplete = "off" name = "domain" placeholder = "Enter domain here.." class = "form-control" required >
2023-01-01 02:17:46 +00:00
< input autocomplete = "off" name = "reason" placeholder = "Enter ban reason here.." data-nonce = "{{g.nonce}}" data-undisable_element = "ban-submit" class = "form-control mt-2" >
2023-03-07 00:21:08 +00:00
< input autocomplete = "off" id = "ban-submit" type = "submit" class = "btn btn-primary mt-2" value = "Ban domain" disabled >
2022-10-20 22:14:25 +00:00
< / form >
< / div >
{% endblock %}