X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/6a429aae0a80ca103bd1cad3f24864fbe215fc63..4076b2736c50e6122d3d840f9c1f6f7d2cf81c28:/src/store/process-logs-panel/process-logs-panel.ts diff --git a/src/store/process-logs-panel/process-logs-panel.ts b/src/store/process-logs-panel/process-logs-panel.ts index 65ed78d73d..e0753cde7b 100644 --- a/src/store/process-logs-panel/process-logs-panel.ts +++ b/src/store/process-logs-panel/process-logs-panel.ts @@ -1,3 +1,5 @@ +import { RootState } from '../store'; +import { matchProcessLogRoute } from '~/routes/routes'; // Copyright (C) The Arvados Authors. All rights reserved. // // SPDX-License-Identifier: AGPL-3.0 @@ -15,3 +17,9 @@ export interface ProcessLogs { export const getProcessPanelLogs = ({ selectedFilter, logs }: ProcessLogsPanel) => { return logs[selectedFilter]; }; + +export const getProcessLogsPanelCurrentUuid = ({ router }: RootState) => { + const pathname = router.location ? router.location.pathname : ''; + const match = matchProcessLogRoute(pathname); + return match ? match.params.id : undefined; +};