Create new email template for new evaluation comment created and add it to system_emails view

This commit is contained in:
lalo
2019-03-27 12:13:43 +01:00
parent a6f8969728
commit 28815cb290
14 changed files with 248 additions and 8 deletions

View File

@@ -120,6 +120,13 @@ class Mailer < ApplicationMailer
mail(to: @email_to, from: @newsletter.from, subject: @newsletter.subject)
end
def evaluation_comment(comment, to)
@email = EvaluationCommentEmail.new(comment)
@email_to = to
mail(to: @email_to.email, subject: @email.subject) if @email.can_be_sent?
end
private
def with_user(user, &block)