diff --git a/app/views/projects/environments/_environment.html.haml b/app/views/projects/environments/_environment.html.haml index 16d04832e1a0fc1d639f098c23e4e0d76aeaa87f..5ca57bd153d376b1ca1bb7510ce3d6aaddf11951 100644 --- a/app/views/projects/environments/_environment.html.haml +++ b/app/views/projects/environments/_environment.html.haml @@ -3,7 +3,7 @@ %tr.environment %td %strong - = link_to environment.name, namespace_project_environment_path(@project.namespace, @project, environment), class: "monospace" + = link_to environment.name, namespace_project_environment_path(@project.namespace, @project, environment) %td - if last_deployment @@ -27,5 +27,3 @@ - if last_deployment %p #{time_ago_with_tooltip(last_deployment.created_at)} - - %td diff --git a/app/views/projects/environments/index.html.haml b/app/views/projects/environments/index.html.haml index 2da8d068e9f52bb549efe1a91d565639b28b7186..4a445a157ec62e2758f8edf050d3d177b16f597f 100644 --- a/app/views/projects/environments/index.html.haml +++ b/app/views/projects/environments/index.html.haml @@ -9,17 +9,16 @@ = link_to new_namespace_project_environment_path(@project.namespace, @project), class: 'btn btn-create' do New environment - %ul.content-list.environments - - if @environments.blank? - %li - .nothing-here-block No environments to show - - else - .table-holder - %table.table - %tbody - %th Environment - %th Last deployment - %th Date - %th - - @environments.each do |environment| - = render 'environment', environment: environment + - if @environments.blank? + %ul.content-list.environments + %li.nothing-here-block + No environments to show + - else + .table-holder + %table.table + %tbody + %th Environment + %th Last deployment + %th Date + - @environments.each do |environment| + = render 'environment', environment: environment diff --git a/app/views/projects/environments/new.html.haml b/app/views/projects/environments/new.html.haml index 5e8bc596f1e0008d649abb9500b9daf7fbcb953c..c7abac6e49f87886e9c4eceb5173db92aa7fb5ea 100644 --- a/app/views/projects/environments/new.html.haml +++ b/app/views/projects/environments/new.html.haml @@ -1,15 +1,15 @@ - page_title "New Environment" += render "projects/pipelines/head" -%h3.page-title - New Environment -%hr +.row.prepend-top-default.append-bottom-default + .col-lg-3 + %h4.prepend-top-0 + New Environment -= form_for @environment, url: namespace_project_environments_path(@project.namespace, @project), html: { id: "new-environment-form", class: "form-horizontal js-new-environment-form js-requires-input" } do |f| - = form_errors(@environment) - .form-group - = f.label :ref, 'Name', class: 'control-label' - .col-sm-10 - = f.text_field :name, required: true, tabindex: 2, class: 'form-control' - .form-actions - = f.submit 'Create', class: 'btn btn-create', tabindex: 3 - = link_to 'Cancel', namespace_project_environments_path(@project.namespace, @project), class: 'btn btn-cancel' + = form_for @environment, url: namespace_project_environments_path(@project.namespace, @project), html: { id: "new-environment-form", class: "col-lg-9 js-new-environment-form js-requires-input" } do |f| + = form_errors(@environment) + .form-group + = f.label :ref, 'Environment name', class: 'label-light' + = f.text_field :name, required: true, class: 'form-control' + = f.submit 'Create environment', class: 'btn btn-create' + = link_to "Cancel", namespace_project_environments_path(@project.namespace, @project), class: "btn btn-cancel" diff --git a/app/views/projects/environments/show.html.haml b/app/views/projects/environments/show.html.haml index dc07ad1a769e538424fcd99968d3f4a3355777c1..f5e30d75b429f3134ce5177e3318bb2ae22548b5 100644 --- a/app/views/projects/environments/show.html.haml +++ b/app/views/projects/environments/show.html.haml @@ -9,23 +9,24 @@ .col-md-3 .nav-controls - = link_to 'Destroy', namespace_project_environment_path(@project.namespace, @project, @environment), data: { confirm: 'Are you sure?' }, class: 'btn btn-danger', method: :post + = link_to 'Destroy', namespace_project_environment_path(@project.namespace, @project, @environment), data: { confirm: 'Are you sure?' }, class: 'btn btn-danger', method: :delete - %ul.content-list - - if @deployments.blank? - %li - .nothing-here-block No deployments for #{@environment.name} - - else - .table-holder - %table.table.builds - %thead - %tr - %th ID - %th Commit - %th Build - %th Date - %th + - if @deployments.blank? + %ul.content-list + %li.nothing-here-block + No deployments for + %strong= @environment.name + - else + .table-holder + %table.table.builds + %thead + %tr + %th ID + %th Commit + %th Build + %th Date + %th - = render @deployments + = render @deployments - = paginate @deployments, theme: 'gitlab' + = paginate @deployments, theme: 'gitlab'