diff options
author | Heinrich Lee Yu <heinrich@gitlab.com> | 2018-12-12 17:51:36 +0800 |
---|---|---|
committer | Heinrich Lee Yu <hleeyu@gmail.com> | 2018-12-21 18:00:14 +0800 |
commit | 51ac77af9a9bd70297ae6dd8c0290c73a46d8bf8 (patch) | |
tree | 80f309b336f92f7d841129d67bcbbe93f9db45dd /app/mailers | |
parent | 62d250ff666770f9807eec2199a7b208ea8b518a (diff) | |
download | gitlab-ce-51ac77af9a9bd70297ae6dd8c0290c73a46d8bf8.tar.gz |
Add date range to milestone changed emails
Also refactored issues and MRs to use the same email template file
Diffstat (limited to 'app/mailers')
-rw-r--r-- | app/mailers/emails/issues.rb | 4 | ||||
-rw-r--r-- | app/mailers/emails/merge_requests.rb | 4 | ||||
-rw-r--r-- | app/mailers/notify.rb | 1 |
3 files changed, 7 insertions, 2 deletions
diff --git a/app/mailers/emails/issues.rb b/app/mailers/emails/issues.rb index 93b51fb1774..370e6d2f90b 100644 --- a/app/mailers/emails/issues.rb +++ b/app/mailers/emails/issues.rb @@ -56,7 +56,9 @@ module Emails @milestone = milestone @milestone_url = milestone_url(@milestone) - mail_answer_thread(@issue, issue_thread_options(updated_by_user_id, recipient_id, reason)) + mail_answer_thread(@issue, issue_thread_options(updated_by_user_id, recipient_id, reason).merge({ + template_name: 'changed_milestone_email' + })) end def issue_status_changed_email(recipient_id, issue_id, status, updated_by_user_id, reason = nil) diff --git a/app/mailers/emails/merge_requests.rb b/app/mailers/emails/merge_requests.rb index 6524d0c2087..9ba8f92fcbf 100644 --- a/app/mailers/emails/merge_requests.rb +++ b/app/mailers/emails/merge_requests.rb @@ -51,7 +51,9 @@ module Emails @milestone = milestone @milestone_url = milestone_url(@milestone) - mail_answer_thread(@merge_request, merge_request_thread_options(updated_by_user_id, recipient_id, reason)) + mail_answer_thread(@merge_request, merge_request_thread_options(updated_by_user_id, recipient_id, reason).merge({ + template_name: 'changed_milestone_email' + })) end def closed_merge_request_email(recipient_id, merge_request_id, updated_by_user_id, reason = nil) diff --git a/app/mailers/notify.rb b/app/mailers/notify.rb index 15710bee4d4..efa1233b434 100644 --- a/app/mailers/notify.rb +++ b/app/mailers/notify.rb @@ -16,6 +16,7 @@ class Notify < BaseMailer include Emails::AutoDevops include Emails::RemoteMirrors + helper MilestonesHelper helper MergeRequestsHelper helper DiffHelper helper BlobHelper |