// GET: Books public ActionResult Index() { using (BooksDAL svBooks = new BooksDAL()) { var results = svBooks.GetData(); return(View(results)); } }
// GET: Books public ActionResult Index() { using (BooksDAL svBooks = new BooksDAL()) { if (TempData["Pesan"] != null) { ViewBag.Pesan = TempData["Pesan"].ToString(); } var results = svBooks.GetData().ToList(); return(View(results)); } }