mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-28 09:24:45 +00:00
fix(employee): js error if user does not have write permission for date field (backport #55312) (#55314)
Co-authored-by: Himanshu Jain <118419692+trufurs@users.noreply.github.com> fix(employee): js error if user does not have write permission for date field (#55312)
This commit is contained in:
@@ -44,7 +44,7 @@ frappe.ui.form.on("Employee", {
|
||||
},
|
||||
|
||||
refresh: function (frm) {
|
||||
frm.fields_dict.date_of_birth.datepicker.update({ maxDate: new Date() });
|
||||
frm.fields_dict.date_of_birth.datepicker?.update({ maxDate: new Date() });
|
||||
|
||||
if (!frm.is_new() && !frm.doc.user_id) {
|
||||
frm.add_custom_button(__("Create User"), () => {
|
||||
|
||||
Reference in New Issue
Block a user