← Back to team overview

openerp-india team mailing list archive

[Bug 926640] [NEW] Inventory correction moves are calculated based on current date and not inventory date

 

Public bug reported:

When doing a stocktaking and fill an inventory, moves are calculated
based on current date and not on inventory creation date.

eg:
2011/12/31 total stock moves = 100
2012/01/01 stocktaking = 90
2012/01/02 out product move for 5
2012/01/03 inventory for 90 is posted  (with creation date = 1/1)

Done correction move is 100 - 90 + 5 = 5
Correct correction move is 100 - 90 = 10

This is because following line in stock.py/stock_inventory/action_confirm seems incorrect and currently do ask the available quantity up to date (to_date context field):
#                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, prodlot_id=line.prod_lot_id.id)#EC

** Affects: openobject-addons
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Addons.
https://bugs.launchpad.net/bugs/926640

Title:
  Inventory correction moves are calculated based on current date and
  not inventory date

Status in OpenERP Addons (modules):
  New

Bug description:
  When doing a stocktaking and fill an inventory, moves are calculated
  based on current date and not on inventory creation date.

  eg:
  2011/12/31 total stock moves = 100
  2012/01/01 stocktaking = 90
  2012/01/02 out product move for 5
  2012/01/03 inventory for 90 is posted  (with creation date = 1/1)

  Done correction move is 100 - 90 + 5 = 5
  Correct correction move is 100 - 90 = 10

  This is because following line in stock.py/stock_inventory/action_confirm seems incorrect and currently do ask the available quantity up to date (to_date context field):
  #                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, prodlot_id=line.prod_lot_id.id)#EC

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/926640/+subscriptions


Follow ups

References