现在我想根据Panel内的form按提交按钮添加组件,但是doLayout了之后一直不render,为什么doLayout无效呢
buttons : [{
text : "提交",
handler : function() {
if (!this.grid) {
this.store = new Ext.data.JsonStore({
id : "id",
url : "WzxwReport.do?step=step0",
root : "result",
totalProperty : "rowCount",
remoteSort : true,
fields : this.storeMapping
});
this.grid = new Ext.grid.GridPanel({
id : 'gd',
title : "结果列表",
store : this.store,
cm : this.cm,
trackMouseOver : false,
loadMask : true,
region : "south",
bbar : new Ext.PagingToolbar({
pageSize : this.pageSize,
store : this.store,
displayInfo : true,
displayMsg : '记录 {0} - {1} of {2}',
emptyMsg : "没有数据记录"
})
});
this.add(this.grid);
this.doLayout();
}