admin
2019-11-20 8b2191df2f7d94aa299bd43dcbe97c94e5a61bbd
fanli/src/main/java/com/yeshi/fanli/util/factory/RedPackDetailFactory.java
@@ -25,7 +25,7 @@
      RedPackDetail detail = new RedPackDetail();
      detail.setDisplay(false);
      detail.setDescInfo( "等待人工审核");
      detail.setDescInfo("等待人工审核");
      detail.setUid(exchange.getUid());
      detail.setMoney(new BigDecimal("-" + exchange.getMoney()));
      detail.setType(RedPackDetailTypeEnum.redExchange);
@@ -169,6 +169,7 @@
   }
   /**
    * 板栗商城使用
    * 
    * @param giveRecord
    * @return
@@ -183,7 +184,7 @@
      RedPackDetail detail = new RedPackDetail();
      detail.setDisplay(false);
      detail.setUid(uid);
      detail.setMoney(money);
      detail.setMoney(new BigDecimal(0).subtract(money));
      detail.setType(RedPackDetailTypeEnum.useByShopOrder);
      detail.setTitle(title);
      detail.setIdentifyCode(StringUtil.Md5(RedPackDetailTypeEnum.useByShopOrder.name() + "-" + orderId));
@@ -191,10 +192,10 @@
      detail.setDescInfo(setName);
      return detail;
   }
   /**
    *  新人奖励
    * 新人奖励
    *
    * @param winInvite
    * @return
    * @throws RedPackDetailException
@@ -202,7 +203,7 @@
   public static RedPackDetail createNewUserReward(Long uid, Integer num, BigDecimal money) throws RedPackDetailException {
      if (uid == null || num == null || money == null)
         throw new RedPackDetailException(1, "获得记录不能为空");
      // 红包明细- 退回红包
      RedPackDetail detail = new RedPackDetail();
      detail.setDisplay(true);
      detail.setUid(uid);
@@ -214,9 +215,10 @@
      detail.setCreateTime(new Date());
      return detail;
   }
   /**
    * 立得现金
    *
    * @param winInvite
    * @return
    * @throws RedPackDetailException
@@ -224,7 +226,7 @@
   public static RedPackDetail createInvite(RedPackWinInvite winInvite) throws RedPackDetailException {
      if (winInvite == null)
         throw new RedPackDetailException(1, "获得记录不能为空");
      // 红包明细- 退回红包
      RedPackDetail detail = new RedPackDetail();
      detail.setDisplay(true);
@@ -237,9 +239,10 @@
      detail.setCreateTime(new Date());
      return detail;
   }
   /**
    * 递增奖励 + 好友完成分享订单
    *
    * @param winInvite
    * @return
    * @throws RedPackDetailException
@@ -247,7 +250,7 @@
   public static RedPackDetail createIncreaseReward(RedPackWinInvite winInvite) throws RedPackDetailException {
      if (winInvite == null)
         throw new RedPackDetailException(1, "获得记录不能为空");
      // 红包明细- 退回红包
      RedPackDetail detail = new RedPackDetail();
      detail.setDisplay(true);
@@ -260,10 +263,10 @@
      detail.setCreateTime(new Date());
      return detail;
   }
   /**
    * 连续奖励 + 好友完成分享订单
    *
    * @param winInvite
    * @return
    * @throws RedPackDetailException
@@ -271,7 +274,7 @@
   public static RedPackDetail createSeriesReward(RedPackWinInvite winInvite) throws RedPackDetailException {
      if (winInvite == null)
         throw new RedPackDetailException(1, "获得记录不能为空");
      // 红包明细- 退回红包
      RedPackDetail detail = new RedPackDetail();
      detail.setDisplay(true);
@@ -284,8 +287,7 @@
      detail.setCreateTime(new Date());
      return detail;
   }
   public static RedPackDetail createShopOrderDrawBack(Long orderId, Long uid, String title, String setName,
         BigDecimal money) throws RedPackDetailException {
      if (orderId == null)