Extjs4中RadioGroup的赋值与取值


1.定义rg

var rg = new Ext.form.RadioGroup({
            fieldLabel : "test",
            items : [{
                boxLabel : '每天',
                inputValue : "1",
                name : "rg"
            }, {
                boxLabel : '一次',
                name : "rg",
                inputValue : "2"
            }]
        });     

2.赋值

rg.setValue({rg: "2"});//一次被选中

rg.setValue({rg: "1"});//每天被选中

 

3.取值

rg.getValue().rg

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM