BigW Consortium Gitlab

Commit 8e4ec561 by Annabel Dunstone

Order by build status

parent fa576d38
......@@ -8,7 +8,19 @@
- builds = @build.pipeline.builds.latest.to_a
- if builds.size > 1
%ul.nav-links.no-top.no-bottom
- builds.each do |build|
- statuses = ["failed", "pending", "running", "canceled", "skipped", "success"]
- statuses.each do |build_status|
- builds.select{|build| build.status == build_status}.each do |build|
%li{class: ('active' if build == @build) }
= link_to namespace_project_build_path(@project.namespace, @project, build) do
= ci_icon_for_status(build.status)
%span
- if build.name
= build.name
- else
= build.id
- builds.select{|build| build.status == "success"}.each do |build|
%li{class: ('active' if build == @build) }
= link_to namespace_project_build_path(@project.namespace, @project, build) do
= ci_icon_for_status(build.status)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment