Skip to content

feat: add a pending page for users without roles - #111

Merged
MZC-CSC merged 3 commits into
m-cmp:mainfrom
MZC-CSC:develop
Oct 15, 2026
Merged

MZC-CSC merged 3 commits into
m-cmp:mainfrom
MZC-CSC:develop

Conversation

@MZC-CSC

@MZC-CSC MZC-CSC commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

What's Changed

  • When a screen opens, the console compares the full menu (Getmenuresources) with the user's menu (GetAllAvailableMenus). If the screen is a menu screen and is not in the user's menu, the user is sent to /auth/unauthorized#menuNotAllowed
  • Menu URLs follow the same rules as the sidebar (iframe: /_view/{id}, local: the path or the menu ID path). Screens that are not menus are not checked
  • After login, if the default screen (Infra Workloads) is not in the user's menu, the user goes to the first menu screen in sidebar order
  • Menu lists are cached for 60 seconds. If the lookup fails, the screen is not blocked and only a log entry is written

Waiting for role assignment page (/auth/pending)

  • If the user's menu has no screens (for example, right after sign-up approval with no group or role yet), the default screen and menu screens redirect to /auth/pending
  • The page explains that the user is waiting for role assignment and offers Change Password (reuses the existing modal and changepassword.js) and Logout

Related

  • Depends on m-cmp/mc-iam-manager v0.7.1

yh-noh and others added 3 commits October 15, 2026 10:14
- 화면 진입 시 전체 메뉴(Getmenuresources)와 사용자 메뉴(GetAllAvailableMenus)를 대조해, 메뉴 화면인데 사용자 메뉴에 없으면 /auth/unauthorized#menuNotAllowed 로 이동
- 메뉴 URL 은 사이드바와 같은 규칙(iframe: /_view/{id}, local: path 또는 메뉴 id 경로)으로 계산, 메뉴가 아닌 화면은 대상 아님
- 로그인 직후 기본 화면(Infra Workloads)이 사용자 메뉴에 없으면 사이드바 순서상 첫 메뉴 화면으로 이동
- 메뉴 목록은 60초 캐시, 조회 실패 시 화면을 막지 않고 로그만 남김
- 사용자 메뉴에 화면 메뉴가 하나도 없으면(가입 승인 직후 그룹·역할 미배정) 기본 화면·메뉴 화면 진입 시 /auth/pending 으로 이동
- /auth/pending: 안내 문구와 Change Password(기존 모달·changepassword.js 재사용), Logout 제공
- 메뉴 0개 사용자 단위 테스트 추가
fix: 사용자 메뉴에 없는 화면 URL 직접 접근 차단 및 역할 배정 대기 화면 추가
@MZC-CSC MZC-CSC changed the title feat: block menu screens the user cannot access and add a pending page for users without roles feat: add a pending page for users without roles Oct 15, 2026
@MZC-CSC
MZC-CSC merged commit d09cc79 into m-cmp:main Oct 15, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants