Skip to content

Commit

Permalink
Merge 'dev': cc authors on new submission emails
Browse files Browse the repository at this point in the history
  • Loading branch information
jweisber committed Apr 9, 2019
2 parents 13e47dc + 3c042cb commit 3f90e64
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions app/mailers/notification_mailer.rb
Expand Up @@ -38,7 +38,9 @@ def notify_me_new_submission(submission)
managing_editors = User.where(managing_editor: true)
@recipients_list = name_list(managing_editors)

message = mail(to: mailto_string(managing_editors), subject: 'New Submission')
message = mail(to: mailto_string(managing_editors),
cc: mailto_string([@submission.author]),
subject: 'New Submission')
end

def remind_managing_editors_assignment_overdue(submission)
Expand Down Expand Up @@ -465,7 +467,7 @@ def cc_editors
'notify_re_outcome'
]

message.cc = Mail::AddressContainer.new('cc') # TODO: is this right? Unnecessary?
message.cc = Mail::AddressContainer.new('cc') unless message.cc.present?

if cc_managing_editors_actions.include? action_name
message.cc << mailto_string(managing_editors)
Expand Down
@@ -1,4 +1,4 @@
Dear <%= @recipients_list %>,
Dear Managing Editors (cc <%= @submission.author.full_name %>),

A new manuscript has been submitted to Ergo: submission #<%= @submission.id %>, "<%= @submission.title %>".

Expand Down

0 comments on commit 3f90e64

Please sign in to comment.