2024-01-16 05:18:59 +11:00
|
|
|
= content_for :heading do
|
2024-01-17 23:19:51 +11:00
|
|
|
= render 'application/mailer/heading', heading_title: t("user_mailer.warning.title.#{@warning.action}"), heading_image_url: frontend_asset_url('images/mailer-new/heading/warning.png')
|
2024-01-16 05:18:59 +11:00
|
|
|
%table.email-w-full{ cellspacing: 0, cellpadding: 0, border: 0, role: 'presentation' }
|
|
|
|
%tr
|
|
|
|
%td.email-body-padding-td
|
|
|
|
%table.email-inner-card-table{ cellspacing: 0, cellpadding: 0, border: 0, role: 'presentation' }
|
|
|
|
%tr
|
|
|
|
%td.email-inner-card-td-without-padding
|
|
|
|
%table.email-w-full{ cellspacing: 0, cellpadding: 0, border: 0, role: 'presentation' }
|
Add moderation warnings (#9519)
* Add moderation warnings
Replace individual routes for disabling, silencing, and suspending
a user, as well as the report update route, with a unified account
action controller that allows you to select an action (none,
disable, silence, suspend) as well as whether it should generate an
e-mail notification with optional custom text. That notification,
with the optional custom text, is saved as a warning.
Additionally, there are warning presets you can configure to save
time when performing the above.
* Use Account#local_username_and_domain
2018-12-23 06:02:09 +11:00
|
|
|
%tr
|
2024-01-16 05:18:59 +11:00
|
|
|
%td.email-prose.email-padding-24
|
|
|
|
- unless @warning.none_action?
|
|
|
|
%p= t "user_mailer.warning.explanation.#{@warning.action}", instance: @instance
|
|
|
|
|
|
|
|
- if @warning.text.present?
|
|
|
|
= linkify(@warning.text)
|
|
|
|
|
|
|
|
- if @warning.report && !@warning.report.other?
|
|
|
|
%p
|
|
|
|
%strong= t('user_mailer.warning.reason')
|
|
|
|
= t("user_mailer.warning.categories.#{@warning.report.category}")
|
|
|
|
|
|
|
|
- if @warning.report.violation? && @warning.report.rule_ids.present?
|
|
|
|
%ul.rules-list
|
|
|
|
- @warning.report.rules.each do |rule|
|
|
|
|
%li= rule.text
|
|
|
|
|
|
|
|
- unless @statuses.empty?
|
|
|
|
%p
|
|
|
|
%strong= t('user_mailer.warning.statuses')
|
|
|
|
|
|
|
|
- unless @statuses.empty?
|
|
|
|
%table.email-w-full{ cellspacing: 0, cellpadding: 0, border: 0, role: 'presentation' }
|
|
|
|
%tr
|
|
|
|
%td.email-border-top
|
|
|
|
- @statuses.each_with_index do |status, i|
|
|
|
|
%table.email-w-full{ cellspacing: 0, cellpadding: 0, border: 0, role: 'presentation' }
|
|
|
|
%tr
|
|
|
|
%td.email-border-bottom.email-padding-24
|
|
|
|
= render 'notification_mailer/status', status: status, i: i + 1, highlighted: true, time_zone: @resource.time_zone.presence
|
|
|
|
|
|
|
|
%table.email-w-full{ cellspacing: 0, cellpadding: 0, border: 0, role: 'presentation' }
|
2019-08-24 06:37:23 +10:00
|
|
|
%tr
|
2024-01-16 05:18:59 +11:00
|
|
|
%td.email-prose.email-padding-24
|
|
|
|
%p= t 'user_mailer.warning.appeal_description', instance: @instance
|
|
|
|
= render 'application/mailer/button', text: t('user_mailer.warning.appeal'), url: disputes_strike_url(@warning)
|