diff options
| author | larisa <larisa@merchise.org> | 2018-12-24 20:17:47 +0000 |
|---|---|---|
| committer | Martin Trigaux <mat@odoo.com> | 2019-01-14 15:16:44 +0000 |
| commit | 6edfadbdd2abf13aed42a9cd7392ca42edbbc52e (patch) | |
| tree | 74c0cc130d8af69bc086bfe1a9f9e8a21508c68d | |
| parent | 9c6d9697754d3e661794fa7be890ebccde6818ed (diff) | |
[FIX] hr_payroll_account: correct account move lines creation
The super call of action_payslip_done executes the method compute_sheet.
Without this compute_sheet call, there is no salary lines and no accounting
move is created.
closes odoo/odoo#29737
| -rw-r--r-- | addons/hr_payroll_account/models/hr_payroll_account.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/addons/hr_payroll_account/models/hr_payroll_account.py b/addons/hr_payroll_account/models/hr_payroll_account.py index e76173d45a4..93d2ad307bf 100644 --- a/addons/hr_payroll_account/models/hr_payroll_account.py +++ b/addons/hr_payroll_account/models/hr_payroll_account.py @@ -53,6 +53,7 @@ class HrPayslip(models.Model): @api.multi def action_payslip_done(self): + res = super(HrPayslip, self).action_payslip_done() precision = self.env['decimal.precision'].precision_get('Payroll') for slip in self: @@ -138,7 +139,7 @@ class HrPayslip(models.Model): move = self.env['account.move'].create(move_dict) slip.write({'move_id': move.id, 'date': date}) move.post() - return super(HrPayslip, self).action_payslip_done() + return res class HrSalaryRule(models.Model): |
