public async Task <IActionResult> Create()
 {
     ViewBag.Fabricantes = (await fabricanteRepository.ListaFabricantesAsync())
                           .Select(c => new SelectListItem()
     {
         Text = c.Nome, Value = c.Id.ToString()
     })
                           .ToList();
     return(View());
 }
Beispiel #2
0
 public async Task <IActionResult> Index()
 {
     return(View(await fabricanteRepository.ListaFabricantesAsync()));
 }