Skip to content

feat: 重构管制员中心 - #58

Merged
0x00A0 merged 56 commits into
VATPRChina:mainfrom
0x00A0:feat/controller-center
Jul 22, 2026
Merged

feat: 重构管制员中心#58
0x00A0 merged 56 commits into
VATPRChina:mainfrom
0x00A0:feat/controller-center

Conversation

@0x00A0

@0x00A0 0x00A0 commented Jul 18, 2026

Copy link
Copy Markdown
Member

新增

  • 管制员中心 /controllers:布局路由承载全部子页——大标签(我的训练 / 训练管理 / 申请审核,按角色显隐)+ 右侧资源栏 + 主栏 Outlet;标题/身份徽章/加载骨架统一在布局层,子页零重复
  • 我的训练:主-从式训练浏览器(列表+详情)、即将到来的活动报名一览;访客视图含入门引导 + 我的申请状态卡
  • 训练管理:原独立页并入为 /controllers/trainings 页内视图,训练列表+学员申请两层管理,详情页去壳后在中心骨架内渲染
  • 申请审核:/controllers/applications 收窄为纯审核页,审核列表 + 审计日志入口;申请流程页(新建/详情/审计)同样在骨架内渲染
  • 管制员列表表格化 /controller/controller-list:卡片网格改为可排序/筛选/搜索/分页的表(姓名、Rating、 DEL/GND/TWR/T2/APP/CTR/FSS/FMP/MIL 列)

移除

  • 独立的训练管理页、独立的申请列表页(重定向到中心)
  • 管制员列表页底部硬编码的军用席位名单段落
  • 导航冗余条目(ATC 训练、ATC 申请)

@0x00A0
0x00A0 marked this pull request as draft July 18, 2026 21:25
@0x00A0 0x00A0 changed the title feat: rebuild controller center as personal dashboard feat: 重构管制员中心 Jul 18, 2026
0x00A0 and others added 28 commits July 19, 2026 11:42
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Separate the applications page into two distinct sections:
- All users see their own application card and can apply when eligible
- Training directors see additional review section with the full review table

The canApply logic now treats both 'rejected' and 'aborted' statuses as
re-applicable, allowing users to resubmit after abort.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- identity chip in green for legibility in both color schemes
- add SOP and LOA links to controlling resources
- move resources into a sticky right sidebar on desktop so long
  training lists no longer push them below the fold
- cap training list height with its own scrollbar

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…terpart name

- training list now caps at max(24rem, viewport minus page chrome) on
  desktop instead of a fixed 32rem, and scrolls with the page on mobile
- list rows and detail meta show the other party: trainees see the
  trainer, trainers see the trainee

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- inner master-detail grid uses minmax(0) tracks with min-w-0 children
  so long monospace lines no longer force horizontal page overflow on
  phones and tablets
- resources sidebar moves to xl so iPad landscape keeps a single column
- selected training marked with a green left border; upcoming rows keep
  their badge
- training list rows, mobile back button, and resource cards now use
  Mantine UnstyledButton/Button

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Revert the UnstyledButton conversions; the Mantine guideline means no
third-party UI libraries besides Mantine, not wrapping every native
element. Overflow fixes, green selected border, and xl sidebar stay.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Prevents the become-a-controller guide from flashing before the
dashboard for logged-in controllers on refresh.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…dy toolbar

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ear contrast in both schemes

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… translations

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…black too

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…t via search param

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…t view

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
0x00A0 and others added 21 commits July 21, 2026 00:21
…side the center layout

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…lications item

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…on refetch loop

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…etches cannot loop it

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ment roles to lib

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The two-role gate locked out controller-training-instructor and
controller-training-director, who could reach the old ungated page.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…t tab

The instructor identity lives in ATC permission state (UserControllerState
"mentor"), not in UserRole, so the role-only gate hid the tab from mentors.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…e application entry at the form

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…e application entry at the form

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Item hover was gray-50 on a white dropdown (near-invisible) and large
tiles lightened on hover; both now darken one step in light mode.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…utton

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…dcoded military roster

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Hide the redundant global search (the controller column already has its
own text filter), pin the header while scrolling, center the position
and military column headers, sharpen the mentor/military badge colors,
and shorten the military column label to MIL.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@0x00A0
0x00A0 marked this pull request as ready for review July 22, 2026 02:18
@0x00A0
0x00A0 requested a review from xfoxfu July 22, 2026 02:23
xfoxfu
xfoxfu previously approved these changes Jul 22, 2026

@xfoxfu xfoxfu left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM,部分小修改建议可以后续另行提交 PR 重构。

Comment thread src/routes/controllers.tsx Outdated
Comment thread src/routes/controllers.tsx Outdated
Comment thread src/lib/center-tab.ts Outdated
Comment thread src/components/table.tsx Outdated
Comment thread src/components/controller-list.tsx Outdated
@0x00A0 0x00A0 mentioned this pull request Jul 22, 2026
@0x00A0
0x00A0 merged commit 2aef494 into VATPRChina:main Jul 22, 2026
1 check 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