@(commits: Seq[Seq[gitbucket.core.util.JGitUtil.CommitInfo]], diffs: Seq[gitbucket.core.util.JGitUtil.DiffInfo], members: List[(String, String)], comments: List[gitbucket.core.model.Comment], originId: String, forkedId: String, sourceId: String, commitId: String, repository: gitbucket.core.service.RepositoryService.RepositoryInfo, originRepository: gitbucket.core.service.RepositoryService.RepositoryInfo, forkedRepository: gitbucket.core.service.RepositoryService.RepositoryInfo, hasOriginWritePermission: Boolean, collaborators: List[String], milestones: List[gitbucket.core.model.Milestone], labels: List[gitbucket.core.model.Label])(implicit context: gitbucket.core.controller.Context) @import context._ @import gitbucket.core.view.helpers._ @html.main(s"Pull Requests - ${repository.owner}/${repository.name}", Some(repository)){ @html.menu("pulls", repository){
@helper.html.dropdown(originRepository.owner + "/" + originRepository.name, "base fork") { @members.map { case (owner, name) =>
- @helper.html.checkicon(owner == originRepository.owner) @owner/@name
} } @helper.html.dropdown(originId, "base") { @originRepository.branchList.map { branch =>
- @helper.html.checkicon(branch == originId) @branch
} } ... @helper.html.dropdown(forkedRepository.owner + "/" + forkedRepository.name, "head fork") { @members.map { case (owner, name) =>
- @helper.html.checkicon(owner == forkedRepository.owner) @owner/@name
} } @helper.html.dropdown(forkedId, "compare") { @forkedRepository.branchList.map { branch =>
- @helper.html.checkicon(branch == forkedId) @branch
} }
Checking...
@if(commits.nonEmpty && loginAccount.isDefined){
Create pull request Discuss and review the changes in this comparison with others.
@avatar(loginAccount.get.userName, 48)
@helper.html.preview( repository = repository, content = "", enableWikiLink = false, enableRefsLink = true, enableLineBreaks = true, enableTaskList = true, hasWritePermission = true, style = "width: 680px; height: 200px;" )
@issues.html.issueinfo(None, Nil, Nil, collaborators, milestones.map((_, 0, 0)), labels, hasOriginWritePermission, repository)
} @if(commits.isEmpty){

#### There isn't anything to compare.

@originRepository.owner:@originId and @forkedRepository.owner:@forkedId are identical.
@*

#### There isn't anything to compare. @originRepository.owner:@originId and @forkedRepository.owner:@forkedId are identical.

*@ } else {

@defining(commits.flatten){ commits => @commits.size @plural(commits.size, "commit") } | @diffs.size @plural(diffs.size, "file") changed | @defining(comments.collect { case c: gitbucket.core.model.CommitComment => c }){ comments => @comments.size commit @plural(comments.size, "comment") } | @defining(commits.flatMap(_.map(_.authorEmailAddress)).distinct){ contributors => @contributors.size @plural(contributors.size, "contributor") }

@commits.map { day =>
Commits on @date(day.head.commitTime)

@day.map { commit =>
@avatar(commit, 20) @user(commit.authorName, commit.authorEmailAddress, "username strong") | @commit.shortMessage @* @if(comments.isDefined){ @comments.get.flatMap @{ case comment: CommitComment => Some(comment) case other => None }.count(t => t.commitId == commit.id && !t.pullRequest) } *@ | @commit.id.substring(0, 7)
}

}
@helper.html.diff(diffs, repository, Some(commitId), Some(sourceId), true, None, false, false)

Showing you all comments on commits in this comparison.

@issues.html.commentlist(None, comments, false, repository, None) } } }