EXT 다중 라디오 가로 정렬

7657 단어 ext
프로젝트에서 라디오를 사용하고 가로로 두 개를 모두 정상적으로 배열했다. 네 개를 배열하면 완전히 혼란스럽다. baidu가 한 번 배열하면layout:'column','layout:'form', 혼합으로 해결한다
// 
    var panelItem=  [

    		       {
                    		columnWidth:1,
                			layout: 'form',
                			items:[{
	                    		xtype:'hidden',
			                    fieldLabel: ' ',
			                    id:'id',
			                    name: 'Obj.id',
			                    readOnly:true,
			                    hidden:false,
			                    width: 100,
			                    maxLength:10,
			                    minLength:1,
			                    allowBlank: false
                    			}]

	                    },
	              {
                    		columnWidth:1,
                			layout: 'form',
                			items:[{
                			    xtype:'hidden',
			                    fieldLabel: ' id',
			                    id:'pId',
			                    msgTarget:'under',
			                    name: 'Obj.base.id',// 
			                    height:22,
width:180,
			                    readOnly:true,
			                    maxLength:20,
			                    allowBlank: true }
                    			]

	                    },
    		    {
                    layout:'column',
                    items:[
                    	{
                    		columnWidth:.5,
                			layout: 'form',
                			items:[{
	                    		xtype:'textfield',
                                fieldLabel: ' ',
			                    id:'parentName',
			                    hidden:false,
			                    readOnly:true,
			                    name: 'parentName', // 
			                    height:22,
                                width:180,
			                    minLength:1
                    			}]

	                    },
	                    {
	                    	columnWidth:.5,
                			layout: 'form',
                			items:[{xtype:'textfield',
			                    fieldLabel: '     ',
			                    id:'name',
			                    msgTarget:'under',
			                    name: 'Obj.name',
			                    height:22,
                                width:180,
			                    maxLength:20,
			                    allowBlank: false }]
	                    },



	                    	                     {
 	columnWidth:.5,
                 layout:'column',
                 items:[
                       {
                       	columnWidth:.5,
                         layout: 'form',
                         items: [new Ext.form.Radio({style:'margin-top:5px',
                         fieldLabel: '     ',
                         id:'length1',
			                    			boxLabel:' ',
							                name: 'Obj.length',
							                inputValue:1,
							                checked:false})]
                     },

                     {
                     	columnWidth:.5,

                     	items: [new Ext.form.Radio({style:'margin-top:5px',
                     id:'length2',
			                    			boxLabel:' ',
							                name: 'Obj.length',
							                inputValue:0,
							                checked:true})]
                     }
                     ]
             },



	                     {
 	columnWidth:.5,
                 layout:'column',
                 items:[
                       {
                       	columnWidth:.5,
                         layout: 'form',
                         items: [new Ext.form.Radio({style:'margin-top:5px',
                         fieldLabel: '     ',
                         id:'width1',
			                    			boxLabel:' ',
							                name: 'Obj.width',
							                inputValue:1,
							                checked:false})]
                     },

                     {columnWidth:.5,
                     items: [new Ext.form.Radio({style:'margin-top:5px',
                     id:'width2',
			                    			boxLabel:' ',
							                name: 'Obj.width',
							                inputValue:0,
							                checked:true})]
                     }
                     ]
             },



 {
 	columnWidth:.5,
                 layout:'column',
                 items:[
                       {
                       	columnWidth:.5,
                         layout: 'form',
                         items: [new Ext.form.Radio({style:'margin-top:5px',
                         fieldLabel: '     ',
                         id:'height1',
			                    			boxLabel:' ',
							                name: 'Obj.height',
							                inputValue:1,
							                checked:false})]
                     },

                     {
                     	columnWidth:.5,
                     	items: [new Ext.form.Radio({style:'margin-top:5px',
                     id:'height2',
			                    			boxLabel:' ',
							                name: 'Obj.height',
							                inputValue:0,
							                checked:true})]
                     }
                     ]
             },

 {
 	columnWidth:.5,
                 layout:'column',
                 items:[
                       {
                       	columnWidth:.5,
                         layout: 'form',
                         items: [new Ext.form.Radio({style:'margin-top:5px',
                         fieldLabel: '     ',
                         id:'volume1',
			                    			boxLabel:' ',
							                name: 'Obj.volume',
							                inputValue:1,
							                checked:false})]
                     },

                     {
                     	columnWidth:.5,
                     items: [new Ext.form.Radio({style:'margin-top:5px',
                     id:'volume2',
			                    			boxLabel:' ',
							                name: 'Obj.volume',
							                inputValue:0,
							                checked:true})]
                     }
                     ]
             },



	                     {
	                    	columnWidth:.5,
                			layout: 'form',
                			items:[{xtype:'textfield',
			                    fieldLabel: '     ',
			                    id:'descn',
			                    msgTarget:'under',
			                    name: 'Obj.descn',
			                    height:22,
                                width:180,
			                    maxLength:20,
			                    allowBlank: true }]
	                    }
	                   ]
                }


                ];

	//form
    var panel = new Ext.FormPanel({
        applyTo: 'Content-render-panel-div',
        frame:true,
        url:'saveOrUpdateBase.action',
        //reader:thospital,
        autoHeight:true,
        autoWidth:true,
        autoScroll:true,
        items:panelItem ,
		buttons: [{
            text: ' ',
            id:'hsubmit',
            handler:save
        }]

좋은 웹페이지 즐겨찾기