Commit 37c01e62 by mushishixian

数量问题

parent 60228d9e
Showing with 1 additions and 5 deletions
...@@ -177,11 +177,7 @@ func getBomTermQuery(goodsName, brandName string, number int32, isRawSearch bool ...@@ -177,11 +177,7 @@ func getBomTermQuery(goodsName, brandName string, number int32, isRawSearch bool
} }
source := elastic.NewSearchSource().Query(query) source := elastic.NewSearchSource().Query(query)
source.From(0) source.From(0)
if isRawSearch { source.Size(50)
source.Size(100)
} else {
source.Size(1)
}
source.Sort("_score", false).Sort("sort", false).Sort("single_price", true) source.Sort("_score", false).Sort("sort", false).Sort("single_price", true)
queryRequest := elastic.NewSearchRequest().Source(source) queryRequest := elastic.NewSearchRequest().Source(source)
result, _ = queryRequest.Body() result, _ = queryRequest.Body()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment