Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
2 Odpowiedzi
2792 Widoki

How to setup a state named onhold in payroll process along with draft and done because we need salary of few employees on hold. Suppose if an employee going to relieve by next month end, we will hold this month and settle the entire amount in next month.

Help us hos to handle this scenario

Awatar
Odrzuć
Autor Najlepsza odpowiedź

Above code is not working

Awatar
Odrzuć
Najlepsza odpowiedź

Inherit the model hr.payslip and you can add the new value to the state field, add below code in the Python side and do necessary changes in the views like adding button to control this state etc


class HrPayslip(models.Model):
_inherit = 'hr.payslip'

state = fields.Selection(
selection_add=[('hold', 'On Hold')])
Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
1
wrz 22
4594
0
kwi 21
1986
1
wrz 25
563
1
maj 25
1786
1
kwi 25
4157