Authored by LUOXC

去掉闪购寄存优惠券限制

@@ -2,13 +2,11 @@ package com.yohoufo.order.charge; @@ -2,13 +2,11 @@ package com.yohoufo.order.charge;
2 2
3 import com.google.common.collect.Lists; 3 import com.google.common.collect.Lists;
4 import com.yohobuy.ufo.model.order.constants.RegionEnum; 4 import com.yohobuy.ufo.model.order.constants.RegionEnum;
5 -import com.yohobuy.ufo.model.order.constants.SkupType;  
6 import com.yohobuy.ufo.model.promotion.UserCouponsBo; 5 import com.yohobuy.ufo.model.promotion.UserCouponsBo;
7 import com.yohobuy.ufo.model.promotion.constant.CouponProductLimitTypeEnum; 6 import com.yohobuy.ufo.model.promotion.constant.CouponProductLimitTypeEnum;
8 import com.yohobuy.ufo.model.promotion.constant.CouponUseLimitTypeEnum; 7 import com.yohobuy.ufo.model.promotion.constant.CouponUseLimitTypeEnum;
9 import com.yohoufo.order.charge.model.ChargeGoods; 8 import com.yohoufo.order.charge.model.ChargeGoods;
10 import com.yohoufo.order.charge.model.CouponMatchResult; 9 import com.yohoufo.order.charge.model.CouponMatchResult;
11 -import com.yohoufo.order.utils.BuyerOrderUtils;  
12 import com.yohoufo.order.utils.LoggerUtils; 10 import com.yohoufo.order.utils.LoggerUtils;
13 import org.apache.commons.collections.CollectionUtils; 11 import org.apache.commons.collections.CollectionUtils;
14 import org.slf4j.Logger; 12 import org.slf4j.Logger;
@@ -157,23 +155,14 @@ public class CouponRuleMatcher { @@ -157,23 +155,14 @@ public class CouponRuleMatcher {
157 @Override 155 @Override
158 public boolean match(ChargeGoods chargeGoods, UserCouponsBo couponsBo) { 156 public boolean match(ChargeGoods chargeGoods, UserCouponsBo couponsBo) {
159 157
160 - // 闪购寄存不可以用券 TODO 后台可控制  
161 - if (chargeGoods.getSkupType() == SkupType.QUICK_DELIVER && chargeGoods.isDepositRequirement()) {  
162 - return false;  
163 - }  
164 -  
165 if (couponsBo.getSkupForbidType() == null){ 158 if (couponsBo.getSkupForbidType() == null){
166 return true; 159 return true;
167 } 160 }
168 161
169 -  
170 -  
171 if (Arrays.asList(couponsBo.getSkupForbidType().split(",")).contains(String.valueOf(chargeGoods.getAttributes()))){ 162 if (Arrays.asList(couponsBo.getSkupForbidType().split(",")).contains(String.valueOf(chargeGoods.getAttributes()))){
172 return false; 163 return false;
173 } 164 }
174 165
175 -  
176 -  
177 return true; 166 return true;
178 } 167 }
179 } 168 }