aboutsummaryrefslogblamecommitdiffstats
path: root/actionmailer/lib/rails/generators/mailer/templates/mailer.rb
blob: edcfb4233d1bc500e9a868e35c898b68c750b040 (plain) (tree)
1
2
3
4
5
6
7
8
9
                            
                                            
                                  
                               
 


                                                                 
                                                           


                    
 
                             
     
          
   
          
<% module_namespacing do -%>
class <%= class_name %> < ActionMailer::Base
  default from: "from@example.com"
<% actions.each do |action| -%>

  # Subject can be set in your I18n file at config/locales/en.yml
  # with the following lookup:
  #
  #   en.<%= file_path.tr("/",".") %>.<%= action %>.subject
  #
  def <%= action %>
    @greeting = "Hi"

    mail to: "to@example.org"
  end
<% end -%>
end
<% end -%>