fixing connectors path redirection issue no to navigate dashboard (#2187)
This commit is contained in:
parent
46bcbb3436
commit
a77869783b
1 changed files with 50 additions and 44 deletions
|
@ -7,15 +7,20 @@ import {
|
|||
clusterConnectConnectorsRelativePath,
|
||||
clusterConnectorNewRelativePath,
|
||||
getNonExactPath,
|
||||
clusterConnectorsPath,
|
||||
} from 'lib/paths';
|
||||
import { BreadcrumbRoute } from 'components/common/Breadcrumb/Breadcrumb.route';
|
||||
import useAppParams from 'lib/hooks/useAppParams';
|
||||
|
||||
import ListContainer from './List/ListContainer';
|
||||
import NewContainer from './New/NewContainer';
|
||||
import DetailsContainer from './Details/DetailsContainer';
|
||||
import EditContainer from './Edit/EditContainer';
|
||||
|
||||
const Connect: React.FC = () => (
|
||||
const Connect: React.FC = () => {
|
||||
const { clusterName } = useAppParams();
|
||||
|
||||
return (
|
||||
<Routes>
|
||||
<Route
|
||||
index
|
||||
|
@ -51,13 +56,14 @@ const Connect: React.FC = () => (
|
|||
/>
|
||||
<Route
|
||||
path={clusterConnectConnectorsRelativePath}
|
||||
element={<Navigate to="/" replace />}
|
||||
element={<Navigate to={clusterConnectorsPath(clusterName)} replace />}
|
||||
/>
|
||||
<Route
|
||||
path={RouteParams.connectName}
|
||||
element={<Navigate to="/" replace />}
|
||||
/>
|
||||
</Routes>
|
||||
);
|
||||
);
|
||||
};
|
||||
|
||||
export default Connect;
|
||||
|
|
Loading…
Add table
Reference in a new issue