diff --git a/src/main/java/cn/com/tenlion/systemoa/service/mail/impl/MailServiceImpl.java b/src/main/java/cn/com/tenlion/systemoa/service/mail/impl/MailServiceImpl.java index 8198250..b9f225c 100644 --- a/src/main/java/cn/com/tenlion/systemoa/service/mail/impl/MailServiceImpl.java +++ b/src/main/java/cn/com/tenlion/systemoa/service/mail/impl/MailServiceImpl.java @@ -12,7 +12,9 @@ import ink.wgink.common.base.DefaultBaseService; import ink.wgink.common.component.SecurityComponent; import ink.wgink.pojo.ListPage; import ink.wgink.pojo.bos.UserInfoBO; +import ink.wgink.pojo.dtos.user.UserDTO; import ink.wgink.pojo.result.SuccessResultList; +import ink.wgink.service.user.service.IUserService; import ink.wgink.util.UUIDUtil; import ink.wgink.util.date.DateUtil; import ink.wgink.util.map.HashMapUtil; @@ -36,6 +38,8 @@ public class MailServiceImpl extends DefaultBaseService implements IMailService private IMailDao mailDao; @Autowired private SecurityComponent securityComponent; + @Autowired + private IUserService userService; @Override @@ -133,7 +137,8 @@ public class MailServiceImpl extends DefaultBaseService implements IMailService } } } - dto.setCreatorNames(currentUser.getUserUsername() + "[" + currentUser.getUserName() + "]"); + UserDTO sendDto = userService.get(dto.getCreator()); + dto.setCreatorNames(sendDto.getUserUsername() + "[" + sendDto.getUserName() + "]"); String spx = "
在 "+ dto.getGmtCreate() + ", " +""+ currentUser.getUserUsername() + " [" + currentUser.getUserName() + "] 写道:" +"
" + "