diff --git a/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/dto/PlanMsgRecordDto.java b/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/dto/PlanMsgRecordDto.java index 0fa7270..ae8e695 100644 --- a/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/dto/PlanMsgRecordDto.java +++ b/hzims-service-api/message-api/src/main/java/com/hnac/hzims/message/dto/PlanMsgRecordDto.java @@ -59,5 +59,7 @@ public class PlanMsgRecordDto implements Serializable { @ApiModelProperty("消息推送耳机") @NotNull private String content; + @ApiModelProperty("租户ID") + private String tenantId; } 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 d192faf..7565730 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 @@ -95,6 +95,9 @@ public class MessageClient extends BladeController implements IMessageClient{ entity.setPusherName(UserCache.getUser(request.getReceiver()).getName()); entity.setAccount(request.getReceiver().toString()); entity.setContent(request.getContent()); + if(Func.isNotEmpty(request.getTenantId())) { + entity.setTenantId(request.getTenantId()); + } Assert.isTrue(recordService.saveAndSend(entity),()-> { throw new ServiceException("消息保存失败!"); });