]> source.dussan.org Git - gitblit.git/commitdiff
Link to open tickets view for open milestones from ticket page
authorJames Moger <james.moger@gitblit.com>
Mon, 9 Jun 2014 15:33:42 +0000 (11:33 -0400)
committerJames Moger <james.moger@gitblit.com>
Mon, 9 Jun 2014 15:33:42 +0000 (11:33 -0400)
src/main/java/com/gitblit/wicket/pages/TicketPage.java

index f7e4ada59ce29e44ffe5ce4d649789c4bb69b004..f5f63d23027a7af7dcd32d7e1cd38df1686272d3 100644 (file)
@@ -250,8 +250,12 @@ public class TicketPage extends RepositoryPage {
                } else {\r
                        // link to milestone query\r
                        TicketMilestone milestone = app().tickets().getMilestone(repository, ticket.milestone);\r
-                       PageParameters milestoneParameters = new PageParameters();\r
-                       milestoneParameters.put("r", repositoryName);\r
+                       PageParameters milestoneParameters;\r
+                       if (milestone.isOpen()) {\r
+                               milestoneParameters = WicketUtils.newOpenTicketsParameter(repositoryName);\r
+                       } else {\r
+                               milestoneParameters = WicketUtils.newRepositoryParameter(repositoryName);\r
+                       }\r
                        milestoneParameters.put(Lucene.milestone.name(), ticket.milestone);\r
                        int progress = 0;\r
                        int open = 0;\r