Esempio n. 1
0
        public ActionResult DeleteAdminComment(int?id)
        {
            if (id.HasValue)
            {
                var cmt = AdminCommentObject.GetAdminComment(id.Value);
                if (cmt != null)
                {
                    cmt.Delete();
                }
            }

            return(null);
        }
Esempio n. 2
0
 public void Save()
 {
     if (AdminCommentId.HasValue)
     {
         var cmt = AdminCommentObject.GetAdminComment(AdminCommentId.Value);
         if (cmt != null)
         {
             cmt.Comment   = AdminComment;
             cmt.AdminOnly = AdminOnly;
             cmt.Save();
         }
     }
     else
     {
         AdminCommentId = AdminCommentObject.Add(MainId, AdminComment, AdminOnly);
     }
 }
Esempio n. 3
0
 public AdminCommentsModel(int mainId)
 {
     MainId   = mainId;
     Comments = AdminCommentObject.Get(MainId, IsReleaseOfficer);
 }