From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id A254073CA2 for ; Fri, 16 Apr 2021 15:36:24 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 4479624EF3 for ; Fri, 16 Apr 2021 15:35:29 +0200 (CEST) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [212.186.127.180]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS id 2053C24C84 for ; Fri, 16 Apr 2021 15:35:24 +0200 (CEST) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id DBF4D45B68 for ; Fri, 16 Apr 2021 15:35:23 +0200 (CEST) From: Wolfgang Bumiller To: pbs-devel@lists.proxmox.com Date: Fri, 16 Apr 2021 15:35:17 +0200 Message-Id: <20210416133517.23349-25-w.bumiller@proxmox.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20210416133517.23349-1-w.bumiller@proxmox.com> References: <20210416133517.23349-1-w.bumiller@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.031 Adjusted score from AWL reputation of From: address KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment RCVD_IN_DNSWL_MED -2.3 Sender listed at https://www.dnswl.org/, medium trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Subject: [pbs-devel] [RFC widget-toolkit] acme: separate flag to disable the 'domains=' array X-BeenThere: pbs-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox Backup Server development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Apr 2021 13:36:24 -0000 PVE has 2 domain lists, PMG only 1 since it requires the additional type. In PBS I do not want to have 2 lists either, since it seems rather inconvenient to have 2 different ways to access the same list. Currently we decide this based on whether we have multiple certificate types, which in PBS we don't, so we need a separate option for this. Signed-off-by: Wolfgang Bumiller --- src/panel/ACMEDomains.js | 4 ++++ src/window/ACMEDomains.js | 5 ++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/panel/ACMEDomains.js b/src/panel/ACMEDomains.js index 6cfc501..a7fb088 100644 --- a/src/panel/ACMEDomains.js +++ b/src/panel/ACMEDomains.js @@ -21,6 +21,8 @@ Ext.define('Proxmox.panel.ACMEDomains', { domainUsages: undefined, // if no domainUsages parameter is supllied, the orderUrl is required instead: orderUrl: undefined, + // Force the use of 'acmedomainX' properties. + separateDomainEntries: undefined, acmeUrl: undefined, @@ -87,6 +89,7 @@ Ext.define('Proxmox.panel.ACMEDomains', { acmeUrl: view.acmeUrl, nodeconfig: view.nodeconfig, domainUsages: view.domainUsages, + separateDomainEntries: view.separateDomainEntries, apiCallDone: function() { me.reload(); }, @@ -105,6 +108,7 @@ Ext.define('Proxmox.panel.ACMEDomains', { acmeUrl: view.acmeUrl, nodeconfig: view.nodeconfig, domainUsages: view.domainUsages, + separateDomainEntries: view.separateDomainEntries, domain: selection[0].data, apiCallDone: function() { me.reload(); diff --git a/src/window/ACMEDomains.js b/src/window/ACMEDomains.js index 930a4c3..b040e33 100644 --- a/src/window/ACMEDomains.js +++ b/src/window/ACMEDomains.js @@ -16,6 +16,9 @@ Ext.define('Proxmox.window.ACMEDomainEdit', { // For PMG the we have multiple certificates, so we have a "usage" attribute & column. domainUsages: undefined, + // Force the use of 'acmedomainX' properties. + separateDomainEntries: undefined, + cbindData: function(config) { let me = this; return { @@ -50,7 +53,7 @@ Ext.define('Proxmox.window.ACMEDomainEdit', { }; // If we have a 'usage' property (pmg), we only use the `acmedomainX` config keys. - if (win.domainUsages) { + if (win.separateDomainEntries || win.domainUsages) { if (!configkey || configkey === 'acme') { configkey = find_free_slot(); } -- 2.20.1