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
Boxiang Sun
gitlab-ce
Commits
55fb75b9
Commit
55fb75b9
authored
May 22, 2019
by
Adriel Santiago
Committed by
Mike Greiling
May 22, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove datapoint sorting from area chart
parent
8f0ad134
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
app/assets/javascripts/monitoring/components/charts/area.vue
app/assets/javascripts/monitoring/components/charts/area.vue
+8
-8
No files found.
app/assets/javascripts/monitoring/components/charts/area.vue
View file @
55fb75b9
...
@@ -125,17 +125,17 @@ export default {
...
@@ -125,17 +125,17 @@ export default {
},
},
earliestDatapoint
()
{
earliestDatapoint
()
{
return
this
.
chartData
.
reduce
((
acc
,
series
)
=>
{
return
this
.
chartData
.
reduce
((
acc
,
series
)
=>
{
if
(
!
series
.
data
.
length
)
{
const
{
data
}
=
series
;
const
{
length
}
=
data
;
if
(
!
length
)
{
return
acc
;
return
acc
;
}
}
const
[[
timestamp
]]
=
series
.
data
.
sort
(([
a
],
[
b
])
=>
{
if
(
a
<
b
)
{
return
-
1
;
}
return
a
>
b
?
1
:
0
;
});
return
timestamp
<
acc
||
acc
===
null
?
timestamp
:
acc
;
const
[
first
]
=
data
[
0
];
const
[
last
]
=
data
[
length
-
1
];
const
seriesEarliest
=
first
<
last
?
first
:
last
;
return
seriesEarliest
<
acc
||
acc
===
null
?
seriesEarliest
:
acc
;
},
null
);
},
null
);
},
},
isMultiSeries
()
{
isMultiSeries
()
{
...
...
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