Authored by 胡古飞

fix BUG

... ... @@ -339,6 +339,10 @@ public class SearchServiceHelper {
if (this.checkParamNotFiltered(paramMap, filterParamName, SearchRequestParams.PARAM_SEARCH_SERIESID)) {
boolFilter.must(QueryBuilders.termQuery(ProductIndexEsField.seriesId, paramMap.get(SearchRequestParams.PARAM_SEARCH_SERIESID)));
}
// 判断是否需要包含全球购[全球购的开关]
if (!searchCommonHelper.containGlobal(paramMap)) {
boolFilter.mustNot(QueryBuilders.termsQuery(ProductIndexEsField.isGlobal, "Y"));
}
// 判断是否需要是筛选全球购[全球购的筛选项]
if (this.checkParamNotFiltered(paramMap, filterParamName, SearchRequestParams.PARAM_SEARCH_IS_GLOBAL)) {
boolFilter.must(QueryBuilders.termsQuery(ProductIndexEsField.isGlobal, paramMap.get(SearchRequestParams.PARAM_SEARCH_IS_GLOBAL)));
... ... @@ -443,11 +447,7 @@ public class SearchServiceHelper {
if (activitiesTermsBuilder != null) {
boolFilter.must(QueryBuilders.nestedQuery(ProductIndexEsField.activities, activitiesTermsBuilder));
}
// 判断是否需要包含全球购[全球购的开关]
if (!searchCommonHelper.containGlobal(paramMap)) {
boolFilter.mustNot(QueryBuilders.termsQuery(ProductIndexEsField.isGlobal, "Y"));
}
// 如果contain_seckill!=Y,则过滤掉秒杀商品
if (!paramMap.containsKey(SearchRequestParams.PARAM_SEARCH_CONTAIN_SECKILL) || !"Y".equals(paramMap.get(SearchRequestParams.PARAM_SEARCH_CONTAIN_SECKILL))) {
boolFilter.mustNot(QueryBuilders.termsQuery(ProductIndexEsField.isSeckill, "Y"));
... ...