public JsonResult DeleteBook(string bookId) { try { Models.BookService BookService = new Models.BookService(); BookService.DeleteBookById(bookId); return(this.Json(true)); } catch (Exception ex) { return(this.Json(false)); } }
public JsonResult DeleteBookById(string id) { bookService.DeleteBookById(id); return(this.Json(true)); }