show.html.haml 1.1 KB
Newer Older
1
- @no_container = true
K
Kamil Trzcinski 已提交
2
- page_title "Environments"
3
= render "projects/pipelines/head"
K
Kamil Trzcinski 已提交
4

V
Valery Sizov 已提交
5
%div{ class: container_class }
K
Kamil Trzcinski 已提交
6 7
  .top-area
    .col-md-9
8
      %h3.page-title= @environment.name.titleize
K
Kamil Trzcinski 已提交
9 10 11

    .col-md-3
      .nav-controls
K
Kamil Trzcinski 已提交
12
        - if can?(current_user, :update_environment, @environment)
K
Kamil Trzcinski 已提交
13
          = 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
K
Kamil Trzcinski 已提交
14

P
Phil Hughes 已提交
15
  - if @deployments.blank?
16 17 18 19 20 21 22 23
    .blank-state.blank-state-no-icon
      %h2.blank-state-title
        You don't have any deployments right now.
      %p.blank-state-text
        Define environments in the deploy stage(s) in
        %code .gitlab-ci.yml
        to track deployments here.
      = link_to "Read more", help_page_path("ci", "environments"), class: "btn btn-success"
P
Phil Hughes 已提交
24 25
  - else
    .table-holder
26
      %table.table.environments
P
Phil Hughes 已提交
27 28 29 30 31 32 33
        %thead
          %tr
            %th ID
            %th Commit
            %th Build
            %th Date
            %th
K
Kamil Trzcinski 已提交
34

P
Phil Hughes 已提交
35
        = render @deployments
K
Kamil Trzcinski 已提交
36

P
Phil Hughes 已提交
37
    = paginate @deployments, theme: 'gitlab'