Update taxes_and_totals.py

This commit is contained in:
Rushabh Mehta 2017-05-19 18:59:16 +05:30 committed by Nabin Hait
parent bf4915b285
commit e4afab7fb0

View File

@ -462,9 +462,10 @@ class calculate_taxes_and_totals(object):
if self.doc.is_pos:
for payment in self.doc.get('payments'):
payment.base_amount = flt(flt(payment.amount) * self.doc.conversion_rate)
paid_amount += flt(payment.amount)
base_paid_amount += flt(payment.base_amount)
payment.amount = flt(payment.amount)
payment.base_amount = payment.amount * flt(self.doc.conversion_rate)
paid_amount += payment.amount
base_paid_amount += payment.base_amount
elif not self.doc.is_return:
self.doc.set('payments', [])