← Back to team overview

openerp-dev-web team mailing list archive

[Merge] lp:~openerp-dev/openobject-addons/trunk-bug-787717-aag into lp:openobject-addons

 

Atik Agewan(OpenERP) has proposed merging lp:~openerp-dev/openobject-addons/trunk-bug-787717-aag into lp:openobject-addons.

Requested reviews:
  Rucha (Open ERP) (rpa-openerp)
Related bugs:
  Bug #787717 in OpenERP Addons: "Physical Inventory - wrong calculation"
  https://bugs.launchpad.net/openobject-addons/+bug/787717

For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-787717-aag/+merge/62270

Hello 

 [FIX] STOCK:Physical Inventory - wrong calculation, 
 Now calculate current location's stock not all child location stock'

Thanks
-- 
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-787717-aag/+merge/62270
Your team OpenERP R&D Team is subscribed to branch lp:~openerp-dev/openobject-addons/trunk-bug-787717-aag.
=== modified file 'stock/stock.py'
--- stock/stock.py	2011-05-25 09:22:53 +0000
+++ stock/stock.py	2011-05-25 10:32:31 +0000
@@ -2646,7 +2646,7 @@
             return {'value': {'product_qty': 0.0, 'product_uom': False}}
         obj_product = self.pool.get('product.product').browse(cr, uid, product)
         uom = uom or obj_product.uom_id.id
-        amount = self.pool.get('stock.location')._product_get(cr, uid, location_id, [product], {'uom': uom, 'to_date': to_date})[product]
+        amount = self.pool.get('stock.location')._product_get(cr, uid, location_id, [product], {'uom': uom, 'to_date': to_date, 'compute_child': False})[product]
         result = {'product_qty': amount, 'product_uom': uom}
         return {'value': result}