From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [45.144.208.40]) by lore.proxmox.com (Postfix) with ESMTPS id 317381FF129 for ; Thu, 06 Aug 2026 18:41:01 +0200 (CEST) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id A0E7E21575; Thu, 06 Aug 2026 18:40:58 +0200 (CEST) From: Hannes Laimer To: pve-devel@lists.proxmox.com Subject: [PATCH pve-manager] ui: sdn: dns selector: keep an untouched edit dialog clean Date: Thu, 6 Aug 2026 18:40:01 +0200 Message-ID: <20260806164001.1901538-1-h.laimer@proxmox.com> X-Mailer: git-send-email 2.47.3 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1786034434313 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.673 Adjusted score from AWL reputation of From: address DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment (newer systems) RCVD_IN_DNSWL_LOW -0.7 Sender listed at https://www.dnswl.org/, low trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: 5ODSUKIXX2ARVV6TSTGO6T4HXXL7DPIM X-Message-ID-Hash: 5ODSUKIXX2ARVV6TSTGO6T4HXXL7DPIM X-MailFrom: h.laimer@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: The selector starts out on the empty string, and once its store has loaded an empty selection reads back as null. Both mean that no server is picked, but the dirty tracking told them apart, so just opening a zone edit dialog enabled its reset button and let an unchanged form be submitted. Signed-off-by: Hannes Laimer --- just noticed here because zone edit kept being marked as dirty, this could also make sense in ComboGrid directly (don't think we ever actually differentiate between `null` and `''`?) www/manager6/form/SDNDnsSelector.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/www/manager6/form/SDNDnsSelector.js b/www/manager6/form/SDNDnsSelector.js index 7a134541..9d36e8d7 100644 --- a/www/manager6/form/SDNDnsSelector.js +++ b/www/manager6/form/SDNDnsSelector.js @@ -8,6 +8,10 @@ Ext.define( valueField: 'dns', displayField: 'dns', + isEqual: function (value1, value2) { + return String(value1 ?? '') === String(value2 ?? ''); + }, + initComponent: function () { var me = this; -- 2.47.3