public IActionResult Edit(int id) { var producerToEdit = _producerService.Get(id); ProducerEditViewModel producerEditViewModel = new ProducerEditViewModel() { Id = producerToEdit.Id, Name = producerToEdit.Name, Address = producerToEdit.Address, }; return(View(producerEditViewModel)); }
public async Task <IActionResult> GetListing() { var listing = await service.Get <ProducerListingModel>(); return(Ok(listing)); }