refactoring part 1

This commit is contained in:
Peter Papp
2021-08-23 09:32:21 +02:00
parent a926545146
commit cc0436b8f3
8 changed files with 54 additions and 59 deletions

View File

@@ -121,7 +121,7 @@ export default {
},
canEditName() {
return !this.$isMobile()
&& !this.$isThisLocation(['trash', 'trash-root'])
&& !this.$isThisRoute(this.$route, ['Trash'])
&& !this.$checkPermission('visitor')
&& !(this.sharedDetail && this.sharedDetail.type === 'file')
},

View File

@@ -117,7 +117,7 @@ export default {
return mimetypes.includes(this.item.mimetype) && this.item.type === 'audio'
},
canEditName() {
return !this.$isMobile() && !this.$isThisLocation(['trash', 'trash-root']) && !this.$checkPermission('visitor') && !(this.sharedDetail && this.sharedDetail.type === 'file')
return !this.$isMobile() && !this.$isThisRoute(this.$route, ['Trash']) && !this.$checkPermission('visitor') && !(this.sharedDetail && this.sharedDetail.type === 'file')
},
canDrag() {
return !this.isDeleted && this.$checkPermission(['master', 'editor'])