Adding some prelim UI to support multiple hypervisors in the hybrid branch

This commit is contained in:
will 2010-09-16 18:07:02 -07:00 committed by edison
parent 8943cc6745
commit 67cc587603
4 changed files with 29 additions and 5 deletions

View File

@ -533,6 +533,13 @@ long milliseconds = new Date().getTime();
Availability Zone:</label>
<select class="select" id="wizard_zone" name="zone">
</select>
<label for="wizard_zone">
Hypervisor:</label>
<select class="select" id="wizard_hypervisor" name="hypervisor">
<option value='VmWare'>VMware ESX</option>
<option value='XenServer'>Citrix XenServer</option>
<option value='KVM'>KVM</option>
</select>
<div class="rev_tempsearchbox">
<form method="post" action="#">
<ol>
@ -819,6 +826,12 @@ long milliseconds = new Date().getTime();
<div class="rev_wiz_reviewanswers" id="wizard_review_group">
</div>
</div>
<div class="rev_wiz_reviewlist">
<div class="rev_wiz_reviewlabel">
Hypervisor:</div>
<div class="rev_wiz_reviewanswers" id="wizard_review_hypervisor">
</div>
</div>
<div class="rev_wiz_reviewlist">
<div class="rev_wiz_reviewlabel">
Template:</div>

View File

@ -256,7 +256,15 @@ long milliseconds = new Date().getTime();
<label for="add_template_os_type">OS Type:</label>
<select class="select" name="add_template_os_type" id="add_template_os_type">
</select>
</li>
</li>
<li>
<label for="add_template_hypervisor">Hypervisor:</label>
<select class="select" name="add_template_hypervisor" id="add_template_hypervisor">
<option value='VmWare'>VMware ESX</option>
<option value='XenServer'>Citrix XenServer</option>
<option value='KVM'>KVM</option>
</select>
</li>
<li>
<label for="add_template_format">Format:</label>
<select class="select" name="add_template_format" id="add_template_format">

View File

@ -1617,7 +1617,8 @@ function showInstancesTab(p_domainId, p_account) {
thisPopup.find("#wizard_review_service_offering").text(thisPopup.find("#wizard_service_offering input[name=service]:checked").next().text());
thisPopup.find("#wizard_review_zone").text(thisPopup.find("#wizard_zone option:selected").text());
thisPopup.find("#wizard_review_name").text(thisPopup.find("#wizard_vm_name").val());
thisPopup.find("#wizard_review_group").text(thisPopup.find("#wizard_vm_group").val());
thisPopup.find("#wizard_review_group").text(thisPopup.find("#wizard_vm_group").val());
thisPopup.find("#wizard_review_hypervisor").text(thisPopup.find("#wizard_hypervisor option:selected").text());
if(thisPopup.find("#wizard_network_groups_container").css("display") != "none" && thisPopup.find("#wizard_network_groups").val() != null) {
var networkGroupList = thisPopup.find("#wizard_network_groups").val().join(",");
@ -1631,7 +1632,8 @@ function showInstancesTab(p_domainId, p_account) {
if (currentStepInVmPopup == 4) {
// Create a new VM!!!!
var moreCriteria = [];
moreCriteria.push("&zoneId="+thisPopup.find("#wizard_zone").val());
moreCriteria.push("&zoneId="+thisPopup.find("#wizard_zone").val());
moreCriteria.push("&hypervisor="+thisPopup.find("#wizard_hypervisor").val());
var name = trim(thisPopup.find("#wizard_vm_name").val());
if (name != null && name.length > 0)

View File

@ -173,7 +173,8 @@ function showTemplatesTab() {
var format = thisDialog.find("#add_template_format").val();
var password = thisDialog.find("#add_template_password").val();
var isPublic = thisDialog.find("#add_template_public").val();
var osType = thisDialog.find("#add_template_os_type").val();
var osType = thisDialog.find("#add_template_os_type").val();
var hypervisor = thisDialog.find("#add_template_hypervisor").val();
var moreCriteria = [];
if(thisDialog.find("#add_template_featured_container").css("display")!="none") {
@ -193,7 +194,7 @@ function showTemplatesTab() {
submenuContent.find("#grid_content").prepend(template.fadeIn("slow"));
$.ajax({
data: createURL("command=registerTemplate&name="+encodeURIComponent(name)+"&displayText="+encodeURIComponent(desc)+"&url="+encodeURIComponent(url)+"&zoneid="+zoneId+"&ispublic="+isPublic+moreCriteria.join("")+"&format="+format+"&passwordEnabled="+password+"&osTypeId="+osType+"&response=json"),
data: createURL("command=registerTemplate&name="+encodeURIComponent(name)+"&displayText="+encodeURIComponent(desc)+"&url="+encodeURIComponent(url)+"&zoneid="+zoneId+"&ispublic="+isPublic+moreCriteria.join("")+"&format="+format+"&passwordEnabled="+password+"&osTypeId="+osType+"&hypervisor="+hypervisor+"&response=json"),
dataType: "json",
success: function(json) {
var result = json.registertemplateresponse;