Commit f341d957 authored by Katarzyna Kobierska's avatar Katarzyna Kobierska

Build path with call

parent 80c86bcc
...@@ -21,8 +21,8 @@ ...@@ -21,8 +21,8 @@
%th %th
- if admin - if admin
= render partial: "shared/builds/build", collection: builds, as: :build, locals: { commit_sha: true, ref: true, stage: true, allow_retry: true, runner: true, admin: true } = render partial: "projects/ci/builds/build", collection: builds, as: :build, locals: { commit_sha: true, ref: true, stage: true, allow_retry: true, runner: true, admin: true }
- else - else
= render partial: "shared/builds/build", collection: builds, as: :build, locals: {commit_sha: true, ref: true, stage: true, allow_retry: true, coverage: project.build_coverage_enabled? } = render partial: "projects/ci/builds/build", collection: builds, as: :build, locals: {commit_sha: true, ref: true, stage: true, allow_retry: true, coverage: project.build_coverage_enabled? }
= paginate builds, theme: 'gitlab' = paginate builds, theme: 'gitlab'
%ul.nav-links
%li{class: ('active' if scope.nil?)}
= link_to build_path[nil] do
All
%span.badge.js-totalbuilds-count
= number_with_delimiter(all_builds.count(:id))
%li{class: ('active' if scope == 'pending')}
= link_to build_path[:pending] do
Pending
%span.badge
= number_with_delimiter(all_builds.pending.count(:id))
%li{class: ('active' if scope == 'running')}
= link_to build_path[:running] do
Running
%span.badge
= number_with_delimiter(all_builds.running.count(:id))
%li{class: ('active' if scope == 'finished')}
= link_to build_path[:finished] do
Finished
%span.badge
= number_with_delimiter(all_builds.finished.count(:id))
%ul.nav-links %ul.nav-links
%li{class: ('active' if scope.nil?)} %li{class: ('active' if scope.nil?)}
= link_to build_path[nil] do = link_to build_path.call(nil) do
All All
%span.badge.js-totalbuilds-count %span.badge.js-totalbuilds-count
= number_with_delimiter(all_builds.count(:id)) = number_with_delimiter(all_builds.count(:id))
%li{class: ('active' if scope == 'pending')} %li{class: ('active' if scope == 'pending')}
= link_to build_path[:pending] do = link_to build_path.call('pending') do
Pending Pending
%span.badge %span.badge
= number_with_delimiter(all_builds.pending.count(:id)) = number_with_delimiter(all_builds.pending.count(:id))
%li{class: ('active' if scope == 'running')} %li{class: ('active' if scope == 'running')}
= link_to build_path[:running] do = link_to build_path.call('running') do
Running Running
%span.badge %span.badge
= number_with_delimiter(all_builds.running.count(:id)) = number_with_delimiter(all_builds.running.count(:id))
%li{class: ('active' if scope == 'finished')} %li{class: ('active' if scope == 'finished')}
= link_to build_path[:finished] do = link_to build_path.call('finished') do
Finished Finished
%span.badge %span.badge
= number_with_delimiter(all_builds.finished.count(:id)) = number_with_delimiter(all_builds.finished.count(:id))
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