Merge lp:~alhashash/openobject-addons/7.0-fix-lp-1307523 into lp:openobject-addons/7.0

Proposed by Mohammad Alhashash
Status: Needs review
Proposed branch: lp:~alhashash/openobject-addons/7.0-fix-lp-1307523
Merge into: lp:openobject-addons/7.0
Diff against target: 14 lines (+2/-2)
1 file modified
stock/stock.py (+2/-2)
To merge this branch: bzr merge lp:~alhashash/openobject-addons/7.0-fix-lp-1307523
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email: mp+216128@code.launchpad.net

Description of the change

Fix the return value for stock.picking.do_partial when creating back order

To post a comment you must log in.

Unmerged revisions

9990. By Mohammad Alhashash

fix bug lp:1307523 incorrect return value from stock.picking.do_partial()

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'stock/stock.py'
2--- stock/stock.py 2014-04-15 16:03:31 +0000
3+++ stock/stock.py 2014-04-16 15:06:40 +0000
4@@ -1368,8 +1368,8 @@
5 self.action_move(cr, uid, [new_picking], context=context)
6 wf_service.trg_validate(uid, 'stock.picking', new_picking, 'button_done', cr)
7 wf_service.trg_write(uid, 'stock.picking', pick.id, cr)
8- delivered_pack_id = pick.id
9- back_order_name = self.browse(cr, uid, delivered_pack_id, context=context).name
10+ delivered_pack_id = new_picking
11+ back_order_name = self.browse(cr, uid, pick.id, context=context).name
12 self.message_post(cr, uid, new_picking, body=_("Back order <em>%s</em> has been <b>created</b>.") % (back_order_name), context=context)
13 else:
14 self.action_move(cr, uid, [pick.id], context=context)