// POST: api/cliente public IHttpActionResult Post([FromBody]TipoEvento value) { try { ControlTipoEvento.devolverInstacia().grabar(value); return Ok(value); } catch (UsuarioException ex) { throw new HttpResponseException(Request.CreateResponse(HttpStatusCode.BadRequest, ex.errores)); } }
// DELETE: api/ApiCliente/5 public void Delete(int id) { ControlTipoEvento.devolverInstacia().eliminar(id); }
// PUT: api/cliente/5 public void Put(int id, [FromBody]TipoEvento value) { // var tipoEvento = ControlTipoEvento.devolverInstacia().devolver(id); ControlTipoEvento.devolverInstacia().grabar(value); }
// GET: api/cliente/5 public TipoEvento Get(int id) { return ControlTipoEvento.devolverInstacia().devolver(id); }
// GET: api/cliente public IEnumerable<TipoEvento> Get() { return ControlTipoEvento.devolverInstacia().devolverTodos(); }