[FIX] stock: mutation of the context
If the method do_enter_transfer_details is called form the new API, the context is a frozendict and can not be updated and the previous code would crash. Copying it before updating. Closes #9872
This commit is contained in:
parent
8a0b4ca39f
commit
9f65dad250
|
@ -1406,7 +1406,8 @@ class stock_picking(osv.osv):
|
||||||
def do_enter_transfer_details(self, cr, uid, picking, context=None):
|
def do_enter_transfer_details(self, cr, uid, picking, context=None):
|
||||||
if not context:
|
if not context:
|
||||||
context = {}
|
context = {}
|
||||||
|
else:
|
||||||
|
context = context.copy()
|
||||||
context.update({
|
context.update({
|
||||||
'active_model': self._name,
|
'active_model': self._name,
|
||||||
'active_ids': picking,
|
'active_ids': picking,
|
||||||
|
|
Loading…
Reference in New Issue