I'm targeting my push notifications to users within a certain distance of an event. I've got this working with a hard coded distance value as follows:

var pushQuery = new Parse.Query(Parse.Installation);
pushQuery.withinMiles("location", geoPoint, 10.0);

The issue is, I want the user to be able to specify their "range" for receiving these notifications. I have this preference saved in the user Installation object, but can't figure out how to go about pushing to users where the event is within their "distance preference" of miles. Is this possible?

Related posts

Recent Viewed