fix: work order status should be in process if material transfer is s… (#55641)

This commit is contained in:
Mihir Kandoi
2026-06-05 11:04:43 +05:30
committed by GitHub
parent e2a1f6057d
commit 34a0aa2ee9

View File

@@ -124,7 +124,11 @@ class StatusService:
if status in ["Closed", "Stopped"]:
return status
status = "In Process" if flt(self.doc.material_transferred_for_manufacturing) > 0 else "Not Started"
status = (
"In Process"
if flt(self.doc.material_transferred_for_manufacturing) > 0 or self.doc.skip_transfer
else "Not Started"
)
precision = frappe.get_precision("Work Order", "produced_qty")
total_qty = flt(self.doc.produced_qty, precision) + flt(self.doc.process_loss_qty, precision)
if flt(total_qty, precision) >= flt(self.doc.qty, precision):