Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-01-14 21:10:59 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2021-01-14 21:10:59 +0300
commitea3306a15e945e694afba62dc93b17500ffaec7f (patch)
treeaa444f7fe503e5650bfdb6500ed428b4619ff37b /app/mailers/emails/members.rb
parent8106ac487c3b52471e2ca894c65c13162c2fb1a8 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/mailers/emails/members.rb')
-rw-r--r--app/mailers/emails/members.rb17
1 files changed, 17 insertions, 0 deletions
diff --git a/app/mailers/emails/members.rb b/app/mailers/emails/members.rb
index 02726c4354e..69f5fe1430a 100644
--- a/app/mailers/emails/members.rb
+++ b/app/mailers/emails/members.rb
@@ -114,6 +114,23 @@ module Emails
subject: subject('Invitation declined'))
end
+ def member_expiration_date_updated_email(member_source_type, member_id)
+ @member_source_type = member_source_type
+ @member_id = member_id
+
+ return unless member_exists?
+
+ subject = if member.expires?
+ _('Group membership expiration date changed')
+ else
+ _('Group membership expiration date removed')
+ end
+
+ member_email_with_layout(
+ to: member.user.notification_email_for(notification_group),
+ subject: subject(subject))
+ end
+
# rubocop: disable CodeReuse/ActiveRecord
def member
@member ||= Member.find_by(id: @member_id)