5
0
mirror of git://git.proxmox.com/git/proxmox-backup.git synced 2025-03-05 20:58:33 +03:00

ui: datastore summary: start store updates after mount task is done

Without this, we immediately start the store updates even before the
browser created the (async) mount API request. So it's very likely
that the first store load will still get an error due to the backing
device of the datastore not being mounted yet. That in turn will
trigger our error detection behavior in the load even listener and
disable periodic store updates again.

Move the start of the update into the taskDone handler. We do not need
to check if the task succeeded, as either it did, and we will do
periodic updates, or it did not and we do at least one update to load
the current status and then stop again auto-loading the store anyway.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Thomas Lamprecht 2024-11-25 20:22:31 +01:00
parent 127de88a95
commit f784201c63

View File

@ -272,9 +272,9 @@ Ext.define('PBS.DataStoreSummary', {
method: 'POST',
failure: response => Ext.Msg.alert(gettext('Error'), response.htmlStatus),
success: function(response, options) {
me.up('panel').statusStore.startUpdate();
Ext.create('Proxmox.window.TaskViewer', {
upid: response.result.data,
taskDone: () => me.up('panel').statusStore.startUpdate(),
}).show();
},
});