openerp-dev-web team mailing list archive
-
openerp-dev-web team
-
Mailing list archive
-
Message #06803
[Merge] lp:~openerp-dev/openobject-addons/trunk-bug-781718-ron into lp:openobject-addons
Rohan Nayani(Open ERP) has proposed merging lp:~openerp-dev/openobject-addons/trunk-bug-781718-ron into lp:openobject-addons.
Requested reviews:
Rucha (Open ERP) (rpa-openerp)
Related bugs:
Bug #781718 in OpenERP Addons: "[PS] When doing a partial reception, it should link Incoming Shipments together"
https://bugs.launchpad.net/openobject-addons/+bug/781718
For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-781718-ron/+merge/61068
--
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-781718-ron/+merge/61068
Your team OpenERP R&D Team is subscribed to branch lp:~openerp-dev/openobject-addons/trunk-bug-781718-ron.
=== modified file 'stock/wizard/stock_partial_picking.py'
--- stock/wizard/stock_partial_picking.py 2011-05-02 18:46:43 +0000
+++ stock/wizard/stock_partial_picking.py 2011-05-16 06:32:34 +0000
@@ -165,8 +165,22 @@
'product_price' : move.cost,
'product_currency': move.currency.id,
})
- pick_obj.do_partial(cr, uid, picking_ids, partial_datas, context=context)
- return {'type': 'ir.actions.act_window_close'}
+ res = pick_obj.do_partial(cr, uid, picking_ids, partial_datas, context=context)
+
+ backorder_id = res.values()[0]['delivered_picking']
+ if res.keys()[0] <> backorder_id:
+ context.update({'search_default_done':1, 'search_default_available':False})
+ return {
+ 'domain': "[('id','=', %s)]" % (backorder_id),
+ 'name' : _('Incoming Shipments'),
+ 'view_type': 'form',
+ 'view_mode': 'tree,form',
+ 'res_model': 'stock.picking',
+ 'context': context,
+ 'type': 'ir.actions.act_window',
+ }
+ else:
+ return {'type': 'ir.actions.act_window_close'}
stock_partial_picking()
Follow ups