|
@@ -33,6 +33,7 @@ namespace GxPress.Service.Implement
|
|
|
private readonly IUserRepository _userRepository;
|
|
|
private readonly IDepartmentRepository _departmentRepository;
|
|
|
private readonly IAddressBookGroupRepository _addressBookGroupRepository;
|
|
|
+ private readonly IAddressBookGroupUserRepository addressBookGroupUserRepository;
|
|
|
private IWebHostEnvironment _webHostEnvironment;
|
|
|
private readonly IBlacklistUserRepository _blacklistUserRepository;
|
|
|
private readonly IRoleRepository _roleRepository;
|
|
@@ -47,7 +48,7 @@ namespace GxPress.Service.Implement
|
|
|
private readonly IGroupUserRepository groupUserRepository;
|
|
|
public UserService(IUserRepository userRepository, IDepartmentRepository departmentRepository,
|
|
|
IAddressBookGroupRepository addressBookGroupRepository, IBlacklistUserRepository blacklistUserRepository,
|
|
|
- IMapper mapper, IWebHostEnvironment webHostEnvironment, IRoleRepository roleRepository, IIMService imService, IFlowRepository flowRepository, IFlowTodoRepository flowTodoRepository, IWaitHandleRepository waitHandleRepository, IDepartmentUserRepository departmentUserRepository, IFriendsRepository friendsRepository, IGroupChatUserRepository groupChatUserRepository, IGroupUserRepository groupUserRepository)
|
|
|
+ IMapper mapper, IWebHostEnvironment webHostEnvironment, IRoleRepository roleRepository, IIMService imService, IFlowRepository flowRepository, IFlowTodoRepository flowTodoRepository, IWaitHandleRepository waitHandleRepository, IDepartmentUserRepository departmentUserRepository, IFriendsRepository friendsRepository, IGroupChatUserRepository groupChatUserRepository, IGroupUserRepository groupUserRepository, IAddressBookGroupUserRepository addressBookGroupUserRepository)
|
|
|
{
|
|
|
|
|
|
_userRepository = userRepository;
|
|
@@ -65,6 +66,7 @@ namespace GxPress.Service.Implement
|
|
|
this.friendsRepository = friendsRepository;
|
|
|
this.groupChatUserRepository = groupChatUserRepository;
|
|
|
this.groupUserRepository = groupUserRepository;
|
|
|
+ this.addressBookGroupUserRepository = addressBookGroupUserRepository;
|
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
@@ -562,6 +564,13 @@ namespace GxPress.Service.Implement
|
|
|
var result = await _userRepository.GetSearchUserInfoResults(keyword, groupUsers.Select(n => n.UserId));
|
|
|
return result;
|
|
|
}
|
|
|
+ //自建小组
|
|
|
+ if (typeValue == 3)
|
|
|
+ {
|
|
|
+ var addressGroupUsers = await addressBookGroupUserRepository.GetAllAsync(Q.Where(nameof(Entity.AddressBookGroupUser.AddressBookGroupId), id));
|
|
|
+ var result = await _userRepository.GetSearchUserInfoResults(keyword, addressGroupUsers.Select(n => n.UserId));
|
|
|
+ return result;
|
|
|
+ }
|
|
|
return null;
|
|
|
}
|
|
|
|