mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-06 15:00:27 +00:00
Merge pull request #17926 from Mangesh-Khairnar/get-bom-items-fix
fix: Check fields before making BOM items
This commit is contained in:
@@ -186,6 +186,7 @@ frappe.ui.form.on('Material Request', {
|
|||||||
var values = d.get_values();
|
var values = d.get_values();
|
||||||
if(!values) return;
|
if(!values) return;
|
||||||
values["company"] = frm.doc.company;
|
values["company"] = frm.doc.company;
|
||||||
|
if(!frm.doc.company) frappe.throw(__("Company field is required"));
|
||||||
frappe.call({
|
frappe.call({
|
||||||
method: "erpnext.manufacturing.doctype.bom.bom.get_bom_items",
|
method: "erpnext.manufacturing.doctype.bom.bom.get_bom_items",
|
||||||
args: values,
|
args: values,
|
||||||
|
|||||||
Reference in New Issue
Block a user