mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-21 14:50:08 +03:00
B #~: fix Vnet Templates AR (#1078)
Signed-off-by: Frederick Borges <fborges@opennebula.io> (cherry picked from commit bbb3b84b40a3e0e7e0b58c3e576fb11221493ec7)
This commit is contained in:
parent
2ab0fa2943
commit
d1b410901c
@ -273,10 +273,7 @@ define(function(require) {
|
||||
CustomTagsTable.setup($("#vntemplateCreateContextTab", context));
|
||||
|
||||
Foundation.reflow(context, "tabs");
|
||||
|
||||
// Add first AR
|
||||
$("#vnet_wizard_ar_btn", context).trigger("click");
|
||||
|
||||
|
||||
Tips.setup();
|
||||
|
||||
if (config["mode"] === "kvm"){
|
||||
@ -291,7 +288,12 @@ define(function(require) {
|
||||
$("#network_mode option[value=\"ovswitch_vxlan\"]", context).hide();
|
||||
}
|
||||
|
||||
$("#vntemplateCreateARTab ul#vnet_wizard_ar_tabs i.remove-tab", context).trigger("click");
|
||||
// Remove AR given for errors
|
||||
if ($("#vntemplateCreateARTab #ar0Tab").length && $("#vntemplateCreateARTab #ar_tabar0").length){
|
||||
$("#vntemplateCreateARTab #ar0Tab").remove();
|
||||
}
|
||||
|
||||
$("#vntemplateCreateARTab #vnet_wizard_ar_btn", context).click();
|
||||
|
||||
return false;
|
||||
}
|
||||
@ -325,11 +327,12 @@ define(function(require) {
|
||||
|
||||
|
||||
// close icon: removing the tab on click
|
||||
a.on("click", "i.remove-tab", function() {
|
||||
a.on("click", "i.remove-tab", function(e) {
|
||||
e.stopPropagation();
|
||||
var target = $(this).parent().attr("href");
|
||||
var li = $(this).closest("li");
|
||||
var ul = $(this).closest("ul");
|
||||
var content = $(target);
|
||||
var content = $("#vntemplateCreateARTab " + target);
|
||||
|
||||
var ar_id = content.attr("ar_id");
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user