mirror of
https://github.com/nextcloud/server.git
synced 2026-04-28 17:48:40 -04:00
fix(files_sharing): open-in-files should open a folder and not the parent
For files this behavior is fine, but for folders the folder itself should be opened. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
This commit is contained in:
parent
fd14d66373
commit
5d2d98fefe
1 changed files with 3 additions and 1 deletions
|
|
@ -21,7 +21,7 @@
|
|||
*/
|
||||
import type { Node } from '@nextcloud/files'
|
||||
|
||||
import { registerFileAction, FileAction, DefaultType } from '@nextcloud/files'
|
||||
import { registerFileAction, FileAction, DefaultType, FileType } from '@nextcloud/files'
|
||||
import { translate as t } from '@nextcloud/l10n'
|
||||
|
||||
import { sharesViewId, sharedWithYouViewId, sharedWithOthersViewId, sharingByLinksViewId } from '../views/shares'
|
||||
|
|
@ -41,6 +41,8 @@ export const action = new FileAction({
|
|||
].includes(view.id),
|
||||
|
||||
async exec(node: Node) {
|
||||
const isFolder = node.type === FileType.Folder
|
||||
|
||||
window.OCP.Files.Router.goToRoute(
|
||||
null, // use default route
|
||||
{ view: 'files', fileid: node.fileid },
|
||||
|
|
|
|||
Loading…
Reference in a new issue