Incomplete/missing text in notification emails [SCI-9843]

This commit is contained in:
Giga Chubinidze 2023-12-11 11:52:28 +04:00
parent 94e8a8d89f
commit 69ca8c5022
2 changed files with 9 additions and 3 deletions

View file

@ -4,7 +4,7 @@ class RepositoryItemDateNotification < BaseNotification
def message
unit = human_readable_unit(column.metadata['reminder_unit'], column.metadata['reminder_value'])
I18n.t(
'notifications.notification.item_date_reminder_html',
'notifications.content.item_date_reminder.message_html',
repository_row_name: subject.name,
value: column.metadata['reminder_value'],
units: unit
@ -15,7 +15,9 @@ class RepositoryItemDateNotification < BaseNotification
:item_date_reminder
end
def title; end
def title
I18n.t('notifications.content.item_date_reminder.title_html')
end
def subject
RepositoryRow.find(params[:repository_row_id])
@ -36,6 +38,8 @@ class RepositoryItemDateNotification < BaseNotification
private
def human_readable_unit(seconds, value)
return unless seconds
units_hash = {
'2419200' => 'month',
'604800' => 'week',

View file

@ -12,7 +12,9 @@ class TaskDueDateNotification < BaseNotification
:my_module_due_date_reminder
end
def title; end
def title
I18n.t('notifications.content.my_module_due_date_reminder.title_html')
end
def subject
MyModule.find(params[:my_module_id])