|
@@ -162,18 +162,18 @@ public class ExchangeCodeServiceImpl extends ServiceImpl<ExchangeCodeMapper, Exc
|
|
|
Long popularizeId = orderDon.getPopularizeId();
|
|
Long popularizeId = orderDon.getPopularizeId();
|
|
|
|
|
|
|
|
//360 渠道兑换规则验证.
|
|
//360 渠道兑换规则验证.
|
|
|
- if(popularizeId != null && popularizeId != 0){
|
|
|
|
|
- String channel = channelPopularizeMapper.selectChannelByPid(popularizeId);
|
|
|
|
|
- if (Constant.CHANNEL_NAME_360.equals(channel)) {
|
|
|
|
|
- //查询该用户之前是否存在订单.
|
|
|
|
|
- Integer count = orderDonMapper.selectCount(Wrappers.lambdaQuery(OrderDon.class)
|
|
|
|
|
- .eq(OrderDon::getUserId, userId)
|
|
|
|
|
- .notIn(OrderDon::getStatus, Constant.noOrderStatus));
|
|
|
|
|
- if (count > 0) {
|
|
|
|
|
- throw new BusinessRuntimeException("您不符合360活动条件.");
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
|
|
+// if(popularizeId != null && popularizeId != 0){
|
|
|
|
|
+// String channel = channelPopularizeMapper.selectChannelByPid(popularizeId);
|
|
|
|
|
+// if (Constant.CHANNEL_NAME_360.equals(channel)) {
|
|
|
|
|
+// //查询该用户之前是否存在订单.
|
|
|
|
|
+// Integer count = orderDonMapper.selectCount(Wrappers.lambdaQuery(OrderDon.class)
|
|
|
|
|
+// .eq(OrderDon::getUserId, userId)
|
|
|
|
|
+// .notIn(OrderDon::getStatus, Constant.noOrderStatus));
|
|
|
|
|
+// if (count > 0) {
|
|
|
|
|
+// throw new BusinessRuntimeException("您不符合360活动条件.");
|
|
|
|
|
+// }
|
|
|
|
|
+// }
|
|
|
|
|
+// }
|
|
|
|
|
|
|
|
if (orderDon != null && orderDon.getStatus() == OrderDon.Status.refund) {
|
|
if (orderDon != null && orderDon.getStatus() == OrderDon.Status.refund) {
|
|
|
throw BusinessRuntimeException.getInstance("您的订单已退款,无法使用该兑换码");
|
|
throw BusinessRuntimeException.getInstance("您的订单已退款,无法使用该兑换码");
|