Skip to content
Snippets Groups Projects
Commit e9d40cac authored by jbm-odoo's avatar jbm-odoo
Browse files

[FIX] hr_recruitment_survey: Start survey, create answers


Use the correct function to create answers before strating the
survey.

closes odoo/odoo#38779

Signed-off-by: default avatarYannick Tivisse (yti) <yti@odoo.com>
parent 8c47c7f0
No related branches found
No related tags found
No related merge requests found
......@@ -13,7 +13,7 @@ class Applicant(models.Model):
self.ensure_one()
# create a response and link it to this applicant
if not self.response_id:
response = self.env['survey.user_input'].create({'survey_id': self.survey_id.id, 'partner_id': self.partner_id.id})
response = self.survey_id._create_answer(partner=self.partner_id)
self.response_id = response.id
else:
response = self.response_id
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment