Update all ES queries to use Elasticsearch DSL (bug 1036168)

you should be able to do just 

    qs = qs.filter('term', **{k: v})
here and then return `qs`. No need for the reduce.