Helpers for defining and delivering email messages.
Delivers a mailer message email with the given attributes.
@param [Symbol] mailer_name
The name of the mailer.
@param [Symbol] message_name
The name of the message to deliver.
@param attributes
The parameters to pass to the mailer.
@example
deliver(:sample, :birthday, "Joey", 21) deliver(:example, :message, "John")
@see ClassMethods#deliver @api public
# File lib/padrino-mailer/helpers.rb, line 50 def deliver(mailer_name, message_name, *attributes) settings.deliver(mailer_name, message_name, *attributes) end
Delivers an email with the given mail attributes.
@param [Hash] mail_attributes
The attributes for this message (to, from, subject, cc, bcc, body, etc)
@param [Proc] block
The block mail attributes for this message.
@example
email do to @user.email from "awesomeness@example.com" subject "Welcome to Awesomeness!" locals :a => a, :b => b render 'path/to/my/template' end
@see ClassMethods#email @api public
# File lib/padrino-mailer/helpers.rb, line 30 def email(mail_attributes={}, &block) settings.email(mail_attributes, &block) end
Generated with the Darkfish Rdoc Generator 2.