feat: support multi y axis

This commit is contained in:
vicanso 2021-12-18 09:49:44 +08:00
parent ead48fef8e
commit 23e2eca0c6
6 changed files with 62 additions and 61 deletions

View file

@ -154,14 +154,10 @@ func convertEChartsSeries(e *ECharsOptions) ([]Series, chart.TickPosition) {
}
data[j] = sd
}
yAxisType := chart.YAxisPrimary
if item.YAxisIndex != 0 {
yAxisType = chart.YAxisSecondary
}
series[index] = Series{
YAxis: yAxisType,
Data: data,
Type: item.Type,
YAxisIndex: item.YAxisIndex,
Data: data,
Type: item.Type,
}
}
return series, tickPosition