Merge pull request #52183 from frappe/mergify/bp/version-16-hotfix/pr-52181

fix: js error if user does not have write permission for date field (backport #52181)
This commit is contained in:
Mihir Kandoi
2026-01-29 15:42:29 +05:30
committed by GitHub

View File

@@ -803,7 +803,7 @@ frappe.ui.form.on("Purchase Order", "is_subcontracted", function (frm) {
function prevent_past_schedule_dates(frm) {
if (frm.doc.transaction_date) {
frm.fields_dict["schedule_date"].datepicker.update({
frm.fields_dict["schedule_date"].datepicker?.update({
minDate: new Date(frm.doc.transaction_date),
});
}