summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorQuentin (OpenERP) <qdp-launchpad@openerp.com>2013-10-24 10:19:01 +0200
committerQuentin (OpenERP) <qdp-launchpad@openerp.com>2013-10-24 10:19:01 +0200
commit085cfd6b59edf4bc2bfad5e6fa587e42f17e4fff (patch)
tree827204557f8cd8a7f46a5639b6d9f2f1e66e1517
parent86d58ed2ddb9c2b3baca75bf007031f3a26a781d (diff)
[FIX] stock: on write of the reception method of a warehouse, recreate the pull rules of reception route in MTO always
bzr revid: qdp-launchpad@openerp.com-20131024081901-r53dvxu2xnsz4mp8
-rw-r--r--addons/stock/stock.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/addons/stock/stock.py b/addons/stock/stock.py
index f909c2138ff..3f77051e7f1 100644
--- a/addons/stock/stock.py
+++ b/addons/stock/stock.py
@@ -2495,7 +2495,7 @@ class stock_warehouse(osv.osv):
for push_rule in push_rules_list:
push_obj.create(cr, uid, vals=push_rule, context=context)
for pull_rule in pull_rules_list:
- #all pull rules in reception route are mto, because we don't won't to wait for the scheduler to trigger an orderpoint on input location
+ #all pull rules in reception route are mto, because we don't want to wait for the scheduler to trigger an orderpoint on input location
pull_rule['procure_method'] = 'make_to_order'
pull_obj.create(cr, uid, vals=pull_rule, context=context)
@@ -2574,6 +2574,8 @@ class stock_warehouse(osv.osv):
for push_rule in push_rules_list:
push_obj.create(cr, uid, vals=push_rule, context=context)
for pull_rule in pull_rules_list:
+ #all pull rules in reception route are mto, because we don't want to wait for the scheduler to trigger an orderpoint on input location
+ pull_rule['procure_method'] = 'make_to_order'
pull_obj.create(cr, uid, vals=pull_rule, context=context)
route_obj.write(cr, uid, warehouse.crossdock_route_id.id, {'active': new_reception_step != 'one_step' and new_delivery_step != 'ship_only'}, context=context)