fix: unsupported operand type(s) for +=: 'int' and 'NoneType'
(cherry picked from commit 2b4eae5f84)
This commit is contained in:
committed by
Mergify
parent
2105193594
commit
b573d9739f
@@ -181,13 +181,13 @@ class PickList(Document):
|
||||
|
||||
if item_map.get(key):
|
||||
item_map[key].qty += item.qty
|
||||
item_map[key].stock_qty += item.stock_qty
|
||||
item_map[key].stock_qty += flt(item.stock_qty, item.precision("stock_qty"))
|
||||
else:
|
||||
item_map[key] = item
|
||||
|
||||
# maintain count of each item (useful to limit get query)
|
||||
self.item_count_map.setdefault(item_code, 0)
|
||||
self.item_count_map[item_code] += item.stock_qty
|
||||
self.item_count_map[item_code] += flt(item.stock_qty, item.precision("stock_qty"))
|
||||
|
||||
return item_map.values()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user