Contact us page and popup

This commit is contained in:
Godwin
2016-07-09 23:29:46 -07:00
parent c6f8d4ed58
commit 22b7dc2129
15 changed files with 340 additions and 168 deletions
+16
View File
@@ -184,6 +184,22 @@ class UserMailer < ActionMailer::Base
mail to: 'goodgodwin@hotmail.com', subject: @subject
end
def contact(from, subject, message, email_list)
@message = message
@from = from
mail to: email_list.join(', '), subject: @subject, reply_to: from.is_a?(User) ? from.named_email : from
end
def contact_details(from, subject, message, request, params)
@message = message
@from = from
@request = request
@params = params
mail to: 'goodgodwin@hotmail.com', subject: @subject
end
private
def set_host(*args)
if Rails.env.production?