Merge pull request #730 from dataease/pr@v1.2@fix_radar

fix: 雷达图空数据报错
This commit is contained in:
XiaJunjie2020 2021-08-31 12:45:51 +08:00 committed by GitHub
commit 067a5979c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -28,6 +28,9 @@ export function baseRadarOption(chart_option, chart) {
const maxValues = []
for (let i = 0; i < chart.data.series.length; i++) {
const y = chart.data.series[i]
if (y.data.length === 0) {
continue
}
// color
y.itemStyle = {
color: hexColorToRGBA(customAttr.color.colors[i % 9], customAttr.color.alpha)