public ActionResult Update(int?id) { var actorMovie = _actorMovieService.Get(id.GetValueOrDefault()); var model = Mapper.Map <ActorMovieViewModel>(actorMovie); model.MovieSelectList = GetRelatedEntitiesList(); return(View("CreateOrUpdate", model)); }
public async Task <IActionResult> OnGetAsync(int id) { tempActorMovie = await _actorMovieService.Get(id); if (tempActorMovie == null) { return(RedirectToPage("/NotFound")); } return(Page()); }
public async Task <IActionResult> OnGetAsync(int?id) { if (id == null) { return(NotFound()); } actorMovieDetail = await _actorMovieService.Get(id.Value); if (actorMovieDetail == null) { return(NotFound()); } return(Page()); }
public Task <ActorMovieOutputDto> Get(int id) { return(ActorMovieService.Get(id)); }