Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wisdom-components
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ReactWeb5
wisdom-components
Commits
f82b373d
Commit
f82b373d
authored
Dec 24, 2024
by
陈龙
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 修复历史曲线同期对比出现max/min设置错误导致无法正确显示曲线的问题
parent
ed252983
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
2 deletions
+13
-2
SingleChart.js
packages/extend-components/EC_HistoryView/src/SingleChart.js
+13
-2
No files found.
packages/extend-components/EC_HistoryView/src/SingleChart.js
View file @
f82b373d
...
...
@@ -251,12 +251,23 @@ const SingleChart = memo((props) => {
}
}
else
{
try
{
let
_maxMap
=
{};
// 确定哪些是需要标记min/max
_option
.
series
.
forEach
(
item
=>
{
if
(
item
.
data
.
length
===
0
)
{
// 泳道图没有yAxisIndex
if
(
item
.
data
.
length
===
0
&&
(
item
.
yAxisIndex
||
item
.
yAxisIndex
===
0
))
{
if
(
item
.
yAxisIndex
||
item
.
yAxisIndex
===
0
)
{
if
(
!
_maxMap
[
item
.
yAxisIndex
])
_maxMap
[
item
.
yAxisIndex
]
=
'noData'
}
}
else
{
_maxMap
[
item
.
yAxisIndex
]
=
'data'
;
}
});
// 标记min/max
_option
.
series
.
forEach
(
item
=>
{
if
(
_maxMap
[
item
.
yAxisIndex
]
===
'noData'
)
{
_option
.
yAxis
[
item
.
yAxisIndex
].
max
=
1
;
_option
.
yAxis
[
item
.
yAxisIndex
].
min
=
0
;
item
.
data
=
[[
moment
(
dataSource
?.[
0
]?.
dateFrom
).
valueOf
(),
null
],
[
moment
(
dataSource
?.[
0
]?.
dateTo
).
valueOf
(),
null
]]
}
})
}
catch
(
e
)
{
...
...
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