Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
gitlab-ce
Commits
4e66551a
Commit
4e66551a
authored
Aug 17, 2016
by
Annabel Dunstone
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add deploy btn in graph; fix JS to toggle one graph at a time if multiple pipelines
parent
49e7070a
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
7 deletions
+17
-7
app/assets/javascripts/pipeline.js.es6
app/assets/javascripts/pipeline.js.es6
+6
-3
app/assets/stylesheets/pages/pipelines.scss
app/assets/stylesheets/pages/pipelines.scss
+8
-0
app/helpers/ci_status_helper.rb
app/helpers/ci_status_helper.rb
+2
-2
app/views/projects/ci/builds/_build_pipeline.html.haml
app/views/projects/ci/builds/_build_pipeline.html.haml
+1
-2
No files found.
app/assets/javascripts/pipeline.js.es6
View file @
4e66551a
function toggleGraph() {
$('.pipeline-graph, .toggle-pipeline-btn').toggleClass('graph-collapsed'
);
const indexOfBtn = $('.toggle-pipeline-btn').index($(this)
);
const $btnText = $('.toggle-pipeline-btn .btn-text');
const graphCollapsed = $('.pipeline-graph').hasClass('graph-collapsed');
$($('.pipeline-graph')[indexOfBtn]).toggleClass('graph-collapsed');
$($('.toggle-pipeline-btn')[indexOfBtn]).toggleClass('graph-collapsed');
const $btnText = $($('.toggle-pipeline-btn .btn-text')[indexOfBtn]);
const graphCollapsed = $($('.pipeline-graph')[indexOfBtn]).hasClass('graph-collapsed');
graphCollapsed ? $btnText.text('Expand') : $btnText.text('Hide')
}
...
...
app/assets/stylesheets/pages/pipelines.scss
View file @
4e66551a
...
...
@@ -298,6 +298,10 @@
width
:
150px
;
margin-bottom
:
10px
;
&
.deployable
{
background-color
:
$gray-light
;
}
.build-content
{
width
:
130px
;
white-space
:
nowrap
;
...
...
@@ -315,6 +319,10 @@
margin-right
:
5px
;
}
.fa
{
font-size
:
13px
;
}
// Connect first build in each stage with right horizontal line
&
:first-child
{
&
:
:
after
{
...
...
app/helpers/ci_status_helper.rb
View file @
4e66551a
...
...
@@ -39,14 +39,14 @@ module CiStatusHelper
when
'running'
'icon_status_running'
when
'play'
'
icon_status_warning
'
'
play
'
when
'created'
'icon_status_pending'
else
'icon_status_cancel'
end
custom_icon
(
icon_name
)
status
==
'play'
?
icon
(
icon_name
+
' fw'
)
:
custom_icon
(
icon_name
)
end
def
render_commit_status
(
commit
,
tooltip_placement:
'auto left'
)
...
...
app/views/projects/ci/builds/_build_pipeline.html.haml
View file @
4e66551a
%li
.build
%li
.build
{
class:
(
"deployable"
if
subject
.
playable?
&&
can?
(
current_user
,
:update_build
,
@project
))}
.build-content
-
if
subject
.
playable?
&&
can?
(
current_user
,
:update_build
,
@project
)
=
link_to
play_namespace_project_build_path
(
subject
.
project
.
namespace
,
subject
.
project
,
subject
,
return_to:
request
.
original_url
),
method: :post
,
title:
'Play'
do
...
...
@@ -11,4 +11,3 @@
-
else
=
render_status_with_link
(
'build'
,
subject
.
status
)
=
ci_icon_for_status
(
subject
.
status
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment