Merge lp:~openerp-dev/openobject-addons/7.0-opw-601201-dhr into lp:openobject-addons/7.0

Proposed by Dharti Ratani(OpenERP)
Status: Needs review
Proposed branch: lp:~openerp-dev/openobject-addons/7.0-opw-601201-dhr
Merge into: lp:openobject-addons/7.0
Diff against target: 12 lines (+1/-1)
1 file modified
procurement/procurement.py (+1/-1)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/7.0-opw-601201-dhr
Reviewer Review Type Date Requested Status
Vinay Rana (OpenERP) Pending
Naresh(OpenERP) Pending
Review via email: mp+198670@code.launchpad.net

Description of the change

Hello Sir,

Fixed the issue of an extra move created from the orderpoint of a product with chained location defined which resulted in wrong inventory.

Steps to produce :

-Create a new product: stockable, make to stock, buy. Add a supplier, add an automatic move from stock to shelf1.
-Add orderpoint, min = 5 max =10. (location = stock).
-Run scheduler.
-Confirm purchase, receive delivery.
-Go to warehouse, stock moves, you will see 4 stock moves.
-One from stock to stock, that is fine, this is the procurement.
-One from partner/supplier to stock, that is fine this is the delivery.
-There are 2 stock moves from stock to shelf1, which is wrong.
-Look at the stock by location, you will see 10 in stock and 20 in shelf1, which is wrong.
-There should not be a chained location move from orderpoint, as minimum stock rule is defined to procure products in stock.

Thanks,
Dharti

To post a comment you must log in.

Unmerged revisions

9683. By Dharti Ratani(OpenERP)

[FIX]Corrected for the extra move created for a product with push flow defined when scheduler runs

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'procurement/procurement.py'
--- procurement/procurement.py 2013-11-12 15:17:47 +0000
+++ procurement/procurement.py 2013-12-12 06:18:19 +0000
@@ -345,7 +345,7 @@
345 'company_id': procurement.company_id.id,345 'company_id': procurement.company_id.id,
346 'auto_validate': True,346 'auto_validate': True,
347 })347 })
348 move_obj.action_confirm(cr, uid, [id], context=context)348 move_obj.write(cr, uid, [id], {'state': 'confirmed'}, context=context)
349 self.write(cr, uid, [procurement.id], {'move_id': id, 'close_move': 1})349 self.write(cr, uid, [procurement.id], {'move_id': id, 'close_move': 1})
350 self.write(cr, uid, ids, {'state': 'confirmed', 'message': ''})350 self.write(cr, uid, ids, {'state': 'confirmed', 'message': ''})
351 return True351 return True