关于Ext checkboxfiled 获取值为 on的解决办法

今天在做Ext checkboxfield 为取值为on,应该是true或false,解决办法是把Name去掉,只设置ID即可

 1             {
 2                            xtype: "container",
 3                            layout: "hbox",
 4                            defaultType: "textfield",
 5                            margin: "5 15 5 15",
 6                            style: 'text-align:right',
 7                            items: [
 8                                 {
 9                                     xtype: "checkboxfield",
10                                     //name: "Enabled",
11                                     id: 'Enabled',//这里把ID去掉即可
12                                     fieldLabel: "是否可用",
13                                     boxLabel: "",
14                                     checked:true,
15                                     labelAlign: "right",
16                                     flex: 0.5
17                                 }]
18                      }

 

posted @ 2015-06-20 00:13  changsen-  阅读(1145)  评论(0编辑  收藏  举报