getUser 返回账户信息
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
89574e05bc
commit
dcddf88a66
|
@ -140,6 +140,9 @@ namespace IRaCIS.Application.Contracts
|
||||||
public class UserDetailDTO : UserInfo
|
public class UserDetailDTO : UserInfo
|
||||||
{
|
{
|
||||||
public bool CanEditUserType { get; set; }
|
public bool CanEditUserType { get; set; }
|
||||||
|
|
||||||
|
public bool IsMutiAccount => AccountList?.Count > 1;
|
||||||
|
public List<UserAccountInfo> AccountList { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public class UserInfo
|
public class UserInfo
|
||||||
|
|
|
@ -410,7 +410,12 @@ namespace IRaCIS.Core.Application.Service
|
||||||
public async Task<UserDetailDTO> GetUser(Guid id)
|
public async Task<UserDetailDTO> GetUser(Guid id)
|
||||||
{
|
{
|
||||||
var userQuery = _userRepository.Where(t => t.Id == id).ProjectTo<UserDetailDTO>(_mapper.ConfigurationProvider);
|
var userQuery = _userRepository.Where(t => t.Id == id).ProjectTo<UserDetailDTO>(_mapper.ConfigurationProvider);
|
||||||
return await (userQuery.FirstOrDefaultAsync()).IfNullThrowException();
|
var result = await (userQuery.FirstOrDefaultAsync()).IfNullThrowException();
|
||||||
|
|
||||||
|
result.AccountList = _userRepository.Where(t => t.EMail == result.EMail && t.UserTypeEnum != UserTypeEnum.SuperAdmin)
|
||||||
|
.ProjectTo<UserAccountInfo>(_mapper.ConfigurationProvider).ToList();
|
||||||
|
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -627,11 +632,11 @@ namespace IRaCIS.Core.Application.Service
|
||||||
|
|
||||||
//public async Task<IResponseOutput<LoginReturnDTO>> HospitalUserLogin(string token)
|
//public async Task<IResponseOutput<LoginReturnDTO>> HospitalUserLogin(string token)
|
||||||
//{
|
//{
|
||||||
// //同济医院token 地址:http://192.168.40.88:8080
|
// //同济医院token 地址:http://192.168.40.88:8080 appid:third-hirs
|
||||||
|
|
||||||
// //本地测试地址接口
|
// //本地测试地址接口
|
||||||
|
|
||||||
// //RestClientAPI.PostAsync<>
|
// RestClientAPI.PostAsync<>
|
||||||
|
|
||||||
//}
|
//}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue