浏览代码

Merge branch 'feature/pool_es_search' into debug

xiexiaoyuan 2 年之前
父节点
当前提交
f211feb14c
共有 1 个文件被更改,包括 4 次插入4 次删除
  1. 4 4
      services/elastic/report.go

+ 4 - 4
services/elastic/report.go

@@ -132,12 +132,12 @@ func SearchReport(keyWord string, classifyIdFirsts []int, classifyIdSeconds []in
 
 	source["sort"] = []map[string]interface{}{
 		map[string]interface{}{
-			"_score":map[string]interface{}{
+			"PublishTime.keyword":map[string]interface{}{
 				"order":"desc",
 			},
 		},
 		map[string]interface{}{
-			"PublishTime.keyword":map[string]interface{}{
+			"_score":map[string]interface{}{
 				"order":"desc",
 			},
 		},
@@ -271,12 +271,12 @@ func ReportListSearch(keyWord string, classifyIdFirst int, classifyIdSeconds []i
 
 	source["sort"] = []map[string]interface{}{
 		map[string]interface{}{
-			"_score":map[string]interface{}{
+			"PublishTime.keyword":map[string]interface{}{
 				"order":"desc",
 			},
 		},
 		map[string]interface{}{
-			"PublishTime.keyword":map[string]interface{}{
+			"_score":map[string]interface{}{
 				"order":"desc",
 			},
 		},