Skip to content

Commit

Permalink
Fixes for re-activate tabs in Configuration (#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
vmalyk authored and fashxp committed Jan 20, 2020
1 parent 918babe commit 39c3d94
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ pimcore.plugin.alternateObjectTrees.config.item = Class.create({
}
},


addLayout: function () {

this.editpanel = new Ext.Panel({
Expand Down Expand Up @@ -184,13 +183,11 @@ pimcore.plugin.alternateObjectTrees.config.item = Class.create({
autoScroll: true,
bodyStyle: "padding: 20px;",
title: this.data.name,
// iconCls: 'pimcore_panel_tree_objects_alternate_tree_custom_' + this.data.id,
// id: "plugin_alternate_object_trees_config_panel_" + this.data.name,
id: "plugin_alternate_object_trees_config_panel_" + this.data.id,
items: [this.settings, this.itemContainer],
buttons: panelButtons
});


this.parentPanel.getEditPanel().add(this.panel);
this.parentPanel.getEditPanel().setActiveItem(this.panel);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ pimcore.plugin.alternateObjectTrees.config.panel = Class.create({

activate: function () {
var tabPanel = Ext.getCmp("pimcore_panel_tabs");
tabPanel.activate("plugin_alternate_object_trees_config");
tabPanel.setActiveItem("plugin_alternate_object_trees_config");
},

getTabPanel: function () {
Expand Down Expand Up @@ -145,7 +145,7 @@ pimcore.plugin.alternateObjectTrees.config.panel = Class.create({

var existingPanel = Ext.getCmp("plugin_alternate_object_trees_config_panel_" + id);
if (existingPanel) {
this.editPanel.activate(existingPanel);
this.editPanel.setActiveItem(existingPanel);
return;
}

Expand Down Expand Up @@ -240,4 +240,3 @@ pimcore.plugin.alternateObjectTrees.config.panel = Class.create({
this.tree.getStore().remove(model);
}
});

0 comments on commit 39c3d94

Please sign in to comment.