diff --git a/ui/scripts/domains.js b/ui/scripts/domains.js index e82f8ff44e8..01f4236289b 100644 --- a/ui/scripts/domains.js +++ b/ui/scripts/domains.js @@ -435,6 +435,9 @@ ], dataProvider: function(args) { var domainObj = args.context.domains[0]; + var totalVMs=0; + var totalVolumes=0; + $.ajax({ url: createURL("listAccounts&domainid=" + domainObj.id), async: false, @@ -443,26 +446,39 @@ }, success: function(json) { var items = json.listaccountsresponse.account; - var total; - if (items != null) - total = items.length; - else - total = 0; - domainObj["accountTotal"] = total; - var itemsAcc; - var totalVMs=0; - var totalVolumes=0; - for(var i=0;i