Class: Integral::ContactController

Inherits:
Object
  • Object
show all
Defined in:
app/controllers/integral/contact_controller.rb

Overview

Handles visitor communications

Instance Method Summary collapse

Instance Method Details

#contactObject

POST /contact



5
6
7
8
9
10
11
12
13
# File 'app/controllers/integral/contact_controller.rb', line 5

def contact
  @enquiry = Enquiry.new(contact_params)

  if @enquiry.save
    head :created
  else
    head :unprocessable_entity
  end
end

#newsletter_signupObject

POST /newsletter_signup



16
17
18
19
20
21
22
23
24
# File 'app/controllers/integral/contact_controller.rb', line 16

def 
  resource = NewsletterSignup.new()

  if resource.save
    head :created
  else
    head :unprocessable_entity
  end
end