From a6d86f0544e44bcfb9177e46250fdde1b094cf3b Mon Sep 17 00:00:00 2001 From: zouap Date: Fri, 11 Mar 2022 09:41:27 +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, 3 insertions(+), 1 deletion(-) diff --git a/routers/search.go b/routers/search.go index 7fbe42ff3..6c8998a40 100644 --- a/routers/search.go +++ b/routers/search.go @@ -772,7 +772,7 @@ func searchIssue(ctx *context.Context, TableName string, Key string, Page int, P resultObj.PrivateTotal = count issuesSize := len(issues) if issuesSize > 0 { - log.Info("Query private repo issue number is:" + fmt.Sprint(issuesSize)) + log.Info("Query private repo issue number is:" + fmt.Sprint(issuesSize) + " count=" + fmt.Sprint(count)) makePrivateIssueOrPr(issues, resultObj, Key) } else { log.Info("not found private repo issue,keyword=" + Key) @@ -814,7 +814,9 @@ func searchIssue(ctx *context.Context, TableName string, Key string, Page int, P searchJson, _ := json.Marshal(res) log.Info("searchJson=" + string(searchJson)) esresult := makeIssueResult(res, Key, OnlyReturnNum) + resultObj.Total = resultObj.PrivateTotal + esresult.Total + log.Info("query issue es count=" + fmt.Sprint(esresult.Total) + " total=" + fmt.Sprint(resultObj.Total)) resultObj.Result = append(resultObj.Result, esresult.Result...) ctx.JSON(200, resultObj) } else {