vuestorefront / storefront-query-builder

ElasticSearch Query builder from the abstract "SearchQuery" object used by storefront-api, vue-storefront-api and vue-storefront projects
MIT License
7 stars 21 forks source link

Does query builder supports search attribute by text? #22

Closed mushketer888 closed 3 years ago

mushketer888 commented 3 years ago

Hello! Does query builder supports search attribute by text?

In vue storefront im using for example ProductsQuery = ProductsQuery.applyFilter({ key: 'name', value: 'Test' }) And it doesn't return any item Maybe I must add it to vsf-api schema (type=keyword)? rebuild db?

It generates { "query": { "bool": { "filter": { "terms": { "name": [ "Test" ] } } } } }

I checked in elasticvue manually - this request really return 0 items. What to do?

mushketer888 commented 3 years ago

I changed type to keyword