|
|
@@ -2,6 +2,7 @@ package cn.reghao.tnb.message.app.service;
|
|
|
|
|
|
import cn.reghao.jutil.jdk.thread.ThreadPoolWrapper;
|
|
|
import cn.reghao.tnb.common.util.ConstantId;
|
|
|
+import cn.reghao.tnb.message.api.constant.MsgType;
|
|
|
import cn.reghao.tnb.message.api.dto.UserMessageDto;
|
|
|
import cn.reghao.tnb.message.app.service.notifier.Notify;
|
|
|
import cn.reghao.tnb.message.app.service.notifier.ding.DingMsg;
|
|
|
@@ -66,9 +67,10 @@ public class NotifyService {
|
|
|
try {
|
|
|
notify.send(receiver, msg);
|
|
|
} catch (Exception e) {
|
|
|
+ int msgType = MsgType.sysMsg.getValue();
|
|
|
String title = "发送通知失败";
|
|
|
String content = String.format("发送给 %s 的通知失败 -> %s", receiver, e.getMessage());
|
|
|
- UserMessageDto userMessageDto = new UserMessageDto(title, content, ConstantId.ANONYMOUS_USER_ID);
|
|
|
+ UserMessageDto userMessageDto = new UserMessageDto(msgType, title, content, ConstantId.ANONYMOUS_USER_ID);
|
|
|
userMessageService.addMessage(userMessageDto);
|
|
|
}
|
|
|
}
|