mirror of
https://git.proxmox.com/git/proxmox-widget-toolkit
synced 2025-05-29 15:33:08 +00:00
utils: task descriptions: allow to add/override entries
Allows having only the common ones here, and more special ones in the per product code. Sometimes there are simple worker IDs which can have a very different meaning for one product, with this that clash can be resolved in a standardized way. Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
f4d366dc85
commit
4afd5b2f9d
7
Utils.js
7
Utils.js
@ -552,6 +552,13 @@ Ext.define('Proxmox.Utils', { utilities: {
|
|||||||
zfscreate: [ gettext('ZFS Storage'), gettext('Create') ]
|
zfscreate: [ gettext('ZFS Storage'), gettext('Create') ]
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// to add or change existing for product specific ones
|
||||||
|
override_task_descriptions: function(extra) {
|
||||||
|
for (const [key, value] of Object.entries(extra)) {
|
||||||
|
Proxmox.Utils.task_desc_table[key] = value;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
format_task_description: function(type, id) {
|
format_task_description: function(type, id) {
|
||||||
var farray = Proxmox.Utils.task_desc_table[type];
|
var farray = Proxmox.Utils.task_desc_table[type];
|
||||||
var text;
|
var text;
|
||||||
|
Loading…
Reference in New Issue
Block a user