Skip to content

Commit

Permalink
Add temporary new settings_new route
Browse files Browse the repository at this point in the history
  • Loading branch information
arbulu89 committed Nov 10, 2022
1 parent 6fed75a commit d305245
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
7 changes: 5 additions & 2 deletions assets/js/components/ClusterDetails/ClusterSettings.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import classNames from 'classnames';
import BackButton from '@components/BackButton';
import { Tab } from '@headlessui/react';
import { ChecksSelection } from '@components/ClusterDetails/ChecksSelection';
import ChecksSelectionNew from '@components/ClusterDetails/ChecksSelectionNew';
import { ConnectionSettings } from '@components/ClusterDetails/ConnectionSettings';
import { getCluster } from '@state/selectors';
import TriggerChecksExecutionRequest from '@components/TriggerChecksExecutionRequest';
Expand All @@ -17,13 +18,15 @@ import WarningBanner from '@components/Banners/WarningBanner';

export const UNKNOWN_PROVIDER = 'unknown';

export const ClusterSettings = () => {
export const ClusterSettings = ({ newChecksSelectionView = false }) => {
const { clusterID } = useParams();

const cluster = useSelector(getCluster(clusterID));

const tabsSettings = {
'Checks Selection': (
'Checks Selection': newChecksSelectionView ? (
<ChecksSelectionNew clusterId={clusterID} cluster={cluster} />
) : (
<ChecksSelection clusterId={clusterID} cluster={cluster} />
),
'Connection Settings': (
Expand Down
4 changes: 4 additions & 0 deletions assets/js/trento.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ const App = () => {
path="clusters/:clusterID/settings"
element={<ClusterSettings />}
/>
<Route
path="clusters/:clusterID/settings_new"
element={<ClusterSettings newChecksSelectionView={true} />}
/>
<Route
path="clusters/:clusterID/checks/results"
element={<ChecksResults />}
Expand Down

0 comments on commit d305245

Please sign in to comment.