Sha256: 79e4ec38a76ab1aa6b195657a527c797ed12b8f4d3471954ccf0a44e53e6379f

Contents?: true

Size: 679 Bytes

Versions: 2

Compression:

Stored size: 679 Bytes

Contents

module IshManager
  class ApplicationMailer < ActionMailer::Base
    default from: '314658@gmail.com'
    layout 'mailer'

    def shared_galleries profiles, gallery
      return if profiles.count == 0
      @gallery        = gallery
      @domain         = Rails.application.config.action_mailer.default_url_options[:host]
      @galleries_path = IshManager::Engine.routes.url_helpers.galleries_path
      @gallery_path   = IshManager::Engine.routes.url_helpers.gallery_path(@gallery.slug)
      mail( :to => '314658@gmail.com',
            :bcc => profiles.map { |p| p.email },
            :subject => 'You got new shared galleries on pi manager' ).deliver
    end

  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
ish_manager-0.1.8.277 app/mailers/ish_manager/application_mailer.rb
ish_manager-0.1.8.274 app/mailers/ish_manager/application_mailer.rb