Exemple #1
0
 public IResult Update(Comment comment)
 {
     _validation = new Validation <CommentValidator>();
     _validation.Validate(comment);
     _commentDal.Update(comment);
     return(new SuccessResult());
 }
Exemple #2
0
 public bool Update(Comment model)
 {
     try
     {
         return(commentDal.Update(model));
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemple #3
0
        public bool Update(Comment comment)
        {
            bool result = _commentDal.Update(comment);

            if (result)
            {
                return(true);
            }

            return(false);
        }
Exemple #4
0
 public IResult Update(Comment comment)
 {
     try
     {
         _commentDal.Update(comment);
         return(new SuccessResult(Messages.SuccessUpdated));
     }
     catch (Exception)
     {
         return(new ErrorResult(Messages.ErrorUpdated));
     }
 }
 public EntityResult Update(Comment model)
 {
     try
     {
         if (_commentDal.Update(model))
         {
             return(new EntityResult("Başarılı", ResultState.Success));
         }
         return(new EntityResult("Hata Oluştu", ResultState.Warning));
     }
     catch (Exception ex)
     {
         return(new EntityResult("DataBase Hatası", ResultState.Error));
     }
 }
Exemple #6
0
        public IResult Update(Comment comment)
        {
            IResult result = BusinessRule.Run
                             (
                CheckIfCommentExist(comment.Id)
                             );

            if (result != null)
            {
                return(result);
            }

            _commentDal.Update(comment);

            return(new SuccessResult());
        }
        public DataResponse Update(Comment entity)
        {
            var comment = _commentDal.Update(entity);

            if (comment == null)
            {
                return new DataResponse
                       {
                           Mesaj      = "Yorum Duzenlenemedi",
                           Tamamlandi = false,
                       }
            }
            ;
            return(new DataResponse
            {
                Data = comment,
                Tamamlandi = true,
                Mesaj = comment.YorumBaslik + " Baslikli Yorum Duzenlendi",
            });
        }
Exemple #8
0
        public bool UpdateComment(Expression <Func <Comment, bool> > expression)
        {
            try
            {
                var comment = _commentDal.Get(expression);
                if (!comment.IsActive)
                {
                    comment.IsActive = true;
                }
                else
                {
                    comment.IsActive = false;
                }

                _commentDal.Update(comment);
                _commentDal.Save();

                return(true);
            }
            catch (Exception exp)
            {
                return(false);
            }
        }
Exemple #9
0
 public IResult Update(Comment entity)
 {
     _commentDal.Update(entity);
     return(new SuccessResult(Messages.CommentUpdated));
 }
 public Comment Update(Comment comment)
 {
     _commentDal.Update(comment);
     return(GetById(comment.CommentId));
 }
 public IResult Update(Comment comment)
 {
     _commentDal.Update(comment);
     return(new SuccessDataResult <Comment>(Messages.Updated));
 }
Exemple #12
0
 public bool Update(Comment comment)
 {
     return(_commentDal.Update(comment));
 }
 public void Update(Comment comment)
 {
     ValidationTool.Validate(new CommentValidator(), comment);
     commentDal.Update(comment);
 }
 public Comment Update(Comment entity)
 {
     return(_CommentDal.Update(entity));
 }
Exemple #15
0
 public void Update(Comments entity)
 {
     _commentDal.Update(entity);
 }
Exemple #16
0
 public IResult Update(Comment comment)
 {
     _commentDal.Update(comment);
     return(new SuccessResult());
 }
 public void Update(Comment entity)
 {
     commentDal.Update(entity);
 }
 public void Update(Comment commend)
 {
     _commentDal.Update(commend);
 }
Exemple #19
0
 public IResult Update(Comment comment)
 {
     _commentDal.Update(comment);
     return(new SuccessResult(Messages.CommnetUpdated));
 }