You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by we...@apache.org on 2013/11/29 11:11:56 UTC
[2/5] git commit: updated refs/heads/4.3 to 814ae73
[UI] kvm vm snapshot not shown if kvm.snapshot.enabled is set to false
(cherry picked from commit 64c03dbc3129fe7b2c613f2981b3f645d88b449b)
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/62a675d6
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/62a675d6
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/62a675d6
Branch: refs/heads/4.3
Commit: 62a675d69845f9f6564f33efb01331e828f3378b
Parents: db5739b
Author: Wei Zhou <w....@leaseweb.com>
Authored: Thu Nov 28 10:47:37 2013 +0100
Committer: Wei Zhou <w....@leaseweb.com>
Committed: Fri Nov 29 10:54:40 2013 +0100
----------------------------------------------------------------------
ui/scripts/instances.js | 6 ++++--
ui/scripts/storage.js | 2 +-
2 files changed, 5 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/62a675d6/ui/scripts/instances.js
----------------------------------------------------------------------
diff --git a/ui/scripts/instances.js b/ui/scripts/instances.js
index 06acc16..27e0e4f 100644
--- a/ui/scripts/instances.js
+++ b/ui/scripts/instances.js
@@ -2106,7 +2106,8 @@
} else if (jsonObj.state == 'Running') {
allowedActions.push("stop");
allowedActions.push("restart");
- allowedActions.push("snapshot");
+ if (jsonObj.hypervisor != 'KVM' || g_KVMsnapshotenabled == true)
+ allowedActions.push("snapshot");
allowedActions.push("destroy");
allowedActions.push("reset");
@@ -2135,7 +2136,8 @@
allowedActions.push("start");
allowedActions.push("destroy");
allowedActions.push("reset");
- allowedActions.push("snapshot");
+ if (jsonObj.hypervisor != 'KVM' || g_KVMsnapshotenabled == true)
+ allowedActions.push("snapshot");
allowedActions.push("scaleUp"); //when vm is stopped, scaleUp is supported for all hypervisors
allowedActions.push("changeAffinity");
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/62a675d6/ui/scripts/storage.js
----------------------------------------------------------------------
diff --git a/ui/scripts/storage.js b/ui/scripts/storage.js
index 03b88f8..4875662 100644
--- a/ui/scripts/storage.js
+++ b/ui/scripts/storage.js
@@ -1896,7 +1896,7 @@
if (jsonObj.hypervisor != "Ovm" && jsonObj.state == "Ready") {
if (jsonObj.hypervisor == 'KVM') {
- if (json.vmstate == 'Running') {
+ if (jsonObj.vmstate == 'Running') {
if (g_KVMsnapshotenabled == true) { //"kvm.snapshot.enabled" flag should be taken to account only when snapshot is being created for Running vm (CLOUDSTACK-4428)
allowedActions.push("takeSnapshot");
allowedActions.push("recurringSnapshot");