// GET: Film/Edit/{id} public ActionResult Edit(int id) { var service = new FilmService(); var detail = service.GetFilmById(id); var model = new FilmEdit { FilmId = detail.FilmId, MediaType = detail.MediaType, Title = detail.Title, Director = detail.Director, Writer = detail.Writer, Stars = detail.Stars, Cinematographer = detail.Cinematographer, Editor = detail.Editor, Synopsis = detail.Synopsis, Genre1 = detail.Genre1, Genre2 = detail.Genre2, //Released = detail.Released, Year = detail.Year, Runtime = detail.Runtime, Rating = detail.Rating, }; ViewBag.Title = service.GetFilmTitle(id); return(View(model)); }
public ActionResult Delete(int id) { var service = new FilmService(); var model = service.GetFilmById(id); return(View(model)); }
// GET: Film/Detail/{id} public ActionResult Details(int id) { var service = new FilmService(); var model = service.GetFilmById(id); ViewBag.FilmTitle = service.GetFilmTitle(id); return(View(model)); }
public FilmFull GetById(int Id) { return(_service.GetFilmById(Id)); }
//根据ID查询电影信息 public static Films GetFilmById(int id) { return(FilmService.GetFilmById(id)); }