public async Task <ActionResult <ModelDto> > Post([FromBody] ModelStatusDto newModelStatus) { try { var result = await _modelStatusService.AddModelStatusAsync(newModelStatus); return(Ok(result)); } catch (Exception) { return(BadRequest("Error adding model status")); } }
public async Task <ActionResult <ModelDto> > Put([FromBody] ModelStatusDto modelStatus) { try { var result = await _modelStatusService.UpdateModelStatusAsync(modelStatus); return(Ok(result)); } catch (ArgumentNullException) { return(BadRequest("Error with input model status")); } catch (Exception) { return(BadRequest("Error updating model status")); } }
public Task <ModelStatusDto> UpdateModelStatusAsync(ModelStatusDto model) { throw new NotImplementedException(); }