1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-23 22:50:09 +03:00

feature #3748: Add onShow event for tab panels

This commit is contained in:
Daniel Molina 2015-06-08 16:56:45 +02:00
parent e5edf2129c
commit 3c3aa820f9

View File

@ -581,9 +581,17 @@ define(function(require) {
$.each(panelInstances, function(index, panel) {
panel.setup(context);
if (panel.onShow) {
context.off('click', '[href="#' + panel.panelId + '"]');
context.on('click', '[href="#' + panel.panelId + '"]', function(){
panel.onShow(context);
});
}
});
$(document).foundation('reflow', 'tab');
context.foundation('reflow', 'tab');
$('[href=' + activaTabHref + ']', context).trigger("click");
}
//Runs a predefined action. Wraps the calls to opennebula.js and