public Video Create(Video video) { /*Video newVideo = new Video(); * newVideo.AllowComments = video.AllowComments; * newVideo.AllowRaiting = video.AllowRaiting; * newVideo.Blocked = false; * newVideo.CreationDate = DateTime.Now.*/ _context.Videos.Add(video); _context.SaveChanges(); return(video); }
public Comment Create(Comment comment) { _context.Comments.Add(comment); _context.SaveChanges(); return(comment); }
public LikeDislikeVideo Add(LikeDislikeVideo likeDislike) { _context.Add(likeDislike); _context.SaveChanges(); return(likeDislike); }
public LikeDislikeComment Add(LikeDislikeComment likeDislike) { _context.Add(likeDislike); _context.SaveChanges(); return(likeDislike); }
public User Add(User newUser) { _context.Users.Add(newUser); _context.SaveChanges(); return(newUser); }
public Follow Add(Follow follow) { _context.Follow.Add(follow); _context.SaveChanges(); return(follow); }