English 中文(简体)
我用推器设计了制片小组。
原标题:I have made a layout of tab panel with extjs designer
  • 时间:2011-03-25 16:38:23
  •  标签:
  • extjs

I have made a layout of tab panel with extjs designer but its not displaying anything if I am running it.

在此,请帮助我:

Ext.onReady(function(){
    Ext.BLANK_IMAGE_URL =  extjs/s.gif ;
    Ext.onReady(function(){
        MyTabPanelUi = Ext.extend(Ext.TabPanel, {
            activeTab: 0,
            width: 800,
            height: 500,
            title:  Ledger ,
            itemId:  ledger_tab ,
            initComponent: function() {
                this.items = [
                {
                    xtype:  panel ,
                    title:  Ledger ,
                    autoScroll: true,
                    items: [
                    {
                        xtype:  editorgrid ,
                        title:  Ledger ,
                        store:  store ,
                        height: 150,
                        footer: true,
                        stripeRows: true,
                        header: true,
                        loadMask: true,
                        id:  leg_grid_up ,
                        columns: [
                        {
                            xtype:  gridcolumn ,
                            dataIndex:  string ,
                            header:  Column ,
                            sortable: true,
                            width: 100,
                            editor: {
                                xtype:  textfield 
                            }
                        },
                        {
                            xtype:  numbercolumn ,
                            dataIndex:  number ,
                            header:  Column ,
                            sortable: true,
                            width: 100,
                            align:  right ,
                            editor: {
                                xtype:  numberfield 
                            }
                        },
                        {
                            xtype:  datecolumn ,
                            dataIndex:  date ,
                            header:  Column ,
                            sortable: true,
                            width: 100,
                            editor: {
                                xtype:  datefield 
                            }
                        },
                        {
                            xtype:  booleancolumn ,
                            dataIndex:  bool ,
                            header:  Column ,
                            sortable: true,
                            width: 100,
                            editor: {
                                xtype:  checkbox ,
                                boxLabel:  BoxLabel 
                            }
                        }
                        ],
                        tbar: {
                            xtype:  toolbar ,
                            height: 50,
                            items: [
                            {
                                xtype:  container ,
                                layout:  column ,
                                width: 794,
                                height: 43,
                                items: [
                                {
                                    xtype:  spacer ,
                                    width: 588,
                                    height: 18
                                },
                                {
                                    xtype:  spacer ,
                                    width: 200,
                                    height: 18
                                },
                                {
                                    xtype:  datefield 
                                }
                                ]
                            }
                            ]//toolbar items
                        }
                    },
                    {
                        xtype:  container ,
                        height: 70
                    },
                    {
                        xtype:  editorgrid ,
                        title:  Ledger ,
                        height: 150,
                        id:  leg_grid_down ,
                        columns: [
                        {
                            xtype:  gridcolumn ,
                            dataIndex:  string ,
                            header:  Column ,
                            sortable: true,
                            width: 100,
                            editor: {
                                xtype:  textfield 
                            }
                        },
                        {
                            xtype:  numbercolumn ,
                            dataIndex:  number ,
                            header:  Column ,
                            sortable: true,
                            width: 100,
                            align:  right ,
                            editor: {
                                xtype:  numberfield 
                            }
                        },
                        {
                            xtype:  datecolumn ,
                            dataIndex:  date ,
                            header:  Column ,
                            sortable: true,
                            width: 100,
                            editor: {
                                xtype:  datefield 
                            }
                        },
                        {
                            xtype:  booleancolumn ,
                            dataIndex:  bool ,
                            header:  Column ,
                            sortable: true,
                            width: 100,
                            editor: {
                                xtype:  checkbox ,
                                boxLabel:  BoxLabel 
                            }
                        }
                        ],
                        tbar: {
                            xtype:  toolbar 
                        }
                    },
                    {
                        xtype:  container 
                    }
                    ]//ledger panel
                }
                ];//this
                MyTabPanelUi.superclass.initComponent.call(this);
            }
        });
    });
});
问题回答

你们需要把它放在一些超文本标签上。 您可使用“财产”使小组进入“机构”或“部分主角”(<代码>id)。

让我假定,你正计划让给机构主。 页: 1 Ext.getBody方法简单地将尸体交还。

MyTabPanelUi = Ext.extend(Ext.TabPanel, {
            activeTab: 0,
            width: 800,
            height: 500,
            renderTo: Ext.getBody(),
            .
            .
            .

你们就是这样做的。

引自:

MyTabPanelUi.render(Ext.getBody());




相关问题
ExtJS load form items/fields from database

I am using ExtJS 3 here. I would like to populate a formpanel from database with fields to be submitted. Basically, I don t know witch fields my form will have and I want to generate all formpanel ...

How to use Ext JS for role based application

I am planning to use Ext JS for a large application. The application s features are role based. When user login, they only see menu and screen features related to them. My server side technology will ...

Dynamically adding a TabPanel to a Panel Region

I have a Panel layout with a TreePanel in one region. A user clicks on an node in the tree and a TabPanel should be displayed in another region with information, editing tools etc. for that tree node....

How to embed Json result within Extjs Panel?

I have some issues with Json result and embed it within the html of the Extjs Panel. Here s that I have managed to get so far. myPanel is embedded within a mainPanel, and I have some shows/hide of ...

Ajax data update. Extjs

I need to keep certain data ( in a grid) up to date and was gonna do a poll to the server every 15 seocnds or so to get the data and refresh the grid, however it feels a bit dirty ( the grid will have ...

Better way to call superclass method in ExtJS

All the ExtJS documentation and examples I have read suggest calling superclass methods like this: MyApp.MyPanel = Ext.extend(Ext.Panel, { initComponent: function() { // do something MyPanel ...

Merged Headers in Ext JS Grid

Is it possible to have two headers in Ext JS grids? I have to show my grid as grouped data.. for example product types and products. In my case I need a grid like this: Field | Product Type A ...

热门标签