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 498E3617F8; Tue, 18 Aug 2020 19:59:49 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 34C87166C7; Tue, 18 Aug 2020 19:59:19 +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 A0E1B166B9; Tue, 18 Aug 2020 19:59:18 +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 65D654466E; Tue, 18 Aug 2020 19:59:18 +0200 (CEST) To: Proxmox VE development discussion , Hannes Laimer , pbs-devel@lists.proxmox.com References: <20200818084023.54780-1-h.laimer@proxmox.com> <20200818084023.54780-4-h.laimer@proxmox.com> From: Thomas Lamprecht Message-ID: <8706f161-b1b0-f96b-d9fb-d53da07639ff@proxmox.com> Date: Tue, 18 Aug 2020 19:59:13 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:80.0) Gecko/20100101 Thunderbird/80.0 MIME-Version: 1.0 In-Reply-To: <20200818084023.54780-4-h.laimer@proxmox.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.278 Adjusted score from AWL reputation of From: address KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment NICE_REPLY_A -0.567 Looks like a legit reply (A) 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 URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [item.id] Subject: Re: [pve-devel] [PATCH proxmox-widget-toolkit 3/5] ui: added possibility to show a small note in SafeRemove dialog X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Aug 2020 17:59:49 -0000 general note, while I find tags in the comment subject nice, this doesn't really adds value as everything in widget toolkit is "ui" :) We only use that in things like pve-manager or proxmox-backup-server as there API, UI and possibly other stuff are shared in the same repo. You could use: "safe destroy: add possibility to show a small extra note" On 18.08.20 10:40, Hannes Laimer wrote: > Signed-off-by: Hannes Laimer > --- > src/window/SafeRemove.js | 28 ++++++++++++++++++++++++++++ > 1 file changed, 28 insertions(+) > > diff --git a/src/window/SafeRemove.js b/src/window/SafeRemove.js > index c541272..c3fc7dd 100644 > --- a/src/window/SafeRemove.js > +++ b/src/window/SafeRemove.js ... > @@ -173,6 +199,8 @@ Ext.define('Proxmox.window.SafeRemove', { > msg = Proxmox.Utils.format_task_description('cephdestroypool', item.id); > } else if (item.type === 'Image') { > msg = Proxmox.Utils.format_task_description('unknownimgdel', item.id); > + } else if (item.type === 'Dir') { > + msg = `${gettext('Directory')} ${item.id} - ${gettext('Remove')}` few issues: 1. misses a semicolon - did you even built it once? I'd guess that eslint complains about it then. 2. has nothing to do with this patch, should be separate 3. why not a format task description? In combination with my comments on patch 1/5 that could be much nicer, avoiding this clunky if/else block completely. > } else { > throw "unknown item type specified"; > } >