diff options
author | Vincent Petry <vincent@nextcloud.com> | 2021-07-02 17:42:55 +0200 |
---|---|---|
committer | Vincent Petry <vincent@nextcloud.com> | 2021-07-27 12:19:24 +0200 |
commit | 46b8cf4f64a8a2d9320ded762eeb0a4b9347181d (patch) | |
tree | 2425ff8806f82cff5e46142af504430f612566f0 /apps/files_sharing/js | |
parent | 7130a98e4730c9ba4e40593a958beb3683d02ef1 (diff) | |
download | nextcloud-server-46b8cf4f64a8a2d9320ded762eeb0a4b9347181d.tar.gz nextcloud-server-46b8cf4f64a8a2d9320ded762eeb0a4b9347181d.zip |
Remove "Reject share" for pending remote shares
In the list of pending shares, the option for rejecting the share has
been removed.
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
Diffstat (limited to 'apps/files_sharing/js')
-rw-r--r-- | apps/files_sharing/js/app.js | 6 | ||||
-rw-r--r-- | apps/files_sharing/js/sharedfilelist.js | 4 |
2 files changed, 10 insertions, 0 deletions
diff --git a/apps/files_sharing/js/app.js b/apps/files_sharing/js/app.js index 6af8224baf4..8fb5cb02e56 100644 --- a/apps/files_sharing/js/app.js +++ b/apps/files_sharing/js/app.js @@ -315,6 +315,12 @@ OCA.Sharing.App = { permissions: OC.PERMISSION_ALL, iconClass: 'icon-close', type: OCA.Files.FileActions.TYPE_INLINE, + shouldRender(context) { + if (context.$file.attr('data-remote-id')) { + return false + } + return true + }, actionHandler(fileName, context) { const shareId = context.$file.data('shareId') let shareBase = 'shares' diff --git a/apps/files_sharing/js/sharedfilelist.js b/apps/files_sharing/js/sharedfilelist.js index 1f467f549d7..2afd8a21b31 100644 --- a/apps/files_sharing/js/sharedfilelist.js +++ b/apps/files_sharing/js/sharedfilelist.js @@ -96,6 +96,10 @@ $tr.attr('data-share-permissions', permission) } + if (fileData.remoteId) { + $tr.attr('data-remote-id', fileData.remoteId) + } + // add row with expiration date for link only shares - influenced by _createRow of filelist if (this._linksOnly) { var expirationTimestamp = 0 |