Ejemplo n.º 1
0
        public void AcceptFriend(int friendRequestId)
        {
            var friendRequestManager = new FriendRequestManager();
            var friendProfileManager = new FriendProfileManager();
            var friendRequest        = friendRequestManager.AcceptFriendRequest(friendRequestId);

            friendProfileManager.Add(new FriendRelationshiop()
            {
                UserProfileId       = friendRequest.UserProfileId,
                FriendUserProfileId = friendRequest.FriendUserProfileId
            });

            friendProfileManager.Add(new FriendRelationshiop()
            {
                UserProfileId       = friendRequest.FriendUserProfileId,
                FriendUserProfileId = friendRequest.UserProfileId,
            });
        }
        public void AcceptFriend(long friendRequestId)
        {
            var friendRequestManager = new FriendRequestManager();
            var friendProfileManager = new FriendProfileManager();
            var friendRequest        = friendRequestManager.AcceptFriendRequest(friendRequestId);

            friendProfileManager.Add(new FriendProfile()
            {
                ProfileId       = friendRequest.ProfileId,
                FriendProfileId = friendRequest.FriendRequestProfileId,
                IsFavourite     = false
            });

            friendProfileManager.Add(new FriendProfile()
            {
                ProfileId       = friendRequest.FriendRequestProfileId,
                FriendProfileId = friendRequest.ProfileId,
                IsFavourite     = false
            });
        }
Ejemplo n.º 3
0
 public int AcceptFriendRequest(int friendRequestId)
 {
     Console.WriteLine("Accepting...");
     return(_repo.AcceptFriendRequest(friendRequestId));
 }