From ee19c32c3aa0c4b5fa1ec44b2af46b651a80a853 Mon Sep 17 00:00:00 2001 From: Mihir Kandoi Date: Wed, 4 Mar 2026 16:05:24 +0530 Subject: [PATCH] fix: disallow all actions on job card if work order is closed --- erpnext/manufacturing/doctype/job_card/job_card.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/erpnext/manufacturing/doctype/job_card/job_card.py b/erpnext/manufacturing/doctype/job_card/job_card.py index 5bd3391ef18..461be0d76ad 100644 --- a/erpnext/manufacturing/doctype/job_card/job_card.py +++ b/erpnext/manufacturing/doctype/job_card/job_card.py @@ -1322,9 +1322,9 @@ class JobCard(Document): def is_work_order_closed(self): if self.work_order: - status = frappe.get_value("Work Order", self.work_order) + status = frappe.get_value("Work Order", self.work_order, "status") - if status == "Closed": + if status in ["Closed", "Stopped"]: return True return False