小编Raz*_*era的帖子

CheckBox,动作事件

我需要添加一个Check box,当用户checks在其上(如更改值check/uncheck)打印一个console.log语句.到目前为止,我能够显示复选框,但无法访问其检查事件.

{
    xtype: 'checkboxgroup',
    columns: 1,

    listeners: {
        change: function (this, newValue, oldValue, eOpts) {
            console.log('change');
            console.log(newValue);
        }
    },
    items: [{
        boxLabel: 'Cars',
        name: 'chk1',
        inputValue: '1'
    }]
}
Run Code Online (Sandbox Code Playgroud)

extjs extjs4 extjs4.1

5
推荐指数
1
解决办法
9700
查看次数

标签 统计

extjs ×1

extjs4 ×1

extjs4.1 ×1