liuyun 1272b48fc1 chore(openspec): track fe-admin-user-page component extraction
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-10-11 01:26:11 +08:00

28 lines
1.8 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

## Why
布局壳已完成。Phase 1 需要开始搭管理后台的真实页面。用户管理是最具代表性的 CRUD 页——跑通「搜索 + 表格 + 分页 + 弹窗表单 + 删除 + 重置密码」的页面模式,作为后续角色/资源/组织/字典/配置/日志页面的模板。本阶段只做界面,占位数据字段对齐后端,后端对接放到后面。
## What Changes
- 新增「用户管理」页面(`src/pages/system/user/index.vue`,对应菜单 `/system/user`)。
- 页面功能:搜索(用户名/昵称/手机/状态)、表格(用户名/昵称/邮箱/手机/状态/组织/创建时间)、分页、新增/编辑弹窗、删除确认、重置密码。
- **抽取公共 CRUD 组件**(本次核心目标):`ty-schema-form`(JSON Schema 驱动表单)、`ty-search-form`、`ty-table`、`ty-form-dialog`、`ty-crud`(整页组合),供后续 8 个域页面复用。
- **JSON Schema 描述表单**:搜索与弹窗表单字段用 JSON Schema 声明式配置(类型/标题/枚举/校验/showOn)。
- 数据:页面内联 + `setTimeout` 模拟异步(不建 mock 模块),字段对齐后端 `user` 模型,后续接后端只替换数据函数。
## Capabilities
### New Capabilities
- `frontend/AD/user`: 用户管理页面(列表查询/新增/编辑/删除/重置密码/状态展示)
### Modified Capabilities
(无)
## Impact
- 前端 `sources/sysmgr-admin`:
- 新增公共组件 `src/components/ty-schema-form.vue`、`ty-search-form.vue`、`ty-table.vue`、`ty-form-dialog.vue`、`ty-crud.vue`
- 新增类型 `src/types/crud.ts`(JsonSchema/TableColumn/PageResult 等)
- 新增 `src/pages/system/user/index.vue`(用户管理页,ty-crud + JSON Schema + 内联数据)
- 后端无变更;不接真实接口。