From 6ab2aae92f55d777e6dea42709f248c0a68cd4e2 Mon Sep 17 00:00:00 2001
From: admin <weikou2014>
Date: 星期一, 13 四月 2020 18:38:49 +0800
Subject: [PATCH] 删除无用消息
---
fanli/src/main/java/com/yeshi/fanli/service/impl/msg/MsgOtherDetailServiceImpl.java | 40 ++--------------------------------------
1 files changed, 2 insertions(+), 38 deletions(-)
diff --git a/fanli/src/main/java/com/yeshi/fanli/service/impl/msg/MsgOtherDetailServiceImpl.java b/fanli/src/main/java/com/yeshi/fanli/service/impl/msg/MsgOtherDetailServiceImpl.java
index 7145976..d6e35b1 100644
--- a/fanli/src/main/java/com/yeshi/fanli/service/impl/msg/MsgOtherDetailServiceImpl.java
+++ b/fanli/src/main/java/com/yeshi/fanli/service/impl/msg/MsgOtherDetailServiceImpl.java
@@ -27,44 +27,8 @@
@Override
public void addMsgOtherDetail(MsgOtherDetail detail) throws MsgOtherDetailException {
- if (detail.getType() == MsgTypeOtherTypeEnum.couponMianDan
- || detail.getType() == MsgTypeOtherTypeEnum.couponReward
- || detail.getType() == MsgTypeOtherTypeEnum.couponWelfareMianDan) {
- if (detail.getCoupnContent() == null)
- throw new MsgOtherDetailException(1, "鍐呭涓虹┖");
- detail.setContent(new Gson().toJson(detail.getCoupnContent()));
- if (detail.getCreateTime() == null)
- detail.setCreateTime(new Date());
- msgOtherDetailMapper.insertSelective(detail);
- userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
- } else if (detail.getType() == MsgTypeOtherTypeEnum.taoLiJin) {
- msgOtherDetailMapper.insertSelective(detail);
- userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
- } else if (detail.getType() == MsgTypeOtherTypeEnum.give) {
- msgOtherDetailMapper.insertSelective(detail);
- userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
- } else if (detail.getType() == MsgTypeOtherTypeEnum.exchange) {
- msgOtherDetailMapper.insertSelective(detail);
- userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
- } else if (detail.getType() == MsgTypeOtherTypeEnum.couponActivate) {
- msgOtherDetailMapper.insertSelective(detail);
- userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
- } else if (detail.getType() == MsgTypeOtherTypeEnum.firstOrderReward) {
- msgOtherDetailMapper.insertSelective(detail);
- userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
- }else if (detail.getType() == MsgTypeOtherTypeEnum.systemGive) {
- msgOtherDetailMapper.insertSelective(detail);
- userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
- } else if (detail.getType() == MsgTypeOtherTypeEnum.taoLiJinExchange) {
- msgOtherDetailMapper.insertSelective(detail);
- userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
- } else if (detail.getType() == MsgTypeOtherTypeEnum.passVIPApply
- || detail.getType() == MsgTypeOtherTypeEnum.rejectVIPApply
- || detail.getType() == MsgTypeOtherTypeEnum.teamVIPCallBoss
- || detail.getType() == MsgTypeOtherTypeEnum.teamSplitCallBoss) {
- msgOtherDetailMapper.insertSelective(detail);
- userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
- }
+ msgOtherDetailMapper.insertSelective(detail);
+ userMsgReadStateService.addOtherMsgUnReadCount(detail.getUser().getId(), 1);
}
@Override
--
Gitblit v1.8.0