Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/actions/sharingPopupAction.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ export const action = {
name: node.basename,
path: node.dirname,
size: node.size,
type: node.mime === 'httpd/unix-directory' ? 'dir' : 'file',
mimetype: node.mime,
permissions: node.permissions,
mime: node.mime,
})
Expand Down
2 changes: 2 additions & 0 deletions src/actions/sharingPopupMenuAction.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ export const action = {
path: node.dirname,
size: node.size,
permissions: node.permissions,
type: node.mime === 'httpd/unix-directory' ? 'dir' : 'file',
mimetype: node.mime,
mime: node.mime,
})

Expand Down
7 changes: 4 additions & 3 deletions src/components/SharingInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<div v-if="canReshare" class="sharing-search">
<SharingInputDetailsLink :file-info="fileInfo"
:disabled="!isValidValue"
:share.sync="newShare"

Check warning on line 27 in src/components/SharingInput.vue

View workflow job for this annotation

GitHub Actions / eslint

Unexpected mutation of "newShare" prop
@open-sharing-details-all="openDetails" />
<NcSelect ref="select"
v-model="value"
Expand Down Expand Up @@ -403,15 +403,18 @@

let request = null
try {
const itemType = this.fileInfo.type === 'dir' ? 'dir' : 'file'
request = await axios.get(generateOcsUrl('apps/files_sharing/api/v1/sharees_recommended'), {
params: {
format: 'json',
itemType: this.fileInfo.type,
itemType,
},
})
} catch (error) {
console.error('Error fetching recommendations', error)
return
} finally {
this.loading = false
}

// Add external results from the OCA.Sharing.ShareSearch api
Expand All @@ -425,8 +428,6 @@
this.recommendations = this.filterOutExistingShares(rawRecommendations)
.map(share => this.formatForMultiselect(share))
.concat(externalResults)

this.loading = false
},

/**
Expand Down
Loading