bugfix 20240111
This commit is contained in:
@@ -82,7 +82,11 @@ function Oxygen(props) {
|
||||
export default Oxygen;
|
||||
|
||||
function getOptions(source, period, trend) {
|
||||
if (trend[source].length == 0) return null;
|
||||
if (
|
||||
trend[source].length == 0 ||
|
||||
trend[source].filter((item) => item.value).length == 0
|
||||
)
|
||||
return null;
|
||||
return {
|
||||
color: ["#FFD160", "#12FFF5", "#2760FF"],
|
||||
grid: { top: 40, right: 12, bottom: 20, left: 80 },
|
||||
@@ -143,7 +147,11 @@ function getOptions(source, period, trend) {
|
||||
},
|
||||
series: [
|
||||
{
|
||||
data: trend[source].map((item) => !(item.value == null || isNaN(+item.value)) ? (+item.value).toFixed(2) : null),
|
||||
data: trend[source].map((item) =>
|
||||
!(item.value == null || isNaN(+item.value))
|
||||
? (+item.value).toFixed(2)
|
||||
: null
|
||||
),
|
||||
type: "line",
|
||||
symbol: "circle",
|
||||
symbolSize: 6,
|
||||
|
||||
Reference in New Issue
Block a user