minor fix

This commit is contained in:
Camilo Sarmiento 2020-10-07 16:58:50 -05:00
parent 43700fcc95
commit 5132753f99
1 changed files with 4 additions and 4 deletions

View File

@ -341,8 +341,8 @@ class Payroll(Workflow, ModelSQL, ModelView):
amount_credit = line.amount + expense
debit_acc = line.wage_type.debit_account
if 1:
# try:
# if 1:
try:
if debit_acc and amount_debit > _ZERO:
if line.wage_type.definition == 'discount':
amount_debit = amount_debit * (-1)
@ -390,8 +390,8 @@ class Payroll(Workflow, ModelSQL, ModelView):
if credit_acc and not line_credit_ready:
lines_moves[credit_acc.id][party.id]['credit'] += amount_credit
else:
# except:
# else:
except:
self.raise_user_error('bad_configuration_wage_type', line.wage_type.name)
result = []