[pve-devel] [PATCH manager 3/3] add onlineonly/sharedonly flags to migrate all gui
Dominik Csapak
d.csapak at proxmox.com
Thu Dec 1 17:21:42 CET 2016
Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
www/manager6/window/MigrateAll.js | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)
diff --git a/www/manager6/window/MigrateAll.js b/www/manager6/window/MigrateAll.js
index 1bcba1e..4f97144 100644
--- a/www/manager6/window/MigrateAll.js
+++ b/www/manager6/window/MigrateAll.js
@@ -3,10 +3,10 @@ Ext.define('PVE.window.MigrateAll', {
resizable: false,
- migrate: function(target, maxworkers) {
+ migrate: function(params) {
var me = this;
PVE.Utils.API2Request({
- params: { target: target, maxworkers: maxworkers},
+ params: params,
url: '/nodes/' + me.nodename + '/' + "/migrateall",
waitMsgTarget: me,
method: 'POST',
@@ -36,7 +36,7 @@ Ext.define('PVE.window.MigrateAll', {
bodyPadding: 10,
border: false,
fieldDefaults: {
- labelWidth: 100,
+ labelWidth: 200,
anchor: '100%'
},
items: [
@@ -45,6 +45,7 @@ Ext.define('PVE.window.MigrateAll', {
name: 'target',
fieldLabel: 'Target node',
allowBlank: false,
+ disallowedNodes: [me.nodename],
onlineValidator: true
},
{
@@ -53,8 +54,18 @@ Ext.define('PVE.window.MigrateAll', {
minValue: 1,
maxValue: 100,
value: 1,
- fieldLabel: 'Parallel jobs',
+ fieldLabel: gettext('Parallel Migrations'),
allowBlank: false
+ },
+ {
+ xtype: 'pvecheckbox',
+ name: 'onlineonly',
+ fieldLabel: gettext('Online Guests only')
+ },
+ {
+ xtype: 'pvecheckbox',
+ name: 'sharedonly',
+ fieldLabel: gettext('Shared Storage only')
}
]
});
@@ -64,14 +75,13 @@ Ext.define('PVE.window.MigrateAll', {
var submitBtn = Ext.create('Ext.Button', {
text: 'Migrate',
handler: function() {
- var values = form.getValues();
- me.migrate(values.target, values.maxworkers);
+ me.migrate(form.getValues());
}
});
Ext.apply(me, {
title: "Migrate All VMs",
- width: 350,
+ width: 450,
modal: true,
layout: 'auto',
border: false,
--
2.1.4
More information about the pve-devel
mailing list