Merge pull request #17927 from Mangesh-Khairnar/bom-item-fix

fix: Check fields before making BOM items
This commit is contained in:
Shivam Mishra 2019-06-13 16:18:12 +05:30 committed by GitHub
commit ae7e13a58f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -192,6 +192,7 @@ frappe.ui.form.on('Material Request', {
var values = d.get_values();
if(!values) return;
values["company"] = frm.doc.company;
if(!frm.doc.company) frappe.throw(__("Company field is required"));
frappe.call({
method: "erpnext.manufacturing.doctype.bom.bom.get_bom_items",
args: values,