Sha256: effad53617997da87792478af2bdacbe8cc25862e4c9c5e7287c9618e5d58dae

Contents?: true

Size: 1.63 KB

Versions: 1

Compression:

Stored size: 1.63 KB

Contents

o:$YARD::CodeObjects::MethodObject:@current_file_has_commentsT:
@linei:@signature"-def send_marketing_mail(template, *args):@scope:
class:@source"³def send_marketing_mail(template, *args)
  options = args.extract_options!
  options[:locale] ||= I18n.locale

  # ensure the :to parameter.
  raise "Should specify :to option" if options[:to].blank?

  # find the template from database.
  template_path = File.join("mail_engine", "mail_dispatcher", template)
  unless mail_template = MailEngine::MailTemplate.where(:path => template_path, :locale => options[:locale], :for_marketing => true, :partial => false).first
    raise "Can't find the template: #{template_path}"
  end

  options[:subject] ||= mail_template.subject
  I18n.with_locale(mail_template.locale) do
    MailEngine::MailDispatcher.send(template, options).deliver
  end
end:
@tags[:@docstringIC:YARD::Docstring"±send mail template with given data.
=== example

  MailEngine::Base.send_marketing_mail("newsletter", :to => 'm@theplant.jp', :values => {:users => MailEngine::USER_MODEL.last}):@ref_tags[;[:@objectu:YARD::StubProxy)MailEngine::Base.send_marketing_mail:
@summary0:	@all[
"(send mail template with given data."=== example""€  MailEngine::Base.send_marketing_mail("newsletter", :to => 'm@theplant.jp', :values => {:users => MailEngine::USER_MODEL.last})":@line_rangeo:
Range:endi:
begini:	exclF:@namespaceu;MailEngine::Base:@files[["lib/mail_engine/base.rbi:
@name:send_marketing_mail:
@dynamicT:
@path")MailEngine::Base.send_marketing_mail:@parameters[["
template0["
*args0:@docstring_extra0:@visibility:public:@source_type:	ruby:@explicitT

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
mail_engine-0.1.0 .yardoc/objects/MailEngine/Base/send_marketing_mail_c.dat