Add block list report to show active blocks

This commit is contained in:
Edward Betts 2020-04-22 14:22:33 +01:00
parent 3bbb25226b
commit 95d69ef302
5 changed files with 102 additions and 0 deletions

View file

@ -0,0 +1,25 @@
{% macro local_block_alert() %}
{% if g.local_blocks %}
<div class="alert alert-danger" role="alert">
<h4 class="alert-heading">Wikidata IP block preventing edits</h4>
<p>Editing is currently unavailable due to a block of the server that hosts this tool.</p>
{% if request.endpoint != 'server_block_report' %}
<hr>
<p class="mb-0">See the <a href="{{ url_for('server_block_report') }}">block report</a> for more details.</p>
{% endif %}
</div>
{% endif %}
{% endmacro %}
{% macro global_block_alert() %}
{% if g.global_blocks %}
<div class="alert alert-danger" role="alert">
<h4 class="alert-heading">Wikimedia global IP block preventing edits</h4>
<p>Editing is currently unavailable due to a block of the server that hosts this tool.</p>
{% if request.endpoint != 'server_block_report' %}
<hr>
<p class="mb-0">See the <a href="{{ url_for('server_block_report') }}">block report</a> for more details.</p>
{% endif %}
</div>
{% endif %}
{% endmacro %}