From d726e413339948a3e3c47370caabce39dd23a89c Mon Sep 17 00:00:00 2001 From: "sbh (Open ERP)" Date: Mon, 30 Aug 2010 11:44:07 +0530 Subject: [PATCH 01/91] [IMP] stock: Improve the tooltips of state bzr revid: sbh@tinyerp.com-20100830061407-amdn6oscg7dqyw0w --- addons/stock/stock.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/addons/stock/stock.py b/addons/stock/stock.py index c76bc609a65..68e20908a47 100644 --- a/addons/stock/stock.py +++ b/addons/stock/stock.py @@ -553,10 +553,14 @@ class stock_picking(osv.osv): ('done', 'Done'), ('cancel', 'Cancelled'), ], 'State', readonly=True, select=True, - help=' * The \'Draft\' state is used when a user is encoding a new and unconfirmed picking. \ - \n* The \'Confirmed\' state is used for stock movement to do with unavailable products. \ - \n* The \'Available\' state is set automatically when the products are ready to be moved.\ - \n* The \'Waiting\' state is used in MTO moves when a movement is waiting for another one.'), + help=' * The \'Draft\' state is used when a user not confirmed yet and will not be scheduled until confirmed picking. \ + \n* The \'Confirmed \' state is still waiting for the availability of products. \ + \n* The \'Available\' state is products reserved, simply waiting for confirmation.\ + \n* The \'Waiting\' state is used waiting for another move to proceed before it becomes automatically available. (e.g. in Make-To-Order flows).\ + \n* The \'Done\' has been processed, cant be modified or cancelled anymore. \ + \n* The \'Cancelled\' has been cancelled, cant be confirmed anymore. \ + '), + 'min_date': fields.function(get_min_max_date, fnct_inv=_set_minimum_date, multi="min_max_date", method=True, store=True, type='datetime', string='Expected Date', select=1, help="Expected date for Picking. Default it takes current date"), 'date': fields.datetime('Order Date', help="Date of Order"), From 5e868d7702fd6dcc4f0c27f3c6c6f01e12647657 Mon Sep 17 00:00:00 2001 From: "sbh (Open ERP)" Date: Mon, 30 Aug 2010 11:47:09 +0530 Subject: [PATCH 02/91] [REM] stock : Remove the print statement bzr revid: sbh@tinyerp.com-20100830061709-fxav28ycd71zjonv --- addons/stock/wizard/stock_move.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/stock/wizard/stock_move.py b/addons/stock/wizard/stock_move.py index e50266706d5..54855a32280 100644 --- a/addons/stock/wizard/stock_move.py +++ b/addons/stock/wizard/stock_move.py @@ -261,7 +261,7 @@ class split_in_production_lot(osv.osv_memory): 'name': line.name, 'product_id': move.product_id.id}, context=context) - print 'write', current_move, {'prodlot_id': prodlot_id, 'state':move.state} + move_obj.write(cr, uid, [current_move], {'prodlot_id': prodlot_id, 'state':move.state}) update_val = {} From c8fe0020aff4f1a97287ad4428550ada6395c197 Mon Sep 17 00:00:00 2001 From: "sbh (Open ERP)" Date: Mon, 30 Aug 2010 12:19:19 +0530 Subject: [PATCH 03/91] [IMP] stock: Remove origin and backorder when copy the picking bzr revid: sbh@tinyerp.com-20100830064919-oks1ga3sslwf8x11 --- addons/stock/stock.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/addons/stock/stock.py b/addons/stock/stock.py index 68e20908a47..6d57781895f 100644 --- a/addons/stock/stock.py +++ b/addons/stock/stock.py @@ -596,6 +596,8 @@ class stock_picking(osv.osv): if ('name' not in default) or (picking_obj.name=='/'): seq_obj_name = 'stock.picking.' + picking_obj.type default['name'] = self.pool.get('ir.sequence').get(cr, uid, seq_obj_name) + default['origin'] = '' + default['backorder_id'] = False return super(stock_picking, self).copy(cr, uid, id, default, context) def onchange_partner_in(self, cr, uid, context=None, partner_id=None): From fc98b81be826a09f85713bf1ef86c997ebe6327c Mon Sep 17 00:00:00 2001 From: "sbh (Open ERP)" Date: Mon, 30 Aug 2010 12:35:47 +0530 Subject: [PATCH 04/91] [ADD] stock: Add a scrap button in form view of stock_move bzr revid: sbh@tinyerp.com-20100830070547-8o374ip8lbahaoqz --- addons/stock/stock.py | 1 + addons/stock/stock_view.xml | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/addons/stock/stock.py b/addons/stock/stock.py index 6d57781895f..f9db523c5b9 100644 --- a/addons/stock/stock.py +++ b/addons/stock/stock.py @@ -1183,6 +1183,7 @@ class stock_picking(osv.osv): 'assigned': 'is ready to process.', 'cancel': 'is Cancelled.', 'done': 'is processed.', + 'draft':'is draft.', } message += state_list[pick.state] self.log(cr, uid, pick.id, message) diff --git a/addons/stock/stock_view.xml b/addons/stock/stock_view.xml index f81de1c5faf..1cd46f881f5 100644 --- a/addons/stock/stock_view.xml +++ b/addons/stock/stock_view.xml @@ -1439,6 +1439,10 @@ groups="base.group_extended" icon="terp-stock_effects-object-colorize" states="draft,assigned,confirmed,done"/> +