From 35fffdb39369391291d1678845fdddd25e166fcc Mon Sep 17 00:00:00 2001 From: zouap Date: Fri, 7 Jan 2022 09:59:09 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: zouap --- routers/search.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/routers/search.go b/routers/search.go index f43836cc9..658cd2963 100644 --- a/routers/search.go +++ b/routers/search.go @@ -427,7 +427,7 @@ func searchIssue(ctx *context.Context, TableName string, Key string, Page int, P commentQuery := elastic.NewMatchQuery("comment", Key).Boost(1).QueryName("f_third") boolQ.Should(nameQuery, contentQuery, commentQuery) } - isIssueQuery := elastic.NewTermQuery("is_pull.keyword", false) + isIssueQuery := elastic.NewTermQuery("is_pull", "f") boolQ.Must(isIssueQuery) res, err := client.Search(TableName).Query(boolQ).Sort(SortBy, ascending).From((Page - 1) * PageSize).Size(PageSize).Do(ctx.Req.Context()) if err == nil { @@ -510,7 +510,7 @@ func searchPR(ctx *context.Context, TableName string, Key string, Page int, Page commentQuery := elastic.NewMatchQuery("comment", Key).Boost(1).QueryName("f_third") boolQ.Should(nameQuery, contentQuery, commentQuery) } - isIssueQuery := elastic.NewTermQuery("is_pull", true) + isIssueQuery := elastic.NewTermQuery("is_pull", "t") boolQ.Must(isIssueQuery) res, err := client.Search(TableName).Query(boolQ).Sort(SortBy, ascending).From((Page - 1) * PageSize).Size(PageSize).Do(ctx.Req.Context()) if err == nil {