Fix: populate correctly uom_index
This commit is contained in:
1 parent
a3a3af27c1
commit
273f017ca7
1 file changed
+5
-1
+5
-1
@@ -287,10 +287,14 @@ class PackingOut(OSV):
|
||||
location_obj = self.pool.get('stock.location')
|
||||
move_obj = self.pool.get('stock.move')
|
||||
product_obj = self.pool.get('product.product')
|
||||
uom_obj = self.pool.get('product.uom')
|
||||
packing = self.browse(cursor, user, id, context=context)
|
||||
parent_to_locations = {}
|
||||
inventory_moves = []
|
||||
uom_index = {}
|
||||
uom_ids = uom_obj.search(cursor, user, [], context=context)
|
||||
uom_index = dict( (uom.id, uom) for uom in \
|
||||
uom_obj.browse(cursor, user, uom_ids, context=context))
|
||||
|
||||
location_index = {}
|
||||
# Fetch child_of for each location
|
||||
for move in packing.inventory_moves:
|
||||
|
||||
Reference in new issue
Block a user