diff --git a/ui/jsp/instance.jsp b/ui/jsp/instance.jsp index 2b35f6cb7d8..ccec2ef7dec 100644 --- a/ui/jsp/instance.jsp +++ b/ui/jsp/instance.jsp @@ -139,8 +139,20 @@
- +
+
+
+ <%=t.t("OS.Type")%>:
+
+
+
+
+ +
+
+
<%=t.t("Service")%>:
@@ -150,7 +162,7 @@
-
+
<%=t.t("HA.Enabled")%>:
@@ -164,7 +176,7 @@
-
+
<%=t.t("Created")%>:
@@ -174,7 +186,7 @@
-
+
<%=t.t("Account")%>:
@@ -184,7 +196,7 @@
-
+
<%=t.t("Domain")%>:
@@ -194,7 +206,7 @@
-
+
<%=t.t("Host")%>:
@@ -204,7 +216,7 @@
-
+
<%=t.t("ISO.attached")%>:
@@ -214,7 +226,7 @@
-
+
<%=t.t("Group")%>:
diff --git a/ui/scripts/cloud.core.instance.js b/ui/scripts/cloud.core.instance.js index d9b1084db82..7199618bad0 100644 --- a/ui/scripts/cloud.core.instance.js +++ b/ui/scripts/cloud.core.instance.js @@ -88,6 +88,7 @@ function instanceBuildSubMenu2(label, commandString) { var $doTemplateNo, $doTemplateCustom,$doTemplateExisting, $soTemplate; var init = false; var $selectedVmWizardTemplate; +var osTypeMap = {}; function afterLoadInstanceJSP() { if (!init) { //initialize VM Wizard @@ -132,6 +133,20 @@ function afterLoadInstanceJSP() { initDialog("dialog_confirmation_start_router"); initDialog("dialog_confirmation_stop_router"); initDialog("dialog_confirmation_reboot_router"); + + $.ajax({ + data: createURL("command=listOsTypes"), + dataType: "json", + async: false, + success: function(json) { + types = json.listostypesresponse.ostype; + if (types != null && types.length > 0) { + for (var i = 0; i < types.length; i++) { + osTypeMap[types[i].id] = fromdb(types[i].description); + } + } + } + }); } function bindStartVMButton() { @@ -1536,6 +1551,10 @@ function vmJsonToDetailsTab(){ $thisTab.find("#ipaddress").text(fromdb(jsonObj.ipaddress)); $thisTab.find("#templateName").text(fromdb(jsonObj.templatename)); + + $thisTab.find("#ostypename").text(osTypeMap[fromdb(jsonObj.guestosid)]); + $thisTab.find("#ostypename_edit").val(fromdb(jsonObj.guestosid)); + $thisTab.find("#serviceOfferingName").text(fromdb(jsonObj.serviceofferingname)); $thisTab.find("#account").text(fromdb(jsonObj.account)); $thisTab.find("#domain").text(fromdb(jsonObj.domain)); diff --git a/ui/scripts/cloud.core.iso.js b/ui/scripts/cloud.core.iso.js index 88eaf938058..1f8f5aa12a7 100644 --- a/ui/scripts/cloud.core.iso.js +++ b/ui/scripts/cloud.core.iso.js @@ -94,6 +94,7 @@ function initAddIsoDialog() { $.ajax({ data: createURL("command=listOsTypes"), dataType: "json", + async: false, success: function(json) { types = json.listostypesresponse.ostype; if (types != null && types.length > 0) { diff --git a/ui/scripts/cloud.core.template.js b/ui/scripts/cloud.core.template.js index 547ff38da62..ad4b9af1c21 100644 --- a/ui/scripts/cloud.core.template.js +++ b/ui/scripts/cloud.core.template.js @@ -166,6 +166,7 @@ function afterLoadTemplateJSP() { $.ajax({ data: createURL("command=listOsTypes&response=json"), dataType: "json", + async: false, success: function(json) { types = json.listostypesresponse.ostype; if (types != null && types.length > 0) {