(refs #488)Add link to clear search condition

This commit is contained in:
Naoki Takezoe
2014-09-22 10:18:26 +09:00
parent 90487eb7b7
commit cb512cd98d
2 changed files with 10 additions and 0 deletions

View File

@@ -341,6 +341,13 @@ object IssuesService {
sort: String = "created",
direction: String = "desc"){
def isEmpty: Boolean = {
labels.isEmpty && milestoneId.isEmpty && author.isEmpty && assigned.isEmpty &&
state == "open" && sort == "created" && direction == "desc"
}
def nonEmpty: Boolean = !isEmpty
def toURL: String =
"?" + List(
if(labels.isEmpty) None else Some("labels=" + urlEncode(labels.mkString(","))),