Show commit status icon in commits table (#1688)
* Show commit status icon in commits table * Add comments * Fix icons * Few more places where commit table is displayed * Change integration test to use goquery for parsing html * Add integration tests for commit table and status icons * Fix status to return lates status correctly on all databases * Rewrote lates commit status selects
This commit is contained in:
@ -69,6 +69,7 @@ func Commits(ctx *context.Context) {
|
||||
commits = renderIssueLinks(commits, ctx.Repo.RepoLink)
|
||||
commits = models.ValidateCommitsWithEmails(commits)
|
||||
commits = models.ParseCommitsWithSignature(commits)
|
||||
commits = models.ParseCommitsWithStatus(commits, ctx.Repo.Repository)
|
||||
ctx.Data["Commits"] = commits
|
||||
|
||||
ctx.Data["Username"] = ctx.Repo.Owner.Name
|
||||
@ -123,6 +124,7 @@ func SearchCommits(ctx *context.Context) {
|
||||
commits = renderIssueLinks(commits, ctx.Repo.RepoLink)
|
||||
commits = models.ValidateCommitsWithEmails(commits)
|
||||
commits = models.ParseCommitsWithSignature(commits)
|
||||
commits = models.ParseCommitsWithStatus(commits, ctx.Repo.Repository)
|
||||
ctx.Data["Commits"] = commits
|
||||
|
||||
ctx.Data["Keyword"] = keyword
|
||||
@ -170,6 +172,7 @@ func FileHistory(ctx *context.Context) {
|
||||
commits = renderIssueLinks(commits, ctx.Repo.RepoLink)
|
||||
commits = models.ValidateCommitsWithEmails(commits)
|
||||
commits = models.ParseCommitsWithSignature(commits)
|
||||
commits = models.ParseCommitsWithStatus(commits, ctx.Repo.Repository)
|
||||
ctx.Data["Commits"] = commits
|
||||
|
||||
ctx.Data["Username"] = ctx.Repo.Owner.Name
|
||||
@ -281,6 +284,7 @@ func CompareDiff(ctx *context.Context) {
|
||||
}
|
||||
commits = models.ValidateCommitsWithEmails(commits)
|
||||
commits = models.ParseCommitsWithSignature(commits)
|
||||
commits = models.ParseCommitsWithStatus(commits, ctx.Repo.Repository)
|
||||
|
||||
ctx.Data["CommitRepoLink"] = ctx.Repo.RepoLink
|
||||
ctx.Data["Commits"] = commits
|
||||
|
Reference in New Issue
Block a user