From 7fcb3c9865be43131e02c4a338a75979b47e39f9 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Mon, 21 Jul 2014 17:51:14 +0530 Subject: [PATCH] [minor] Item query - search by description --- erpnext/controllers/queries.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/erpnext/controllers/queries.py b/erpnext/controllers/queries.py index 2650c66ac2..4a30eed652 100644 --- a/erpnext/controllers/queries.py +++ b/erpnext/controllers/queries.py @@ -167,7 +167,8 @@ def item_query(doctype, txt, searchfield, start, page_len, filters): where tabItem.docstatus < 2 and (tabItem.end_of_life > %(today)s or ifnull(tabItem.end_of_life, '0000-00-00')='0000-00-00') and (tabItem.`{key}` LIKE %(txt)s - or tabItem.item_name LIKE %(txt)s) + or tabItem.item_name LIKE %(txt)s + or tabItem.description LIKE %(txt)s) {fcond} {mcond} order by if(locate(%(_txt)s, name), locate(%(_txt)s, name), 99999),