我是 Sencha Touch 的新手。我有一个必须改进的现有 Web 应用程序。
我创建了一个新面板并尝试将项目添加到现有面板,但尝试将 NULL 元素添加为 Container itemId/id 的子项时出现错误:ext-comp-1050
我的代码如下
Myapp.views.mainView = new Ext.extend(Ext.Panel, {
initComponent: function() {
this.items = [
Myapp.views.welcomePanel, // new panel I am trying to add
Myapp.views.settingsView,
Myapp.views.placePopup,
Myapp.views.newsPanel
];
this.dockedItems = [];
this.cardAnimation='slide';
this.html = null;
this.fullscreen = true;
this.layout = 'card';
this.align = 'stretch';
Myapp.views.mainView.superclass.initComponent.call(this);
}
});
欢迎面板的代码是
Myapp.views.welcomePanel = new Ext.Panel({
frame:true,
autoHeight:true,
collapsible:true,
layout:'card',
items:[
Myapp.views.mapPlaces,
Myapp.views.listOfPlaces
],
dockedItems:[
Myapp.views.mainToolBar,
Myapp.views.changerPanelsToolbar
]
});
Myapp.views.mapPlaces, Myapp.views.listOfPlaces, Myapp.views.mainToolBar, Myapp.views.changerPanelsToolbar
已经存在并且可以正常工作
请帮忙