Commit Graph
8 Commits
Author SHA1 Message Date
kongkx 04c12ad340 feat(users): add user admin section and delegate login authorization to API 2026-08-10 23:04:41 +08:00
kongkxandClaude Fable 5 46056ae4b0 feat(auth): wire permission gating through menu, routes and actions
The store's can()/useCan() helpers existed but were unused. Now:
- src/auth/permissions.ts PERM catalog mirrors backend keys
- every nav item carries a permission; sidebar filter reuses can()
- requirePermission() beforeLoad guard on all child routes (direct URLs
  redirect home when the session lacks the key)
- useCan() hides/disables mutation buttons: moderation actions,
  retranslate, robot-author edit/pause, category + locale CRUD, and the
  reserved-SID assign path (admin:sid:override hint)
- 403 responses toast 无权限执行此操作; can() unit tests added

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-12 06:42:31 +08:00
kongkxandClaude Fable 5 ddf07bbf58 feat(exc): 专长交易 read-only monitoring pages
New nav group with four pages against the Exc admin API:
- /exc/demands — status/mode filters, detail sheet with related
  services, quotes and dispatch rounds
- /exc/dispatches — status/round filters
- /exc/orders — status/payment filters, detail sheet with items and
  状态流转 audit trail
- /exc/providers — status/verified filters, detail sheet with dispatch
  settings and status logs

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-11 14:54:58 +08:00
kongkxandClaude Fable 5 f5a7249969 feat(moderation): resource-centric reported comments/events pages
Rework 内容审核 pages around reported resources instead of individual
reports, matching the new backend endpoints: rows group all reports on
one comment/event, with a slide-over listing report details and
per-row actions 通过并屏蔽 (approve) / 驳回举报 (reject) / 撤销屏蔽
(revert). Filters: 待处理 / 已屏蔽 / 全部.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-11 14:20:37 +08:00
kongkxandClaude Fable 5 999d5353fd feat(moderation): comment/event report and dimzou translation pages
New 内容审核 nav group covering the remaining admin API groups:
- /comment-reports — status filter; hide/delete comment or dismiss
- /event-reports — status filter; hide/delete/resolve/dismiss
- /dimzou-translations — language/status filters, draft block progress,
  requeue machine translation

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-11 13:28:28 +08:00
kongkx eb617ce436 feat: api client, auth store, login, authed shell, data-table + CRUD kit 2026-07-07 22:15:08 +08:00
kongkx 2cdb4c5a23 chore: shadcn/ui (24 components), tailwind v4 tokens, query/table/form/i18n deps 2026-07-07 22:04:43 +08:00
kongkx 0ca06fa00b chore: scaffold TanStack Start project 2026-07-07 21:52:49 +08:00