Showing
1 changed file
with
7 additions
and
3 deletions
@@ -3,8 +3,10 @@ package com.yoho.search.service.aggregations.impls; | @@ -3,8 +3,10 @@ package com.yoho.search.service.aggregations.impls; | ||
3 | import com.yoho.search.core.es.agg.IAggregation; | 3 | import com.yoho.search.core.es.agg.IAggregation; |
4 | import com.yoho.search.service.aggregations.AggInterface; | 4 | import com.yoho.search.service.aggregations.AggInterface; |
5 | import com.yoho.search.service.service.SearchCommonService; | 5 | import com.yoho.search.service.service.SearchCommonService; |
6 | +import com.yoho.search.service.service.base.BrandIndexBaseService; | ||
6 | import com.yoho.search.service.servicenew.IShopsService; | 7 | import com.yoho.search.service.servicenew.IShopsService; |
7 | import com.yoho.search.service.servicenew.impl.SearchAfterCacheService; | 8 | import com.yoho.search.service.servicenew.impl.SearchAfterCacheService; |
9 | + | ||
8 | import org.springframework.beans.factory.annotation.Autowired; | 10 | import org.springframework.beans.factory.annotation.Autowired; |
9 | import org.springframework.stereotype.Service; | 11 | import org.springframework.stereotype.Service; |
10 | 12 | ||
@@ -17,6 +19,8 @@ public class AggregationFactoryService { | @@ -17,6 +19,8 @@ public class AggregationFactoryService { | ||
17 | private SearchCommonService searchCommonService; | 19 | private SearchCommonService searchCommonService; |
18 | @Autowired | 20 | @Autowired |
19 | private SearchAfterCacheService searchAfterCacheService; | 21 | private SearchAfterCacheService searchAfterCacheService; |
22 | + @Autowired | ||
23 | + private BrandIndexBaseService brandIndexBaseService; | ||
20 | 24 | ||
21 | @Autowired | 25 | @Autowired |
22 | private IShopsService shopsService; | 26 | private IShopsService shopsService; |
@@ -43,7 +47,7 @@ public class AggregationFactoryService { | @@ -43,7 +47,7 @@ public class AggregationFactoryService { | ||
43 | iAggregation = new StyleAggregation(searchCommonService, paramMap); | 47 | iAggregation = new StyleAggregation(searchCommonService, paramMap); |
44 | break; | 48 | break; |
45 | case AggInterface.BRAND: | 49 | case AggInterface.BRAND: |
46 | - iAggregation = new BrandAggregation(searchCommonService, paramMap); | 50 | + iAggregation = new BrandAggregation(brandIndexBaseService, paramMap); |
47 | break; | 51 | break; |
48 | case AggInterface.SIZE: | 52 | case AggInterface.SIZE: |
49 | iAggregation = new SizeAggregation(searchCommonService); | 53 | iAggregation = new SizeAggregation(searchCommonService); |
@@ -96,11 +100,11 @@ public class AggregationFactoryService { | @@ -96,11 +100,11 @@ public class AggregationFactoryService { | ||
96 | } | 100 | } |
97 | 101 | ||
98 | public IAggregation getBrandAggregation(Map<String, String> paramMap) { | 102 | public IAggregation getBrandAggregation(Map<String, String> paramMap) { |
99 | - return new BrandAggregation(searchCommonService, paramMap); | 103 | + return new BrandAggregation(brandIndexBaseService, paramMap); |
100 | } | 104 | } |
101 | 105 | ||
102 | public IAggregation getBrandAggregation(Map<String, String> paramMap, int brandCount) { | 106 | public IAggregation getBrandAggregation(Map<String, String> paramMap, int brandCount) { |
103 | - return new BrandAggregation(searchCommonService, paramMap, brandCount); | 107 | + return new BrandAggregation(brandIndexBaseService, paramMap, brandCount); |
104 | } | 108 | } |
105 | 109 | ||
106 | public IAggregation getSizeAggregation() { | 110 | public IAggregation getSizeAggregation() { |
-
Please register or login to post a comment