[FIX] account_voucher : Allow to close payment voucher with 0.00 amount

bzr revid: nep@tinyerp.com-20120404113045-k2lrejk3b9oigv59
This commit is contained in:
nep-OpenERP
2012-04-04 17:00:45 +05:30
parent c3501275b3
commit 5aaa2cfe75
+2 -1
View File
@@ -1014,7 +1014,8 @@ class account_voucher(osv.osv):
for line in voucher_brw.line_ids:
#create one move line per voucher line where amount is not 0.0
if not line.amount:
continue
if line.amount != line_total:
continue
# convert the amount set on the voucher line into the currency of the voucher's company
amount = self._convert_amount(cr, uid, line.untax_amount or line.amount, voucher_brw.id, context=ctx)
# if the amount encoded in voucher is equal to the amount unreconciled, we need to compute the