0
我如何顯示/隱藏第二y軸我試圖使我的高位代碼功能化,並且我正在努力理解如何根據條件if語句繪製第二個y軸,例如下面的代碼:highcharts - 基於可選參數
yAxis: [{ // Primary yAxis shown for all charts
min: 0,
labels: {
format: '{value} pcks ',
style: {
color: '#4572A7'
}
},
title: {
text: 'Volume',
style: {
color: '#4572A7'
}
}
}, { // Secondary yAxis make this optional based on AxisNum accepted values:1/2
formatter: function(){
if(AxisNum === 2])
{
gridLineWidth: 0, min:0, title: { text: 'Cycle Time', style: { color: '#C88622' } }, labels: {format: '{value} days',style: {color: '#C88622'}},opposite: true;
}
}
}],
臨屋你這樣做了! – k7hulu