I reed Tower.js doc and totally cant see - how I may get worked mailer?
Mailers section said:
class App.Notification extends Tower.Mailer
# app/views/mailers/welcome.coffee template
@welcome: (user) ->
@mail to: user.email, from: "me@gmail.com"
but example do not marked where this code need to be placed.
Please appoint me.
I believe the mailer should go in app/mailers
, based on the generator for mailers:
class Tower.Generator.MailerGenerator extends Tower.Generator
sourceRoot: __dirname
run: ->
@inside "app", '.', ->
@inside "mailers", '.', ->
@template "mailer.coffee", "#{@model.name}Mailer.coffee", ->
module.exports = Tower.Generator.MailerGenerator