commit
a6493fab39
|
|
@ -296,12 +296,13 @@ class OverTimeController(http.Controller):
|
||||||
}
|
}
|
||||||
|
|
||||||
# if approvel:
|
# 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({
|
vals.update({
|
||||||
'account_id': body['account'],
|
'account_id': body['account'],
|
||||||
'journal_id': body['journal'],
|
'journal_id': body['journal'],
|
||||||
})
|
})
|
||||||
elif s.transfer_type == 'payroll' and 'rule' in body :
|
elif s.transfer_type == 'payroll' and body.get("rule") :
|
||||||
vals.update({
|
vals.update({
|
||||||
'benefits_discounts':int( body['rule']),
|
'benefits_discounts':int( body['rule']),
|
||||||
})
|
})
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue