// GET: Suppliers/Details/5 public async Task <IActionResult> Details(int?id) { if (id == null) { return(NotFound()); } var supplier = await _invoicesRepository.GetSupplierAsync(id.Value); if (supplier == null) { return(NotFound()); } return(View(supplier)); }