summaryrefslogtreecommitdiffstats
path: root/src/main/java/com/gitblit/wicket/pages
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2014-03-05 11:26:26 -0500
committerJames Moger <james.moger@gitblit.com>2014-03-05 11:42:34 -0500
commit0353c1fc521826c57a318affec4fbec7aa3b71e9 (patch)
treeddfc5554d6a8eba22422d156e1c6a08ef642ac80 /src/main/java/com/gitblit/wicket/pages
parent7ae1fac1236d61c6b60d295bdc06caa654fa8098 (diff)
downloadgitblit-0353c1fc521826c57a318affec4fbec7aa3b71e9.tar.gz
gitblit-0353c1fc521826c57a318affec4fbec7aa3b71e9.zip
Allow unregistered milestone selection on edit ticket page
Diffstat (limited to 'src/main/java/com/gitblit/wicket/pages')
-rw-r--r--src/main/java/com/gitblit/wicket/pages/EditTicketPage.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/main/java/com/gitblit/wicket/pages/EditTicketPage.java b/src/main/java/com/gitblit/wicket/pages/EditTicketPage.java
index 32b202fb..ac7ff97e 100644
--- a/src/main/java/com/gitblit/wicket/pages/EditTicketPage.java
+++ b/src/main/java/com/gitblit/wicket/pages/EditTicketPage.java
@@ -284,6 +284,13 @@ public class EditTicketPage extends RepositoryPage {
break;
}
}
+ if (milestoneModel.getObject() == null && !StringUtils.isEmpty(ticket.milestone)) {
+ // ensure that this unrecognized milestone is listed
+ // so that we get the <nil> selection.
+ TicketMilestone tms = new TicketMilestone(ticket.milestone);
+ milestones.add(tms);
+ milestoneModel.setObject(tms);
+ }
if (!milestones.isEmpty()) {
milestones.add(new TicketMilestone(NIL));
}