REQ-3345: 返回用户头像

This commit is contained in:
yanglin 2025-02-08 09:10:30 +08:00
parent 525f69e04a
commit 514e54230c
5 changed files with 8 additions and 8 deletions

View File

@ -131,7 +131,7 @@ public class GroupManager {
throw new ServiceException("群聊人数上限" + group.getMemberLimit() + "人, 请删除部分已选人员");
ImAccounts imAccounts = accountService.getOrCreateImAccounts(toAddMembers);
if (imAccounts.isAccountEmpty()) {
groupSupport.sendNotification("添加群成员[{},{}], 有效群成员IM账号列表为空. 请求成员信息: {}",
groupSupport.send("添加群成员[{},{}], 有效群成员IM账号列表为空. 请求成员信息: {}",
group.getTid(), group.getName(), JSON.toJSONString(request.getMembers()));
return new GroupAddMembersResponse();
}
@ -160,7 +160,7 @@ public class GroupManager {
groupSupport.log(group.getTid(), "remove-members", request);
ImAccounts imAccounts = accountService.getAccountsByPersons(request.getMembers());
if (imAccounts.isAccountEmpty()) {
groupSupport.sendNotification("移除群成员[{},{}], 有效群成员IM账号列表为空. 请求成员信息: {}",
groupSupport.send("移除群成员[{},{}], 有效群成员IM账号列表为空. 请求成员信息: {}",
group.getTid(), group.getName(), JSON.toJSONString(request.getMembers()));
return;
}

View File

@ -4,5 +4,5 @@ package cn.axzo.im.group;
* @author yanglin
*/
public interface GroupNotification {
void sendNotification(String message, Object... args);
void send(String message, Object... args);
}

View File

@ -106,8 +106,8 @@ public class GroupSupport implements GroupNotification {
groupLogDao.save(log);
}
public void sendNotification(String message, Object... args) {
chatGroupService.sendNotification(message, args);
public void send(String message, Object... args) {
chatGroupService.send(message, args);
}
}

View File

@ -32,7 +32,7 @@ public class ImAccounts {
}
public Set<PersonAccountAttribute> getAccountNotFoundPersons(
GroupNotification logger, String operation,
GroupNotification notification, String operation,
Group group, Set<PersonAccountAttribute> persons) {
if (CollectionUtils.isEmpty(persons))
return Collections.emptySet();
@ -40,7 +40,7 @@ public class ImAccounts {
.filter(person -> !findAccount(person).isPresent())
.collect(toSet());
if (!notFound.isEmpty())
logger.sendNotification("{}[{},{}], IM账号不存在列表: {}", operation,
notification.send("{}[{},{}], IM账号不存在列表: {}", operation,
group.getTid(), group.getName(),
JSON.toJSONString(notFound));
return notFound;

View File

@ -768,7 +768,7 @@ public class ChatGroupServiceImpl extends ServiceImpl<ChatGroupMapper, ChatGrou
}
@Override
public void sendNotification(String message, Object... args) {
public void send(String message, Object... args) {
try {
sendDingRobot(MessageFormatter.arrayFormat(message, args).getMessage());
} catch (Exception e) {