small fix
This commit is contained in:
parent
76d0976ae8
commit
e3bdb3148a
|
@ -133,8 +133,20 @@ class RecruitmentsController < PseudoSessionController
|
||||||
end
|
end
|
||||||
|
|
||||||
def show_candidate(params)
|
def show_candidate(params)
|
||||||
|
rp = RecruitProfile.where(:uid => params[:uid]).first
|
||||||
|
profile = rp.profile
|
||||||
|
phone = !profile.country_code.nil? ? profile.country_code + " - " + profile.phone_number : profile.phone_number
|
||||||
|
skills = profile.skills
|
||||||
{
|
{
|
||||||
"data" => {}
|
"data" => {
|
||||||
|
"name" => rp.name,
|
||||||
|
"job-title" => profile.desired_job_title,
|
||||||
|
"company-name" => profile.current_company,
|
||||||
|
"phone" => phone,
|
||||||
|
"email" => rp.email,
|
||||||
|
"website" => profile.website,
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -462,7 +474,7 @@ class RecruitmentsController < PseudoSessionController
|
||||||
|
|
||||||
def profile_params
|
def profile_params
|
||||||
par = params.require(:recruit_profile).permit!
|
par = params.require(:recruit_profile).permit!
|
||||||
if par[:employee_profile_attributes][:skills].present?
|
if par[:employee_profile_attributes].present? && par[:employee_profile_attributes][:skills].present?
|
||||||
par[:employee_profile_attributes][:skills] = par[:employee_profile_attributes][:skills].split(",")
|
par[:employee_profile_attributes][:skills] = par[:employee_profile_attributes][:skills].split(",")
|
||||||
par[:employee_profile_attributes][:skills].collect!{|sk| sk.strip}
|
par[:employee_profile_attributes][:skills].collect!{|sk| sk.strip}
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue