fix: don't show bulk actions for doctype with workflow

This commit is contained in:
barredterra 2024-04-04 12:46:09 +02:00
parent 504aab4f38
commit 75b0142c1c

View file

@ -2038,7 +2038,7 @@ frappe.views.ListView = class ListView extends frappe.views.BaseList {
};
// bulk edit
if (has_editable_fields(doctype)) {
if (has_editable_fields(doctype) && !frappe.model.has_workflow(doctype)) {
actions_menu_items.push(bulk_edit());
}
@ -2073,7 +2073,7 @@ frappe.views.ListView = class ListView extends frappe.views.BaseList {
}
// bulk delete
if (frappe.model.can_delete(doctype)) {
if (frappe.model.can_delete(doctype) && !frappe.model.has_workflow(doctype)) {
actions_menu_items.push(bulk_delete());
}