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
原文地址:https://www.cnblogs.com/TomSnail/p/4421397.html