yujian
2019-07-19 4c31405418bdd063605f1e5821d99f85be02f23c
fanli/src/main/java/com/yeshi/fanli/service/impl/hongbao/HongBaoV2ServiceImpl.java
@@ -587,17 +587,20 @@
               if (notificationMap.get(child.getType()) == null) {
                  HongBaoV2 tempHongBao = new HongBaoV2(child.getId());
                  tempHongBao.setUserInfo(child.getUserInfo());
                  tempHongBao.setMoney(childUpdate.getMoney());
                  tempHongBao
                        .setMoney(childUpdate.getMoney() == null ? new BigDecimal(0) : childUpdate.getMoney());
                  CommonOrder tempCommonOrder = new CommonOrder(commonOrder.getId());
                  tempCommonOrder.setPayment(commonOrder.getPayment());
                  notificationMap.put(child.getType(), new HongBaoOrder(tempCommonOrder, tempHongBao));
               } else {
                  // 增加付款金额与资金
                  HongBaoOrder tempHongBaoOrder = notificationMap.get(child.getType());
                  tempHongBaoOrder.getCommonOrder().setPayment(
                        tempHongBaoOrder.getCommonOrder().getPayment().add(commonOrder.getPayment()));
                  tempHongBaoOrder.getHongBaoV2()
                        .setMoney(tempHongBaoOrder.getHongBaoV2().getMoney().add(childUpdate.getMoney()));
                  if (commonOrder.getPayment() != null)
                     tempHongBaoOrder.getCommonOrder().setPayment(
                           tempHongBaoOrder.getCommonOrder().getPayment().add(commonOrder.getPayment()));
                  if (childUpdate.getMoney() != null)
                     tempHongBaoOrder.getHongBaoV2()
                           .setMoney(tempHongBaoOrder.getHongBaoV2().getMoney().add(childUpdate.getMoney()));
                  notificationMap.put(child.getType(), tempHongBaoOrder);
               }
@@ -726,7 +729,7 @@
               firstHongbao.setMoney(
                     MoneyBigDecimalUtil.mul(hongBao.getMoney(), firstRate.divide(new BigDecimal(100))));
            }
            //返利为0的不通知
            // 返利为0的不通知
            if (firstHongbao.getMoney() == null || firstHongbao.getMoney().compareTo(new BigDecimal(0)) <= 0)
               return;
@@ -777,8 +780,8 @@
                  secondHongbao.setMoney(
                        MoneyBigDecimalUtil.mul(hongBao.getMoney(), secondRate.divide(new BigDecimal(100))));
               }
               //返利为0的不统计
               // 返利为0的不统计
               if (secondHongbao.getMoney() == null || secondHongbao.getMoney().compareTo(new BigDecimal(0)) <= 0)
                  return;
@@ -1034,9 +1037,9 @@
   public List<HongBaoV2> listChildrenById(Long id) {
      return hongBaoV2Mapper.listChildrenById(id);
   }
   @Override
   public List<Long> getUidByNear30DayShareSucceed(){
   public List<Long> getUidByNear30DayShareSucceed() {
      return hongBaoV2Mapper.getUidByNear30DayShareSucceed();
   }
}