Updated command module tree, folders expand upon click

git-svn-id: https://beef.googlecode.com/svn/trunk@634 b87d56ec-f9c0-11de-8c8a-61c5e9addfc9
This commit is contained in:
xntrik
2010-12-23 05:46:50 +00:00
parent fe4ece8715
commit bf43a0e8be

View File

@@ -75,20 +75,22 @@ ZombieTab_Commands = function(zombie) {
}),
listeners: {
'click': function(node) {
if(!node.leaf) return;
commands_statusbar.showBusy('Loading ' + node.text);
command_module_grid.i = 0;
command_module_grid.store.baseParams = {command_module_id: node.attributes.id, zombie_session: zombie.session};
command_module_grid.store.reload({ //reload the command module grid
params: { // insert the nonce with the request to reload the grid
nonce: Ext.get ("nonce").dom.value
}
});
genNewExploitPanel(command_module_config, node.id, node.text, zombie, commands_statusbar);
commands_statusbar.showValid('Ready');
if(!node.leaf) {
node.toggle();
} else {
commands_statusbar.showBusy('Loading ' + node.text);
command_module_grid.i = 0;
command_module_grid.store.baseParams = {command_module_id: node.attributes.id, zombie_session: zombie.session};
command_module_grid.store.reload({ //reload the command module grid
params: { // insert the nonce with the request to reload the grid
nonce: Ext.get ("nonce").dom.value
}
});
genNewExploitPanel(command_module_config, node.id, node.text, zombie, commands_statusbar);
commands_statusbar.showValid('Ready');
}
},
'afterrender' : function() {
}
@@ -126,4 +128,4 @@ ZombieTab_Commands = function(zombie) {
var sb = Ext.getCmp('command-module-bbar-zombie-'+zombie.session);
};
Ext.extend(ZombieTab_Commands, Ext.Panel, {});
Ext.extend(ZombieTab_Commands, Ext.Panel, {});