Merge pull request #254 from expsa/dev_odex25_mobile

Dev odex25 mobile
This commit is contained in:
AbuzarExp 2024-07-17 15:43:12 +03:00 committed by GitHub
commit a6493fab39
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 2 deletions

View File

@ -296,12 +296,13 @@ class OverTimeController(http.Controller):
}
# if approvel:
if s.transfer_type == 'accounting' and 'account' in body and 'journal' in body:
s.write(vals)
if s.transfer_type == 'accounting' and body.get("account") and body.get("journal"):
vals.update({
'account_id': body['account'],
'journal_id': body['journal'],
})
elif s.transfer_type == 'payroll' and 'rule' in body :
elif s.transfer_type == 'payroll' and body.get("rule") :
vals.update({
'benefits_discounts':int( body['rule']),
})