Add notifications for statuses deleted by moderators (#17204)
This commit is contained in:
parent
d5c9feb7b7
commit
14f436c457
59 changed files with 1220 additions and 598 deletions
|
@ -37,16 +37,26 @@
|
|||
%tr
|
||||
%td.column-cell.text-center
|
||||
- unless @warning.none_action?
|
||||
%p= t "user_mailer.warning.explanation.#{@warning.action}"
|
||||
%p= t "user_mailer.warning.explanation.#{@warning.action}", instance: @instance
|
||||
|
||||
- unless @warning.text.blank?
|
||||
= Formatter.instance.linkify(@warning.text)
|
||||
|
||||
- if !@statuses.nil? && !@statuses.empty?
|
||||
- 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')
|
||||
|
||||
- if !@statuses.nil? && !@statuses.empty?
|
||||
- unless @statuses.empty?
|
||||
- @statuses.each_with_index do |status, i|
|
||||
= render 'notification_mailer/status', status: status, i: i + 1, highlighted: true
|
||||
|
||||
|
|
|
@ -3,11 +3,24 @@
|
|||
===
|
||||
|
||||
<% unless @warning.none_action? %>
|
||||
<%= t "user_mailer.warning.explanation.#{@warning.action}" %>
|
||||
<%= t "user_mailer.warning.explanation.#{@warning.action}", instance: @instance %>
|
||||
|
||||
<% end %>
|
||||
<% if @warning.text.present? %>
|
||||
<%= @warning.text %>
|
||||
<% if !@statuses.nil? && !@statuses.empty? %>
|
||||
|
||||
<% end %>
|
||||
<% if @warning.report && !@warning.report.other? %>
|
||||
**<%= t('user_mailer.warning.reason') %>** <%= t("user_mailer.warning.categories.#{@warning.report.category}") %>
|
||||
|
||||
<% if @warning.report.violation? && @warning.report.rule_ids.present? %>
|
||||
<% @warning.report.rules.each do |rule| %>
|
||||
- <%= rule.text %>
|
||||
<% end %>
|
||||
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% if !@statuses.empty? %>
|
||||
<%= t('user_mailer.warning.statuses') %>
|
||||
|
||||
<% @statuses.each do |status| %>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue