private void InsertValueComment(int Wall_ID, string Content)
 {
     try
     {
         if (Session["login"] != null &&
             Session["AccountID"] != null)
         {
             var obj = new DTOWallComment
             {
                 Wall_ID   = Wall_ID,
                 AccountID = int.Parse(Session["AccountID"].ToString()),
                 Content   = Content
             };
             BllWallComment.Insert(obj);
             //_ErrorComment = LibAlert.Alert.AlertSucess("Bạn đã bình luận thành công !");
         }
         else
         {
             lbMsg.Text = "<b>Chương trình bị ngắt quãng vì lý do an toàn</b><br/>Vui lòng thoát ra và đăng nhập lại !";
             LibWindowUI.Window.OpenWindows(Page, GetType(), "#myModal");
         }
     }
     catch (Exception ex)
     {
         _ErrorComment = LibAlert.Alert.AlertError("Có lỗi xảy ra trong quá trình bình luận <br/>" + ex.Message);
     }
 }
 private void DeleteComment()
 {
     try
     {
         var obj = new DTOWallComment {
             WallComment_ID = int.Parse(lbWallIDDel.Text)
         };
         BllWallComment.Delete(obj);
         lbMsgDel.Text = string.Empty;
         GetWall(Request.Params["username"], int.Parse(WebConfigurationManager.AppSettings["pageSizeWall"]));
         LibWindowUI.Window.CloseWindows(Page, GetType(), "#myModalDel");
     }
     catch (Exception ex)
     {
         lbMsgDel.Text = "Có lỗi xảy ra trong quá trình xoá bài viết.<br/>" + ex.Message;
     }
 }
Example #3
0
 public static bool Delete(DTOWallComment obj)
 {
     return(DalWallComment.Delete(obj));
 }
Example #4
0
 public static bool Insert(DTOWallComment obj)
 {
     return(DalWallComment.Insert(obj));
 }