admin
2020-04-13 8b9d35fbe2a64294bc9532de96082a675dcade1e
删除无效的消息调用
5个文件已修改
151 ■■■■ 已修改文件
fanli/src/main/java/com/yeshi/fanli/service/impl/elme/ElmeOrderProcessServiceImpl.java 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/HongBaoV2ServiceImpl.java 47 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/LostOrderServiceImpl.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/manger/order/HongBaoV2AddManager.java 45 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/manger/order/HongBaoV2AddManagerV2.java 44 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/elme/ElmeOrderProcessServiceImpl.java
@@ -97,9 +97,7 @@
            } catch (ElmeHongBaoOrderMapException e) {
                throw new ElmeOrderException(e.getCode(), e.getMsg());
            }
            // 发送消息
            userOrderMsgNotificationService.orderElmeStatistic(user.getId(), elmeOrder.getOrderId(),
                    Constant.SOURCE_TYPE_ELME, elmeOrder.getPayMoney(), hongBao.getMoney(), hongBao.getState());
        } else {// 订单存在
            HongBaoV2 oldHongBao = hongBaoV2Service.selectByPrimaryKey(map.getHongBao().getId());
            if (oldHongBao == null)
@@ -115,10 +113,7 @@
                update.setPreGetTime(hongBao.getPreGetTime());
                update.setUpdateTime(new Date());
                hongBaoV2Service.updateByPrimaryKeySelective(update);
                // 发送消息
                userOrderMsgNotificationService.orderElmeStateChanged(oldHongBao.getUserInfo().getId(),
                        elmeOrder.getOrderId(), Constant.SOURCE_TYPE_ELME, elmeOrder.getPayMoney(), hongBao.getMoney(),
                        hongBao.getState());
            }
        }
fanli/src/main/java/com/yeshi/fanli/service/impl/order/HongBaoV2ServiceImpl.java
@@ -205,54 +205,21 @@
                        userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, orderType,
                                commonOrder.getPayment(), money, goodsCount, commonOrder.getState(),
                                commonOrder.getThirdCreateTime());
                        break;
                    case HongBaoV2.TYPE_ERJI:
                        userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, orderType,     commonOrder.getPayment(), money,
                                goodsCount,  commonOrder.getState(), commonOrder.getThirdCreateTime());
                        break;
                    case HongBaoV2.TYPE_SHARE_YIJI:
                        userOrderMsgNotificationService.orderShareFirstLevelStatistic(uid, orderId, orderType,
                                commonOrder.getPayment(), money, goodsCount, state, notify.getBeizhu());
                        userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, orderType,
                                commonOrder.getPayment(), money, goodsCount, commonOrder.getState(),
                                commonOrder.getThirdCreateTime());
                    case HongBaoV2.TYPE_SHARE_ERJI:
                        userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, orderType,     commonOrder.getPayment(), money,
                                goodsCount,  commonOrder.getState(), commonOrder.getThirdCreateTime());
                        break;
                    }
                }
            }
            // 添加新版本通知
            if (!hasAdd) {
                Iterator<Integer> its = notificationMap.keySet().iterator();
                while (its.hasNext()) {
                    Integer t = its.next();
                    HongBaoV2 notify = notificationMap.get(t).getHongBaoV2();
                    CommonOrder commonOrder = notificationMap.get(t).getCommonOrder();
                    String orderId = commonOrderList.get(0).getOrderNo();
                    Long uid = notify.getUserInfo().getId();
                    BigDecimal money = notify.getMoney();
                    switch (t) {
                    case HongBaoV2.TYPE_ZIGOU:
                        userOrderMsgNotificationService.orderFanLiStateChanged(uid, orderId, orderType,
                                commonOrder.getPayment(), money, state);
                        break;
                    case HongBaoV2.TYPE_SHARE_GOODS:
                        userOrderMsgNotificationService.orderShareStateChanged(uid, orderId, orderType,
                                commonOrder.getPayment(), money, state);
                        break;
                    case HongBaoV2.TYPE_YIJI:
                        userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId, orderType,
                                commonOrder.getPayment(), money, state);
                        break;
                    case HongBaoV2.TYPE_ERJI:
                        userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId, orderType,
                                commonOrder.getPayment(), money, state);
                        break;
                    case HongBaoV2.TYPE_SHARE_YIJI:
                        userOrderMsgNotificationService.orderShareFirstLevelStateChanged(uid, orderId, orderType,
                                commonOrder.getPayment(), money, state);
                    }
                }
            }
