[FIX] hr_recruitment_survey: bound applicant with survey answer
Issue: When applicant retakes the survey, we only see the first answer of the applicant from -Consult Interview- smartbutton from the applicant form. Desired behavior: We should see the latest answer closes odoo/odoo#159833 Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
This commit is contained in:
@@ -2,3 +2,4 @@
|
||||
|
||||
from . import models
|
||||
from . import wizard
|
||||
from . import controllers
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from . import main
|
||||
@@ -0,0 +1,12 @@
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from odoo.addons.survey.controllers import main
|
||||
|
||||
|
||||
class ApplicantSurvey(main.Survey):
|
||||
def _prepare_retry_additional_values(self, answer):
|
||||
result = super()._prepare_retry_additional_values(answer)
|
||||
if answer.applicant_id:
|
||||
result["applicant_id"] = answer.applicant_id.id
|
||||
|
||||
return result
|
||||
@@ -0,0 +1,11 @@
|
||||
Vietnam, 2024-03-29
|
||||
|
||||
I hereby agree to the terms of the Odoo Individual Contributor License
|
||||
Agreement v1.0.
|
||||
|
||||
I declare that I am authorized and able to make this agreement and sign this
|
||||
declaration.
|
||||
|
||||
Signed,
|
||||
|
||||
Pham Van Bao 58139951+baor000@users.noreply.github.com https://github.com/baor000
|
||||
Reference in New Issue
Block a user