mod reports: enable reporting for members, add dmail reporting.
* Add ability to report dmails. * Enable reports for comments, forum posts, and dmails. * Allow Members to send reports. * Don't allow users to report the same thing twice.
This commit is contained in:
@@ -33,10 +33,13 @@
|
||||
<% if @dmail.is_spam? %>
|
||||
| <%= link_to "Not spam", ham_dmail_path(@dmail), remote: :true, method: :post %>
|
||||
<% else %>
|
||||
| <%= link_to "Mark as spam", spam_dmail_path(@dmail), remote: :true, method: :post %>
|
||||
| <%= link_to "Spam", spam_dmail_path(@dmail), remote: :true, method: :post %>
|
||||
<% end %>
|
||||
</span>
|
||||
<% end %>
|
||||
<% if @dmail.reportable_by?(CurrentUser.user) %>
|
||||
| <%= link_to "Report", new_moderation_report_path(moderation_report: { model_type: "Dmail", model_id: @dmail.id }), remote: true, title: "Report this dmail to the moderators" %>
|
||||
<% end %>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user