diff --git a/src/sunstone/public/js/opennebula.js b/src/sunstone/public/js/opennebula.js index 0cba8a056e..3956b35752 100644 --- a/src/sunstone/public/js/opennebula.js +++ b/src/sunstone/public/js/opennebula.js @@ -585,6 +585,9 @@ var OpenNebula = { "resubmit": function(params){ OpenNebula.Action.simple_action(params,OpenNebula.VM.resource,"resubmit"); }, + "reboot" : function(params){ + OpenNebula.Action.simple_action(params,OpenNebula.VM.resource,"reboot"); + }, "log": function(params){ OpenNebula.Action.show(params,OpenNebula.VM.resource,"log"); diff --git a/src/sunstone/public/js/plugins/vms-tab.js b/src/sunstone/public/js/plugins/vms-tab.js index a8f8caad3d..de1000a875 100644 --- a/src/sunstone/public/js/plugins/vms-tab.js +++ b/src/sunstone/public/js/plugins/vms-tab.js @@ -241,6 +241,15 @@ var vm_actions = { notify: true }, + "VM.reboot" : { + type: "multiple", + call: OpenNebula.VM.reboot, + callback: vmShow, + elements: vmElements, + error: onError, + notify: true + }, + "VM.saveasmultiple" : { type: "custom", call: function(){ @@ -464,6 +473,11 @@ var vm_buttons = { text: tr("Resubmit"), tip: tr("This will resubmits VMs to PENDING state") }, + "VM.reboot" : { + type : "confirm", + text: tr("Reboot"), + tip: tr("This will send a reboot action to running VMs") + }, "VM.saveasmultiple" : { type: "action", text: tr("Save as")