Authored by 胡古飞

fix bug

@@ -55,20 +55,20 @@ public class SpecialDealLogicService { @@ -55,20 +55,20 @@ public class SpecialDealLogicService {
55 specialSearchField.append("全球购,quanqiugou,"); 55 specialSearchField.append("全球购,quanqiugou,");
56 } 56 }
57 57
58 - if (productIBO.getBundleType() != null){ 58 + if (productIBO.getBundleType() != null) {
59 // 处理折扣类型 0:正常商品 1:套餐 2:量贩 3:搭配 59 // 处理折扣类型 0:正常商品 1:套餐 2:量贩 3:搭配
60 - switch (productIBO.getBundleType()){  
61 - case 1:  
62 - specialSearchField.append("套餐,taocan,");  
63 - break;  
64 - case 2:  
65 - specialSearchField.append("量贩,liangfan,");  
66 - break;  
67 - case 3:  
68 - specialSearchField.append("搭配,dapei,");  
69 - break;  
70 - default:  
71 - break; 60 + switch (productIBO.getBundleType()) {
  61 + case 1:
  62 + specialSearchField.append("套餐,taocan,");
  63 + break;
  64 + case 2:
  65 + specialSearchField.append("量贩,liangfan,");
  66 + break;
  67 + case 3:
  68 + specialSearchField.append("搭配,dapei,");
  69 + break;
  70 + default:
  71 + break;
72 } 72 }
73 } 73 }
74 74
@@ -90,19 +90,22 @@ public class SpecialDealLogicService { @@ -90,19 +90,22 @@ public class SpecialDealLogicService {
90 // 1、处理ageLevel 90 // 1、处理ageLevel
91 String ageLevel = specialDealAgeLevel(productIBO.getAgeLevel()); 91 String ageLevel = specialDealAgeLevel(productIBO.getAgeLevel());
92 productIBO.setAgeLevel(ageLevel); 92 productIBO.setAgeLevel(ageLevel);
93 - 93 +
94 // 2、处理specialSearchField 94 // 2、处理specialSearchField
95 String specialSearchField = getSpecialSearchFieldFromProduct(productIBO); 95 String specialSearchField = getSpecialSearchFieldFromProduct(productIBO);
96 productIBO.setSpecialSearchField(specialSearchField); 96 productIBO.setSpecialSearchField(specialSearchField);
97 - 97 +
98 // 3、处理isForiddenSortBrand 98 // 3、处理isForiddenSortBrand
99 int isForbiddenSortBrand = this.getIsForbiddenSortBrand(productIBO); 99 int isForbiddenSortBrand = this.getIsForbiddenSortBrand(productIBO);
100 productIBO.setIsForbiddenSortBrand(isForbiddenSortBrand); 100 productIBO.setIsForbiddenSortBrand(isForbiddenSortBrand);
101 - 101 +
102 // 4、处理物理分类对应的销售分类 102 // 4、处理物理分类对应的销售分类
103 List<Integer> physicalChannels = salesCategoryLogicService.getPhysicalChannelsBySmallSortId(productIBO.getSmallSortId()); 103 List<Integer> physicalChannels = salesCategoryLogicService.getPhysicalChannelsBySmallSortId(productIBO.getSmallSortId());
104 productIBO.setPhysicalChannels(StringUtils.join(physicalChannels, ",")); 104 productIBO.setPhysicalChannels(StringUtils.join(physicalChannels, ","));
105 - 105 + if ("Y".equals(productIBO.getIsGlobal())) {
  106 + productIBO.setPhysicalChannels("1,2,3,4");
  107 + }
  108 +
106 // 5、处理限购,防止数据库未设置 109 // 5、处理限购,防止数据库未设置
107 if (StringUtils.isBlank(productIBO.getIsLimitbuy())) { 110 if (StringUtils.isBlank(productIBO.getIsLimitbuy())) {
108 productIBO.setIsLimitbuy("N"); 111 productIBO.setIsLimitbuy("N");