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 8BB1BB84BC for ; Mon, 4 Dec 2023 16:42:49 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 6372E1088A for ; Mon, 4 Dec 2023 16:42:19 +0100 (CET) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS for ; Mon, 4 Dec 2023 16:42:18 +0100 (CET) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id CF1BD4488D for ; Mon, 4 Dec 2023 16:42:17 +0100 (CET) Message-ID: <1d497261-271e-4a07-8f79-3ef1e8508f77@proxmox.com> Date: Mon, 4 Dec 2023 16:42:16 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: Proxmox Backup Server development discussion , Christian Ebner References: <20231130140104.378248-1-c.ebner@proxmox.com> From: Gabriel Goller In-Reply-To: <20231130140104.378248-1-c.ebner@proxmox.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-SPAM-LEVEL: Spam detection results: 0 AWL -0.163 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record T_SCC_BODY_TEXT_LINE -0.01 - Subject: Re: [pbs-devel] [PATCH proxmox-backup] ui: warn of missing gc-schedule, prune/verify jobs 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: Mon, 04 Dec 2023 15:42:49 -0000 Comments inline. On 11/30/23 15:01, Christian Ebner wrote: > Warn about a missing garbage collection schedule, prune job or verify > jobs configuration in summary panel of a datastore. > > Show the number of prune/verify job configurations, if there are jobs > configured. > > Signed-off-by: Christian Ebner > --- > www/datastore/Summary.js | 80 ++++++++++++++++++++++++++++++++++++++++ > 1 file changed, 80 insertions(+) > > diff --git a/www/datastore/Summary.js b/www/datastore/Summary.js > index a932b4e0..6a63ca14 100644 > --- a/www/datastore/Summary.js > +++ b/www/datastore/Summary.js > @@ -49,12 +49,19 @@ Ext.define('PBS.DataStoreInfo', { > usage: {}, > stillbad: 0, > mountpoint: "", > + gcScheduldeMsg: gettext('unknown'), Small typo here... This should say `gcScheduleMsg`. > + pruneJobMsg: gettext('unknown'), > + verifyJobMsg: gettext('unknown'), > }, > }, > > controller: { > xclass: 'Ext.app.ViewController', > > + fmtWarning: function(msg) { > + return ` ${msg}`; > + }, > + > onLoad: function(store, data, success) { > let me = this; > if (!success) { > @@ -101,6 +108,51 @@ Ext.define('PBS.DataStoreInfo', { > vm.set('ctcount', countstext(counts.ct)); > vm.set('vmcount', countstext(counts.vm)); > vm.set('hostcount', countstext(counts.host)); > + > + Proxmox.Utils.API2Request({ > + url: `/config/datastore/${me.view.datastore}`, > + success: function(response) { > + if (response.result.data['gc-schedule']) { > + vm.set('gcScheduleMsg', gettext('configured')); How about we put a green checkmark here (and on the other lines below)? Otherwise this wall of text looks kinda bleak :( We could add the `fa fa-check-circle` icon with the `good` (color: green) class? There are also a few linting issues: 3 issues marked with (*) could be auto-fixed using '--fix'. [./datastore/Summary.js]: WARN: line 123 col 4: comma-dangle - Missing trailing comma. (*) WARN: line 138 col 4: comma-dangle - Missing trailing comma. (*) WARN: line 153 col 4: comma-dangle - Missing trailing comma. (*)