For example this document
{
_index: "documents",
_type: "_doc",
_id: "bjQbFXMBUTNnZQiIspyw",
_score: 1,
_source: {
text: "blablabla",
tags: [
"apple",
"iphone",
"iphonexr"
]
}
When i enter "iphon", i want to get "iphone", "iphonexr":
suggest: {
gotsuggest: {
prefix : "iphon",
completion : {
field : "tags"
}
}
}
A result, in field text there is only "iphone" tag. So, how i can get "iphone" and "iphonexr"?
{
text: "iphone",
_index: "documents",
_type: "_doc",
_id: "bjQbFXMBUTNnZQiIspyw",
_score: 1,
_source: {
text: "blablabla",
tags: [
"apple",
"iphone",
"iphonexr"
]
}