Add busy state to volumes view

This commit is contained in:
Johannes Zellner
2025-01-02 19:33:48 +01:00
parent c3ab43a9fc
commit 8c8ae57103

View File

@@ -84,7 +84,7 @@
<Card>
<div v-html="$t('volumes.description')"></div>
<br/>
<TableView :columns="columns" :model="volumes">
<TableView :columns="columns" :model="volumes" :busy="busy">
<template #target="slotProps">
{{ (slotProps.mountType === 'mountpoint' || slotProps.mountType === 'filesystem') ? slotProps.hostPath : (slotProps.mountOptions.host || slotProps.mountOptions.diskPath || slotProps.hostPath) + (slotProps.mountOptions.remoteDir || '') }}
</template>
@@ -182,6 +182,7 @@ export default {
},
data() {
return {
busy: true,
mountTypeOptions: [
{ name: 'CIFS', value: 'cifs' },
{ name: 'EXT4', value: 'ext4' },
@@ -210,7 +211,9 @@ export default {
},
methods: {
async refresh() {
this.busy = true;
this.volumes = await volumesModel.list();
this.busy = false;
for (const v of this.volumes) {
const status = await volumesModel.getStatus(v.id);