public async Task <IActionResult> Add(CategoriaModel model) { try { return(Ok(await _service.Add(model))); } catch (Exception e) { return(BadRequest(e.Message)); } }
public ActionResult <CategoriaResponse> Post(CategoriaRequest request) { CategoriaResponse response = _service.Add(request); return(Ok(response)); }