From: Gabriel Goller <g.goller@proxmox.com>
To: pbs-devel@lists.proxmox.com
Subject: [pbs-devel] [PATCH v5 proxmox-backup 5/5] ui: dashboard: nicely display kernel version
Date: Wed, 29 Nov 2023 14:23:39 +0100 [thread overview]
Message-ID: <20231129132339.157063-6-g.goller@proxmox.com> (raw)
In-Reply-To: <20231129132339.157063-1-g.goller@proxmox.com>
Extract and display the build version and kernel
release nicely.
Signed-off-by: Gabriel Goller <g.goller@proxmox.com>
---
www/panel/NodeInfo.js | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/www/panel/NodeInfo.js b/www/panel/NodeInfo.js
index cba6d2a1..72f97c7c 100644
--- a/www/panel/NodeInfo.js
+++ b/www/panel/NodeInfo.js
@@ -140,11 +140,20 @@ Ext.define('PBS.NodeInfoPanel', {
value: '',
},
{
- itemId: 'kversion',
colspan: 2,
title: gettext('Kernel Version'),
printBar: false,
- textField: 'kversion',
+ // TODO: remove with next major and only use newish current-kernel textfield
+ multiField: true,
+ //textField: 'current-kernel',
+ renderer: ({ data }) => {
+ if (!data['current-kernel']) {
+ return data.kversion;
+ }
+ let kernel = data['current-kernel'];
+ let buildDate = kernel.version.match(/\((.+)\)\s*$/)[1] ?? 'unknown';
+ return `${kernel.sysname} ${kernel.release} (${buildDate})`;
+ },
value: '',
},
{
--
2.39.2
prev parent reply other threads:[~2023-11-29 13:24 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-29 13:23 [pbs-devel] [PATCH v5 proxmox{, -backup} 0/5] Add boot_mode, improve " Gabriel Goller
2023-11-29 13:23 ` [pbs-devel] [PATCH v5 proxmox 1/5] sys: add helper to get bootmode and secureboot status Gabriel Goller
2023-11-29 13:23 ` [pbs-devel] [PATCH v5 proxmox-backup 2/5] node: status: added bootmode Gabriel Goller
2023-11-29 13:23 ` [pbs-devel] [PATCH v5 proxmox-backup 3/5] ui: dashboard: show the bootmode Gabriel Goller
2023-11-29 13:23 ` [pbs-devel] [PATCH v5 proxmox-backup 4/5] node: status: declutter kernel-version Gabriel Goller
2023-11-29 13:23 ` Gabriel Goller [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=20231129132339.157063-6-g.goller@proxmox.com \
--to=g.goller@proxmox.com \
--cc=pbs-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