mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-09-27 05:50:05 +00:00
UI for deciding to send reports to remote
Shows a checkbox for the user and lets the admin know
This commit is contained in:
parent
d4013b9721
commit
0612930fb9
3 changed files with 19 additions and 1 deletions
|
@ -44,7 +44,7 @@ class GoalForm(CustomForm):
|
|||
class ReportForm(CustomForm):
|
||||
class Meta:
|
||||
model = models.Report
|
||||
fields = ["reported_user", "user", "status", "links", "note"]
|
||||
fields = ["reported_user", "user", "status", "links", "note", "allow_broadcast"]
|
||||
|
||||
|
||||
class ReadThroughForm(CustomForm):
|
||||
|
|
|
@ -23,6 +23,15 @@
|
|||
<div class="card-footer-item">
|
||||
<p>{% blocktrans with username=report.user|username path=report.user.local_path %}Reported by <a href="{{ path }}">@{{ username }}</a>{% endblocktrans %}</p>
|
||||
</div>
|
||||
{% if not report.reported_user.local %}
|
||||
<div class="card-footer-item">
|
||||
{% if report.allow_broadcast %}
|
||||
<p>{% trans "Sent to remote instance" %}</p>
|
||||
{% else %}
|
||||
<p>{% trans "<b>Not</b> sent to remote instance" %}</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endif %}
|
||||
<div class="card-footer-item">
|
||||
{{ report.created_date | naturaltime }}
|
||||
</div>
|
||||
|
|
|
@ -36,6 +36,15 @@
|
|||
{% trans "Links from this domain will be removed until your report has been reviewed." %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% if not reported_user.local %}
|
||||
<label class="checkbox label">
|
||||
<input class="checkbox" id="id_allow_broadcast" type="checkbox" name="allow_broadcast" checked>
|
||||
{% trans "Also send this report to the user's instance admins" %}
|
||||
</label>
|
||||
{% else %}
|
||||
<input type="hidden" name="allow_broadcast">
|
||||
{% endif %}
|
||||
</p>
|
||||
<div class="control">
|
||||
<label class="label" for="id_{{ controls_uid }}_report_note">
|
||||
{% trans "More info about this report:" %}
|
||||
|
|
Loading…
Reference in a new issue