diff --git a/tdrive/frontend/src/app/features/drive/hooks/use-drive-preview.ts b/tdrive/frontend/src/app/features/drive/hooks/use-drive-preview.ts index ae15f1a0..ebab9c82 100644 --- a/tdrive/frontend/src/app/features/drive/hooks/use-drive-preview.ts +++ b/tdrive/frontend/src/app/features/drive/hooks/use-drive-preview.ts @@ -31,7 +31,7 @@ export const useDrivePreviewModal = () => { const close = () => { setStatus({ item: null, loading: true }); - history.push(RouterServices.generateRouteFromState({companyId: company, viewId: "", itemId: ""})); + history.push(RouterServices.generateRouteFromState({companyId: company, itemId: ""})); } return { open, close, isOpen: !!status.item }; diff --git a/tdrive/frontend/src/app/features/router/services/router-service.ts b/tdrive/frontend/src/app/features/router/services/router-service.ts index 06235326..0d55298c 100644 --- a/tdrive/frontend/src/app/features/router/services/router-service.ts +++ b/tdrive/frontend/src/app/features/router/services/router-service.ts @@ -51,6 +51,7 @@ class RouterServices extends Observable { '/client/:companyId', '/client/:companyId/v/:viewId', '/client/:companyId/preview/:itemId', + '/client/:companyId/v/:viewId/preview/:itemId', '/client/:companyId/w/:workspaceId', '/client/:companyId/w/:workspaceId/c/:channelId', '/client/:companyId/w/:workspaceId/c/:channelId/t/:threadId', diff --git a/tdrive/frontend/src/app/views/client/body/drive/documents/document-row.tsx b/tdrive/frontend/src/app/views/client/body/drive/documents/document-row.tsx index b1f140da..d362e678 100644 --- a/tdrive/frontend/src/app/views/client/body/drive/documents/document-row.tsx +++ b/tdrive/frontend/src/app/views/client/body/drive/documents/document-row.tsx @@ -57,7 +57,7 @@ export const DocumentRow = ({ const device = getDevice(); console.log("DEVICE:: " + device); if (device != "ios" && device != "android") { - history.push(RouterServices.generateRouteFromState({companyId: company, viewId: "", itemId: item.id})); + history.push(RouterServices.generateRouteFromState({companyId: company, itemId: item.id})); open(item); } };