NO WAI! :P
Code:
onTreeSelect : function(view, record, item, index, e, eOpts){
var data=record.data;
if(data.leaf==true){
var intId=data.id.replace(/tree_item_/,'')
var tabbar=this.getTopTabbar();
var activetab=tabbar.getActiveTab()
activetab.getEl().mask('test');
this.getMessagePanel().update('<p class="details-info">Nachrichten für Modul <b>'+data.text+'</b></p>')
if(intId=='ag_verwaltung'){
this.getController('AgSuche')
activetab.setTitle(data.text)
activetab.removeAll();
activetab.add({
border:false,
items:[{
xtype:'agsuche'
}],
listeners:{
close: function() {
this.removeAll(true);
Ext.getStore('Agencies').removeAll();
if(typeof(Ext.getStore('CRSItems'))!='undefined')
Ext.getStore('CRSItems').removeAll();
if(typeof(Ext.getStore('BankData'))!='undefined')
Ext.getStore('BankData').removeAll();
if(typeof(Ext.getStore('Employees'))!='undefined')
Ext.getStore('Employees').removeAll();
if(typeof(Ext.getStore('Provisions'))!='undefined')
Ext.getStore('Provisions').removeAll();
}
}
}).show();
}
else if(intId=='stammdaten_verpflegungsarten'){
this.getController('Stammdaten.Verpflegungsarten')
activetab.setTitle(data.text)
activetab.removeAll();
activetab.add({
border:false,
items:[{
xtype:'stammdaten_verpflegungsarten'
}]}).show();
}
else{
activetab.removeAll();
activetab.setTitle(data.text)
activetab.add({
closable: true,
border:false,
title: data.text,
html:'<h1>'+data.text+'</h1>'+"<hr>To be implemented"
}).show();
}
activetab.doLayout();
activetab.getEl().unmask();
}else{
if(record.isExpanded()){
this.getModuleTree().collapseNode(record);
}else{
this.getModuleTree().expandNode(record);
}
}
},
onTreeSelect is called when a tree item is selected and basically fills the "content area" (=right side) of the active tab (see picture)
screen1.jpg