[fix] set required quantity if item in bom found (#12460)
This commit is contained in:
parent
7b78f6bee6
commit
b19fd57043
@ -462,7 +462,8 @@ class ProductionOrder(Document):
|
||||
|
||||
if reset_only_qty:
|
||||
for d in self.get("required_items"):
|
||||
d.required_qty = item_dict.get(d.item_code).get("qty")
|
||||
if item_dict.get(d.item_code):
|
||||
d.required_qty = item_dict.get(d.item_code).get("qty")
|
||||
else:
|
||||
for item in sorted(item_dict.values(), key=lambda d: d['idx']):
|
||||
self.append('required_items', {
|
||||
|
Loading…
Reference in New Issue
Block a user