summaryrefslogtreecommitdiff
path: root/app/views/projects/environments/show.html.haml
diff options
context:
space:
mode:
authorKamil Trzcinski <ayufan@ayufan.eu>2016-10-17 16:13:19 +0200
committerKamil Trzcinski <ayufan@ayufan.eu>2016-10-17 16:13:19 +0200
commit9b790f1cf97157240178601c62d2e557a404503e (patch)
tree5013faeb348f3b68c5066742bac575026d6e74a7 /app/views/projects/environments/show.html.haml
parent50d3cc2b677dac855a6270f5ffed7085df8edcf8 (diff)
downloadgitlab-ce-9b790f1cf97157240178601c62d2e557a404503e.tar.gz
Improve after code review
Diffstat (limited to 'app/views/projects/environments/show.html.haml')
-rw-r--r--app/views/projects/environments/show.html.haml5
1 files changed, 2 insertions, 3 deletions
diff --git a/app/views/projects/environments/show.html.haml b/app/views/projects/environments/show.html.haml
index 3b4d0395db0..b6a1a7fc89e 100644
--- a/app/views/projects/environments/show.html.haml
+++ b/app/views/projects/environments/show.html.haml
@@ -13,9 +13,8 @@
- if can?(current_user, :update_environment, @environment)
= link_to 'Edit', edit_namespace_project_environment_path(@project.namespace, @project, @environment), class: 'btn'
- - if @environment.available? && @environment.stoppable?
- = link_to 'Stop', stop_namespace_project_environment_path(@project.namespace, @project, @environment), data: { confirm: 'Are you sure you want to close this environment?' }, class: 'btn btn-danger', method: :post
- = link_to 'Destroy', namespace_project_environment_path(@project.namespace, @project, @environment), data: { confirm: 'Are you sure you want to delete this environment?' }, class: 'btn btn-danger', method: :delete
+ - if @environment.stoppable?
+ = link_to 'Stop', stop_namespace_project_environment_path(@project.namespace, @project, @environment), data: { confirm: 'Are you sure you want to stop this environment?' }, class: 'btn btn-danger', method: :post
.deployments-container
- if @deployments.blank?