[FIX] stock: on inventory, product qty should be computed up to 'inventory date', not after
bzr revid: xal@openerp.com-20120327083440-m4sr25bv7wtodmr1
This commit is contained in:
parent
85be0cf0a4
commit
69d6d9ba8f
|
@ -2670,7 +2670,7 @@ class stock_inventory(osv.osv):
|
|||
move_ids = []
|
||||
for line in inv.inventory_line_id:
|
||||
pid = line.product_id.id
|
||||
product_context.update(uom=line.product_uom.id, date=inv.date, prodlot_id=line.prod_lot_id.id)
|
||||
product_context.update(uom=line.product_uom.id, to_date=inv.date, date=inv.date, prodlot_id=line.prod_lot_id.id)
|
||||
amount = location_obj._product_get(cr, uid, line.location_id.id, [pid], product_context)[pid]
|
||||
|
||||
change = line.product_qty - amount
|
||||
|
|
Loading…
Reference in New Issue