[FIX]: purchase: Fixed invoiced rate for purchase order

bzr revid: rpa@tinyerp.com-20110414093540-lv5x998zs3cv770b
This commit is contained in:
Rucha (Open ERP)
2011-04-14 15:05:40 +05:30
parent ad0ececa4e
commit 39d0932dfa
+1 -1
View File
@@ -98,7 +98,7 @@ class purchase_order(osv.osv):
tot = 0.0
for invoice in purchase.invoice_ids:
if invoice.state not in ('draft','cancel'):
tot += invoice.amount_untaxed
tot += (invoice.amount_untaxed - invoice.residual)
if purchase.amount_untaxed:
res[purchase.id] = tot * 100.0 / purchase.amount_untaxed
else: