public ActionResult Delete([FromBody] GeofenceDTO geofence) { try { var resp = geofenceDAO.Delete(geofence); return(Ok(resp <= 0 ? "Ningun registro Afectado" : "Eliminacion exitosa")); } catch (Exception e) { return(BadRequest($"Error al eliminar: {e.Message}")); } }
public ActionResult Post([FromBody] GeofenceDTO geofence) { try { var resp = geofenceDAO.Insert(geofence); return(Ok(resp <= 0 ? "Ningun registro Afectado" : "Insercion exitosa")); } catch (Exception e) { return(BadRequest($"Error al insertar: {e.Message}")); } }