CLOUDSTACK-1008:Egress tab should not be presented in the UI for Shared Networks

Signed-off-by: Pranav Saxena <pranav.saxena@citrix.com>
This commit is contained in:
Pranav Saxena 2013-03-26 16:02:19 +05:30 committed by Chip Childers
parent e46601463c
commit af442f7621
1 changed files with 14 additions and 1 deletions

View File

@ -807,6 +807,7 @@
var hasSRXFirewall = false;
var isVPC = false;
var isAdvancedSGZone = false;
var type;
var hiddenTabs = [];
// Get network offering data
@ -862,12 +863,24 @@
isAdvancedSGZone = zone.securitygroupsenabled;
}
});
$.ajax({
url:createURL('listNetworks'),
data:{ id:args.context.networks[0].id },
async:false,
success:function(json){
type = json.listnetworksresponse.network[0].type;
}
});
if (!networkOfferingHavingELB) {
hiddenTabs.push("addloadBalancer");
}
if (isVPC || isAdvancedSGZone || hasSRXFirewall) {
if (isVPC || isAdvancedSGZone || hasSRXFirewall || type="Shared") {
hiddenTabs.push('egressRules');
}