Class: ApplicantsController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- ApplicantsController
- Defined in:
- app/controllers/applicants_controller.rb
Instance Method Summary collapse
Instance Method Details
#create ⇒ Object
14 15 16 17 18 19 20 21 22 23 24 |
# File 'app/controllers/applicants_controller.rb', line 14 def create @applicant = Applicant.new(params[:applicant]) if @applicant.save if RefinerySetting.find_or_set(:applicant_recipients, '').present? ApplicantMailer.notification(@applicant, request).deliver end redirect_to thank_you_applicants_url else render :action => 'new' end end |
#new ⇒ Object
9 10 11 12 |
# File 'app/controllers/applicants_controller.rb', line 9 def new @applicant = Applicant.new @applicant.build_answers end |
#thank_you ⇒ Object
5 6 7 |
# File 'app/controllers/applicants_controller.rb', line 5 def thank_you @page = Page.find_by_link_url('/apply/thank-you', :include => [:parts, :slugs]) end |