From c6f32fd5fd0cf1cf0758765a697c9e9ad5bbba13 Mon Sep 17 00:00:00 2001 From: yujian <yujian@123.com> Date: 星期二, 30 七月 2019 17:30:46 +0800 Subject: [PATCH] 分享bug --- fanli/src/main/java/com/yeshi/fanli/service/impl/hongbao/HongBaoV2ServiceImpl.java | 27 +++++++++++++++------------ 1 files changed, 15 insertions(+), 12 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/service/impl/hongbao/HongBaoV2ServiceImpl.java b/fanli/src/main/java/com/yeshi/fanli/service/impl/hongbao/HongBaoV2ServiceImpl.java index f6f1a96..6dfde25 100644 --- a/fanli/src/main/java/com/yeshi/fanli/service/impl/hongbao/HongBaoV2ServiceImpl.java +++ b/fanli/src/main/java/com/yeshi/fanli/service/impl/hongbao/HongBaoV2ServiceImpl.java @@ -152,6 +152,8 @@ public void addHongBao(List<CommonOrder> commonOrderList, int type) throws HongBaoException { Set<Integer> stateSet = new HashSet<>();// 璁㈠崟鐘舵�丼et if (commonOrderList != null && commonOrderList.size() > 0) { + int orderType = commonOrderList.get(0).getSourceType(); + Map<Integer, HongBaoOrder> notificationMap = new HashMap<>(); int goodsCount = 0; boolean hasAdd = false; @@ -183,30 +185,30 @@ BigDecimal money = notify.getMoney(); switch (t) { case HongBaoV2.TYPE_ZIGOU: - userOrderMsgNotificationService.orderFanLiStatistic(uid, orderId, commonOrder.getPayment(), + userOrderMsgNotificationService.orderFanLiStatistic(uid, orderId, orderType,commonOrder.getPayment(), money, goodsCount, state); break; case HongBaoV2.TYPE_SHARE_GOODS: userNotificationService.orderShareStatisticed(uid, orderId, goodsCount, MsgOrderDetail.STATE_FK, null, money); - userOrderMsgNotificationService.orderShareStatistic(uid, orderId, commonOrder.getPayment(), + userOrderMsgNotificationService.orderShareStatistic(uid, orderId,orderType, commonOrder.getPayment(), money, goodsCount, state); break; case HongBaoV2.TYPE_YIJI: userNotificationService.orderInviteStatisticed(uid, orderId, goodsCount, MsgOrderDetail.STATE_FK, null, money); - userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, commonOrder.getPayment(), + userOrderMsgNotificationService.orderInviteStatistic(uid, orderId,orderType, commonOrder.getPayment(), money, goodsCount, state); break; case HongBaoV2.TYPE_ERJI: userNotificationService.orderInviteStatisticed(uid, orderId, goodsCount, MsgOrderDetail.STATE_FK, null, money); - userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, commonOrder.getPayment(), + userOrderMsgNotificationService.orderInviteStatistic(uid, orderId,orderType, commonOrder.getPayment(), money, goodsCount, state); break; case HongBaoV2.TYPE_SHARE_YIJI: - userOrderMsgNotificationService.orderShareFirstLevelStatistic(uid, orderId, + userOrderMsgNotificationService.orderShareFirstLevelStatistic(uid, orderId,orderType, commonOrder.getPayment(), money, goodsCount, state, notify.getBeizhu()); break; } @@ -226,23 +228,23 @@ BigDecimal money = notify.getMoney(); switch (t) { case HongBaoV2.TYPE_ZIGOU: - userOrderMsgNotificationService.orderFanLiStateChanged(uid, orderId, commonOrder.getPayment(), + userOrderMsgNotificationService.orderFanLiStateChanged(uid, orderId,orderType, commonOrder.getPayment(), money, state); break; case HongBaoV2.TYPE_SHARE_GOODS: - userOrderMsgNotificationService.orderShareStateChanged(uid, orderId, commonOrder.getPayment(), + userOrderMsgNotificationService.orderShareStateChanged(uid, orderId,orderType, commonOrder.getPayment(), money, state); break; case HongBaoV2.TYPE_YIJI: - userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId, commonOrder.getPayment(), + userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId,orderType, commonOrder.getPayment(), money, state); break; case HongBaoV2.TYPE_ERJI: - userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId, commonOrder.getPayment(), + userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId,orderType, commonOrder.getPayment(), money, state); break; case HongBaoV2.TYPE_SHARE_YIJI: - userOrderMsgNotificationService.orderShareFirstLevelStateChanged(uid, orderId, + userOrderMsgNotificationService.orderShareFirstLevelStateChanged(uid, orderId,orderType, commonOrder.getPayment(), money, state); } } @@ -288,7 +290,8 @@ payMent = commonOrder.getSettlement(); if (payMent.compareTo(new BigDecimal(10)) < 0) { - mianDan = userSystemCouponRecordService.isSuccessMianDan(commonOrder.getOrderNo()); + mianDan = userSystemCouponRecordService.isSuccessMianDan(commonOrder.getSourceType(), + commonOrder.getOrderNo()); } } @@ -961,7 +964,7 @@ hb.setMoney(hongBao.getMoney()); try { - userShareGoodsGroupService.updateOrderRecord(hb); + userShareGoodsGroupService.updateOrderRecord(hb,commonOrder.getSourceType()); } catch (UserShareGoodsRecordException e) { try { LogHelper.errorDetailInfo(e); -- Gitblit v1.8.0