diff --git a/emhttp/plugins/dynamix.vm.manager/include/libvirt.php b/emhttp/plugins/dynamix.vm.manager/include/libvirt.php index 7b301426b..d55422197 100644 --- a/emhttp/plugins/dynamix.vm.manager/include/libvirt.php +++ b/emhttp/plugins/dynamix.vm.manager/include/libvirt.php @@ -468,9 +468,8 @@ if (isset($usbopt[$v]) && !$vmclone ) { if (strpos($usbopt[$v], "#remove") == false) $startupPolicy = 'startupPolicy="optional"' ; else $startupPolicy = '' ; } - if ($vmclone ) { + if (isset($v["startupPolicy"]) && $vmclone ) { if ($v["startupPolicy"] == "optional" ) $startupPolicy = 'startupPolicy="optional"' ; else $startupPolicy = '' ; - #$startupPolicy = 'startupPolicy="optional"' ; } $usbstr .= " @@ -481,7 +480,7 @@ if (!empty($usbboot[$v]) && !$vmclone ) { $usbstr .= "" ; } - if ($vmclone ) { + if (isset($v["usbboot"]) && $vmclone ) { if ($v["usbboot"] != NULL) $usbstr .= "" ; } $usbstr .= ""; diff --git a/emhttp/plugins/dynamix.vm.manager/include/libvirt_helpers.php b/emhttp/plugins/dynamix.vm.manager/include/libvirt_helpers.php index 8fdbbf7c3..5bea9798a 100644 --- a/emhttp/plugins/dynamix.vm.manager/include/libvirt_helpers.php +++ b/emhttp/plugins/dynamix.vm.manager/include/libvirt_helpers.php @@ -1483,7 +1483,7 @@ private static $encoding = 'UTF-8'; */ $uuid = $lv->domain_get_uuid($clone) ; write("addLog\0".htmlspecialchars(_("Checking if clone exists"))); - if ($uuid) { $arrResponse = ['error' => _("Clone VM name already inuse")]; return $arrResponse ;} + if ($uuid) { $arrResponse = ['error' => _("Clone VM name already inuse")]; return false ;} #VM must be shutdown. $res = $lv->get_domain_by_name($vm); $dom = $lv->domain_get_info($res); @@ -1530,7 +1530,7 @@ private static $encoding = 'UTF-8'; if ($usb["checked"] == "checked") continue ; unset($usbs[$i]) ; } - $config["domain"]["usb"] = $usbs ; + $config["usb"] = $usbs ; $files_exist = false ; $files_clone = array() ; diff --git a/emhttp/plugins/dynamix/include/DefaultPageLayout.php b/emhttp/plugins/dynamix/include/DefaultPageLayout.php index db36fda94..e227908f8 100644 --- a/emhttp/plugins/dynamix/include/DefaultPageLayout.php +++ b/emhttp/plugins/dynamix/include/DefaultPageLayout.php @@ -971,12 +971,12 @@ nchan_vmaction.on('message', function(data) { rows = document.getElementsByClassName('logLine'); if (rows.length) { var row = rows[rows.length-1]; - row.innerHTML += ''+data[1]+': '+data[2]+'.
'; + row.innerHTML += ''+data[1]+' '+data[2]+'
'; } } else { var rows_content = rows.getElementsByClassName('content'); if (!rows_content.length || rows_content[rows_content.length-1].textContent != data[2]) { - rows.innerHTML += ''+data[2]+'.'; + rows.innerHTML += ''+data[2]+''; } } break;