Signed-off-by: Alexandre Derumier <[email protected]>
---
www/manager/qemu/CmdMenu.js | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/www/manager/qemu/CmdMenu.js b/www/manager/qemu/CmdMenu.js
index f80922b..3dedc43 100644
--- a/www/manager/qemu/CmdMenu.js
+++ b/www/manager/qemu/CmdMenu.js
@@ -90,6 +90,26 @@ Ext.define('PVE.qemu.CmdMenu', {
}
},
{
+ text: gettext('Convert To Template'),
+ icon: '/pve2/images/forward.png',
+ handler: function() {
+ var msg = Ext.String.format(gettext("Do you really want
convert VM {0} to template (You'll can use the VM anymore)?"), vmid);
+ Ext.Msg.confirm(gettext('Confirm'), msg, function(btn) {
+ if (btn !== 'yes') {
+ return;
+ }
+
+ PVE.Utils.API2Request({
+ url: '/nodes/' + nodename + '/qemu/' + vmid +
'/template',
+ method: 'POST',
+ failure: function(response, opts) {
+ Ext.Msg.alert('Error', response.htmlStatus);
+ }
+ });
+ });
+ }
+ },
+ {
text: gettext('Console'),
icon: '/pve2/images/display.png',
handler: function() {
--
1.7.10.4
_______________________________________________
pve-devel mailing list
[email protected]
http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel