Merge lp:~camptocamp/openobject-addons/6.1-merge-xa into lp:~camptocamp/openobject-addons/6.1-c2c-official

Proposed by Matthieu Dietrich @ camptocamp
Status: Needs review
Proposed branch: lp:~camptocamp/openobject-addons/6.1-merge-xa
Merge into: lp:~camptocamp/openobject-addons/6.1-c2c-official
Diff against target: 39 lines (+12/-16)
1 file modified
stock/wizard/stock_return_picking.py (+12/-16)
To merge this branch: bzr merge lp:~camptocamp/openobject-addons/6.1-merge-xa
Reviewer Review Type Date Requested Status
Camptocamp Pending
Review via email: mp+216118@code.launchpad.net

Commit message

[MRG] merged from latest upstream

Description of the change

A fix was merged on 6.1-XA (upstream), but not on this branch.
To keep them consistent, I made this MP.

To post a comment you must log in.

Unmerged revisions

6640. By Matthieu Dietrich @ camptocamp on 2014-04-16

[MRG] merge from latest XA trunk

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'stock/wizard/stock_return_picking.py'
2--- stock/wizard/stock_return_picking.py 2012-06-12 16:15:51 +0000
3+++ stock/wizard/stock_return_picking.py 2014-04-16 14:07:22 +0000
4@@ -202,23 +202,19 @@
5 pick_obj.force_assign(cr, uid, [new_picking], context)
6 # Update view id in context, lp:702939
7 view_list = {
8- 'out': 'view_picking_out_tree',
9- 'in': 'view_picking_in_tree',
10- 'internal': 'vpicktree',
11- }
12- data_obj = self.pool.get('ir.model.data')
13- res = data_obj.get_object_reference(cr, uid, 'stock', view_list.get(new_type, 'vpicktree'))
14- context.update({'view_id': res and res[1] or False})
15- return {
16- 'domain': "[('id', 'in', ["+str(new_picking)+"])]",
17- 'name': 'Picking List',
18- 'view_type':'form',
19- 'view_mode':'tree,form',
20- 'res_model':'stock.picking',
21- 'type':'ir.actions.act_window',
22- 'context':context,
23+ 'out': 'action_picking_tree',
24+ 'in': 'action_picking_tree4',
25+ 'internal': 'action_picking_tree6',
26 }
27-
28+ data_pool = self.pool.get('ir.model.data')
29+ action = {}
30+ action_model,action_id = data_pool.get_object_reference(cr, uid, 'stock', view_list.get(new_type,'action_picking_tree6'))
31+ if action_model:
32+ action_pool = self.pool.get(action_model)
33+ action = action_pool.read(cr, uid, action_id, context=context)
34+ action['domain'] = "[('id','=', "+str(new_picking)+")]"
35+ action['context'] = context
36+ return action
37 stock_return_picking()
38
39 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

Subscribers

People subscribed via source and target branches

to all changes: