fix: don't show "create" on cancelled BOMs (#29570) (#29572)

(cherry picked from commit a3a05c0c23)

Co-authored-by: Ankush Menat <ankush@frappe.io>
This commit is contained in:
mergify[bot]
2022-02-01 17:44:13 +05:30
committed by GitHub
parent c0a2388ab2
commit ffbf7ec3b7

View File

@@ -93,7 +93,7 @@ frappe.ui.form.on("BOM", {
});
}
if(frm.doc.docstatus!=0) {
if(frm.doc.docstatus==1) {
frm.add_custom_button(__("Work Order"), function() {
frm.trigger("make_work_order");
}, __("Create"));