extjs一个Panel两个grid,上下承接的
2个回答
展开全部
用vbox布局,当然,border布局也可以
Ext.create('Ext.Panel', {
width: 500,
height: 400,
title: "VBoxLayout Panel",
layout: {
type: 'vbox',
align: 'center'
},
renderTo: document.body,
items: [{
xtype: 'panel',//你要加的gridpanel
title: 'Inner Panel One',
width: 250,
flex: 2
},
{
xtype: 'panel',,//你要加的gridpanel
title: 'Inner Panel Two',
width: 250,
flex: 4
]
});
Ext.create('Ext.Panel', {
width: 500,
height: 400,
title: "VBoxLayout Panel",
layout: {
type: 'vbox',
align: 'center'
},
renderTo: document.body,
items: [{
xtype: 'panel',//你要加的gridpanel
title: 'Inner Panel One',
width: 250,
flex: 2
},
{
xtype: 'panel',,//你要加的gridpanel
title: 'Inner Panel Two',
width: 250,
flex: 4
]
});
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询