mirror of
https://github.com/nextcloud/server.git
synced 2026-04-15 22:11:17 -04:00
Merge pull request #58718 from nextcloud/backport/58204/stable32
Some checks are pending
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Integration sqlite / changes (push) Waiting to run
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, --tags ~@large files_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, capabilities_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, collaboration_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, comments_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, dav_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, federation_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, file_conversions) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, files_reminders) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, filesdrop_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, ldap_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, openldap_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, openldap_numerical_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, remoteapi_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, routing_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, setup_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, sharees_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, sharing_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, theming_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, videoverification_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite-summary (push) Blocked by required conditions
Some checks are pending
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Integration sqlite / changes (push) Waiting to run
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, --tags ~@large files_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, capabilities_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, collaboration_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, comments_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, dav_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, federation_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, file_conversions) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, files_reminders) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, filesdrop_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, ldap_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, openldap_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, openldap_numerical_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, remoteapi_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, routing_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, setup_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, sharees_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, sharing_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, theming_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite (stable32, 8.1, stable32, videoverification_features) (push) Blocked by required conditions
Integration sqlite / integration-sqlite-summary (push) Blocked by required conditions
[stable32] Remove external shares from share list
This commit is contained in:
commit
a1d3429f67
9 changed files with 32 additions and 48 deletions
|
|
@ -432,23 +432,8 @@ export default {
|
|||
)
|
||||
|
||||
for (const share of shares) {
|
||||
if ([ShareType.Link, ShareType.Email].includes(share.type)) {
|
||||
this.linkShares.push(share)
|
||||
} else if ([ShareType.Remote, ShareType.RemoteGroup].includes(share.type)) {
|
||||
if (this.config.showFederatedSharesToTrustedServersAsInternal) {
|
||||
if (share.isTrustedServer) {
|
||||
this.shares.push(share)
|
||||
} else {
|
||||
this.externalShares.push(share)
|
||||
}
|
||||
} else if (this.config.showFederatedSharesAsInternal) {
|
||||
this.shares.push(share)
|
||||
} else {
|
||||
this.externalShares.push(share)
|
||||
}
|
||||
} else {
|
||||
this.shares.push(share)
|
||||
}
|
||||
const shareList = this.findShareListByShare(share)
|
||||
shareList.push(share)
|
||||
}
|
||||
|
||||
logger.debug(`Processed ${this.linkShares.length} link share(s)`)
|
||||
|
|
@ -510,23 +495,8 @@ export default {
|
|||
* @param {Function} [resolve] a function to run after the share is added and its component initialized
|
||||
*/
|
||||
addShare(share, resolve = () => { }) {
|
||||
// only catching share type MAIL as link shares are added differently
|
||||
// meaning: not from the ShareInput
|
||||
if (share.type === ShareType.Email) {
|
||||
this.linkShares.unshift(share)
|
||||
} else if ([ShareType.Remote, ShareType.RemoteGroup].includes(share.type)) {
|
||||
if (this.config.showFederatedSharesAsInternal) {
|
||||
this.shares.unshift(share)
|
||||
} if (this.config.showFederatedSharesToTrustedServersAsInternal) {
|
||||
if (share.isTrustedServer) {
|
||||
this.shares.unshift(share)
|
||||
}
|
||||
} else {
|
||||
this.externalShares.unshift(share)
|
||||
}
|
||||
} else {
|
||||
this.shares.unshift(share)
|
||||
}
|
||||
const shareList = this.findShareListByShare(share)
|
||||
shareList.unshift(share)
|
||||
this.awaitForShare(share, resolve)
|
||||
},
|
||||
/**
|
||||
|
|
@ -535,13 +505,27 @@ export default {
|
|||
* @param {Share} share the share to remove
|
||||
*/
|
||||
removeShare(share) {
|
||||
// Get reference for this.linkShares or this.shares
|
||||
const shareList
|
||||
= share.type === ShareType.Email
|
||||
|| share.type === ShareType.Link
|
||||
? this.linkShares
|
||||
: this.shares
|
||||
const index = shareList.findIndex(item => item.id === share.id)
|
||||
this.removeShareFromList(this.findShareListByShare(share), share)
|
||||
},
|
||||
|
||||
findShareListByShare(share) {
|
||||
if (share.type === ShareType.Remote || share.type === ShareType.RemoteGroup) {
|
||||
if (this.config.showFederatedSharesToTrustedServersAsInternal) {
|
||||
return share.isTrustedServer ? this.shares : this.externalShares
|
||||
} else if (this.config.showFederatedSharesAsInternal) {
|
||||
return this.shares
|
||||
} else {
|
||||
return this.externalShares
|
||||
}
|
||||
} else if (share.type === ShareType.Email || share.type === ShareType.Link) {
|
||||
return this.linkShares
|
||||
} else {
|
||||
return this.shares
|
||||
}
|
||||
},
|
||||
|
||||
removeShareFromList(shareList, share) {
|
||||
const index = shareList.findIndex((item) => item.id === share.id)
|
||||
if (index !== -1) {
|
||||
shareList.splice(index, 1)
|
||||
}
|
||||
|
|
|
|||
1
dist/4505-4505.js.map
vendored
1
dist/4505-4505.js.map
vendored
File diff suppressed because one or more lines are too long
1
dist/4505-4505.js.map.license
vendored
1
dist/4505-4505.js.map.license
vendored
|
|
@ -1 +0,0 @@
|
|||
4505-4505.js.license
|
||||
4
dist/4505-4505.js → dist/9530-9530.js
vendored
4
dist/4505-4505.js → dist/9530-9530.js
vendored
File diff suppressed because one or more lines are too long
1
dist/9530-9530.js.map
vendored
Normal file
1
dist/9530-9530.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/9530-9530.js.map.license
vendored
Symbolic link
1
dist/9530-9530.js.map.license
vendored
Symbolic link
|
|
@ -0,0 +1 @@
|
|||
9530-9530.js.license
|
||||
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