From f941585379dcfb799fb040b74a9fb621cea506e1 Mon Sep 17 00:00:00 2001 From: Marica Date: Sun, 21 Jul 2024 19:08:56 +0200 Subject: [PATCH] fix: Use `frm` instead of `this` (#1990) (cherry picked from commit 82dd597da82fb9b1e23a590303908e566d32f3d8) --- hrms/hr/doctype/leave_application/leave_application.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hrms/hr/doctype/leave_application/leave_application.js b/hrms/hr/doctype/leave_application/leave_application.js index 0144b39820..237dc0294b 100755 --- a/hrms/hr/doctype/leave_application/leave_application.js +++ b/hrms/hr/doctype/leave_application/leave_application.js @@ -104,7 +104,7 @@ frappe.ui.form.on("Leave Application", { frm.perm[0].submit && !frm.is_dirty() && !frm.is_new() && - !frappe.model.has_workflow(this.doctype) && + !frappe.model.has_workflow(frm.doctype) && frm.doc.docstatus === 0 ) { frm.set_intro(__("Submit this Leave Application to confirm."));