瀏覽代碼

elsticutil

张金坤 8 年之前
父節點
當前提交
ee4b8ecd8e
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      common/src/qfw/util/elastic/elasticutil.go

+ 1 - 1
common/src/qfw/util/elastic/elasticutil.go

@@ -987,7 +987,7 @@ func GetByNgramOther(index, itype string, query interface{}, mustquery, findfiel
 func GetByNgramAll(index, itype string, query interface{}, mustquery, findfields, order, fields string, start, limit int, highlight bool, filtermode bool) *[]map[string]interface{} {
 	defer util.Catch()
 	qstr := ""
-	if mustquery != "" {
+	if mustquery != "" && filtermode {
 		qstr = GetNgramQuery(query, "", findfields)
 		qstr = fmt.Sprintf(FilterQuery, mustquery, qstr[1:])
 	} else {