Class: WCC::Contentful::App::ContactFormController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- WCC::Contentful::App::ContactFormController
show all
- Includes:
- PreviewPassword
- Defined in:
- app/controllers/wcc/contentful/app/contact_form_controller.rb
Instance Method Summary
collapse
#preview?, #preview_password
Instance Method Details
#create ⇒ Object
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
# File 'app/controllers/wcc/contentful/app/contact_form_controller.rb', line 6
def create
address =
form_model.to_address(email_object_id: params[:email_object_id])
form_model.send_email(
form_params.merge!(
{
notification_email: address,
internal_title: params[:internal_title]
}
)
)
render json: { type: 'success', message: "Thanks for reaching out. We'll be in touch soon!" }
end
|