diff --git a/src/main/scala/app/IssuesController.scala b/src/main/scala/app/IssuesController.scala index 88f5937..d2e4082 100644 --- a/src/main/scala/app/IssuesController.scala +++ b/src/main/scala/app/IssuesController.scala @@ -256,7 +256,7 @@ } /** - * @see [[https://github.com/takezoe/gitbucket/wiki/CommentAction]] + * @see [[https://github.com/takezoe/gitbucket/wiki/CommentAction]] */ private def handleComment(issueId: Int, content: Option[String], repository: RepositoryService.RepositoryInfo) (getAction: model.Issue => Option[String] = @@ -317,7 +317,7 @@ searchIssue(owner, repoName, condition, filter, userName, (page - 1) * IssueLimit, IssueLimit), page, (getCollaborators(owner, repoName) :+ owner).sorted, - getMilestones(owner, repoName).filter(_.closedDate.isEmpty), + getMilestones(owner, repoName), getLabels(owner, repoName), countIssue(owner, repoName, condition.copy(state = "open"), filter, userName), countIssue(owner, repoName, condition.copy(state = "closed"), filter, userName), diff --git a/src/main/scala/view/helpers.scala b/src/main/scala/view/helpers.scala index 650627c..2d9c0e0 100644 --- a/src/main/scala/view/helpers.scala +++ b/src/main/scala/view/helpers.scala @@ -82,6 +82,7 @@ def assets(implicit context: app.Context): String = s"${context.path}/assets" + def isPast(date: Date): Boolean = System.currentTimeMillis > date.getTime /** * Implicit conversion to add mkHtml() to Seq[Html]. diff --git a/src/main/twirl/issues/list.scala.html b/src/main/twirl/issues/list.scala.html index 425e1a8..a80d38f 100644 --- a/src/main/twirl/issues/list.scala.html +++ b/src/main/twirl/issues/list.scala.html @@ -65,7 +65,7 @@ @helper.html.checkicon(condition.milestoneId == Some(None)) Issues with no milestone - @milestones.map { milestone => + @milestones.filter(_.closedDate.isEmpty).map { milestone =>
Due in @date(dueDate)
+ } else {
+ Due in @date(dueDate)
+ }
+ }
}
-
Due in @date(dueDate)
+ } else {
+ Due in @date(dueDate)
+ }
+ }.getOrElse {
No due date
}
}
diff --git a/src/main/webapp/assets/common/css/gitbucket.css b/src/main/webapp/assets/common/css/gitbucket.css
index 2e7d1a8..6c9c387 100644
--- a/src/main/webapp/assets/common/css/gitbucket.css
+++ b/src/main/webapp/assets/common/css/gitbucket.css
@@ -441,10 +441,16 @@
margin-bottom: 10px;
}
+span.milestone-alert {
+ font-weight: bold;
+ color: #bd2c00;
+}
+
a.milestone-title {
font-size: 120%;
font-weight: bold;
}
+
div.milestone-description {
border-top: 1px solid #eee;
color: #666;
diff --git a/src/main/webapp/assets/common/images/alert.png b/src/main/webapp/assets/common/images/alert.png
new file mode 100644
index 0000000..10545e7
--- /dev/null
+++ b/src/main/webapp/assets/common/images/alert.png
Binary files differ