mirror of
https://git.proxmox.com/git/proxmox-backup
synced 2025-08-14 06:54:51 +00:00
ui: mask unmounted datastores in datastore overview
Currently, showing the Datastore summary page leads to errors since the status returned by the API does not contain any fields that are checked by the component rendering the datastore summary. We solve this by checking if the datastore is currently mounted first and mask the element if it is currently unmounted. Signed-off-by: Stefan Hanreich <s.hanreich@proxmox.com> Tested-by: Shannon Sterz <s.sterz@proxmox.com>
This commit is contained in:
parent
6ab04f14ae
commit
38d961f9e4
@ -35,6 +35,15 @@ Ext.define('PBS.datastore.DataStoreListSummary', {
|
||||
let me = this;
|
||||
let vm = me.getViewModel();
|
||||
|
||||
if (statusData['mount-status'] === 'notmounted') {
|
||||
let maskMessage = gettext('Datastore is not mounted');
|
||||
let maskIcon = 'fa pbs-unplugged-mask';
|
||||
me.mask(maskMessage, maskIcon);
|
||||
return;
|
||||
} else if (me.isMasked()) {
|
||||
me.unmask();
|
||||
}
|
||||
|
||||
if (statusData.error !== undefined) {
|
||||
Proxmox.Utils.API2Request({
|
||||
url: `/config/datastore/${statusData.store}`,
|
||||
|
Loading…
Reference in New Issue
Block a user