public async Task <IActionResult> Details(int?id) { if (id == null) { return(NotFound()); } var idiomaViewModel = await _idiomaHttpService.GetByIdAsync(id.Value); if (idiomaViewModel == null) { return(NotFound()); } var pais = await _paisHttpService.GetByIdAsync(idiomaViewModel.PaisId); if (pais.Id == idiomaViewModel.PaisId) { idiomaViewModel.Pais = pais; } return(View(idiomaViewModel)); }
// GET: Pais/Details/5 public async Task <IActionResult> Details(int?id) { if (id == null) { return(NotFound()); } var paisViewModel = await _paisHttpService.GetByIdAsync(id.Value); if (paisViewModel == null) { return(NotFound()); } return(View(paisViewModel)); }