Merge pull request #47329 from frappe/mergify/bp/version-15-hotfix/pr-47325

fix: validate if from and to time are present on submission of job card (backport #47325)
This commit is contained in:
ruthra kumar
2025-04-29 16:46:34 +05:30
committed by GitHub

View File

@@ -705,6 +705,12 @@ class JobCard(Document):
bold("Job Card"), get_link_to_form("Job Card", self.name)
)
)
else:
for row in self.time_logs:
if not row.from_time or not row.to_time:
frappe.throw(
_("Row #{0}: From Time and To Time fields are required").format(row.idx),
)
precision = self.precision("total_completed_qty")
total_completed_qty = flt(