acme domains: fix ui-reload gettext + code cleanup

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Thomas Lamprecht 2021-03-28 16:54:51 +02:00
parent 08d092b679
commit c5cade500a

View File

@ -206,12 +206,13 @@ Ext.define('Proxmox.panel.ACMEDomains', {
orderFinished: function(success, cert) { orderFinished: function(success, cert) {
if (!success || !cert.reloadUi) return; if (!success || !cert.reloadUi) return;
var txt = gettext('gui will be restarted with new certificates, please reload!');
Ext.getBody().mask(txt, ['x-mask-loading']); Ext.getBody().mask(
// reload after 10 seconds automatically gettext('API server will be restarted to use new certificates, please reload web-interface!'),
Ext.defer(function() { ['pve-static-mask'],
window.location.reload(true); );
}, 10000); // try to reload after 10 seconds automatically
Ext.defer(() => window.location.reload(true), 10000);
}, },
reload: function() { reload: function() {