Beispiel #1
0
 public IActionResult Delete(string id)
 {
     try
     {
         _questionnaireService.Delete(id);
         return(Ok());
     }
     catch (AppException ex)
     {
         _response         = new ServiceResponse();
         _response.message = ex.Message;
         return(StatusCode(StatusCodes.Status400BadRequest, _response));
     }
     catch (Exception ex)
     {
         _response         = new ServiceResponse();
         _response.message = "Something went wrong, " + ex.Message.ToString();
         return(StatusCode(StatusCodes.Status500InternalServerError, _response));
     }
 }