diff --git a/hzims-service/message/src/main/java/com/hnac/hzims/message/fegin/MessageClient.java b/hzims-service/message/src/main/java/com/hnac/hzims/message/fegin/MessageClient.java index 83c3092..f8b5a26 100644 --- a/hzims-service/message/src/main/java/com/hnac/hzims/message/fegin/MessageClient.java +++ b/hzims-service/message/src/main/java/com/hnac/hzims/message/fegin/MessageClient.java @@ -138,13 +138,13 @@ public class MessageClient extends BladeController implements IMessageClient{ if(saveResult) { List appRecords = pushRecords.stream().filter(record -> MessageConstants.APP_PUSH.equals(record.getType())).collect(Collectors.toList()); // 推送消息 - app - recordService.sendAppMsgByUsers(request,appRecords); + Boolean appFlag = recordService.sendAppMsgByUsers(request, appRecords); // 推送消息 - web - recordService.sendWsMsgByUsers(CollectionUtils.subtract(pushRecords,appRecords).stream().collect(Collectors.toList())); - return R.success("推送成功"); + Boolean wsFlag = recordService.sendWsMsgByUsers(CollectionUtils.subtract(pushRecords, appRecords).stream().collect(Collectors.toList())); + return R.data(appFlag && wsFlag); } else { - return R.fail("保存消息失败"); + return R.data(false); } }