incubator-cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jessicaw...@apache.org
Subject git commit: CS-16407: cloudstack UI - Infrastructure page - total number of Virtual Routers should include both project type and account type.
Date Thu, 27 Sep 2012 19:14:19 GMT
Updated Branches:
  refs/heads/master 220107c93 -> b88580963


CS-16407: cloudstack UI - Infrastructure page - total number of Virtual Routers should include
both project type and account type.


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

Branch: refs/heads/master
Commit: b885809638dc376a998a03c6852b4c11ee64d16b
Parents: 220107c
Author: Jessica Wang <jessica.wang@citrix.com>
Authored: Thu Sep 27 12:12:40 2012 -0700
Committer: Jessica Wang <jessica.wang@citrix.com>
Committed: Thu Sep 27 12:13:52 2012 -0700

----------------------------------------------------------------------
 ui/scripts/system.js |   19 ++++++++++++++-----
 1 files changed, 14 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/b8858096/ui/scripts/system.js
----------------------------------------------------------------------
diff --git a/ui/scripts/system.js b/ui/scripts/system.js
index 3759229..7b242bc 100644
--- a/ui/scripts/system.js
+++ b/ui/scripts/system.js
@@ -273,13 +273,22 @@
             $.ajax({
               url: createURL('listRouters'),
               data: {
-                listAll: true
+                projectid: -1
               },
               success: function(json) {
-                dataFns.capacity($.extend(data, {
-                  virtualRouterCount: json.listroutersresponse.count ?
-                    json.listroutersresponse.count : 0
-                }));
+                var total1 = json.listroutersresponse.count ? json.listroutersresponse.count
: 0;								
+								$.ajax({
+								  url: createURL('listRouters'),
+									data: {
+									  listAll: true
+									},
+									success: function(json) {
+									  var total2 = json.listroutersresponse.count ? json.listroutersresponse.count :
0;		
+										dataFns.capacity($.extend(data, {
+											virtualRouterCount: (total1 + total2)
+										}));																	
+									}									
+								});										
               }
             });
           },


Mime
View raw message