Skip to content

Instantly share code, notes, and snippets.

@drkane
Created February 18, 2020 13:19
Show Gist options
  • Save drkane/c9a99e1bd87a92cc2bffce375a385031 to your computer and use it in GitHub Desktop.
Save drkane/c9a99e1bd87a92cc2bffce375a385031 to your computer and use it in GitHub Desktop.
GrantNav search json query input change
{
"extra_context": {
"amountAwardedFixed_facet_size": 3,
"awardYear_facet_size": 3
},
"sort": {
"_score": {
"order": "desc"
}
},
"aggs": {
"recipientOrganization": {
"terms": {
"field": "recipientOrganization.id_and_name",
"size": 3
}
},
"fundingOrganization": {
"terms": {
"field": "fundingOrganization.id_and_name",
"size": 3
}
},
"currency": {
"terms": {
"field": "currency",
"size": 3
}
},
"recipientRegionName": {
"terms": {
"field": "recipientRegionName",
"size": 3
}
},
"recipientDistrictName": {
"terms": {
"field": "recipientDistrictName",
"size": 3
}
}
},
"query": {
"bool": {
"filter": [
{
"bool": {
"should": []
}
},
{
"bool": {
"should": []
}
},
{
"bool": {
"should": [],
"must": {}
}
},
{
"bool": {
"should": {
"range": {
"amountAwarded": {}
}
},
"must": {}
}
},
{
"bool": {
"should": []
}
},
{
"bool": {
"should": []
}
},
{
"bool": {
"should": []
}
},
{
"bool": {
"should": []
}
}
],
"must": {
"query_string": {
"query": "tech",
"default_field": "*"
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment