mirror of
https://github.com/nextcloud/server.git
synced 2026-04-22 06:37:56 -04:00
Consider link shares in removeShare method in SharingTab
Currently, the `removeShare` method in the `SharingTab` view, does not take into account `linkShares`. Since link shares now shares thesame detail view with other share types, it should therefore be considered hence this commit. Resolves : https://github.com/nextcloud/server/issues/40396 Signed-off-by: fenn-cs <fenn25.fn@gmail.com> Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
This commit is contained in:
parent
d32e03ddac
commit
ef5bb420f2
10 changed files with 20 additions and 13 deletions
|
|
@ -356,9 +356,16 @@ export default {
|
|||
* @param {Share} share the share to remove
|
||||
*/
|
||||
removeShare(share) {
|
||||
const index = this.shares.findIndex(item => item.id === share.id)
|
||||
// eslint-disable-next-line vue/no-mutating-props
|
||||
this.shares.splice(index, 1)
|
||||
// Get reference for this.linkShares or this.shares
|
||||
const shareList
|
||||
= share.type === this.SHARE_TYPES.SHARE_TYPE_EMAIL
|
||||
|| share.type === this.SHARE_TYPES.SHARE_TYPE_LINK
|
||||
? this.linkShares
|
||||
: this.shares
|
||||
const index = shareList.findIndex(item => item.id === share.id)
|
||||
if (index !== -1) {
|
||||
shareList.splice(index, 1)
|
||||
}
|
||||
},
|
||||
/**
|
||||
* Await for next tick and render after the list updated
|
||||
|
|
|
|||
3
dist/6898-6898.js
vendored
Normal file
3
dist/6898-6898.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/6898-6898.js.map
vendored
Normal file
1
dist/6898-6898.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
3
dist/8087-8087.js
vendored
3
dist/8087-8087.js
vendored
File diff suppressed because one or more lines are too long
1
dist/8087-8087.js.map
vendored
1
dist/8087-8087.js.map
vendored
File diff suppressed because one or more lines are too long
4
dist/core-common.js
vendored
4
dist/core-common.js
vendored
File diff suppressed because one or more lines are too long
2
dist/core-common.js.map
vendored
2
dist/core-common.js.map
vendored
File diff suppressed because one or more lines are too long
4
dist/files_sharing-files_sharing_tab.js
vendored
4
dist/files_sharing-files_sharing_tab.js
vendored
File diff suppressed because one or more lines are too long
2
dist/files_sharing-files_sharing_tab.js.map
vendored
2
dist/files_sharing-files_sharing_tab.js.map
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue