public async Task<IActionResult> Providers(int id) { var repo = new ServiceProviderRepository(); var services = await repo.GetAllAsync(it => it.ServiceId == id); var model = new ServiceProvidersViewModel { ServiceProviers = services, ServiceId = id, }; repo.Dispose(); return View(model); }
public async Task <IActionResult> Providers(int id) { var repo = new ServiceProviderRepository(); var services = await repo.GetAllAsync(it => it.ServiceId == id); var model = new ServiceProvidersViewModel { ServiceProviers = services, ServiceId = id, }; repo.Dispose(); return(View(model)); }