Class: Decidim::Conferences::Admin::InviteJoinConferenceMailer
- Inherits:
-
ApplicationMailer
- Object
- ApplicationMailer
- Decidim::Conferences::Admin::InviteJoinConferenceMailer
- Includes:
- SanitizeHelper, TranslationsHelper
- Defined in:
- app/mailers/decidim/conferences/admin/invite_join_conference_mailer.rb
Overview
A custom mailer for sending an invitation to join a conference to an existing user.
Instance Method Summary collapse
-
#invite(user, conference, registration_type, invited_by) ⇒ Object
Send an email to an user to invite them to join a conference.
Instance Method Details
#invite(user, conference, registration_type, invited_by) ⇒ Object
Send an email to an user to invite them to join a conference.
user - The user being invited conference - The conference being joined. invited_by - The user performing the invitation.
22 23 24 25 26 27 28 29 30 31 32 33 34 |
# File 'app/mailers/decidim/conferences/admin/invite_join_conference_mailer.rb', line 22 def invite(user, conference, registration_type, invited_by) with_user(user) do @user = user @conference = conference @invited_by = invited_by @organization = @conference.organization @locator = Decidim::ResourceLocatorPresenter.new(@conference) @registration_type = registration_type subject = I18n.t("invite.subject", scope: "decidim.conferences.mailer.invite_join_conference_mailer") mail(to: user.email, subject:) end end |