cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bfede...@apache.org
Subject git commit: updated refs/heads/ui-vpc-redesign to 612ce62
Date Wed, 15 May 2013 22:33:16 GMT
Updated Branches:
  refs/heads/ui-vpc-redesign 81bce385b -> 612ce62ca


Add tier VM, PF, static NAT links


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/612ce62c
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/612ce62c
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/612ce62c

Branch: refs/heads/ui-vpc-redesign
Commit: 612ce62cae8408cdf66aaab339c1cc387b4bf9b1
Parents: 81bce38
Author: Brian Federle <bfederle@gmail.com>
Authored: Wed May 15 15:33:13 2013 -0700
Committer: Brian Federle <bfederle@gmail.com>
Committed: Wed May 15 15:33:13 2013 -0700

----------------------------------------------------------------------
 ui/modules/vpc/vpc.js   |   11 ++++++-----
 ui/scripts/instances.js |    8 ++++++++
 ui/scripts/vpc.js       |   20 ++++++++++++++++++++
 3 files changed, 34 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/612ce62c/ui/modules/vpc/vpc.js
----------------------------------------------------------------------
diff --git a/ui/modules/vpc/vpc.js b/ui/modules/vpc/vpc.js
index 5c93e6c..64081a8 100644
--- a/ui/modules/vpc/vpc.js
+++ b/ui/modules/vpc/vpc.js
@@ -18,7 +18,9 @@
   var elems = {
     tier: function(args) {
       var tier = args.tier;
-      var context = args.context;
+      var context = $.extend(true, {}, args.context, {
+        networks: [tier]
+      });
       var dashboardItems = args.dashboardItems;
       var $tier = $('<div>').addClass('tier-item');
       var $header = $('<div>').addClass('header');
@@ -41,9 +43,7 @@
             var $detailView = $('<div>').detailView(
               $.extend(true, {}, cloudStack.vpc.tiers.detailView, {
                 $browser: $browser,
-                context: $.extend(true, {}, context, {
-                  networks: [tier]
-                }),
+                context: context,
                 onActionComplete: function() {
                   $tier.closest('.vpc-network-chart').trigger('reload');
                 }
@@ -153,6 +153,7 @@
     dashboard: function(args) {
       var $dashboard = $('<div>').addClass('dashboard');
       var context = args.context;
+      var tier = context.networks[0];
 
       $(args.dashboardItems).map(function(index, dashboardItem) {
         var $dashboardItem = $('<div>').addClass('dashboard-item');
@@ -167,7 +168,7 @@
 
         $dashboardItem.click(function() {
           $('#browser .container').cloudBrowser('addPanel', {
-            title: dashboardItem.name,
+            title: tier.name + ' - ' + dashboardItem.name,
             maximizeIfSelected: true,
             complete: function($panel) {
               var section = cloudStack.vpc.sections[id];

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/612ce62c/ui/scripts/instances.js
----------------------------------------------------------------------
diff --git a/ui/scripts/instances.js b/ui/scripts/instances.js
index c76d843..31237a8 100644
--- a/ui/scripts/instances.js
+++ b/ui/scripts/instances.js
@@ -204,6 +204,14 @@
 					  affinitygroupid: args.context.affinityGroups[0].id
 					});		
 				}
+
+        if("vpc" in args.context &&
+           "networks" in args.context) {
+          $.extend(data, {
+            vpcid: args.context.vpc[0].id,
+            networkid: args.context.networks[0].id
+          });
+        }
               
         $.ajax({
           url: createURL('listVirtualMachines'),

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/612ce62c/ui/scripts/vpc.js
----------------------------------------------------------------------
diff --git a/ui/scripts/vpc.js b/ui/scripts/vpc.js
index cbb3a6f..1e3efb7 100644
--- a/ui/scripts/vpc.js
+++ b/ui/scripts/vpc.js
@@ -294,6 +294,26 @@
   cloudStack.vpc = {
     // nTier sections
     sections: {
+      tierVMs: function() {
+        var list = $.extend(true, {}, cloudStack.sections.instances);
+
+        list.listView.actions.add.action.custom = cloudStack.uiCustom.instanceWizard(
+          $.extend(true, {}, cloudStack.instanceWizard, {
+            pluginForm: { name: 'vpcTierInstanceWizard' }
+          })
+        );
+        
+        return list;
+      },
+
+      tierPortForwarders: function() {
+        return cloudStack.vpc.ipAddresses.listView();
+      },
+
+      tierStaticNATs: function() {
+        return cloudStack.vpc.ipAddresses.listView();
+      },
+      
       // Internal load balancers
       tierLoadBalancers: {
         listView: {


Mime
View raw message