Javascript

示例

Ext.create('Ext.tab.Panel', {
    width: "100%",
    renderTo: "tabBox",
    items: [
        {
            title: "权限查询",
            items: [
                Ext.getCmp("TbRightPanel") //将组件放进tab
            ]
        },
        {
            title: "配置员工权限",
            items: [
                        
            ]
        }
    ]
});

 

配置

bodyPadding:number
//内边距

disabled:bool
//禁用

activeTab:index | Ext.Component
//默认激活哪一个选项卡
View Code

子项配置 

itemId:string
//id

bodyPadding:number
//内边距

hidden:bool
//被隐藏

html:string
//内容

closable: bool
//可关闭

tabIndex:number
//自定索引
View Code

方法

setActiveTab(tabId | tabIndex | Ext.Component)
//设置默认激活参数指定的选项卡组件,返回这个选项卡组件

getActiveTab()
//获取被激活的选项卡组件

remove(tabId | tabIndex | Ext.Component)
//移除参数指定的选项卡组件
View Code

 

原文地址:https://www.cnblogs.com/myrocknroll/p/7455043.html