Commit 365ee846 authored by lixiaofang's avatar lixiaofang

best_answer

parent a85e876d
...@@ -41,6 +41,7 @@ def get_suggest_tips(query, lat, lng, offset=0, size=50): ...@@ -41,6 +41,7 @@ def get_suggest_tips(query, lat, lng, offset=0, size=50):
} }
} }
logging.info("get qqqqqqqq:%s" % q)
have_read_tips_set = set() have_read_tips_set = set()
ret_list = list() ret_list = list()
result_dict = ESPerform.get_search_results(ESPerform.get_cli(), sub_index_name="suggest", query_body=q, result_dict = ESPerform.get_search_results(ESPerform.get_cli(), sub_index_name="suggest", query_body=q,
......
...@@ -3,6 +3,8 @@ ...@@ -3,6 +3,8 @@
"properties": { "properties": {
"id":{"type":"text"}, "id":{"type":"text"},
"suggest":{ "suggest":{
"analyzer":"keyword",
"search_analyzer":"keyword",
"type":"completion", "type":"completion",
"contexts":[ "contexts":[
{ {
......
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