mirror of https://github.com/apache/cloudstack.git
CS-16147: Always show VPC section and VPN customer Gateway if advanced zone is present
This commit is contained in:
parent
ad78a0e918
commit
d134a63ea8
|
|
@ -165,8 +165,9 @@
|
|||
preFilter: function(args) {
|
||||
var havingSecurityGroupNetwork = false;
|
||||
var havingBasicZones = false;
|
||||
var havingAdvancedZones = true;
|
||||
|
||||
// Get basic zones
|
||||
// Get zone types
|
||||
$.ajax({
|
||||
url: createURL('listZones'),
|
||||
async: false,
|
||||
|
|
@ -176,9 +177,14 @@
|
|||
var basicZones = $.grep(zones, function(zone) {
|
||||
return zone.networktype == 'Basic';
|
||||
});
|
||||
var advancedZones = $.grep(zones, function(zone) {
|
||||
return zone.networktype == 'Advanced';
|
||||
});
|
||||
|
||||
|
||||
havingBasicZones = basicZones.length ? true : false;
|
||||
}
|
||||
havingAdvancedZones = advancedZones.length ? true : false;
|
||||
}
|
||||
});
|
||||
|
||||
$.ajax({
|
||||
|
|
@ -197,7 +203,7 @@
|
|||
|
||||
var sectionsToShow = ['networks'];
|
||||
|
||||
if (!havingBasicZones) {
|
||||
if (havingAdvancedZones) {
|
||||
sectionsToShow.push('vpc');
|
||||
sectionsToShow.push('vpnCustomerGateway');
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue