[pve-devel] [PATCH proxmox-backup 2/6] ui: tasks: use warningsText

Fabian Ebner f.ebner at proxmox.com
Fri Mar 12 13:53:25 CET 2021


to avoid having capitalized 'WARNINGS' (especially since 'Error' is not) and
support different languages.

Signed-off-by: Fabian Ebner <f.ebner at proxmox.com>
---

Dependency bump for widget-toolkit is needed.

 www/panel/Tasks.js | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/www/panel/Tasks.js b/www/panel/Tasks.js
index a194e478..adc82d05 100644
--- a/www/panel/Tasks.js
+++ b/www/panel/Tasks.js
@@ -376,8 +376,9 @@ Ext.define('PBS.node.Tasks', {
 		switch (parsed) {
 		    case 'unknown': return Proxmox.Utils.unknownText;
 		    case 'error': return Proxmox.Utils.errorText + ': ' + value;
+		    case 'warning': return Proxmox.Utils.warningsText +
+			value.replace('WARNINGS', '');
 		    case 'ok': // fall-through
-		    case 'warning': // fall-through
 		    default: return value;
 		}
 	    },
-- 
2.20.1






More information about the pve-devel mailing list