Authored by 胡古飞

fix

... ... @@ -27,31 +27,31 @@ public class BrandController {
private IBrandWithShopsService brandWithShopsService;
/**
* 按品牌前缀名获取品牌列表
* 获取品牌列表[不包含全球购]
*
* @param request
* @return
*/
@DownGradeAble(key = "brands")
@RequestMapping(method = RequestMethod.GET, value = "/brands")
@DownGradeAble(key = "brandList")
@RequestMapping(method = RequestMethod.GET, value = "/brand/list")
@ResponseBody
public SearchApiResult brands(HttpServletRequest request) {
public SearchApiResult brandList(HttpServletRequest request) {
Map<String, String> paramMap = HttpServletRequestUtils.transParamType(request);
return brandService.brands(paramMap);
return brandService.brandList(paramMap);
}
/**
* 获取品牌列表
* 按品牌前缀名获取品牌列表
*
* @param request
* @return
*/
@DownGradeAble(key = "brandList")
@RequestMapping(method = RequestMethod.GET, value = "/brand/list")
@DownGradeAble(key = "brands")
@RequestMapping(method = RequestMethod.GET, value = "/brands")
@ResponseBody
public SearchApiResult brandList(HttpServletRequest request) {
public SearchApiResult brands(HttpServletRequest request) {
Map<String, String> paramMap = HttpServletRequestUtils.transParamType(request);
return brandService.brandList(paramMap);
return brandService.brands(paramMap);
}
/**
... ...
... ... @@ -7,7 +7,15 @@ import org.elasticsearch.index.query.BoolQueryBuilder;
import com.yoho.search.service.vo.SearchApiResult;
public interface IBrandService {
/**
* 获取商品列表[直接从brand索引里取全部][不返回全球购品牌]
*
* @param paramMap
* @return
*/
public SearchApiResult brandList(Map<String, String> paramMap);
/**
* 获取品牌的聚合结果[使用本地缓存][按参数决定是否返回全球购品牌]
*
... ... @@ -15,14 +23,14 @@ public interface IBrandService {
* @return
*/
public SearchApiResult aggBrand(Map<String, String> paramMap);
/**
* 获取品牌的聚合结果[使用本地缓存][按参数决定是否返回全球购品牌]
*
* @param paramMap
* @return
*/
public SearchApiResult aggBrand(Map<String, String> paramMap,BoolQueryBuilder mustFilter);
public SearchApiResult aggBrand(Map<String, String> paramMap, BoolQueryBuilder mustFilter);
/**
* 按品牌前缀名获取品牌列表[按参数决定是否返回全球购品牌]
... ... @@ -33,33 +41,26 @@ public interface IBrandService {
public SearchApiResult brands(Map<String, String> paramMap);
/**
* 获取商品列表[直接从brand索引里取全部][不返回全球购品牌]
* 按品牌聚合商品[按参数决定是否返回全球购品牌]
*
* @param paramMap
* @return
*/
public SearchApiResult brandList(Map<String, String> paramMap);
public SearchApiResult groupBrands(Map<String, String> paramMap);
/**
* 按品牌聚合商品[按参数决定是否返回全球购品牌]
* 聚合不同品牌的最新商品
*
* @param paramMap
* @return
*/
public SearchApiResult groupBrands(Map<String, String> paramMap);
/**
* 聚合不同品牌的最新商品
*
* @param paramMap
* @return
*/
public SearchApiResult aggProductsByBrandId(Map<String, String> paramMap);
public SearchApiResult aggProductsByBrandId(Map<String, String> paramMap);
/**
* 获取不同品牌的商品列表【按order参数对商品排序】【参数要传brand】
*
* @param paramMap
* @return
*/
public SearchApiResult aggProductsByBrandIdInParam(Map<String, String> paramMap);
/**
* 获取不同品牌的商品列表【按order参数对商品排序】【参数要传brand】
*
* @param paramMap
* @return
*/
public SearchApiResult aggProductsByBrandIdInParam(Map<String, String> paramMap);
}
... ...