Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitfb1b8f0

Browse files
committed
Redirect organization auditing page
1 parent883353d commitfb1b8f0

File tree

2 files changed

+13
-5
lines changed

2 files changed

+13
-5
lines changed

‎site/src/modules/navigation.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,10 @@
22
*@fileoverview TODO: centralize navigation code here! URL constants, URL formatting, all of it
33
*/
44

5+
exportfunctionwithFilter(path:string,filter:string){
6+
returnpath+(filter ?`?filter=${encodeURIComponent(filter)}` :"");
7+
}
8+
59
exportconstAUDIT_LINK="/audit";
610

7-
exportconstUSERS_LINK=`/users?filter=${encodeURIComponent(
8-
"status:active",
9-
)}`;
11+
exportconstUSERS_LINK=withFilter("/users","status:active");

‎site/src/pages/ManagementSettingsPage/Sidebar.tsx

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { Sidebar as BaseSidebar } from "components/Sidebar/Sidebar";
99
import{Stack}from"components/Stack/Stack";
1010
import{UserAvatar}from"components/UserAvatar/UserAvatar";
1111
import{typeClassName,useClassName}from"hooks/useClassName";
12-
import{AUDIT_LINK,USERS_LINK}from"modules/navigation";
12+
import{AUDIT_LINK,USERS_LINK,withFilter}from"modules/navigation";
1313
import{useOrganizationSettings}from"./ManagementSettingsLayout";
1414

1515
exportconstSidebar:FC=()=>{
@@ -129,8 +129,14 @@ export const OrganizationSettingsNavigation: FC<
129129
<SidebarNavSubItemhref={urlForSubpage(organization.name,"groups")}>
130130
Groups
131131
</SidebarNavSubItem>
132+
{/* For now redirect to the site-wide audit page with the organization
133+
pre-filled into the filter. Based on user feedback we might want
134+
to serve a copy of the audit page or even delete this link. */}
132135
<SidebarNavSubItem
133-
href={urlForSubpage(organization.name,"auditing")}
136+
href={`/deployment${withFilter(
137+
AUDIT_LINK,
138+
`organization:${organization.name}`,
139+
)}`}
134140
>
135141
Auditing
136142
</SidebarNavSubItem>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp