src/ElasticSearch/DSL/Query.php
public function term($term, $field=false) {
        $this->term = ($field)
            ? array($field => $term)
            : $term;
        return $this;
    }
public function term($term, $field=false) {
        $this->term = ($field)
            ? array($field => $term)
            : $term;
        return $this;
    }
Add a term to this query

@return \ElasticSearch\DSL\Query
@param string $term
@param bool|string $field