/// <summary> /// 获得该用户主动follow(关注)的用户 /// </summary> /// <param name="followerUserId"></param> /// <returns></returns> public IEnumerable <OldHouseUser> GetAllFollowingUser(Guid followerUserId) { //IEnumerable<Guid> followingIds = GetAllFollowingIds(followerUserId); //List<OldHouseUser> result = new List<OldHouseUser>(); //foreach(Guid followingId in followingIds) //{ // result.Add(MyUserManager.FindByIdAsync(followingId).Result); //} //return result; IEnumerable <Guid> followingUserProfileIds = GetAllFollowingIds(followerUserId); List <OldHouseUser> result = new List <OldHouseUser>(); foreach (Guid profileId in followingUserProfileIds) { Guid userId = ProfileService.FindOneById(profileId).UserId; result.Add(MyUserManager.FindByIdAsync(userId).Result); } return(result); }
public OldHouseUserProfile GetProfile(Guid profileId) { return(ProfileService.FindOneById(profileId)); }