Class: EffectivePollsMailerPreview

Inherits:
ActionMailer::Preview
  • Object
show all
Defined in:
lib/generators/templates/effective_polls_mailer_preview.rb

Overview

Instance Method Summary collapse

Instance Method Details

#poll_endObject



19
20
21
22
# File 'lib/generators/templates/effective_polls_mailer_preview.rb', line 19

def poll_end
  poll_notification = build_poll_notification('The poll has ended')
  Effective::PollsMailer.poll_end(poll_notification, bccs)
end

#poll_reminderObject



14
15
16
17
# File 'lib/generators/templates/effective_polls_mailer_preview.rb', line 14

def poll_reminder
  poll_notification = build_poll_notification('This is a reminder')
  Effective::PollsMailer.poll_reminder(poll_notification, bccs)
end

#poll_startObject



9
10
11
12
# File 'lib/generators/templates/effective_polls_mailer_preview.rb', line 9

def poll_start
  poll_notification = build_poll_notification('The poll has started')
  Effective::PollsMailer.poll_start(poll_notification, bccs)
end

#poll_upcoming_reminder(poll_notification, bcc) ⇒ Object



5
6
7
# File 'lib/generators/templates/effective_polls_mailer_preview.rb', line 5

def poll_upcoming_reminder(poll_notification, bcc)
  mail(bcc: bcc, body: poll_notification.body, subject: poll_notification.subject)
end