Esempio n. 1
0
        public ActionResult <BookModel> UpdateBook(BookModel changes)
        {
            var book = new Book()
            {
                Id    = changes.Id,
                Title = changes.Title
            };

            _context.Update(book);
            _context.SaveChanges();
            return(changes);
        }