Commit 86cedb08 authored by Kamil Trzcinski's avatar Kamil Trzcinski

Use pipeline permissions instead of build

parent 3953e5fc
.row-content-block.build-content.middle-block .row-content-block.build-content.middle-block
.pull-right .pull-right
- if can?(current_user, :update_build, @project) - if can?(current_user, :update_pipeline, @project)
- if ci_commit.builds.latest.failed.any?(&:retryable?) - if ci_commit.builds.latest.failed.any?(&:retryable?)
= link_to "Retry failed", retry_namespace_project_pipeline_path(@project.namespace, @project, ci_commit.id), class: 'btn btn-grouped btn-primary', method: :post = link_to "Retry failed", retry_namespace_project_pipeline_path(@project.namespace, @project, ci_commit.id), class: 'btn btn-grouped btn-primary', method: :post
......
...@@ -29,7 +29,6 @@ ...@@ -29,7 +29,6 @@
= icon('plus') = icon('plus')
New New
- if can?(current_user, :update_build, @project)
- unless @repository.gitlab_ci_yml - unless @repository.gitlab_ci_yml
= link_to 'Get started with Pipelines', help_page_path('ci/quick_start', 'README'), class: 'btn btn-info' = link_to 'Get started with Pipelines', help_page_path('ci/quick_start', 'README'), class: 'btn btn-info'
...@@ -54,7 +53,7 @@ ...@@ -54,7 +53,7 @@
.table-holder .table-holder
%table.table.builds %table.table.builds
%tbody %tbody
%th Pipeline ID %th ID
%th Commit %th Commit
- @pipelines.stages.each do |stage| - @pipelines.stages.each do |stage|
%th %th
......
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