fixed type error in Production Planning Tool, caused when multiple sales order had the same item and its qty needed to be accumulated
This commit is contained in:
parent
01f689bfe5
commit
2d0ff303e3
@ -286,7 +286,9 @@ class DocType:
|
|||||||
if action == 'download_rm':
|
if action == 'download_rm':
|
||||||
bom_dict[d.bom_no] = bom_dict.get(d.bom_no, 0) + flt(d.planned_qty)
|
bom_dict[d.bom_no] = bom_dict.get(d.bom_no, 0) + flt(d.planned_qty)
|
||||||
elif not d.is_pro_created:
|
elif not d.is_pro_created:
|
||||||
item_dict[d.item_code] = [(item_dict.get(d.item_code, 0) + flt(d.planned_qty)), d.bom_no, d.description, d.stock_uom]
|
item_dict[d.item_code] = [
|
||||||
|
(flt(item_dict.get(d.item_code, [0])[0]) + flt(d.planned_qty)),
|
||||||
|
d.bom_no, d.description, d.stock_uom]
|
||||||
|
|
||||||
if action == 'raise_pro_order':
|
if action == 'raise_pro_order':
|
||||||
for d in item_dict:
|
for d in item_dict:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user