es query string 新增 Fields 方法以支持对多个字段进行查询

master
Wang Yunxiao 1 week ago
parent b28661bf9b
commit 17458fd610
  1. 6
      pkg/es/search_queries_query_string.go

@ -66,6 +66,12 @@ func (q *QueryStringQuery) Field(field string) *QueryStringQuery {
return q
}
// Field adds a field to run the query string against.
func (q *QueryStringQuery) Fields(fields ...string) *QueryStringQuery {
q.fields = append(q.fields, fields...)
return q
}
// Type sets how multiple fields should be combined to build textual part queries,
// e.g. "best_fields".
func (q *QueryStringQuery) Type(typ string) *QueryStringQuery {

Loading…
Cancel
Save