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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
a3f4b8e6
Commit
a3f4b8e6
authored
Sep 15, 2021
by
wortschi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add yAxis formatter
Changelog: fixed
parent
102c945c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
2 deletions
+12
-2
app/assets/javascripts/projects/pipelines/charts/components/pipeline_charts.vue
.../projects/pipelines/charts/components/pipeline_charts.vue
+11
-1
spec/frontend/projects/pipelines/charts/components/pipeline_charts_spec.js
...jects/pipelines/charts/components/pipeline_charts_spec.js
+1
-1
No files found.
app/assets/javascripts/projects/pipelines/charts/components/pipeline_charts.vue
View file @
a3f4b8e6
...
...
@@ -199,6 +199,16 @@ export default {
},
];
},
chartOptions
()
{
return
{
...
this
.
$options
.
timesChartOptions
,
yAxis
:
{
axisLabel
:
{
formatter
:
(
value
)
=>
value
,
},
},
};
},
},
methods
:
{
hideAlert
()
{
...
...
@@ -314,7 +324,7 @@ export default {
<strong>
{{
__
(
'
Pipeline durations for the last 30 commits
'
)
}}
</strong>
<gl-column-chart
:height=
"$options.chartContainerHeight"
:option=
"
$options.timesC
hartOptions"
:option=
"
c
hartOptions"
:bars=
"timesChartTransformedData"
:y-axis-title=
"__('Minutes')"
:x-axis-title=
"__('Commit')"
...
...
spec/frontend/projects/pipelines/charts/components/pipeline_charts_spec.js
View file @
a3f4b8e6
...
...
@@ -60,7 +60,7 @@ describe('~/projects/pipelines/charts/components/pipeline_charts.vue', () => {
expect
(
chart
.
props
(
'
yAxisTitle
'
)).
toBe
(
'
Minutes
'
);
expect
(
chart
.
props
(
'
xAxisTitle
'
)).
toBe
(
'
Commit
'
);
expect
(
chart
.
props
(
'
bars
'
)).
toBe
(
wrapper
.
vm
.
timesChartTransformedData
);
expect
(
chart
.
props
(
'
option
'
)).
toBe
(
wrapper
.
vm
.
$options
.
timesC
hartOptions
);
expect
(
chart
.
props
(
'
option
'
)).
toBe
(
wrapper
.
vm
.
c
hartOptions
);
});
});
...
...
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