Merge pull request #14676 from KanchanChauhan/allow-only-submitted-bo
Allow only submitted Blanket Order in PO/SO
This commit is contained in:
commit
7707cee6b7
@ -25,11 +25,11 @@ frappe.ui.form.on("Purchase Order", {
|
|||||||
frm.set_indicator_formatter('item_code',
|
frm.set_indicator_formatter('item_code',
|
||||||
function(doc) { return (doc.qty<=doc.received_qty) ? "green" : "orange" })
|
function(doc) { return (doc.qty<=doc.received_qty) ? "green" : "orange" })
|
||||||
|
|
||||||
frm.set_query("reserve_warehouse", "supplied_items", function() {
|
frm.set_query("blanket_order", "items", function() {
|
||||||
return {
|
return {
|
||||||
filters: {
|
filters: {
|
||||||
"company": frm.doc.company,
|
"company": frm.doc.company,
|
||||||
"is_group": 0
|
"docstatus": 1
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -32,6 +32,15 @@ frappe.ui.form.on("Sales Order", {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
frm.set_query("blanket_order", "items", function() {
|
||||||
|
return {
|
||||||
|
filters: {
|
||||||
|
"company": frm.doc.company,
|
||||||
|
"docstatus": 1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
erpnext.queries.setup_warehouse_query(frm);
|
erpnext.queries.setup_warehouse_query(frm);
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -444,4 +453,4 @@ erpnext.selling.SalesOrderController = erpnext.selling.SellingController.extend(
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
$.extend(cur_frm.cscript, new erpnext.selling.SalesOrderController({frm: cur_frm}));
|
$.extend(cur_frm.cscript, new erpnext.selling.SalesOrderController({frm: cur_frm}));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user