Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
super-hive-web
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Container Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
SuperHive
front-end
super-hive-web
Commits
d2bbbf87
Commit
d2bbbf87
authored
Aug 13, 2020
by
wends
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update line chart component
parent
49fb1677
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletion
+9
-1
ELine.vue
src/components/Charts/ELine.vue
+9
-1
No files found.
src/components/Charts/ELine.vue
View file @
d2bbbf87
...
...
@@ -45,6 +45,10 @@ export default {
default
:
()
=>
{
return
{}
}
},
format
:
{
type
:
String
,
default
:
'
HH:mm:ss
'
}
},
data
()
{
...
...
@@ -72,10 +76,14 @@ export default {
const
xAxis
=
[]
const
series
=
[]
data
.
forEach
(
v
=>
{
xAxis
.
push
(
moment
(
v
.
time
).
format
(
'
HH:mm:ss
'
))
xAxis
.
push
(
moment
(
v
.
time
).
format
(
this
.
format
))
series
.
push
(
v
.
value
)
})
this
.
chart
.
setOption
({
title
:
{
text
:
`
${
this
.
title
}
监控图表`
,
subtext
:
`单位为:
${
this
.
description
}
`
},
xAxis
:
{
data
:
xAxis
},
...
...
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