From: Dominik Csapak <d.csapak@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH manager 1/1] ui: realm sync: add 'remove-vanished' option
Date: Wed, 27 Oct 2021 14:57:08 +0200 [thread overview]
Message-ID: <20211027125708.1068455-4-d.csapak@proxmox.com> (raw)
In-Reply-To: <20211027125708.1068455-1-d.csapak@proxmox.com>
in default sync options and the sync window. There we disable it if
'full' sync is enabled to make it clear the combination does not make
sense.
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
---
www/manager6/dc/AuthEditLDAP.js | 14 +++++++++++++-
www/manager6/dc/SyncWindow.js | 19 +++++++++++++++++++
2 files changed, 32 insertions(+), 1 deletion(-)
diff --git a/www/manager6/dc/AuthEditLDAP.js b/www/manager6/dc/AuthEditLDAP.js
index 015a5a6e..2942ae64 100644
--- a/www/manager6/dc/AuthEditLDAP.js
+++ b/www/manager6/dc/AuthEditLDAP.js
@@ -100,7 +100,7 @@ Ext.define('PVE.panel.LDAPSyncInputPanel', {
xtype: 'pveAuthLDAPSyncPanel',
editableAttributes: ['email'],
- editableDefaults: ['scope', 'full', 'enable-new', 'purge'],
+ editableDefaults: ['scope', 'full', 'enable-new', 'purge', 'remove-vanished'],
default_opts: {},
sync_attributes: {},
@@ -216,6 +216,18 @@ Ext.define('PVE.panel.LDAPSyncInputPanel', {
name: 'full',
fieldLabel: gettext('Full'),
},
+ {
+ xtype: 'proxmoxKVComboBox',
+ value: '__default__',
+ deleteEmpty: false,
+ comboItems: [
+ ['__default__', Proxmox.Utils.NoneText],
+ ['1', Proxmox.Utils.yesText],
+ ['0', Proxmox.Utils.noText],
+ ],
+ name: 'remove-vanished',
+ fieldLabel: gettext('Remove vanished'),
+ },
],
column2: [
diff --git a/www/manager6/dc/SyncWindow.js b/www/manager6/dc/SyncWindow.js
index 25a42182..c988a4bf 100644
--- a/www/manager6/dc/SyncWindow.js
+++ b/www/manager6/dc/SyncWindow.js
@@ -12,6 +12,11 @@ Ext.define('PVE.dc.SyncWindow', {
xclass: 'Ext.app.ViewController',
control: {
+ 'field[name=full]': {
+ change: function(field, value) {
+ this.lookup('remove-vanished').setDisabled(value === '1');
+ },
+ },
'form': {
validitychange: function(field, valid) {
let me = this;
@@ -101,6 +106,20 @@ Ext.define('PVE.dc.SyncWindow', {
name: 'full',
fieldLabel: gettext('Full'),
},
+ {
+ xtype: 'proxmoxKVComboBox',
+ value: '',
+ emptyText: gettext('No default available'),
+ deleteEmpty: false,
+ allowBlank: false,
+ comboItems: [
+ ['1', Proxmox.Utils.yesText],
+ ['0', Proxmox.Utils.noText],
+ ],
+ name: 'remove-vanished',
+ reference: 'remove-vanished',
+ fieldLabel: gettext('Remove vanished'),
+ },
],
column2: [
--
2.30.2
prev parent reply other threads:[~2021-10-27 12:57 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-27 12:57 [pve-devel] [PATCH access-control/manager] improve realm sync Dominik Csapak
2021-10-27 12:57 ` [pve-devel] [PATCH access-control 1/2] fix #3668: realm sync: add 'remove-vanished' parameter to delete non-existing users Dominik Csapak
2021-11-09 17:58 ` Thomas Lamprecht
2021-10-27 12:57 ` [pve-devel] [PATCH access-control 2/2] realm sync: improve wording in log and description Dominik Csapak
2021-10-27 12:57 ` Dominik Csapak [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211027125708.1068455-4-d.csapak@proxmox.com \
--to=d.csapak@proxmox.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal