summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2016-06-01 16:53:21 +0000
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2016-06-01 16:53:21 +0000
commit4621531a40ff46650e89b62b4e60933673ef904a (patch)
tree67651f17fbd58add3defa4fb891408e093b8e3b0
parent2d084dd8481417ba8031a378d68009738d076229 (diff)
parent390ea8e0d41589d46dec9c0c89dd3cbb959ec20f (diff)
downloadgitlab-ce-4621531a40ff46650e89b62b4e60933673ef904a.tar.gz
Merge branch 'dz-one-ci-cd-tab' into 'master'
Merge Builds and Pipelines tab into one Based on https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4053#note_12064642. Main idea is to keep all CI-related pages under one tab. So we can keep top navigation clean. First I tried `CI/CD` naming but it looked weird so I just used Pipelines as tab name. I did not change project settings naming. cc @ayufan @markpundsack @jschatz1 See merge request !4340
-rw-r--r--app/views/layouts/nav/_project.html.haml15
-rw-r--r--app/views/projects/builds/index.html.haml1
-rw-r--r--app/views/projects/pipelines/_head.html.haml14
-rw-r--r--app/views/projects/pipelines/index.html.haml1
4 files changed, 22 insertions, 9 deletions
diff --git a/app/views/layouts/nav/_project.html.haml b/app/views/layouts/nav/_project.html.haml
index 087b7472701..2c9b9006668 100644
--- a/app/views/layouts/nav/_project.html.haml
+++ b/app/views/layouts/nav/_project.html.haml
@@ -52,15 +52,6 @@
= icon('ship fw')
%span
Pipelines
- %span.badge.count.ci_counter= number_with_delimiter(@project.ci_commits.running_or_pending.count)
-
- - if project_nav_tab? :builds
- = nav_link(controller: %w(builds)) do
- = link_to project_builds_path(@project), title: 'Builds', class: 'shortcuts-builds' do
- = icon('cubes fw')
- %span
- Builds
- %span.badge.count.builds_counter= number_with_delimiter(@project.builds.running_or_pending.count(:all))
- if project_nav_tab? :container_registry
= nav_link(controller: %w(container_registry)) do
@@ -132,4 +123,10 @@
= link_to new_namespace_project_issue_path(@project.namespace, @project), class: 'shortcuts-new-issue' do
Create a new issue
+ -# Shortcut to builds page
+ - if project_nav_tab? :builds
+ %li.hidden
+ = link_to project_builds_path(@project), title: 'Builds', class: 'shortcuts-builds' do
+ Builds
+
.fade-right
diff --git a/app/views/projects/builds/index.html.haml b/app/views/projects/builds/index.html.haml
index 8fb9ebc1b8b..818d5d28f04 100644
--- a/app/views/projects/builds/index.html.haml
+++ b/app/views/projects/builds/index.html.haml
@@ -1,4 +1,5 @@
- page_title "Builds"
+= render "projects/pipelines/head"
.top-area
%ul.nav-links
diff --git a/app/views/projects/pipelines/_head.html.haml b/app/views/projects/pipelines/_head.html.haml
new file mode 100644
index 00000000000..2c8ae625e67
--- /dev/null
+++ b/app/views/projects/pipelines/_head.html.haml
@@ -0,0 +1,14 @@
+%ul.nav-links
+ - if project_nav_tab? :pipelines
+ = nav_link(controller: :pipelines) do
+ = link_to project_pipelines_path(@project), title: 'Pipelines', class: 'shortcuts-pipelines' do
+ %span
+ Pipelines
+ %span.badge.count.ci_counter= number_with_delimiter(@project.ci_commits.running_or_pending.count)
+
+ - if project_nav_tab? :builds
+ = nav_link(controller: %w(builds)) do
+ = link_to project_builds_path(@project), title: 'Builds', class: 'shortcuts-builds' do
+ %span
+ Builds
+ %span.badge.count.builds_counter= number_with_delimiter(@project.builds.running_or_pending.count(:all))
diff --git a/app/views/projects/pipelines/index.html.haml b/app/views/projects/pipelines/index.html.haml
index 8788db09dbe..453767920b5 100644
--- a/app/views/projects/pipelines/index.html.haml
+++ b/app/views/projects/pipelines/index.html.haml
@@ -1,4 +1,5 @@
- page_title "Pipelines"
+= render "projects/pipelines/head"
.top-area
%ul.nav-links