mirror of
https://github.com/mastodon/mastodon.git
synced 2024-11-26 15:31:52 +00:00
Add list of pending releases directly in mail notifications for version updates (#29436)
This commit is contained in:
parent
32938dadd7
commit
cfea9cc172
|
@ -46,12 +46,16 @@ class AdminMailer < ApplicationMailer
|
|||
end
|
||||
|
||||
def new_software_updates
|
||||
@software_updates = SoftwareUpdate.all.to_a.sort_by(&:gem_version)
|
||||
|
||||
locale_for_account(@me) do
|
||||
mail subject: default_i18n_subject(instance: @instance)
|
||||
end
|
||||
end
|
||||
|
||||
def new_critical_software_updates
|
||||
@software_updates = SoftwareUpdate.where(urgent: true).to_a.sort_by(&:gem_version)
|
||||
|
||||
headers['Priority'] = 'urgent'
|
||||
headers['X-Priority'] = '1'
|
||||
headers['Importance'] = 'high'
|
||||
|
|
|
@ -1,3 +1,7 @@
|
|||
<%= raw t('admin_mailer.new_critical_software_updates.body') %>
|
||||
|
||||
<% @software_updates.each do |update| %>
|
||||
- Mastodon #{update.version}: #{update.release_notes}
|
||||
<% end %>
|
||||
|
||||
<%= raw t('application_mailer.view')%> <%= admin_software_updates_url %>
|
||||
|
|
|
@ -1,3 +1,7 @@
|
|||
<%= raw t('admin_mailer.new_software_updates.body') %>
|
||||
|
||||
<% @software_updates.each do |update| %>
|
||||
- Mastodon #{update.version}: #{update.release_notes}
|
||||
<% end %>
|
||||
|
||||
<%= raw t('application_mailer.view')%> <%= admin_software_updates_url %>
|
||||
|
|
Loading…
Reference in New Issue
Block a user