mirror of https://github.com/pelias/api.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
43 lines
808 B
43 lines
808 B
9 years ago
|
|
||
|
module.exports = {
|
||
|
'query': {
|
||
|
'filtered': {
|
||
|
'query': {
|
||
|
'bool': {}
|
||
|
},
|
||
|
'filter': {
|
||
|
'bool': {
|
||
|
'must': [
|
||
|
{
|
||
|
'geo_distance': {
|
||
|
'distance': '500km',
|
||
|
'distance_type': 'plane',
|
||
|
'optimize_bbox': 'indexed',
|
||
|
'_cache': true,
|
||
|
'center_point': {
|
||
|
'lat': 29.49136,
|
||
|
'lon': -82.50622
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
]
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
},
|
||
|
'sort': [
|
||
|
'_score',
|
||
|
{
|
||
|
'_geo_distance': {
|
||
|
'center_point': {
|
||
|
'lat': 29.49136,
|
||
|
'lon': -82.50622
|
||
|
},
|
||
|
'order': 'asc',
|
||
|
'distance_type': 'plane'
|
||
|
}
|
||
|
}
|
||
|
],
|
||
|
'size': 1,
|
||
|
'track_scores': true
|
||
|
};
|