Fix set_xxx_moves when value is False
This commit is contained in:
+16
@@ -114,6 +114,10 @@ class PackingIn(OSV):
|
||||
def set_incoming_moves(self, cursor, user, packing_id, name, value, arg,
|
||||
context=None):
|
||||
move_obj = self.pool.get('stock.move')
|
||||
|
||||
if not value:
|
||||
return
|
||||
|
||||
packing = self.browse(cursor, user, packing_id, context=context)
|
||||
move_ids = []
|
||||
for act in value:
|
||||
@@ -157,6 +161,10 @@ class PackingIn(OSV):
|
||||
def set_inventory_moves(self, cursor, user, packing_id, name, value, arg,
|
||||
context=None):
|
||||
move_obj = self.pool.get('stock.move')
|
||||
|
||||
if not value:
|
||||
return
|
||||
|
||||
packing = self.browse(cursor, user, packing_id, context=context)
|
||||
move_ids = []
|
||||
for act in value:
|
||||
@@ -383,6 +391,10 @@ class PackingOut(OSV):
|
||||
def set_outgoing_moves(self, cursor, user, packing_id, name, value, arg,
|
||||
context=None):
|
||||
move_obj = self.pool.get('stock.move')
|
||||
|
||||
if not value:
|
||||
return
|
||||
|
||||
packing = self.browse(cursor, user, packing_id, context=context)
|
||||
move_ids = []
|
||||
for act in value:
|
||||
@@ -426,6 +438,10 @@ class PackingOut(OSV):
|
||||
def set_inventory_moves(self, cursor, user, packing_id, name, value, arg,
|
||||
context=None):
|
||||
move_obj = self.pool.get('stock.move')
|
||||
|
||||
if not value:
|
||||
return
|
||||
|
||||
packing = self.browse(cursor, user, packing_id, context=context)
|
||||
move_ids = []
|
||||
for act in value:
|
||||
|
||||
Reference in New Issue
Block a user