ExtJs Layout:Wie ordnen Sie die Elemente in jeder Zeile?

Ich bin ein Anfänger von extjs.

Ich arrangieren wollen einige Textfelder wie folgt:

    a:______    b:______    c:______


    d:______    e:______    f:______

hier sind meine test-codes unter:

Ext.onReady(function()
{
    new Ext.panel.Panel(
    {
        renderTo: Ext.getBody(),
        layout:'vbox',
        width: 670,
        tbar: [{text:"Add"}],
        defaults:
        {
            layout:"column",
            height:50
        },
        items:
        [
            {
                defaults:
                {
                    labelAlign:"right",
                    labelWidth:50
                },
                items:
                [
                    {
                        xtype: 'textfield',
                        fieldLabel: 'a'
                    },
                    {
                        xtype: 'textfield',
                        fieldLabel: 'b'
                    },
                    {
                        xtype: 'textfield',
                        fieldLabel: 'c'
                    }
                ]
            },
            {
                defaults:
                {
                    labelAlign:"right",
                    labelWidth:50
                },
                items:
                [
                    {
                        xtype: 'textfield',
                        fieldLabel: 'd'
                    },
                    {
                        xtype: 'textfield',
                        fieldLabel: 'e'
                    },
                    {
                        xtype: 'textfield',
                        fieldLabel: 'f'
                    }
                ]
            }
        ]
    });
});

als ein Ergebnis, die Seite kann nicht angezeigt werden alle Felder mit Sternchen.

Vielen Dank für jede Hilfe im Voraus!

InformationsquelleAutor Sharp Kid | 2013-01-16
Schreibe einen Kommentar