mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
bug 8208: Finished the rest of the dialogs in the various resource pages for BareMetal install.
This commit is contained in:
parent
b8a2b766da
commit
7f595871f8
@ -217,7 +217,42 @@ dictionary = {
|
||||
<input class="text" type="text" name="host_vcenter_host" id="host_vcenter_host" />
|
||||
<div id="host_vcenter_host_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_cpucores">
|
||||
# of CPU Cores:</label>
|
||||
<input class="text" type="text" name="host_baremetal_cpucores" id="host_baremetal_cpucores" />
|
||||
<div id="host_baremetal_cpucores_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_cpu">
|
||||
CPU (in MHz):</label>
|
||||
<input class="text" type="text" name="host_baremetal_cpu" id="host_baremetal_cpu" />
|
||||
<div id="host_baremetal_cpu_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_memory">
|
||||
Memory (in MB):</label>
|
||||
<input class="text" type="text" name="host_baremetal_memory" id="host_baremetal_memory" />
|
||||
<div id="host_baremetal_memory_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_mac">
|
||||
Host MAC:</label>
|
||||
<input class="text" type="text" name="host_baremetal_mac" id="host_baremetal_mac" />
|
||||
<div id="host_baremetal_mac_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<label input_group="general">
|
||||
Tags:</label>
|
||||
<input class="text" type="text" name="host_tags" id="host_tags" />
|
||||
<div id="host_tags_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
@ -768,7 +768,42 @@ dictionary = {
|
||||
<input class="text" type="text" name="host_vcenter_host" id="host_vcenter_host" />
|
||||
<div id="host_vcenter_host_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_cpucores">
|
||||
# of CPU Cores:</label>
|
||||
<input class="text" type="text" name="host_baremetal_cpucores" id="host_baremetal_cpucores" />
|
||||
<div id="host_baremetal_cpucores_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_cpu">
|
||||
CPU (in MHz):</label>
|
||||
<input class="text" type="text" name="host_baremetal_cpu" id="host_baremetal_cpu" />
|
||||
<div id="host_baremetal_cpu_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_memory">
|
||||
Memory (in MB):</label>
|
||||
<input class="text" type="text" name="host_baremetal_memory" id="host_baremetal_memory" />
|
||||
<div id="host_baremetal_memory_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_mac">
|
||||
Host MAC:</label>
|
||||
<input class="text" type="text" name="host_baremetal_mac" id="host_baremetal_mac" />
|
||||
<div id="host_baremetal_mac_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<label input_group="general">
|
||||
Tags:</label>
|
||||
<input class="text" type="text" name="host_tags" id="host_tags" />
|
||||
<div id="host_tags_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
@ -342,7 +342,42 @@ dictionary = {
|
||||
<input class="text" type="text" name="host_vcenter_host" id="host_vcenter_host" />
|
||||
<div id="host_vcenter_host_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_cpucores">
|
||||
# of CPU Cores:</label>
|
||||
<input class="text" type="text" name="host_baremetal_cpucores" id="host_baremetal_cpucores" />
|
||||
<div id="host_baremetal_cpucores_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_cpu">
|
||||
CPU (in MHz):</label>
|
||||
<input class="text" type="text" name="host_baremetal_cpu" id="host_baremetal_cpu" />
|
||||
<div id="host_baremetal_cpu_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_memory">
|
||||
Memory (in MB):</label>
|
||||
<input class="text" type="text" name="host_baremetal_memory" id="host_baremetal_memory" />
|
||||
<div id="host_baremetal_memory_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_mac">
|
||||
Host MAC:</label>
|
||||
<input class="text" type="text" name="host_baremetal_mac" id="host_baremetal_mac" />
|
||||
<div id="host_baremetal_mac_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<label input_group="general">
|
||||
Tags:</label>
|
||||
<input class="text" type="text" name="host_tags" id="host_tags" />
|
||||
<div id="host_tags_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
@ -423,6 +423,41 @@ dictionary = {
|
||||
<input class="text" type="text" name="host_vcenter_host" id="host_vcenter_host" />
|
||||
<div id="host_vcenter_host_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_cpucores">
|
||||
# of CPU Cores:</label>
|
||||
<input class="text" type="text" name="host_baremetal_cpucores" id="host_baremetal_cpucores" />
|
||||
<div id="host_baremetal_cpucores_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_cpu">
|
||||
CPU (in MHz):</label>
|
||||
<input class="text" type="text" name="host_baremetal_cpu" id="host_baremetal_cpu" />
|
||||
<div id="host_baremetal_cpu_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_memory">
|
||||
Memory (in MB):</label>
|
||||
<input class="text" type="text" name="host_baremetal_memory" id="host_baremetal_memory" />
|
||||
<div id="host_baremetal_memory_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li input_group="baremetal" style="display: none;">
|
||||
<label for="host_baremetal_mac">
|
||||
Host MAC:</label>
|
||||
<input class="text" type="text" name="host_baremetal_mac" id="host_baremetal_mac" />
|
||||
<div id="host_baremetal_mac_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
<label input_group="general">
|
||||
Tags:</label>
|
||||
<input class="text" type="text" name="host_tags" id="host_tags" />
|
||||
<div id="host_tags_errormsg" class="dialog_formcontent_errormsg" style="display: none;">
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
</form>
|
||||
|
||||
@ -461,10 +461,16 @@ function bindAddHostButton($leftmenuItem1) {
|
||||
if(clusterObj.hypervisortype == "VMware") {
|
||||
$('li[input_group="vmware"]', dialogAddHost).show();
|
||||
$('li[input_group="general"]', dialogAddHost).hide();
|
||||
} else {
|
||||
$('li[input_group="baremetal"]', dialogAddHost).hide();
|
||||
} else if (clusterObj.hypervisortype == "BareMetal") {
|
||||
$('li[input_group="vmware"]', dialogAddHost).hide();
|
||||
$('li[input_group="general"]', dialogAddHost).show();
|
||||
$('li[input_group="baremetal"]', dialogAddHost).show();
|
||||
} else {
|
||||
$('li[input_group="vmware"]', dialogAddHost).hide();
|
||||
$('li[input_group="general"]', dialogAddHost).show();
|
||||
}
|
||||
$('li[input_group="baremetal"]', dialogAddHost).hide();
|
||||
}
|
||||
});
|
||||
|
||||
$button.unbind("click").bind("click", function(event) {
|
||||
@ -521,10 +527,16 @@ function bindAddHostButton($leftmenuItem1) {
|
||||
isValid &= validateString("vCenter Datacenter", $thisDialog.find("#host_vcenter_dc"), $thisDialog.find("#host_vcenter_dc_errormsg"));
|
||||
isValid &= validateString("vCenter Host", $thisDialog.find("#host_vcenter_host"), $thisDialog.find("#host_vcenter_host_errormsg"));
|
||||
} else {
|
||||
isValid &= validateString("Host name", $thisDialog.find("#host_hostname"), $thisDialog.find("#host_hostname_errormsg"));
|
||||
isValid &= validateString("User name", $thisDialog.find("#host_username"), $thisDialog.find("#host_username_errormsg"));
|
||||
isValid &= validateString("Password", $thisDialog.find("#host_password"), $thisDialog.find("#host_password_errormsg"));
|
||||
}
|
||||
if (hypervisor == "BareMetal") {
|
||||
isValid &= validateString("CPU Cores", $thisDialog.find("#host_baremetal_cpucores"), $thisDialog.find("#host_baremetal_cpucores_errormsg"));
|
||||
isValid &= validateString("CPU", $thisDialog.find("#host_baremetal_cpu"), $thisDialog.find("#host_baremetal_cpu_errormsg"));
|
||||
isValid &= validateString("Memory", $thisDialog.find("#host_baremetal_memory"), $thisDialog.find("#host_baremetal_memory_errormsg"));
|
||||
isValid &= validateString("MAC", $thisDialog.find("#host_baremetal_mac"), $thisDialog.find("#host_baremetal_mac_errormsg"));
|
||||
}
|
||||
isValid &= validateString("Host name", $thisDialog.find("#host_hostname"), $thisDialog.find("#host_hostname_errormsg"));
|
||||
isValid &= validateString("User name", $thisDialog.find("#host_username"), $thisDialog.find("#host_username_errormsg"));
|
||||
isValid &= validateString("Password", $thisDialog.find("#host_password"), $thisDialog.find("#host_password_errormsg"));
|
||||
}
|
||||
}
|
||||
if (!isValid)
|
||||
return;
|
||||
@ -537,7 +549,8 @@ function bindAddHostButton($leftmenuItem1) {
|
||||
array1.push("&clusterid="+clusterId);
|
||||
array1.push("&hypervisor=" + hypervisor);
|
||||
var clustertype = clusterObj.clustertype;
|
||||
array1.push("&clustertype=" + clustertype);
|
||||
array1.push("&clustertype=" + clustertype);
|
||||
array1.push("&hosttags=" + todb(trim($thisDialog.find("#host_tags").val())));
|
||||
|
||||
if(hypervisor == "VMware") {
|
||||
var username = trim($thisDialog.find("#host_vcenter_username").val());
|
||||
@ -557,6 +570,19 @@ function bindAddHostButton($leftmenuItem1) {
|
||||
url = hostname;
|
||||
array1.push("&url="+todb(url));
|
||||
} else {
|
||||
if (hypervisor == "BareMetal") {
|
||||
var cpuCores = trim($thisDialog.find("#host_baremetal_cpucores").val());
|
||||
array1.push("&cpunumber="+todb(cpuCores));
|
||||
|
||||
var cpuSpeed = trim($thisDialog.find("#host_baremetal_cpu").val());
|
||||
array1.push("&cpuspeeed="+todb(cpuSpeed));
|
||||
|
||||
var memory = trim($thisDialog.find("#host_baremetal_memory").val());
|
||||
array1.push("&memory="+todb(memory));
|
||||
|
||||
var mac = trim($thisDialog.find("#host_baremetal_mac").val());
|
||||
array1.push("&hostmac="+todb(mac));
|
||||
}
|
||||
var username = trim($thisDialog.find("#host_username").val());
|
||||
array1.push("&username="+todb(username));
|
||||
|
||||
|
||||
@ -696,10 +696,16 @@ function bindAddHostButtonOnZonePage($button, zoneId, zoneName) {
|
||||
if(clusterObj.hypervisortype == "VMware") {
|
||||
$('li[input_group="vmware"]', $dialogAddHost).show();
|
||||
$('li[input_group="general"]', $dialogAddHost).hide();
|
||||
} else {
|
||||
$('li[input_group="baremetal"]', $dialogAddHost).hide();
|
||||
} else if (clusterObj.hypervisortype == "BareMetal") {
|
||||
$('li[input_group="vmware"]', $dialogAddHost).hide();
|
||||
$('li[input_group="general"]', $dialogAddHost).show();
|
||||
$('li[input_group="baremetal"]', $dialogAddHost).show();
|
||||
} else {
|
||||
$('li[input_group="vmware"]', $dialogAddHost).hide();
|
||||
$('li[input_group="general"]', $dialogAddHost).show();
|
||||
}
|
||||
$('li[input_group="baremetal"]', $dialogAddHost).hide();
|
||||
}
|
||||
});
|
||||
|
||||
$button.unbind("click").bind("click", function(event) {
|
||||
@ -730,11 +736,17 @@ function bindAddHostButtonOnZonePage($button, zoneId, zoneName) {
|
||||
isValid &= validateString("vCenter Password", $thisDialog.find("#host_vcenter_password"), $thisDialog.find("#host_vcenter_password_errormsg"));
|
||||
isValid &= validateString("vCenter Datacenter", $thisDialog.find("#host_vcenter_dc"), $thisDialog.find("#host_vcenter_dc_errormsg"));
|
||||
isValid &= validateString("vCenter Host", $thisDialog.find("#host_vcenter_host"), $thisDialog.find("#host_vcenter_host_errormsg"));
|
||||
} else {
|
||||
isValid &= validateString("Host name", $thisDialog.find("#host_hostname"), $thisDialog.find("#host_hostname_errormsg"));
|
||||
isValid &= validateString("User name", $thisDialog.find("#host_username"), $thisDialog.find("#host_username_errormsg"));
|
||||
isValid &= validateString("Password", $thisDialog.find("#host_password"), $thisDialog.find("#host_password_errormsg"));
|
||||
}
|
||||
} else {
|
||||
if (hypervisor == "BareMetal") {
|
||||
isValid &= validateString("CPU Cores", $thisDialog.find("#host_baremetal_cpucores"), $thisDialog.find("#host_baremetal_cpucores_errormsg"));
|
||||
isValid &= validateString("CPU", $thisDialog.find("#host_baremetal_cpu"), $thisDialog.find("#host_baremetal_cpu_errormsg"));
|
||||
isValid &= validateString("Memory", $thisDialog.find("#host_baremetal_memory"), $thisDialog.find("#host_baremetal_memory_errormsg"));
|
||||
isValid &= validateString("MAC", $thisDialog.find("#host_baremetal_mac"), $thisDialog.find("#host_baremetal_mac_errormsg"));
|
||||
}
|
||||
isValid &= validateString("Host name", $thisDialog.find("#host_hostname"), $thisDialog.find("#host_hostname_errormsg"));
|
||||
isValid &= validateString("User name", $thisDialog.find("#host_username"), $thisDialog.find("#host_username_errormsg"));
|
||||
isValid &= validateString("Password", $thisDialog.find("#host_password"), $thisDialog.find("#host_password_errormsg"));
|
||||
}
|
||||
}
|
||||
if (!isValid)
|
||||
return;
|
||||
@ -758,7 +770,8 @@ function bindAddHostButtonOnZonePage($button, zoneId, zoneName) {
|
||||
|
||||
array1.push("&hypervisor="+hypervisor);
|
||||
var clustertype = clusterObj.clustertype;
|
||||
array1.push("&clustertype=" + clustertype);
|
||||
array1.push("&clustertype=" + clustertype);
|
||||
array1.push("&hosttags=" + todb(trim($thisDialog.find("#host_tags").val())));
|
||||
|
||||
if(hypervisor == "VMware") {
|
||||
var username = trim($thisDialog.find("#host_vcenter_username").val());
|
||||
@ -779,6 +792,20 @@ function bindAddHostButtonOnZonePage($button, zoneId, zoneName) {
|
||||
array1.push("&url="+todb(url));
|
||||
|
||||
} else {
|
||||
if (hypervisor == "BareMetal") {
|
||||
var cpuCores = trim($thisDialog.find("#host_baremetal_cpucores").val());
|
||||
array1.push("&cpunumber="+todb(cpuCores));
|
||||
|
||||
var cpuSpeed = trim($thisDialog.find("#host_baremetal_cpu").val());
|
||||
array1.push("&cpuspeeed="+todb(cpuSpeed));
|
||||
|
||||
var memory = trim($thisDialog.find("#host_baremetal_memory").val());
|
||||
array1.push("&memory="+todb(memory));
|
||||
|
||||
var mac = trim($thisDialog.find("#host_baremetal_mac").val());
|
||||
array1.push("&hostmac="+todb(mac));
|
||||
}
|
||||
|
||||
var username = trim($thisDialog.find("#host_username").val());
|
||||
array1.push("&username="+todb(username));
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user