fix: throw correct exception

This commit is contained in:
Mihir Kandoi
2025-02-18 14:49:52 +05:30
parent 8234e659c8
commit 4487edb255

View File

@@ -296,7 +296,8 @@ class JobCard(Document):
frappe.throw( frappe.throw(
_( _(
"Employee {0} is currently working on another workstation. Please assign another employee." "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): if not self.has_overlap(production_capacity, time_logs):