aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files/src/components
diff options
context:
space:
mode:
Diffstat (limited to 'apps/files/src/components')
-rw-r--r--apps/files/src/components/FileEntry.vue2
-rw-r--r--apps/files/src/components/FileEntry/FileEntryActions.vue3
-rw-r--r--apps/files/src/components/FileEntry/FileEntryName.vue2
-rw-r--r--apps/files/src/components/FileEntryGrid.vue2
-rw-r--r--apps/files/src/components/FileEntryMixin.ts7
5 files changed, 12 insertions, 4 deletions
diff --git a/apps/files/src/components/FileEntry.vue b/apps/files/src/components/FileEntry.vue
index 847decd4378..02ddb47f93e 100644
--- a/apps/files/src/components/FileEntry.vue
+++ b/apps/files/src/components/FileEntry.vue
@@ -16,7 +16,7 @@
class="files-list__row"
v-on="rowListeners">
<!-- Failed indicator -->
- <span v-if="source.attributes.failed" class="files-list__row--failed" />
+ <span v-if="isFailedSource" class="files-list__row--failed" />
<!-- Checkbox -->
<FileEntryCheckbox :fileid="fileid"
diff --git a/apps/files/src/components/FileEntry/FileEntryActions.vue b/apps/files/src/components/FileEntry/FileEntryActions.vue
index 24b26bd225e..d0306e5e848 100644
--- a/apps/files/src/components/FileEntry/FileEntryActions.vue
+++ b/apps/files/src/components/FileEntry/FileEntryActions.vue
@@ -93,6 +93,7 @@ import ArrowLeftIcon from 'vue-material-design-icons/ArrowLeft.vue'
import { useNavigation } from '../../composables/useNavigation'
import CustomElementRender from '../CustomElementRender.vue'
+
import logger from '../../logger.js'
// The registered actions list
@@ -160,7 +161,7 @@ export default defineComponent({
// Sorted actions that are enabled for this node
enabledActions() {
- if (this.source.attributes.failed) {
+ if (this.source.status === NodeStatus.FAILED) {
return []
}
diff --git a/apps/files/src/components/FileEntry/FileEntryName.vue b/apps/files/src/components/FileEntry/FileEntryName.vue
index 5e9036ad63d..4e5a3571e74 100644
--- a/apps/files/src/components/FileEntry/FileEntryName.vue
+++ b/apps/files/src/components/FileEntry/FileEntryName.vue
@@ -126,7 +126,7 @@ export default defineComponent({
},
linkTo() {
- if (this.source.attributes.failed) {
+ if (this.source.status === NodeStatus.FAILED) {
return {
is: 'span',
params: {
diff --git a/apps/files/src/components/FileEntryGrid.vue b/apps/files/src/components/FileEntryGrid.vue
index 31df827eea2..1ec4f173a0e 100644
--- a/apps/files/src/components/FileEntryGrid.vue
+++ b/apps/files/src/components/FileEntryGrid.vue
@@ -17,7 +17,7 @@
@dragend="onDragEnd"
@drop="onDrop">
<!-- Failed indicator -->
- <span v-if="source.attributes.failed" class="files-list__row--failed" />
+ <span v-if="isFailedSource" class="files-list__row--failed" />
<!-- Checkbox -->
<FileEntryCheckbox :fileid="fileid"
diff --git a/apps/files/src/components/FileEntryMixin.ts b/apps/files/src/components/FileEntryMixin.ts
index b9cc0398ef5..407df14fa7c 100644
--- a/apps/files/src/components/FileEntryMixin.ts
+++ b/apps/files/src/components/FileEntryMixin.ts
@@ -102,6 +102,13 @@ export default defineComponent({
return String(this.fileid) === String(this.currentFileId)
},
+ /**
+ * Check if the source is in a failed state after an API request
+ */
+ isFailedSource() {
+ return this.source.status === NodeStatus.FAILED
+ },
+
canDrag() {
if (this.isRenaming) {
return false