diff --git a/erpnext/manufacturing/doctype/job_card/job_card.py b/erpnext/manufacturing/doctype/job_card/job_card.py index c82038af342..90ccff720e8 100644 --- a/erpnext/manufacturing/doctype/job_card/job_card.py +++ b/erpnext/manufacturing/doctype/job_card/job_card.py @@ -261,7 +261,8 @@ class JobCard(Document): frappe.throw( _( "Employee {0} is currently working on another workstation. Please assign another employee." - ).format(args.get("employee")) + ).format(args.get("employee")), + OverlapError, ) if not self.has_overlap(production_capacity, time_logs):