提交 1f88522f authored 作者: lihuihui's avatar lihuihui

修改bug

上级 6e9f725d
......@@ -117,6 +117,7 @@ export default {
data1.push(item.score)
data2.push(this.getNowTime(item.date_index))
})
if (data2.length > 1) {
this.polar = {
dataZoom: [{
type: 'inside',
......@@ -199,6 +200,89 @@ export default {
}
}]
}
} else {
this.polar = {
dataZoom: [{
type: 'inside',
start: 0,
end: 50
}],
grid: {
x: 30,
y: 20,
x2: 0,
y2: 30
},
itemStyle: {
// color: 'linear-gradient(0deg, #00A2DB, #35D0E9)'
color: {
type: 'linear',
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [{
offset: 1, color: '#00A2DB'
}, {
offset: 0, color: '#35D0E9'
}],
global: false // 缺省为 false
}
},
xAxis: {
type: 'category',
data: data2,
axisLabel: {
color: 'rgba(255,255,255,0.3)'
},
axisLine: {
show: false
},
axisTick: {
show: false
},
splitLine: {
lineStyle: {
color: ['#D4D4D8'],
opacity: 0.1
}
}
},
yAxis: {
// minInterval: 50,
// interval: 50,
splitNumber: 3,
type: 'value',
axisLabel: {
color: 'rgba(255,255,255,0.3)'
},
axisLine: {
show: false
},
axisTick: {
show: false
},
splitLine: {
lineStyle: {
color: ['#D4D4D8'],
opacity: 0.1
}
}
},
series: [{
data: data1,
type: 'line',
smooth: true,
itemStyle: {
normal: {
lineStyle: {
width: 3
}
}
}
}]
}
}
this.$forceUpdate()
}
})
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论