mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-27 08:54:45 +00:00
[minor] [fix] task close button condition
This commit is contained in:
@@ -30,7 +30,7 @@ frappe.ui.form.on("Task", {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(frm.perm[0].write) {
|
if(frm.perm[0].write) {
|
||||||
if(frm.doc.status==="Open") {
|
if(frm.doc.status!=="Closed" && frm.doc.status!=="Cancelled") {
|
||||||
frm.add_custom_button("Close", function() {
|
frm.add_custom_button("Close", function() {
|
||||||
frm.set_value("status", "Closed");
|
frm.set_value("status", "Closed");
|
||||||
frm.save();
|
frm.save();
|
||||||
|
|||||||
Reference in New Issue
Block a user