add filters and sorting to Elasticsearch query