Use double quotes in app/mailers
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
class ApplicationMailer < ActionMailer::Base
|
class ApplicationMailer < ActionMailer::Base
|
||||||
helper :settings
|
helper :settings
|
||||||
default from: "#{Setting['mailer_from_name']} <#{Setting['mailer_from_address']}>"
|
default from: "#{Setting['mailer_from_name']} <#{Setting['mailer_from_address']}>"
|
||||||
layout 'mailer'
|
layout "mailer"
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
class DeviseMailer < Devise::Mailer
|
class DeviseMailer < Devise::Mailer
|
||||||
helper :application, :settings
|
helper :application, :settings
|
||||||
include Devise::Controllers::UrlHelpers
|
include Devise::Controllers::UrlHelpers
|
||||||
default template_path: 'devise/mailer'
|
default template_path: "devise/mailer"
|
||||||
|
|
||||||
protected
|
protected
|
||||||
|
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = @commentable.author.email
|
@email_to = @commentable.author.email
|
||||||
|
|
||||||
with_user(@commentable.author) do
|
with_user(@commentable.author) do
|
||||||
subject = t('mailers.comment.subject', commentable: t("activerecord.models.#{@commentable.class.name.underscore}", count: 1).downcase)
|
subject = t("mailers.comment.subject", commentable: t("activerecord.models.#{@commentable.class.name.underscore}", count: 1).downcase)
|
||||||
mail(to: @email_to, subject: subject) if @commentable.present? && @commentable.author.present?
|
mail(to: @email_to, subject: subject) if @commentable.present? && @commentable.author.present?
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -33,7 +33,7 @@ class Mailer < ApplicationMailer
|
|||||||
@document_number = document_number
|
@document_number = document_number
|
||||||
|
|
||||||
with_user(user) do
|
with_user(user) do
|
||||||
mail(to: @email_to, subject: t('mailers.email_verification.subject'))
|
mail(to: @email_to, subject: t("mailers.email_verification.subject"))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -43,7 +43,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = @author.email
|
@email_to = @author.email
|
||||||
|
|
||||||
with_user(@author) do
|
with_user(@author) do
|
||||||
mail(to: @email_to, subject: t('mailers.unfeasible_spending_proposal.subject', code: @spending_proposal.code))
|
mail(to: @email_to, subject: t("mailers.unfeasible_spending_proposal.subject", code: @spending_proposal.code))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -53,7 +53,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = @receiver.email
|
@email_to = @receiver.email
|
||||||
|
|
||||||
with_user(@receiver) do
|
with_user(@receiver) do
|
||||||
mail(to: @email_to, subject: t('mailers.direct_message_for_receiver.subject'))
|
mail(to: @email_to, subject: t("mailers.direct_message_for_receiver.subject"))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -63,7 +63,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = @sender.email
|
@email_to = @sender.email
|
||||||
|
|
||||||
with_user(@sender) do
|
with_user(@sender) do
|
||||||
mail(to: @email_to, subject: t('mailers.direct_message_for_sender.subject'))
|
mail(to: @email_to, subject: t("mailers.direct_message_for_sender.subject"))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -72,7 +72,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = user.email
|
@email_to = user.email
|
||||||
|
|
||||||
with_user(user) do
|
with_user(user) do
|
||||||
mail(to: @email_to, subject: t('mailers.proposal_notification_digest.title', org_name: Setting['org_name']))
|
mail(to: @email_to, subject: t("mailers.proposal_notification_digest.title", org_name: Setting["org_name"]))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -80,7 +80,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = email
|
@email_to = email
|
||||||
|
|
||||||
I18n.with_locale(I18n.default_locale) do
|
I18n.with_locale(I18n.default_locale) do
|
||||||
mail(to: @email_to, subject: t('mailers.user_invite.subject', org_name: Setting["org_name"]))
|
mail(to: @email_to, subject: t("mailers.user_invite.subject", org_name: Setting["org_name"]))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -89,7 +89,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = @investment.author.email
|
@email_to = @investment.author.email
|
||||||
|
|
||||||
with_user(@investment.author) do
|
with_user(@investment.author) do
|
||||||
mail(to: @email_to, subject: t('mailers.budget_investment_created.subject'))
|
mail(to: @email_to, subject: t("mailers.budget_investment_created.subject"))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -99,7 +99,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = @author.email
|
@email_to = @author.email
|
||||||
|
|
||||||
with_user(@author) do
|
with_user(@author) do
|
||||||
mail(to: @email_to, subject: t('mailers.budget_investment_unfeasible.subject', code: @investment.code))
|
mail(to: @email_to, subject: t("mailers.budget_investment_unfeasible.subject", code: @investment.code))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -109,7 +109,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = @author.email
|
@email_to = @author.email
|
||||||
|
|
||||||
with_user(@author) do
|
with_user(@author) do
|
||||||
mail(to: @email_to, subject: t('mailers.budget_investment_selected.subject', code: @investment.code))
|
mail(to: @email_to, subject: t("mailers.budget_investment_selected.subject", code: @investment.code))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -119,7 +119,7 @@ class Mailer < ApplicationMailer
|
|||||||
@email_to = @author.email
|
@email_to = @author.email
|
||||||
|
|
||||||
with_user(@author) do
|
with_user(@author) do
|
||||||
mail(to: @email_to, subject: t('mailers.budget_investment_unselected.subject', code: @investment.code))
|
mail(to: @email_to, subject: t("mailers.budget_investment_unselected.subject", code: @investment.code))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user