fix: precision issue in production plan (backport #53370) (#53373)

Co-authored-by: Mihir Kandoi <kandoimihir@gmail.com>
fix: precision issue in production plan (#53370)
This commit is contained in:
mergify[bot]
2026-03-12 09:32:09 +00:00
committed by GitHub
parent 0e00ab8865
commit 5737d2afa3

View File

@@ -1800,6 +1800,7 @@ def get_sub_assembly_items(
skip_available_sub_assembly_item=False,
):
data = get_bom_children(parent=bom_no)
precision = frappe.get_precision("Production Plan Sub Assembly Item", "qty")
for d in data:
if d.expandable:
parent_item_code = frappe.get_cached_value("BOM", bom_no, "item")
@@ -1837,7 +1838,7 @@ def get_sub_assembly_items(
"is_sub_contracted_item": d.is_sub_contracted_item,
"bom_level": indent,
"indent": indent,
"stock_qty": stock_qty,
"stock_qty": flt(stock_qty, precision),
}
)
)