metamaps--metamaps/app/mailers/map_mailer.rb
Connor Turland b0deafc53e Follows and some new notifications (#1063)
* all the good changes

* follows

* dont send duplicates

* remove follow_type for now

* dont add all the extra stuff we're not implementing yet

* refactor

* lots of fixes

* Delete activity.html.erb

* Delete activity.text.erb

* Update 20170209215819_create_follows.rb

* Update schema.rb

* Update mapping.rb

* Update mailboxer.rb
2017-02-11 00:20:42 -05:00

23 lines
608 B
Ruby

# frozen_string_literal: true
class MapMailer < ApplicationMailer
include MapMailerHelper
default from: 'team@metamaps.cc'
def access_approved(request)
@request = request
@map = request.map
mail(to: request.user.email, subject: access_approved_subject(@map))
end
def access_request(request)
@request = request
@map = request.map
mail(to: @map.user.email, subject: access_request_subject(@map))
end
def invite_to_edit(user_map)
@inviter = user_map.map.user
@map = user_map.map
mail(to: user_map.user.email, subject: invite_to_edit_subject(@map))
end
end