Ext开场表单布局设计

    var form = new Ext.form.FormPanel({
        labelAlign: 'right',
        labelWidth: 60,
        buttonAlign: 'center',
        title: 'form',
        frame:true,
        width: 450,
        url: '04_01_01.jsp',

        items: [{
            bodyStyle: 'background:transparent;border:0px;',
            layout:'column',
            items: [{
                bodyStyle: 'background:transparent;border:0px;',
                columnWidth:.5,
                layout: 'form',
                defaultType: 'textfield',
                items:[
                    {fieldLabel: '俩字'},
                    {fieldLabel: '俩字'}
                ]
            },{
                bodyStyle: 'background:transparent;border:0px;',
                columnWidth:.5,
                layout: 'form',
                defaultType: 'textfield',
                items:[
                    {fieldLabel: '三个字'},
                    {fieldLabel: '三个字'},
                    {fieldLabel: '三个字'}
                ]
            }]
        },{
            width: 345,
            height: 100,
            xtype: 'textarea',
            fieldLabel: '四个汉字'
        }],
        buttons: [{
            text: '按钮',
            handler: function() {
                form.getForm().submit();
            }
        }]
    });

 

posted on 2015-02-26 18:10  小忙  阅读(153)  评论(0编辑  收藏  举报

导航