Return-Path: X-Original-To: apmail-cloudstack-commits-archive@www.apache.org Delivered-To: apmail-cloudstack-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1BC73FEA1 for ; Tue, 26 Mar 2013 14:32:43 +0000 (UTC) Received: (qmail 44840 invoked by uid 500); 26 Mar 2013 14:32:42 -0000 Delivered-To: apmail-cloudstack-commits-archive@cloudstack.apache.org Received: (qmail 44823 invoked by uid 500); 26 Mar 2013 14:32:42 -0000 Mailing-List: contact commits-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list commits@cloudstack.apache.org Received: (qmail 44816 invoked by uid 99); 26 Mar 2013 14:32:42 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Mar 2013 14:32:42 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id A006A820C02; Tue, 26 Mar 2013 14:32:42 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: pranavs@apache.org To: commits@cloudstack.apache.org Date: Tue, 26 Mar 2013 14:32:42 -0000 Message-Id: X-Mailer: ASF-Git Admin Mailer Subject: [1/3] git commit: refs/heads/4.1 - CLOUDSTACK-1008:Egress tab should not be presented in the UI for Shared Networks Updated Branches: refs/heads/4.1 af442f762 -> 66fe03429 CLOUDSTACK-1008:Egress tab should not be presented in the UI for Shared Networks Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/e1a9062e Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/e1a9062e Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/e1a9062e Branch: refs/heads/4.1 Commit: e1a9062e1c5d27e5b7a63d4f00c783112a1d3558 Parents: e33ab6e Author: Pranav Saxena Authored: Tue Mar 26 16:02:19 2013 +0530 Committer: Pranav Saxena Committed: Tue Mar 26 16:02:19 2013 +0530 ---------------------------------------------------------------------- ui/scripts/network.js | 15 ++++++++++++++- 1 files changed, 14 insertions(+), 1 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/e1a9062e/ui/scripts/network.js ---------------------------------------------------------------------- diff --git a/ui/scripts/network.js b/ui/scripts/network.js index 84cc067..9bd0857 100755 --- a/ui/scripts/network.js +++ b/ui/scripts/network.js @@ -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'); }