[pve-devel] [PATCH v2 proxmox-backup 4/7] ui: tasks: use format_task_status
Fabian Ebner
f.ebner at proxmox.com
Fri Apr 9 10:44:33 CEST 2021
Signed-off-by: Fabian Ebner <f.ebner at proxmox.com>
---
Dependency bump for widget-toolkit is needed.
Changes from v1:
* use new helper instead of duplicating changes
www/panel/Tasks.js | 9 +--------
1 file changed, 1 insertion(+), 8 deletions(-)
diff --git a/www/panel/Tasks.js b/www/panel/Tasks.js
index a194e478..a64e0eee 100644
--- a/www/panel/Tasks.js
+++ b/www/panel/Tasks.js
@@ -372,14 +372,7 @@ Ext.define('PBS.node.Tasks', {
return '';
}
- let parsed = Proxmox.Utils.parse_task_status(value);
- switch (parsed) {
- case 'unknown': return Proxmox.Utils.unknownText;
- case 'error': return Proxmox.Utils.errorText + ': ' + value;
- case 'ok': // fall-through
- case 'warning': // fall-through
- default: return value;
- }
+ return Proxmox.Utils.format_task_status(value);
},
},
],
--
2.20.1
More information about the pve-devel
mailing list