示例#1
0
        public ActionResult GetBook(int id)
        {
            var allbooks = new Catalog();
            var book = allbooks.Books.FirstOrDefault(x => x.Id == id);

            return View(book);
        }
示例#2
0
 public ActionResult Books()
 {
     var allBook = new Catalog();
     return Json(allBook, JsonRequestBehavior.AllowGet);
 }