mirror of
https://github.com/OpenNebula/one.git
synced 2025-01-27 14:03:40 +03:00
Even if it is deprecated in OneProvision, it is still needed in the VNF appliance. * Re-added to Sunstone * More descriptive and specific name and hint
This commit is contained in:
parent
c8943e8b83
commit
9cbf09e122
@ -204,7 +204,7 @@ define(function(require) {
|
|||||||
nicTab.fill(nicContext, nicJSON);
|
nicTab.fill(nicContext, nicJSON);
|
||||||
|
|
||||||
if (nicJSON.PARENT) {
|
if (nicJSON.PARENT) {
|
||||||
nicTab.fill_alias(nicJSON.PARENT);
|
nicTab.fill_alias(nicJSON.PARENT, nicJSON.EXTERNAL);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -449,6 +449,10 @@ define(function(require) {
|
|||||||
delete nicJSON["PARENT"];
|
delete nicJSON["PARENT"];
|
||||||
} else {
|
} else {
|
||||||
nicJSON["PARENT"] = $("#" + this.nicTabId + "_alias_parent", context).val();
|
nicJSON["PARENT"] = $("#" + this.nicTabId + "_alias_parent", context).val();
|
||||||
|
|
||||||
|
if ($("#" + this.nicTabId + "_alias_external", context).is(':checked')) {
|
||||||
|
nicJSON["EXTERNAL"] = 'YES';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if($("input#" + this.nicTabId + "_rdp", context).prop("checked")) {
|
if($("input#" + this.nicTabId + "_rdp", context).prop("checked")) {
|
||||||
|
@ -35,6 +35,18 @@
|
|||||||
</span>
|
</span>
|
||||||
<select id="{{nicTabId}}_alias_parent" style="width: 200px; margin-left: 5px"></select>
|
<select id="{{nicTabId}}_alias_parent" style="width: 200px; margin-left: 5px"></select>
|
||||||
</div>
|
</div>
|
||||||
|
<div id="{{nicTabId}}_alias_external_wrapper" style="min-height: 40px;">
|
||||||
|
<div class="switch left">
|
||||||
|
<input class="switch-input" id="{{nicTabId}}_alias_external" type="checkbox">
|
||||||
|
<label class="switch-paddle" for="{{nicTabId}}_alias_external">
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
<label class="left">
|
||||||
|
|
||||||
|
{{tr "Skip network contextualizacion"}}
|
||||||
|
{{{tip (tr "A virtual router can be configured to route SDNAT traffic for this NIC IP address")}}}
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
<fieldset class="small-12 large-6 columns">
|
<fieldset class="small-12 large-6 columns">
|
||||||
<legend style="margin:0px;">{{tr "Network selection"}}</legend>
|
<legend style="margin:0px;">{{tr "Network selection"}}</legend>
|
||||||
|
@ -108,6 +108,10 @@ define(function(require) {
|
|||||||
else{
|
else{
|
||||||
if($("#cb_attach_alias", context).prop("checked")) {
|
if($("#cb_attach_alias", context).prop("checked")) {
|
||||||
templateJSON.PARENT = $("#parent").val();
|
templateJSON.PARENT = $("#parent").val();
|
||||||
|
|
||||||
|
if ($('#cb_external').is(':checked')) {
|
||||||
|
templateJSON.EXTERNAL = 'YES'
|
||||||
|
}
|
||||||
|
|
||||||
obj = {
|
obj = {
|
||||||
"NIC_ALIAS": templateJSON
|
"NIC_ALIAS": templateJSON
|
||||||
|
@ -35,6 +35,11 @@
|
|||||||
<select id="parent" style="width: 200px; margin-bottom: 0;"></select>
|
<select id="parent" style="width: 200px; margin-bottom: 0;"></select>
|
||||||
<br>
|
<br>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="attach_external" style="min-height: 50px;">
|
||||||
|
<label>
|
||||||
|
<input type="checkbox" id="cb_external" style="margin-left: 15px"> {{tr "External"}}
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
{{{nicTabHTML}}}
|
{{{nicTabHTML}}}
|
||||||
<div class="reveal-footer">
|
<div class="reveal-footer">
|
||||||
<div class="form_buttons">
|
<div class="form_buttons">
|
||||||
|
@ -171,11 +171,17 @@ define(function(require) {
|
|||||||
if($("input#" + that.id + "_interface_type", context).prop("checked")) {
|
if($("input#" + that.id + "_interface_type", context).prop("checked")) {
|
||||||
if ($("#" + that.id + "_alias_parent", context).val() != "INVALID") {
|
if ($("#" + that.id + "_alias_parent", context).val() != "INVALID") {
|
||||||
nic["PARENT"] = $("#" + that.id + "_alias_parent", context).val();
|
nic["PARENT"] = $("#" + that.id + "_alias_parent", context).val();
|
||||||
|
|
||||||
|
if ($("#" + that.id + "_alias_external", context).is(':checked')) {
|
||||||
|
nic["EXTERNAL"] = 'YES';
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
delete nic["PARENT"];
|
delete nic["PARENT"];
|
||||||
|
delete nic["EXTERNAL"];
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
delete nic["PARENT"];
|
delete nic["PARENT"];
|
||||||
|
delete nic["EXTERNAL"];
|
||||||
}
|
}
|
||||||
|
|
||||||
(Boolean($("input#" + that.id + "_rdp", context).prop("checked")))
|
(Boolean($("input#" + that.id + "_rdp", context).prop("checked")))
|
||||||
@ -555,7 +561,7 @@ define(function(require) {
|
|||||||
Foundation.reInit(context);
|
Foundation.reInit(context);
|
||||||
|
|
||||||
if(options.nic && options.nic.PARENT) {
|
if(options.nic && options.nic.PARENT) {
|
||||||
_fill_alias(options.nic.PARENT);
|
_fill_alias(options.nic.PARENT, options.nic.EXTERNAL);
|
||||||
}
|
}
|
||||||
|
|
||||||
// fill rdp connection
|
// fill rdp connection
|
||||||
@ -722,7 +728,7 @@ define(function(require) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function _fill_alias(nicParentName) {
|
function _fill_alias(nicParentName, isExternal) {
|
||||||
$.each(_nics, function(_, value) {
|
$.each(_nics, function(_, value) {
|
||||||
if (value.NAME === ("NIC" + nicId)) {
|
if (value.NAME === ("NIC" + nicId)) {
|
||||||
value.ALIAS = nicParentName;
|
value.ALIAS = nicParentName;
|
||||||
@ -734,6 +740,10 @@ define(function(require) {
|
|||||||
$("#provision_accordion_dd_" + provision_nic_accordion_dd_id + "_alias_parent", this.context).click();
|
$("#provision_accordion_dd_" + provision_nic_accordion_dd_id + "_alias_parent", this.context).click();
|
||||||
$("#provision_accordion_dd_" + provision_nic_accordion_dd_id + "_interface_type", this.context).click();
|
$("#provision_accordion_dd_" + provision_nic_accordion_dd_id + "_interface_type", this.context).click();
|
||||||
$("#provision_accordion_dd_" + provision_nic_accordion_dd_id + "_alias_parent", this.context).val(nicParentName);
|
$("#provision_accordion_dd_" + provision_nic_accordion_dd_id + "_alias_parent", this.context).val(nicParentName);
|
||||||
|
|
||||||
|
if (isExternal && String(isExternal).toLowerCase() === 'yes') {
|
||||||
|
$("#provision_accordion_dd_" + provision_nic_accordion_dd_id + "_alias_external", this.context).prop('checked', 'checked');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function _hide_remove() {
|
function _hide_remove() {
|
||||||
|
@ -43,6 +43,18 @@
|
|||||||
</span>
|
</span>
|
||||||
<select id="provision_accordion_dd_{{provision_nic_accordion_dd_id}}_alias_parent" style="width: 200px; margin-left: 5px"></select>
|
<select id="provision_accordion_dd_{{provision_nic_accordion_dd_id}}_alias_parent" style="width: 200px; margin-left: 5px"></select>
|
||||||
</div>
|
</div>
|
||||||
|
<div id="provision_accordion_dd_{{provision_nic_accordion_dd_id}}_alias_external_wrapper" style="min-height: 40px;">
|
||||||
|
<div class="switch left">
|
||||||
|
<input class="switch-input" id="provision_accordion_dd_{{provision_nic_accordion_dd_id}}_alias_external" type="checkbox">
|
||||||
|
<label class="switch-paddle" for="provision_accordion_dd_{{provision_nic_accordion_dd_id}}_alias_external">
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
<label class="left">
|
||||||
|
|
||||||
|
{{tr "Skip network contextualizacion"}}
|
||||||
|
{{{tip (tr "A virtual router can be configured to route SDNAT traffic for this NIC IP address")}}}
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{#if displaySelection}}
|
{{#if displaySelection}}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user