Unverified Commit 66e725f4 authored by kaziu687's avatar kaziu687 Committed by GitHub

fix: elasticsearch partial match (#1882)

Improved full text search in elastic provider
parent d0cd340d
......@@ -92,8 +92,26 @@ module.exports = {
index: this.config.indexName,
body: {
query: {
simple_query_string: {
query: q
bool: {
filter: [
{
bool: {
should: [
{
simple_query_string: {
query: q
}
},
{
query_string: {
query: "*" + q + "*"
}
}
],
minimum_should_match: 1
}
}
]
}
},
from: 0,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment