/ Published in: Other
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
/** * Create new tab only if it does not exist before */ // Show tab way HO.Class.CRUD.prototype.showTab = function (id,name) { HO.log("HO.Class.CRUD.showTab " + id + " " + name); var tabID = this.ComponentName + id; var tab = this.TabPanel.items.find(function(i){ return i.id === tabID; }) if (!tab) { showObject = this.getShowObject(id,tabID, name); this.TabPanel.add( showObject ).show(); // x = {title: "dupa", layout: 'fit', items: [showObject] // ,autoScroll : true // ,bodyStyle : 'position:relative' // // } // // this.TabPanel.add( x ).show(); } else { HO.log('tab exists'); this.TabPanel.setActiveTab(tabID); } } // eo function showTab