feat: support multi y axis
This commit is contained in:
parent
ead48fef8e
commit
23e2eca0c6
6 changed files with 62 additions and 61 deletions
10
echarts.go
10
echarts.go
|
|
@ -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
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue