mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-01 19:29:10 +00:00
[get_query]to server side
This commit is contained in:
@@ -57,7 +57,6 @@ cur_frm.fields_dict['default_bom'].get_query = function(doc) {
|
||||
'is_active': 0
|
||||
}
|
||||
}
|
||||
// return 'SELECT DISTINCT `tabBOM`.`name` FROM `tabBOM` WHERE `tabBOM`.`item` = "' + doc.item_code + '" AND ifnull(`tabBOM`.`is_active`, 0) = 0 and `tabBOM`.docstatus != 2 AND `tabBOM`.%(key)s LIKE "%s" ORDER BY `tabBOM`.`name` LIMIT 50'
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -28,5 +28,4 @@ return{
|
||||
['Account', 'debit_or_credit', '=', 'Debit']
|
||||
]
|
||||
}
|
||||
// return 'SELECT tabAccount.name FROM tabAccount WHERE tabAccount.group_or_ledger="Ledger" AND tabAccount.docstatus != 2 AND (tabAccount.account_type = "Tax" OR tabAccount.account_type = "Chargeable" or (tabAccount.is_pl_account = "Yes" and tabAccount.debit_or_credit = "Debit")) AND tabAccount.name LIKE "%s"';
|
||||
}
|
||||
|
||||
@@ -18,7 +18,6 @@ cur_frm.fields_dict['delivery_note'].get_query = function(doc, cdt, cdn) {
|
||||
return{
|
||||
filters:{ 'docstatus': 0}
|
||||
}
|
||||
// return 'SELECT name FROM `tabDelivery Note` WHERE docstatus=0 AND %(key)s LIKE "%s"';
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -49,7 +49,6 @@ cur_frm.fields_dict['territory'].get_query = function(doc,cdt,cdn) {
|
||||
return{
|
||||
filters:{'is_group': "No"}
|
||||
}
|
||||
// return 'SELECT `tabTerritory`.`name`,`tabTerritory`.`parent_territory` FROM `tabTerritory` WHERE `tabTerritory`.`is_group` = "No" AND `tabTerritory`.`docstatus`!= 2 AND `tabTerritory`.%(key)s LIKE "%s" ORDER BY `tabTerritory`.`name` ASC LIMIT 50';
|
||||
}
|
||||
|
||||
// Supplier
|
||||
|
||||
Reference in New Issue
Block a user