admin
2019-12-03 ad1c19461fee4c7c4a26795bef75d26f9738faf1
fanli/src/main/java/com/yeshi/fanli/service/impl/order/CommonOrderServiceImpl.java
@@ -72,6 +72,7 @@
import com.yeshi.fanli.vo.msg.ClientTextStyleVO;
import com.yeshi.fanli.vo.order.CommonOrderGoodsVO;
import com.yeshi.fanli.vo.order.CommonOrderVO;
import com.yeshi.fanli.vo.order.OrderCountVO;
import com.yeshi.fanli.vo.order.WeiQuanInfo;
import net.sf.json.JSONObject;
@@ -214,7 +215,7 @@
    */
   public void setSystemCouponRecord(CommonOrderVO order, boolean hasRewardCoupon, boolean exchangeCoupon,
         Integer hongBaoState, Integer hongBaoType, List<UserSystemCouponRecord> list, List<String> signList,
         AcceptData acceptData) {
         Long uid, AcceptData acceptData) {
      // 是否免单商品
      boolean freeOrder = false;
@@ -283,10 +284,11 @@
            rewardOrder = true; // 奖励成功 2.0.2 消失
         }
      } else if (hasRewardCoupon && !freeOrder && HongBaoV2.TYPE_ZIGOU == hongBaoType
            && HongBaoV2.STATE_YILINGQU == hongBaoState) {
         // 有可用的奖励券 、非免单订单 、且已到账的 、返利订单
         type = 2;
         rewardOrder = true;
            && HongBaoV2.STATE_YILINGQU == hongBaoState) { // 有可用的奖励券 、非免单订单 、且已到账的 、返利订单
         if (!userVIPInfoService.isVIP(uid)) { // 非会员可使用奖励券
            type = 2;
            rewardOrder = true;
         }
      }
      if (rewardOrder) {
@@ -494,6 +496,9 @@
               order.setVipOrder(false);
         } else
            order.setVipOrder(false);
         if(order.isVipOrder())
            order.setVipOrderDesc("订单来源:由超级会员的粉丝产生");
      }
      for (CommonOrderVO order : listOrder) {
@@ -768,16 +773,16 @@
            // 奖励订单、免单 使用记录
            if (sourceType == null) {
               setSystemCouponRecord(order, hasRewardCoupon, exchangeCoupon, hongBaoState, hongBaoType, null,
                     signList, acceptData);
                     signList, uid, acceptData);
            } else if (sourceType == Constant.SOURCE_TYPE_TAOBAO) {
               setSystemCouponRecord(order, hasRewardCoupon, exchangeCoupon, hongBaoState, hongBaoType,
                     listRecordTB, signList, acceptData);
                     listRecordTB, signList, uid, acceptData);
            } else if (sourceType == Constant.SOURCE_TYPE_JD) {
               setSystemCouponRecord(order, hasRewardCoupon, exchangeCoupon, hongBaoState, hongBaoType,
                     listRecordJD, signList, acceptData);
                     listRecordJD, signList, uid, acceptData);
            } else if (sourceType == Constant.SOURCE_TYPE_PDD) {
               setSystemCouponRecord(order, hasRewardCoupon, exchangeCoupon, hongBaoState, hongBaoType,
                     listRecordPDD, signList, acceptData);
                     listRecordPDD, signList, uid, acceptData);
            }
         }
@@ -795,6 +800,11 @@
   public Map<String, BigDecimal> countHistoryOrder(Long uid, Integer day, Integer source) {
      return commonOrderMapper.countHistoryOrder(uid, day, source);
   }
   @Override
   public OrderCountVO getOrderCount(Long uid, Integer day, Integer source) {
      return commonOrderMapper.getOrderCount(uid, day, source);
   }
   @Override
   public long countBonusOrderNumber(Long uid, Integer type, Integer day, String startTime, String endTime,