|
|
package com.yoho.search.service.service.helper;
|
|
|
|
|
|
import java.io.UnsupportedEncodingException;
|
|
|
import java.net.URLDecoder;
|
|
|
import java.util.ArrayList;
|
|
|
import java.util.Date;
|
|
|
import java.util.HashMap;
|
|
|
import java.util.Iterator;
|
|
|
import java.util.List;
|
|
|
import java.util.Map;
|
|
|
|
|
|
import org.apache.commons.collections.CollectionUtils;
|
|
|
import org.apache.commons.lang.StringUtils;
|
|
|
import org.elasticsearch.index.query.BoolQueryBuilder;
|
|
|
import org.elasticsearch.index.query.MatchQueryBuilder;
|
|
|
import org.elasticsearch.index.query.MultiMatchQueryBuilder;
|
|
|
import org.elasticsearch.index.query.QueryBuilder;
|
|
|
import org.elasticsearch.index.query.QueryBuilders;
|
|
|
import org.slf4j.Logger;
|
|
|
import org.slf4j.LoggerFactory;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
import com.yoho.search.base.utils.ConvertUtils;
|
|
|
import com.yoho.search.base.utils.DateUtil;
|
|
|
import com.yoho.search.base.utils.ISearchConstants;
|
...
|
...
|
@@ -32,6 +11,17 @@ import com.yoho.search.service.service.SearchCommonService; |
|
|
import com.yoho.search.service.service.SearchDynamicConfigService;
|
|
|
import com.yoho.search.service.service.SearchKeyWordService;
|
|
|
import com.yoho.search.service.utils.SearchRequestParams;
|
|
|
import org.apache.commons.collections.CollectionUtils;
|
|
|
import org.apache.commons.lang.StringUtils;
|
|
|
import org.elasticsearch.index.query.*;
|
|
|
import org.slf4j.Logger;
|
|
|
import org.slf4j.LoggerFactory;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
import java.io.UnsupportedEncodingException;
|
|
|
import java.net.URLDecoder;
|
|
|
import java.util.*;
|
|
|
|
|
|
@Service
|
|
|
public class SearchServiceHelper {
|
...
|
...
|
@@ -679,6 +669,9 @@ public class SearchServiceHelper { |
|
|
productMap.put("sales_num", map.get("salesNum"));
|
|
|
productMap.put("status", map.get("status"));
|
|
|
productMap.put("is_promotion", map.get("ispromotion"));
|
|
|
productMap.put("is_promotion", map.get("ispromotion"));
|
|
|
productMap.put("tbl_country_id", map.get("tblCountryId"));
|
|
|
productMap.put("tbl_country_name", map.get("tblCountryName"));
|
|
|
|
|
|
String yohoodIdFromMap = (String) map.get("yohoodId");
|
|
|
if (yohoodIdFromMap != null && yohoodIdFromMap.length() > 0) {
|
...
|
...
|
|