applied with typo fixes
(uneccesarry -> unnecessary, (un)priviledged -> (un)privlieged)

On 11/5/18 1:02 PM, Thomas Lamprecht wrote:
So that users are (hopefully) less confused why this is disabled for
priviledged CTs. If we get more feature settings which only make
sense for unpriviledged or priviledged but not both we could split
this into sections which respective headings, but for one only I
didn't wanted to do this - so just add a boxLabel conditionally.

Cc: Dominik Csapak <[email protected]>
Signed-off-by: Thomas Lamprecht <[email protected]>
---
  www/manager6/lxc/FeaturesEdit.js | 5 ++++-
  1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/www/manager6/lxc/FeaturesEdit.js b/www/manager6/lxc/FeaturesEdit.js
index 02ce0a1d..5370b5b5 100644
--- a/www/manager6/lxc/FeaturesEdit.js
+++ b/www/manager6/lxc/FeaturesEdit.js
@@ -54,7 +54,10 @@ Ext.define('PVE.lxc.FeaturesInputPanel', {
      setValues: function(values) {
        var me = this;
- me.down('field[name=keyctl]').setDisabled(!values.unprivileged);
+       var privileged = !values.unprivileged,
+           keyctlField = me.down('field[name=keyctl]');
+       keyctlField.setDisabled(privileged);
+       keyctlField.setBoxLabel(privileged ? gettext('unpriviledged only') : 
null);
if (values.features) {
            var res = PVE.Parser.parsePropertyString(values.features);



_______________________________________________
pve-devel mailing list
[email protected]
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to