comment inline
On 4/2/20 1:34 PM, Dominic Jäger wrote:
Add a radiobox to the settings to control if search should be done recursively
as default or not. Set to no recursion as default.
Signed-off-by: Dominic Jäger <d.jae...@proxmox.com>
---
This did not exist in RFC
www/manager6/storage/ContentView.js | 2 +-
www/manager6/window/Settings.js | 38 +++++++++++++++++++++++++++++
2 files changed, 39 insertions(+), 1 deletion(-)
diff --git a/www/manager6/storage/ContentView.js
b/www/manager6/storage/ContentView.js
index 5c6f1418..fb87f5e6 100644
--- a/www/manager6/storage/ContentView.js
+++ b/www/manager6/storage/ContentView.js
@@ -587,7 +587,7 @@ Ext.define('PVE.storage.ContentView', {
fieldLabel: gettext('Recursive'),
labelWidth: 65,
name : 'recursive',
- checked: false,
+ checked: me.sp.get('recursive-search'),
listeners: {
change: function(box, value) {
me.store.proxy.url = me.store.proxy.url.replace(
diff --git a/www/manager6/window/Settings.js b/www/manager6/window/Settings.js
index 2fa01ef0..af708898 100644
--- a/www/manager6/window/Settings.js
+++ b/www/manager6/window/Settings.js
@@ -41,6 +41,9 @@ Ext.define('PVE.window.Settings', {
if (vncMode !== undefined) {
me.lookupReference('noVNCScalingGroup').setValue({
noVNCScalingField: vncMode });
}
+ var spSearchValue = sp.get('recursive-search');
+ me.lookupReference('recursiveSearchGroup').setValue({
+ recursiveSearchField: spSearchValue });
let summarycolumns = sp.get('summarycolumns', 'auto');
me.lookup('summarycolumns').setValue(summarycolumns);
@@ -428,6 +431,41 @@ Ext.define('PVE.window.Settings', {
},
},
]
+ },{
+ xtype: 'fieldset',
+ title: gettext('Storage Settings'),
+ items: [
+ {
+ xtype: 'radiogroup',
+ fieldLabel: gettext('Recursive Search'),
+ reference: 'recursiveSearchGroup',
+ height: '15px', // renders faster with value assigned
+ layout: {
+ type: 'hbox',
+ },
+ items: [
+ {
+ xtype: 'radiofield',
+ name: 'recursiveSearchField',
+ inputValue: 1,
+ boxLabel: gettext('On'),
+ },{
+ xtype: 'radiofield',
+ name: 'recursiveSearchField',
+ inputValue: 0,
+ boxLabel: gettext('Off'),
+ margin: '0 0 0 10',
+ checked: true,
+ }
+ ],
+ listeners: {
+ change: function(el, newValue, undefined) {
+ var sp = Ext.state.Manager.getProvider();
+ sp.set('recursive-search',
newValue.recursiveSearchField);
same comment about int/string as the previous patch:
'0' and '1' then you do not have to convert
+ }
+ },
+ },
+ ]
},
]
}],
_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel