mirror of
https://github.com/OpenNebula/one.git
synced 2026-12-03 21:52:31 +09:00
(cherry picked from commit 65e66ddad4)
This commit is contained in:
1 parent
ba5db04bb3
commit
fb72a57401
1 file changed
+7
-2
@@ -1255,6 +1255,11 @@ define(function(require) {
|
||||
String(element.USER_TEMPLATE.HYPERVISOR).toLowerCase() === "vcenter");
|
||||
}
|
||||
|
||||
function isKVMVM(element = {}){
|
||||
return Boolean(element.USER_TEMPLATE &&
|
||||
String(element.USER_TEMPLATE.HYPERVISOR).toLowerCase() === "kvm");
|
||||
}
|
||||
|
||||
function isVMRCSupported(element = {}) {
|
||||
var actionEnabled = Config.isTabActionEnabled("vms-tab", "VM.startvmrc");
|
||||
var vmrcSupported = graphicSupported(element, "vnc");
|
||||
@@ -1274,9 +1279,9 @@ define(function(require) {
|
||||
var actionEnabled = Config.isTabActionEnabled("vms-tab", "VM.save_virt_viewer");
|
||||
var vncSupported = graphicSupported(element, "vnc");
|
||||
var spiceSupported = graphicSupported(element, "spice");
|
||||
var isvCenterVM = isVCenterVM(element);
|
||||
var isKVM = isKVMVM(element);
|
||||
|
||||
return (actionEnabled && history && (vncSupported || spiceSupported) && !isvCenterVM)
|
||||
return (actionEnabled && history && (vncSupported || spiceSupported) && isKVM)
|
||||
? {
|
||||
hostname: history.HOSTNAME,
|
||||
type: element.TEMPLATE.GRAPHICS.TYPE.toLowerCase(),
|
||||
|
||||
Reference in new issue
Block a user