mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-21 14:09:19 +00:00
fix: dont fetch draft/cancelled BOMs
(cherry picked from commit 1d1203d5ec)
This commit is contained in:
committed by
Ankush Menat
parent
9c0f8fe7fd
commit
aa684e6f3d
@@ -49,7 +49,7 @@ frappe.ui.form.on('Production Plan', {
|
|||||||
if (d.item_code) {
|
if (d.item_code) {
|
||||||
return {
|
return {
|
||||||
query: "erpnext.controllers.queries.bom",
|
query: "erpnext.controllers.queries.bom",
|
||||||
filters:{'item': cstr(d.item_code)}
|
filters:{'item': cstr(d.item_code), 'docstatus': 1}
|
||||||
}
|
}
|
||||||
} else frappe.msgprint(__("Please enter Item first"));
|
} else frappe.msgprint(__("Please enter Item first"));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -850,7 +850,7 @@ def get_item_details(item, project = None, skip_bom_info=False):
|
|||||||
res = res[0]
|
res = res[0]
|
||||||
if skip_bom_info: return res
|
if skip_bom_info: return res
|
||||||
|
|
||||||
filters = {"item": item, "is_default": 1}
|
filters = {"item": item, "is_default": 1, "docstatus": 1}
|
||||||
|
|
||||||
if project:
|
if project:
|
||||||
filters = {"item": item, "project": project}
|
filters = {"item": item, "project": project}
|
||||||
|
|||||||
Reference in New Issue
Block a user