bugfix improvement

bzr revid: hda@hda-20090310133602-6mazh2nkhce1nwxa
This commit is contained in:
husen daudi
2009-03-10 19:06:02 +05:30
parent 154b124792
commit e424378d4d
+2 -3
View File
@@ -761,9 +761,8 @@ class stock_production_lot(osv.osv):
if context is None:
context = {}
res = super(stock_production_lot, self).search(cr, uid, args, offset, limit, order, context=context, count=count)
for k,v in self._get_stock(cr, uid, res, 'stock_available', None, context).items():
if v==0.0:
res.remove(k)
if res:
return [k for k,v in self._get_stock(cr, uid, res, 'stock_available', None, context).items() if v]
return res
def name_get(self, cr, uid, ids, context={}):