summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorRobert Speicher <robert@gitlab.com>2015-10-23 14:06:34 +0000
committerRobert Speicher <robert@gitlab.com>2015-10-23 14:06:34 +0000
commit17c60173f6e2a543c7a92cd2a992ef8bc1ea2ee6 (patch)
treef44dffdd8defe2f2756a50f436ad1d4f2cb0e84e /app/views
parent2b51823017faec1d75852bcd318bd502099d692d (diff)
parent5921a1edf3eacc23ed25f39d052ad4db4aac91e2 (diff)
downloadgitlab-ce-17c60173f6e2a543c7a92cd2a992ef8bc1ea2ee6.tar.gz
Merge branch 'fix-ci-regressions' into 'master'
Fix CI regressions This MR fixes a couple of small CI regressions - Allow developer to manage builds - On CI Admin page show only projects that are present in GitLab - On Runner CI Admin page show only projects that are present in GitLab - Refresh build log only when status changes - Show the oldest builds on top when viewing Builds - it most cases it shows running builds on top - Fix Lint rendering - Fix number of other builds in build widget Fixes #3164 Fixes #3161 Fixes gitlab-org/gitlab-ci#343 See merge request !1679
Diffstat (limited to 'app/views')
-rw-r--r--app/views/ci/admin/runners/show.html.haml30
-rw-r--r--app/views/ci/lints/_create.html.haml7
-rw-r--r--app/views/projects/builds/show.html.haml2
3 files changed, 25 insertions, 14 deletions
diff --git a/app/views/ci/admin/runners/show.html.haml b/app/views/ci/admin/runners/show.html.haml
index 92787b2e6ac..02b53612663 100644
--- a/app/views/ci/admin/runners/show.html.haml
+++ b/app/views/ci/admin/runners/show.html.haml
@@ -53,13 +53,14 @@
%th
- @runner.runner_projects.each do |runner_project|
- project = runner_project.project
- %tr.alert-info
- %td
- %strong
- = project.name
- %td
- .pull-right
- = link_to 'Disable', [:ci, :admin, project, runner_project], method: :delete, class: 'btn btn-danger btn-xs'
+ - if project.gl_project
+ %tr.alert-info
+ %td
+ %strong
+ = project.name
+ %td
+ .pull-right
+ = link_to 'Disable', [:ci, :admin, project, runner_project], method: :delete, class: 'btn btn-danger btn-xs'
%table.table
%thead
@@ -103,21 +104,26 @@
%th Finished at
- @builds.each do |build|
+ - gl_project = build.gl_project
%tr.build
%td.id
- - gl_project = build.project.gl_project
- = link_to namespace_project_build_path(gl_project.namespace, gl_project, build) do
+ - if gl_project
+ = link_to namespace_project_build_path(gl_project.namespace, gl_project, build) do
+ = build.id
+ - else
= build.id
%td.status
= ci_status_with_icon(build.status)
%td.status
- = build.project.name
+ - if gl_project
+ = gl_project.name_with_namespace
%td.build-link
- = link_to ci_status_path(build.commit) do
- %strong #{build.commit.short_sha}
+ - if gl_project
+ = link_to ci_status_path(build.commit) do
+ %strong #{build.commit.short_sha}
%td.timestamp
- if build.finished_at
diff --git a/app/views/ci/lints/_create.html.haml b/app/views/ci/lints/_create.html.haml
index f45cd05aec0..77f78caa8d8 100644
--- a/app/views/ci/lints/_create.html.haml
+++ b/app/views/ci/lints/_create.html.haml
@@ -17,7 +17,7 @@
%td #{stage.capitalize} Job - #{build[:name]}
%td
%pre
- = simple_format build[:script]
+ = simple_format build[:commands]
%br
%b Tag list:
@@ -28,6 +28,11 @@
%br
%b Refs except:
= build[:except] && build[:except].join(", ")
+ %br
+ %b When:
+ = build[:when]
+ - if build[:allow_failure]
+ %b Allowed to fail
-else
%p
diff --git a/app/views/projects/builds/show.html.haml b/app/views/projects/builds/show.html.haml
index 3a8172dc8e6..e3d8d734913 100644
--- a/app/views/projects/builds/show.html.haml
+++ b/app/views/projects/builds/show.html.haml
@@ -155,7 +155,7 @@
- if @builds.present?
.build-widget
- %h4.title #{pluralize(@builds.count, "other build")} for #{@build.short_sha}:
+ %h4.title #{pluralize(@builds.count(:id), "other build")} for #{@build.short_sha}:
%table.table.builds
- @builds.each_with_index do |build, i|
%tr.build