[FIX] account_analytic_analysis: Change the query for the order quantity

bzr revid: stephane@openerp.com-20110426142951-fjvvuqbigpkkxbhd
This commit is contained in:
Stephane Wirtel 2011-04-26 16:29:51 +02:00
parent 7582068093
commit b8519868a8
1 changed files with 4 additions and 1 deletions

View File

@ -378,7 +378,10 @@ class account_analytic_account(osv.osv):
result = dict.fromkeys(ids, 0)
for record in self.browse(cr, uid, ids, context=context):
result[record.id] = int(record.quantity >= record.quantity_max)
if record.quantity == 0.0 and record.quantity_max == 0.0:
result[record.id] = 0
else:
result[record.id] = int(record.quantity >= record.quantity_max)
return result