[get_query]to server side

This commit is contained in:
Saurabh
2013-07-09 18:20:49 +05:30
parent 38683718e1
commit 2e3c06e66d
33 changed files with 13 additions and 193 deletions

View File

@@ -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'
}

View File

@@ -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"';
}

View File

@@ -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"';
}

View File

@@ -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