New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

反馈版本更新4.0后selected: true,无效 #7515

Closed
webLame opened this Issue Jan 17, 2018 · 0 comments

Comments

Projects
None yet
2 participants
@webLame

webLame commented Jan 17, 2018

One-line summary [问题简述]

用3.0版本,建立了一个饼图在series,type:pie 下得data属性里添加了selected: true,增加了选中状态,4.0更新后换成4.0版本的js,selected: true,就失效了。

js下载的完成版。

Version & Environment [版本及环境]

  • ECharts version [ECharts 版本]: 3.0 切换4.0
  • Browser version [浏览器类型和版本]:谷歌稳定版64位 最新版本
  • OS Version [操作系统类型和版本]:win10

Expected behaviour [期望结果]

替换4.0版本js后能和3.0版本一样,selected: true,选中状态有效;

ECharts option [ECharts配置项]

option = {
series: [
        {
            name:'访问来源',
            type:'pie',
            selectedMode: 'single',
            radius: [0, '30%'],

            label: {
                normal: {
                    position: 'inner'
                }
            },
            labelLine: {
                normal: {
                    show: false
                }
            },
            data:[
                {value:335, name:'直达', selected:true},
                {value:679, name:'营销广告'},
                {value:1548, name:'搜索引擎'}
            ]
        },
        {
            name:'访问来源',
            type:'pie',
            radius: ['40%', '55%'],

            data:[
                {value:335, name:'直达', selected:true},
                {value:310, name:'邮件营销'},
                {value:234, name:'联盟广告'},
                {value:135, name:'视频广告'},
                {value:1048, name:'百度'},
                {value:251, name:'谷歌'},
                {value:147, name:'必应'},
                {value:102, name:'其他'}
            ]
        }
    ]
}

Other comments [其他信息]

这个是selected:true有效的地址不是官方例子, http://gallery.echartsjs.com/editor.html?c=pie-nest
这个是官网例子的地址,在data里添加selected:true无效,http://echarts.baidu.com/examples/editor.html?c=pie-doughnut

@pissang pissang added bug 4.0 labels Jan 17, 2018

@100pah 100pah closed this in 801fc00 Jan 17, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment