From 4d40c84a3131c1a6845f52f2a33ddd22828a2a0a Mon Sep 17 00:00:00 2001 From: Sudharsanan11 Date: Thu, 19 Feb 2026 12:59:11 +0530 Subject: [PATCH] fix(manufacturing): update status for work order before calculating planned qty --- erpnext/manufacturing/doctype/work_order/work_order.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/manufacturing/doctype/work_order/work_order.py b/erpnext/manufacturing/doctype/work_order/work_order.py index 7e77ec6419a..29cfa79befd 100644 --- a/erpnext/manufacturing/doctype/work_order/work_order.py +++ b/erpnext/manufacturing/doctype/work_order/work_order.py @@ -2523,8 +2523,8 @@ def close_work_order(work_order: str, status: str): ) ) - work_order.on_close_or_cancel() work_order.update_status(status) + work_order.on_close_or_cancel() frappe.msgprint(_("Work Order has been {0}").format(status)) work_order.notify_update() return work_order.status