From e0331746c1aee48a18ae2954770ca481d49eaf36 Mon Sep 17 00:00:00 2001 From: James Moger Date: Mon, 9 Jun 2014 11:33:42 -0400 Subject: Link to open tickets view for open milestones from ticket page --- src/main/java/com/gitblit/wicket/pages/TicketPage.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/gitblit/wicket/pages/TicketPage.java b/src/main/java/com/gitblit/wicket/pages/TicketPage.java index f7e4ada5..f5f63d23 100644 --- a/src/main/java/com/gitblit/wicket/pages/TicketPage.java +++ b/src/main/java/com/gitblit/wicket/pages/TicketPage.java @@ -250,8 +250,12 @@ public class TicketPage extends RepositoryPage { } else { // link to milestone query TicketMilestone milestone = app().tickets().getMilestone(repository, ticket.milestone); - PageParameters milestoneParameters = new PageParameters(); - milestoneParameters.put("r", repositoryName); + PageParameters milestoneParameters; + if (milestone.isOpen()) { + milestoneParameters = WicketUtils.newOpenTicketsParameter(repositoryName); + } else { + milestoneParameters = WicketUtils.newRepositoryParameter(repositoryName); + } milestoneParameters.put(Lucene.milestone.name(), ticket.milestone); int progress = 0; int open = 0; -- cgit v1.2.3