Commit c37eace7 by xuxu

修改尼斯大类匹配失败及名称重复的问题

parent d01beb1c
......@@ -37,10 +37,14 @@ class NameEs:
"wildcard": {
"tm_name": include_word_type
}
},
{
"terms": {
"ncl_one": ncl_one_list
}
}
],
"should":[]
],
}
},
"sort": {
......@@ -52,10 +56,5 @@ class NameEs:
}
}
for ncl_one in ncl_one_list:
query['query']['bool']['should'].append({
"match_phrase": {
"ncl_one":ncl_one
}
})
return self.esBase.select(index=index,body=query)
......@@ -52,7 +52,7 @@ def name_treasure(result_json):
else:
name_result_list.append(item['tm_name'])
return name_result_list
result_list = list(set(name_result_list))
return result_list
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