if (this.myEcharts != null && this.myEcharts != '' && this.myEcharts != undefined){
// console.log('进入这个方法时,如果当前页面存在则销毁,this.myEcharts为:',this.myEcharts)
this.myEcharts.dispose()
}
this.myEcharts = await echarts.init(this.$refs.echart_clock)
在方法drawEcharts进行前执行判断当前页面的myEcharts,满足条件后执行dispose进行销毁。
销毁后执行echarts.init初始化