Skip to content

Commit

Permalink
feat: add new account management routes and update navigation paths f…
Browse files Browse the repository at this point in the history
…or user and policy creation
  • Loading branch information
hervedombya committed Jan 16, 2025
1 parent 96717ad commit c53a160
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 2 deletions.
28 changes: 28 additions & 0 deletions src/react/Routes.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,12 @@ import { useBasenameRelativeNavigate } from './ShellHooksContext';
import Workflows from './workflow/Workflows';
import CreateWorkflow from './workflow/CreateWorkflow';
import Objects from './databrowser/objects/Objects';
import Attachments from './account/iamAttachment/Attachments';
import AccountUpdateUser from './account/AccountUpdateUser';
import UpdateAccountPolicy from './account/UpdateAccountPolicy';
import AccountUserAccessKeys from './account/AccountUserAccessKeys';
import AccountCreateUser from './account/AccountCreateUser';
import CreateAccountPolicy from './account/CreateAccountPolicy';

export const RemoveTrailingSlash = ({ ...rest }) => {
const location = useLocation();
Expand Down Expand Up @@ -159,11 +165,33 @@ function PrivateRoutes() {
element={<LocationEditor />}
/>
<Route path="workflows/*" element={<RedirectToAccount />} />
<Route path={`create-user/*`} element={<AccountCreateUser />} />
<Route path={`create-policy/*`} element={<CreateAccountPolicy />} />
<Route path="create-account/*" element={<AccountCreate />} />
<Route path="create-dataservice/*" element={<EndpointCreate />} />
<Route path="dataservices/*" element={<Endpoints />} />
<Route path="locations/*" element={<Locations />} />
<Route path="veeam/configuration/*" element={<VeeamSteppers />} />
<Route
path={`accounts/:accountName/policies/:policyArn/attachments/*`}
element={<Attachments />}
/>
<Route
path={`accounts/:accountName/users/:IAMUserName/update-user/*`}
element={<AccountUpdateUser />}
/>
<Route
path={`accounts/:accountName/policies/:policyArn/:defaultVersionId/update-policy/*`}
element={<UpdateAccountPolicy />}
/>
<Route
path={`accounts/:accountName/users/:IAMUserName/access-keys/*`}
element={<AccountUserAccessKeys />}
/>
<Route
path="accounts/:accountName/users/:IAMUserName/attachments/*"
element={<Attachments />}
/>
<Route
path={'accounts/:accountName/workflows/:workflowId/*'}
element={<Workflows />}
Expand Down
2 changes: 1 addition & 1 deletion src/react/account/AccountPoliciesList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,7 @@ const AccountPoliciesList = ({ accountName }: { accountName: string }) => {
icon={<Icon name="Create-add" color="textSecondary" />}
label="Create Policy"
variant="primary"
onClick={() => navigate('create-policy')}
onClick={() => navigate('/create-policy')}
type="submit"
/>
}
Expand Down
2 changes: 1 addition & 1 deletion src/react/account/AccountUserList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ const AccountUserList = ({ accountName }: { accountName?: string }) => {
icon={<Icon name="Create-add" color="textSecondary" />}
label="Create User"
variant="primary"
onClick={() => navigate('create-user')}
onClick={() => navigate('/create-user')}
type="submit"
/>
}
Expand Down

0 comments on commit c53a160

Please sign in to comment.