From a0471f2e63a969ad50272738ba25616dc2a2a887 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Wed, 25 Aug 2021 18:05:53 +0800 Subject: [PATCH] =?UTF-8?q?=E6=88=AA=E5=8F=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/epmet/service/impl/InfoServiceImpl.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/InfoServiceImpl.java b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/InfoServiceImpl.java index cc73e3c1a5..684b4ebd50 100644 --- a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/InfoServiceImpl.java +++ b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/InfoServiceImpl.java @@ -156,8 +156,8 @@ public class InfoServiceImpl extends BaseServiceImpl implem userMessageEntity.setApp(AppClientConstant.APP_GOV); userMessageEntity.setTitle(UserMessageConstans.INFO_TITLE); userMessageEntity.setMessageContent(String.format(UserMessageConstans.INFO_CONTENT_TEMP, - infoEntity.getContent().length() >= NumConstant.FIFTY ? - StringUtils.substring(infoEntity.getContent(), NumConstant.FORTY_NINE) : infoEntity.getContent())); + infoEntity.getContent().length() > NumConstant.FIFTY ? + StringUtils.substring(infoEntity.getContent(), NumConstant.ZERO,NumConstant.FORTY_NINE) : infoEntity.getContent())); userMessageEntity.setReadFlag(UserMessageConstans.UNREAD); userMessageEntity.setMessageType(UserMessageConstans.MESSAGE_TYPE_INFO); userMessageEntity.setTargetId(infoEntity.getId()); @@ -170,7 +170,7 @@ public class InfoServiceImpl extends BaseServiceImpl implem InfoProfileEntity infoProfileEntity=new InfoProfileEntity(); infoProfileEntity.setCustomerId(formDTO.getCustomerId()); infoProfileEntity.setInfoId(infoEntity.getId()); - infoProfileEntity.setContent(infoEntity.getContent().length() >= NumConstant.FIFTY ? StringUtils.substring(infoEntity.getContent(), NumConstant.FORTY_NINE) : infoEntity.getContent()); + infoProfileEntity.setContent(infoEntity.getContent().length() > NumConstant.ONE_HUNDRED ? StringUtils.substring(infoEntity.getContent(), NumConstant.ZERO,NumConstant.NINETY_NINE) : infoEntity.getContent()); infoProfileEntity.setPublishStaffId(formDTO.getUserId()); infoProfileEntity.setTotalReceiver(totalReceiver.size()); infoProfileEntity.setFirstAttId(firstAttId);