Submit summary
This commit is contained in:
@ -37,14 +37,13 @@ class CandidateController < ApplicationController
|
||||
redirect_to :question and return unless prep_status.current_question_id.nil?
|
||||
end
|
||||
|
||||
# TODO
|
||||
def update_summary
|
||||
# redirect_to :summary
|
||||
|
||||
# only after successful submission
|
||||
CandidateMailer.submitted(current_candidate).deliver_now
|
||||
RecruiterMailer.candidate_submitted(current_candidate).deliver_now
|
||||
ReviewerMailer.candidate_submission(current_candidate).deliver_now
|
||||
prep_status
|
||||
not_completed_error = 'You must complete all questions to submit your test.'
|
||||
record_error = 'There was a problem with your submission. Please try again later.'
|
||||
redirect_to :summary, flash: { error: not_completed_error } and return unless @status.can_submit
|
||||
redirect_to :thankyou and return if current_candidate.complete!
|
||||
redirect_to :summary, flash: { error: record_error }
|
||||
end
|
||||
|
||||
def validate
|
||||
|
Reference in New Issue
Block a user