Skip to content

Commit 090d89e

Browse files
authored
Fixing wrong paging when filtering on the issue dashboard (#19801)
Fixes #19791 by adding an check if filtering after any repo; if yes, simply set the total count for the pageing to the sum of the issue count for each selected repo by utilize `issueCountByRepo`. Fix #19791
1 parent 744e452 commit 090d89e

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

routers/web/user/home.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -610,6 +610,12 @@ func buildIssueOverview(ctx *context.Context, unitType unit.Type) {
610610
shownIssues = int(issueStats.ClosedCount)
611611
ctx.Data["TotalIssueCount"] = shownIssues
612612
}
613+
if len(repoIDs) != 0 {
614+
shownIssues = 0
615+
for _, repoID := range repoIDs {
616+
shownIssues += int(issueCountByRepo[repoID])
617+
}
618+
}
613619

614620
ctx.Data["IsShowClosed"] = isShowClosed
615621

0 commit comments

Comments
 (0)