Ext.Window:items: [memberForm]
memberForm:items : [gridPanel]
gridPanel:store: fileStore
var fileStore = new Ext.data.JsonStore({
url:'getDocListForCancelAttDoc.do?FILEITEMID='+docId,
baseParams:{command:'query'},
totalProperty:'fileCount',
root:'fileMembers',
//列表字段
fields:fileFields,
pruneModifiedRecords:true
});
最开始设置Ext.Window的closeAction为'hide',每次关闭窗口后,下次加载的store还是原来的,于是每次又添加了store.reload();结果还是一样。
将Ext.Window的closeAction改为'close'后,报Ext.fly()为空或不是对象。
将Ext.Window的定义放到里面后就不报了,暂时做个记录如下:
if(!fileAppendixWindow){
fileAppendixWindow = new Ext.Window({ //修改前的代码,fileAppendixWindow在上面有定义
title:'请选择要取消的文档',
layout:'fit',
resizable:false,
width:500,
height:300,
closable:true,
closeAction:'close',
plain:true,
modal: true,
//窗口中加入文档列表Panel
items: [memberForm]
});
}
if(!fileAppendixWindow){
var fileAppendixWindow = new Ext.Window({ //修改后的代码,fileAppendixWindow在里面定义
title:'请选择要取消的文档',
layout:'fit',
resizable:false,
width:500,
height:300,
closable:true,
closeAction:'close',
plain:true,
modal: true,
//窗口中加入文档列表Panel
items: [memberForm]
});
}