solr-node-client
solr-node-client copied to clipboard
Added an ability to search using geo-spatial queries and filter documents by expression
I've added two methods to Query module for geo-spatial search:
- spatial
- expressionFilter
Basic usage:
var solr = require('./../lib/solr');
var client = solr.createClient();
var query = client.createQuery()
.spatial({
pt: '37.7749295,-122.4194155',
sfield: 'location_srpt',
d: 10
}).expressionFilter('{!geofilt}');
It will find all documents which are located in 10 km radius of the chosen point.
Hi there,
Can you add the tests for this feature? Then I can merge the pull request.
Would love to see this merged once tests are written.