setTimeout(function(){
window.onresize = function(){
myChart.resize();
}
},500);
需要用定时器保证执行的顺序。。。。。。。