[PATCH proxmox-backup v7 26/34] ui: utils: add helper to render notification threshold property string

Christian Ebner
2026-04-01T13:48:38Z

Show thresholds as comma and space separated list of configured values,
skipping empty ones.

Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
Reviewed-by: Hannes Laimer <h.laimer@proxmox.com>
Tested-by: Hannes Laimer <h.laimer@proxmox.com>
---
www/Utils.js | 9 +++++++++
1 file changed, 9 insertions(+)

diff --git a/www/Utils.js b/www/Utils.js
index 25fba16f9..d2f3a3c99 100644
--- a/www/Utils.js
+++ b/www/Utils.js
@@ -933,4 +933,13 @@ Ext.define('PBS.Utils', {

return options.join(', ');
},
+
+ render_notification_thresholds: function (notificationThresholds) {
+ let thresholds = [];
+ for (const [k, v] of Object.entries(notificationThresholds)) {
+ thresholds.push(`${k}: ${v}`);
+ }
+
+ return thresholds.join(', ');
+ },
});
--
2.47.3