From ba85c710b50717da26691be23f77a7fea3240014 Mon Sep 17 00:00:00 2001 From: gazebo Date: Mon, 15 Apr 2019 15:04:57 +0800 Subject: [PATCH] =?UTF-8?q?-=20GetSkuNames=20keyword=E5=8F=AF=E6=90=9C?= =?UTF-8?q?=E7=B4=A2upc?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- business/jxstore/cms/sku.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/business/jxstore/cms/sku.go b/business/jxstore/cms/sku.go index 505a5d9b9..001564ecf 100644 --- a/business/jxstore/cms/sku.go +++ b/business/jxstore/cms/sku.go @@ -207,8 +207,8 @@ func GetSkuNames(ctx *jxcontext.Context, keyword string, isBySku bool, params ma } if keyword != "" { keywordLike := "%" + keyword + "%" - sql += " AND (t1.name LIKE ? OR t1.prefix LIKE ? OR t2.comment LIKE ?" - sqlParams = append(sqlParams, keywordLike, keywordLike, keywordLike) + sql += " AND (t1.name LIKE ? OR t1.prefix LIKE ? OR t2.comment LIKE ? OR t1.upc LIKE ?" + sqlParams = append(sqlParams, keywordLike, keywordLike, keywordLike, keywordLike) if keywordInt64, err2 := strconv.ParseInt(keyword, 10, 64); err2 == nil { sql += " OR t2.jd_id = ? OR t1.id = ? OR t1.category_id = ?"