admin
2019-04-19 7da75926f4f910a0fa23ab96f2af637d0a9578a0
fanli/src/main/java/com/yeshi/fanli/service/impl/msg/MsgOtherDetailServiceImpl.java
@@ -34,6 +34,7 @@
         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);
@@ -50,6 +51,7 @@
         if (detail.getCoupnContent() == null)
            throw new MsgOtherDetailException(1, "内容为空");
         detail.setContent(new Gson().toJson(detail.getCoupnContent()));
         if(detail.getUpdateTime()==null)
         detail.setUpdateTime(new Date());
         msgOtherDetailMapper.updateByPrimaryKeySelective(detail);
      }