public void Delete(Guid ID) { objComments = new ARTS_CommentRepository(); ARTS_Comment comment = objComments.GetSingle(x => x.CommentID.Equals(ID)); objComments.Delete(comment); }
public void Update(ARTrackingCommentModel entity) { objComments = new ARTS_CommentRepository(); ARTS_Comment comment = objComments.GetSingle(x=>x.CommentID.Equals(entity.CommentID)); comment.CommentType = entity.CommentType; comment.Comment = entity.Comment; comment.CommentDate = DateTime.Now; comment.ModifiedBy = entity.ModifiedBy; comment.ModifiedDate = DateTime.Now; objComments.Update(comment); }
public ARTrackingCommentModel getCommentByCommentID(Guid id) { objComments=new ARTS_CommentRepository(); Mapper.CreateMap<ARTS_Comment, ARTrackingCommentModel>(); var entity = objComments.GetSingle(x => x.CommentID.Equals(id)); ARTrackingCommentModel result = new ARTrackingCommentModel(); result = Mapper.Map(entity, result); return result; }