index.html.haml 1.15 KB
Newer Older
1
- @no_container = true
Kamil Trzcinski's avatar
Kamil Trzcinski committed
2
- page_title "Environments"
3
= render "projects/pipelines/head"
Kamil Trzcinski's avatar
Kamil Trzcinski committed
4

Valery Sizov's avatar
Valery Sizov committed
5
%div{ class: container_class }
6
  - if can?(current_user, :create_environment, @project) && !@environments.blank?
Kamil Trzcinski's avatar
Kamil Trzcinski committed
7 8 9 10
    .top-area
      .nav-controls
        = link_to new_namespace_project_environment_path(@project.namespace, @project), class: 'btn btn-create' do
          New environment
Kamil Trzcinski's avatar
Kamil Trzcinski committed
11

Phil Hughes's avatar
Phil Hughes committed
12
  - if @environments.blank?
13 14 15 16 17
    .blank-state.blank-state-no-icon
      %h2.blank-state-title
        You don't have any environments right now.
      %p.blank-state-text
        Environments are places where code gets deployed, such as staging or production.
18 19
        %br
        = succeed "." do
20
          = link_to "Read more about environments", help_page_path("ci/environments")
Phil Hughes's avatar
Phil Hughes committed
21 22 23
      - if can?(current_user, :create_environment, @project)
        = link_to new_namespace_project_environment_path(@project.namespace, @project), class: 'btn btn-create' do
          New environment
Phil Hughes's avatar
Phil Hughes committed
24 25
  - else
    .table-holder
26
      %table.table.builds.environments
Phil Hughes's avatar
Phil Hughes committed
27 28
        %tbody
          %th Environment
29
          %th Last Deployment ID
30
          %th Commit
31
          %th
32
          %th
33
        = render @environments