fanli/src/main/java/com/yeshi/fanli/service/impl/order/LostOrderServiceImpl.java
@@ -270,8 +270,7 @@
                update.setResultCode(LostOrder.RESULT_CODE_FAIL);
                lostOrderMapper.updateByPrimaryKeySelective(update);
                // 添加通知
                userOrderMsgNotificationService.orderFoundFail(order.getUserInfo().getId(), order.getOrderId(), null, 1,
                        new Date(order.getHandleTime()));
                userOrderMsgNotificationService.orderFoundFail(order.getUserInfo().getId(), order.getOrderId());
            }
    }
@@ -288,8 +287,7 @@
                update.setResultCode(LostOrder.RESULT_CODE_FAIL);
                lostOrderMapper.updateByPrimaryKeySelective(update);
                // 添加通知
                userOrderMsgNotificationService.orderFoundFail(order.getUserInfo().getId(), order.getOrderId(), null, 1,
                        new Date(order.getHandleTime()));
                userOrderMsgNotificationService.orderFoundFail(order.getUserInfo().getId(), order.getOrderId());
            }
    }
fanli/src/main/java/com/yeshi/fanli/service/manger/order/HongBaoV2AddManager.java
@@ -159,44 +159,17 @@
                            break;
                        case HongBaoV2.TYPE_SHARE_YIJI:
                            userOrderMsgNotificationService.orderShareFirstLevelStatistic(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, goodsCount, state, notify.getBeizhu());
                            userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, goodsCount, commonOrder.getState(),
                                    commonOrder.getThirdCreateTime());
                            break;
                        }
                    }
                }
                        case HongBaoV2.TYPE_SHARE_ERJI:
                            userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, orderType,     commonOrder.getPayment(), money,
                                    goodsCount,  commonOrder.getState(), commonOrder.getThirdCreateTime());
                // 添加新版本通知
                if (!hasAdd) {
                    Iterator<Integer> its = notificationMap.keySet().iterator();
                    while (its.hasNext()) {
                        Integer t = its.next();
                        HongBaoV2 notify = notificationMap.get(t).getHongBaoV2();
                        CommonOrder commonOrder = notificationMap.get(t).getCommonOrder();
                        String orderId = commonOrderList.get(0).getOrderNo();
                        Long uid = notify.getUserInfo().getId();
                        BigDecimal money = notify.getMoney();
                        switch (t) {
                        case HongBaoV2.TYPE_ZIGOU:
                            userOrderMsgNotificationService.orderFanLiStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        case HongBaoV2.TYPE_SHARE_GOODS:
                            userOrderMsgNotificationService.orderShareStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        case HongBaoV2.TYPE_YIJI:
                            userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        case HongBaoV2.TYPE_ERJI:
                            userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        case HongBaoV2.TYPE_SHARE_YIJI:
                            userOrderMsgNotificationService.orderShareFirstLevelStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        }
                    }
                }
fanli/src/main/java/com/yeshi/fanli/service/manger/order/HongBaoV2AddManagerV2.java
@@ -175,44 +175,16 @@
                            break;
                        case HongBaoV2.TYPE_SHARE_YIJI:
                            userOrderMsgNotificationService.orderShareFirstLevelStatistic(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, goodsCount, state, notify.getBeizhu());
                            userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, goodsCount, commonOrder.getState(),
                                    commonOrder.getThirdCreateTime());
                            break;
                        }
                    }
                }
                        case HongBaoV2.TYPE_SHARE_ERJI:
                            userOrderMsgNotificationService.orderInviteStatistic(uid, orderId, orderType,     commonOrder.getPayment(), money,
                                    goodsCount,  commonOrder.getState(), commonOrder.getThirdCreateTime());
                // 添加新版本通知
                if (!hasAdd) {
                    Iterator<Integer> its = notificationMap.keySet().iterator();
                    while (its.hasNext()) {
                        Integer t = its.next();
                        HongBaoV2 notify = notificationMap.get(t).getHongBaoV2();
                        CommonOrder commonOrder = notificationMap.get(t).getCommonOrder();
                        String orderId = commonOrderList.get(0).getOrderNo();
                        Long uid = notify.getUserInfo().getId();
                        BigDecimal money = notify.getMoney();
                        switch (t) {
                        case HongBaoV2.TYPE_ZIGOU:
                            userOrderMsgNotificationService.orderFanLiStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        case HongBaoV2.TYPE_SHARE_GOODS:
                            userOrderMsgNotificationService.orderShareStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        case HongBaoV2.TYPE_YIJI:
                            userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        case HongBaoV2.TYPE_ERJI:
                            userOrderMsgNotificationService.orderInviteStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        case HongBaoV2.TYPE_SHARE_YIJI:
                            userOrderMsgNotificationService.orderShareFirstLevelStateChanged(uid, orderId, orderType,
                                    commonOrder.getPayment(), money, state);
                            break;
                        }
                    }
                }