mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-01 03:09:09 +00:00
Disallowed End of Life Items from getting selected in Production Orders and Stock Reconciliation
This commit is contained in:
@@ -98,3 +98,11 @@ cur_frm.cscript.company = function(doc, cdt, cdn) {
|
||||
cur_frm.cscript.posting_date = function(doc, cdt, cdn){
|
||||
erpnext.get_fiscal_year(doc.company, doc.posting_date);
|
||||
}
|
||||
|
||||
cur_frm.fields_dict.items.grid.get_field('item_code').get_query = function(doc, cdt, cdn) {
|
||||
return {
|
||||
filters:[
|
||||
['Item', 'end_of_life', '>', frappe.datetime.now_datetime()]
|
||||
]
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user