summaryrefslogtreecommitdiffstats
path: root/routers/web/user/home.go
diff options
context:
space:
mode:
authorBrecht Van Lommel <brecht@blender.org>2023-02-25 03:55:50 +0100
committerGitHub <noreply@github.com>2023-02-24 21:55:50 -0500
commit10cdcb9ea8077098921d72720f9f36fcfd950452 (patch)
treee966411cf1bbc62bf7059deaa9238c14c0a9a04d /routers/web/user/home.go
parent843f81113ebe71fd725210c5a382268333865cc7 (diff)
downloadgitea-10cdcb9ea8077098921d72720f9f36fcfd950452.tar.gz
gitea-10cdcb9ea8077098921d72720f9f36fcfd950452.zip
Add "Reviewed by you" filter for pull requests (#22927)
This includes pull requests that you approved, requested changes or commented on. Currently such pull requests are not visible in any of the filters on /pulls, while they may need further action like merging, or prodding the author or reviewers. Especially when working with a large team on a repository it's helpful to get a full overview of pull requests that may need your attention, without having to sift through the complete list.
Diffstat (limited to 'routers/web/user/home.go')
-rw-r--r--routers/web/user/home.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/routers/web/user/home.go b/routers/web/user/home.go
index 2593ab148c..a0a5dc3c4b 100644
--- a/routers/web/user/home.go
+++ b/routers/web/user/home.go
@@ -385,6 +385,8 @@ func buildIssueOverview(ctx *context.Context, unitType unit.Type) {
filterMode = issues_model.FilterModeMention
case "review_requested":
filterMode = issues_model.FilterModeReviewRequested
+ case "reviewed_by":
+ filterMode = issues_model.FilterModeReviewed
case "your_repositories":
fallthrough
default:
@@ -453,6 +455,8 @@ func buildIssueOverview(ctx *context.Context, unitType unit.Type) {
opts.MentionedID = ctx.Doer.ID
case issues_model.FilterModeReviewRequested:
opts.ReviewRequestedID = ctx.Doer.ID
+ case issues_model.FilterModeReviewed:
+ opts.ReviewedID = ctx.Doer.ID
}
// keyword holds the search term entered into the search field.