0
我有一個顯示圖表的拉力賽SDK 2.0p5應用程序。當用戶選擇一個選項時,數據將被更新,我想刷新圖表。但是,不要重新繪製,它會在下面放置一個新圖表。什麼是正確的語法?刷新拉力賽圖
// Configure and Add the chart
this.add(
{
xtype: 'rallychart',
height: 400,
id: 'chart',
chartConfig: {
chart: {
},
title: {
text: 'My Chart',
align: 'center'
},
xAxis: [
{
categories: ['M0','M1','M2','M3','M4','M5'],
title: {
text: 'Interval'
}
}
],
yAxis: {
title: {
text: yText
}
},
series: [ { type: 'column',
name: yText,
data: mCount } ],
plotOptions : {
column: {
color: '#F00'
},
series : {
animation : {
duration : 2000,
easing : 'swing'
}
}
}
}
}
);
我的ID設置爲「圖表」,和它的作品沒有「#」 redrawChart:函數(){ 這一點。除去( '圖表'); this.add({...}); } –