yujian
2019-04-12 3cc9b37357411757f68ca479d7b58dce26b41651
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserLotteryRecordServiceImpl.java
@@ -164,14 +164,15 @@
         throw new UserLotteryRecordException(2, "抽奖次数不足");
      } 
      
      String prize = null;
      String couponType = null;
      // 新人抽奖 -已抽中奖品
      List<UserSystemCoupon> list = userSystemCouponService.getUserCouponBySource(uid, UserSystemCoupon.SOURCE_NEWBIES);
   
      String prize = null;
      if (list == null || list.size() == 0) {
         prize = getLotteryPrizeNewbies(count, 0, null);
      } else if (list.size() == 1) {
         String couponType = null;
         UserSystemCoupon userSystemCoupon = list.get(0);
         SystemCoupon systemCoupon = userSystemCoupon.getSystemCoupon();
         if (systemCoupon != null) {
@@ -186,6 +187,9 @@
      
      if (prize == null || prize.trim().length() == 0) {
         prize = "NoPrize";
      } else if (prize.equals(couponType)) {
         // 已存在此券
         prize = "NoPrize";
      } else {
         try {
            userSystemCouponService.insertUserCoupon(uid, prize, UserSystemCoupon.SOURCE_NEWBIES);