// GET: Livro/Create public async Task <IActionResult> Create() { var autores = await _autorHttpClient.GetAllAsync(); ViewData["AutorId"] = new SelectList( autores, nameof(AutorViewModel.Id), nameof(AutorViewModel.NomeCompletoId), null); return(View()); }
// GET: Autor public async Task <IActionResult> Index() { var autores = await _autorHttpClient.GetAllAsync(); return(View(autores)); }