From 0b127c0aeb57fc5f17441783636c3aa363138cff Mon Sep 17 00:00:00 2001 From: Jessica Wang Date: Thu, 3 Mar 2011 17:41:53 -0800 Subject: [PATCH] Zone Tree - zone arrow should be always expandable since there is always a secondary storage node under it. --- ui/index.jsp | 2 +- ui/scripts/cloud.core.resource.js | 19 +++++-------------- 2 files changed, 6 insertions(+), 15 deletions(-) diff --git a/ui/index.jsp b/ui/index.jsp index 1c41ca3a9b5..37709fc1ac7 100644 --- a/ui/index.jsp +++ b/ui/index.jsp @@ -849,7 +849,7 @@
-
+
: diff --git a/ui/scripts/cloud.core.resource.js b/ui/scripts/cloud.core.resource.js index e4ff669132e..ff6ca1516c3 100644 --- a/ui/scripts/cloud.core.resource.js +++ b/ui/scripts/cloud.core.resource.js @@ -334,25 +334,16 @@ function zoneJSONToTreeNode(jsonObj, $zoneNode) { $zoneNode.data("jsonObj", jsonObj); $zoneNode.find("#secondarystorage_header").data("zoneObj", jsonObj); - if(jsonObj.networktype == "Advanced") { + if(jsonObj.networktype == "Advanced") { //Advanced Zone $zoneNode.find("#network_header").show().data("jsonObj", jsonObj); } + else { //Basic Zone + $zoneNode.find("#network_header").hide(); + } $zoneNode.data("id", zoneid).data("name", fromdb(jsonObj.name)); var zoneName = $zoneNode.find("#zone_name").text(fromdb(jsonObj.name)); - zoneName.data("jsonObj", jsonObj); - - $.ajax({ - data: createURL("command=listPods&zoneid="+zoneid), - dataType: "json", - async: false, - success: function(json) { - var items = json.listpodsresponse.pod; - if (items != null && items.length > 0) { - $zoneNode.find("#zone_arrow").removeClass("white_nonexpanded_close").addClass("expanded_close"); - } - } - }); + zoneName.data("jsonObj", jsonObj); } function podJSONToTreeNode(json, $podNode) {