@(issues: List[gitbucket.core.service.RepositorySearchService.IssueSearchResult], pullRequest: Boolean, query: String, page: Int, repository: gitbucket.core.service.RepositoryService.RepositoryInfo)(implicit context: gitbucket.core.controller.Context) @import gitbucket.core.view.helpers @import gitbucket.core.service.RepositorySearchService @gitbucket.core.html.main("Search Results", Some(repository)){ @gitbucket.core.search.html.menu(if(pullRequest) "pulls" else "issues", query, repository){ @if(query.nonEmpty) { @if(issues.isEmpty) {

#### We couldn't find any @{if(pullRequest) "pull requests" else "issues"} matching '@query'

} else {

#### We've found @issues.size @helpers.plural(issues.size, if(pullRequest) "pull request" else "issue")

} } @issues.drop((page - 1) * RepositorySearchService.IssueLimit).take(RepositorySearchService.IssueLimit).map { issue =>
@if(issue.isClosed){ Closed } #@issue.issueId

#### @issue.title

@if(issue.highlightText.nonEmpty){

    @Html(issue.highlightText)

}
Opened by @issue.openedUserName @gitbucket.core.helper.html.datetimeago(issue.registeredDate) @if(issue.commentCount > 0){ @issue.commentCount @helpers.plural(issue.commentCount, "comment") }
} @gitbucket.core.helper.html.paginator(page, issues.size, RepositorySearchService.IssueLimit, 10, s"${helpers.url(repository)}/search?q=${helpers.urlEncode(query)}&type=${if(pullRequest) "pulls" else "issues"}") } }