From ee4b6cf18b4047238315fddfc12cf5eafb47709f Mon Sep 17 00:00:00 2001 From: Lukas Wagner Date: Tue, 23 Apr 2024 13:52:18 +0200 Subject: [PATCH] ui: utils: add overrides for known notification metadata fields/values This mechanism allows having nice, translatable notification event types and fields. Signed-off-by: Lukas Wagner Tested-by: Gabriel Goller Reviewed-by: Gabriel Goller Tested-by: Maximiliano Sandoval Signed-off-by: Thomas Lamprecht --- www/Utils.js | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/www/Utils.js b/www/Utils.js index 0c1f78b6..14888c75 100644 --- a/www/Utils.js +++ b/www/Utils.js @@ -435,6 +435,23 @@ Ext.define('PBS.Utils', { zfscreate: [gettext('ZFS Storage'), gettext('Create')], }); + Proxmox.Utils.overrideNotificationFieldName({ + 'datastore': gettext('Datastore'), + 'job-id': gettext('Job ID'), + 'media-pool': gettext('Media Pool'), + }); + + Proxmox.Utils.overrideNotificationFieldValue({ + 'acme': gettext('ACME certificate renewal'), + 'gc': gettext('Garbage collection'), + 'package-updates': gettext('Package updates are available'), + 'prune': gettext('Prune job'), + 'sync': gettext('Sync job'), + 'tape-backup': gettext('Tape backup notifications'), + 'tape-load': gettext('Tape loading request'), + 'verify': gettext('Verification job'), + }); + Proxmox.Schema.overrideAuthDomains({ pbs: { name: 'Proxmox Backup authentication server',