[pve-devel] [PATCH manager 1/2] Add a checkbox 'Skip replication' to filter out container mount points to replicate
Emmanuel Kasper
e.kasper at proxmox.com
Tue Jun 27 17:07:08 CEST 2017
---
www/manager6/lxc/ResourceEdit.js | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/www/manager6/lxc/ResourceEdit.js b/www/manager6/lxc/ResourceEdit.js
index bf7c76f1..41bd25cb 100644
--- a/www/manager6/lxc/ResourceEdit.js
+++ b/www/manager6/lxc/ResourceEdit.js
@@ -263,6 +263,11 @@ Ext.define('PVE.lxc.MountPointInputPanel', {
delete me.mpdata.backup;
}
+ if (values.noreplicate) {
+ me.mpdata.replicate = '0';
+ }
+ delete me.mpdata.noreplicate;
+
var res = {};
res[confid] = PVE.Parser.printLxcMountPoint(me.mpdata);
return res;
@@ -285,6 +290,11 @@ Ext.define('PVE.lxc.MountPointInputPanel', {
me.hdstoragesel.setDisabled(true);
}
+ if (mp.replicate) { // check box reverses the config option
+ mp.noreplicate = !PVE.Parser.parseBoolean(mp.replicate, 1);
+ delete mp.replicate;
+ }
+
me.setValues(mp);
},
@@ -513,6 +523,11 @@ Ext.define('PVE.lxc.MountPointInputPanel', {
me.column2.push(me.backup);
}
me.column2.push({
+ xtype: 'pvecheckbox',
+ name: 'noreplicate',
+ fieldLabel: gettext('Skip replication')
+ });
+ me.column2.push({
xtype: 'textfield',
name: 'mp',
value: '',
--
2.11.0
More information about the pve-devel
mailing list