Error in Purchase Return where journal amounts do not match due to rounding fixed.
This commit is contained in:
parent
867935306d
commit
6e6113436b
@ -50,7 +50,7 @@ def purchase_return_create_journals(inventories, ledgerID):
|
|||||||
ledger = Product.by_id(item.product_id).ledger
|
ledger = Product.by_id(item.product_id).ledger
|
||||||
amount += round(item.amount, 2)
|
amount += round(item.amount, 2)
|
||||||
if ledger.id in journals:
|
if ledger.id in journals:
|
||||||
journals[ledger.id].amount += item.amount
|
journals[ledger.id].amount += amount
|
||||||
else:
|
else:
|
||||||
journals[ledger.id] = Journal(debit=-1, cost_center_id=ledger.costcenter_id, ledger_id=ledger.id,
|
journals[ledger.id] = Journal(debit=-1, cost_center_id=ledger.costcenter_id, ledger_id=ledger.id,
|
||||||
amount=item.amount)
|
amount=item.amount)
|
||||||
|
Loading…
Reference in New Issue
Block a user