示例#1
0
 public static int AcceptFriend(string UserId, string FriendUserId)
 {
     int retVal = 0;
     try
     {
         retVal = new FriendFacade().AcceptFriend(new Guid(UserId), new Guid(FriendUserId));
     }
     catch
     { }
     return retVal;
 }
示例#2
0
 public static int AddFriend(string FId)
 {
     int retVal = 0;
     try
     {
         Friend objFriend = new Friend();
         objFriend.UserId = new Guid(HttpContext.Current.Session["UserId"].ToString());
         objFriend.FriendUserId = new Guid(FId);
         objFriend.IsAccepted = false;
         objFriend.IsMailSent = true;
         objFriend.IsBlocked = false;
         objFriend.IsRead = false;
         retVal = new FriendFacade().Insert(objFriend);
     }
     catch
     { }
     return retVal;
 }