Reset amount to pay with Decimal
Otherwise amount to pay can not copy sign from line. Closes #13023 (grafted from 30926e7b8b6fe5deaffeea6a9c8efb120ff2b638) --HG-- branch : 6.0
This commit is contained in:
@@ -349,7 +349,7 @@ class Statement(Workflow, ModelSQL, ModelView):
|
||||
new_line.invoice = None
|
||||
line_offset += 1
|
||||
lines.insert(index + line_offset, new_line)
|
||||
invoice_id2amount_to_pay[line.invoice.id] = 0
|
||||
invoice_id2amount_to_pay[line.invoice.id] = Decimal(0)
|
||||
line.amount = amount_to_pay.copy_sign(line.amount)
|
||||
else:
|
||||
invoice_id2amount_to_pay[line.invoice.id] = (
|
||||
|
||||
Reference in New Issue
Block a user