统一菜单命名并移除剩余台账工具(05-31-unified-menu-remove-ledger-tools-wave2)
这个提交包含在:
@@ -194,7 +194,7 @@ await expect(
|
||||
|
||||
- Runtime smoke must distinguish primary sidebar entries from collapsed
|
||||
`更多` entries.
|
||||
- Core day-to-day ledgers such as `报销`, `采购申请`, `合同台账`, `项目` and
|
||||
- Core day-to-day ledgers such as `报销`, `采购`, `合同`, `项目` and
|
||||
`资产` are expected in `main` when the active role has access.
|
||||
- Low-frequency entries such as `周报` and `公告` may be enabled but should be
|
||||
checked in `backup` / `更多`, not forced into `main`.
|
||||
|
||||
@@ -52,7 +52,7 @@ reference, not a copy of Feishu or Ant Design branding.
|
||||
should simplify or hide low-frequency work for small teams, not invent new
|
||||
controls or unusual action flows.
|
||||
- Page titles default to the route name only, such as `工作台`, `待我处理`, `报销`,
|
||||
`合同台账`, `个人设置` and `通知中心`. Page subtitles are off by default and
|
||||
`合同`, `采购`, `资产`, `个人设置` and `通知中心`. Page subtitles are off by default and
|
||||
appear only for exception, empty, permission-denied, Enterprise WeChat/OA
|
||||
boundary, external-system boundary or irreversible-action explanations.
|
||||
- Normal workflows should not be explained in default-visible copy. Do not add
|
||||
@@ -674,7 +674,7 @@ screen.
|
||||
status, scope and date/time; add business-specific filters such as project,
|
||||
person or type only when they are genuinely frequent.
|
||||
- The default view must match the route's main job: `我的报销`, `待我处理`,
|
||||
`合同台账`, `资产台账` and similar task nouns. Do not default ordinary users
|
||||
`合同`, `资产` and similar task nouns. Do not default ordinary users
|
||||
into company-wide management views.
|
||||
- Rows and cards must answer what the object is, current state, why it relates
|
||||
to the current user and the next action.
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
{"file": ".trellis/spec/hyb-oa/index.md", "reason": "hyb-oa spec entry and read order"}
|
||||
{"file": ".trellis/spec/hyb-oa/project-governance.md", "reason": "Trellis validation and commit rules"}
|
||||
{"file": ".trellis/spec/hyb-oa/frontend-react-vite-design.md", "reason": "frontend action placement and menu naming verification"}
|
||||
{"file": ".trellis/spec/hyb-oa/docs-and-evidence.md", "reason": "documentation evidence hygiene"}
|
||||
{"file": ".trellis/spec/hyb-oa/security-privacy.md", "reason": "sensitive export and permissioned action checks"}
|
||||
@@ -0,0 +1,5 @@
|
||||
{"file": ".trellis/spec/hyb-oa/index.md", "reason": "hyb-oa spec entry and read order"}
|
||||
{"file": ".trellis/spec/hyb-oa/project-governance.md", "reason": "Trellis task, solo-developer scope and commit rules"}
|
||||
{"file": ".trellis/spec/hyb-oa/frontend-react-vite-design.md", "reason": "frontend visual, template, menu and action-placement rules"}
|
||||
{"file": ".trellis/spec/hyb-oa/security-privacy.md", "reason": "export and sensitive business action placement constraints"}
|
||||
{"file": "docs/产品设计规则.md", "reason": "business experience facts and menu/action naming rules"}
|
||||
@@ -0,0 +1,22 @@
|
||||
# 实现说明
|
||||
|
||||
## 设计口径
|
||||
|
||||
- 参考 Ant Design / Ant Design Pro 的成熟后台惯例:业务列表首屏保留标题、常用筛选、列表和明确动作,不再使用泛化 `台账工具`。
|
||||
- 菜单与页面标题统一短模块名:`采购`、`合同`、`资产`、`付款`、`应付账款`、`票据`。
|
||||
- 页面内的具体业务对象仍可使用 `采购申请` 等单据名,避免把对象语义和菜单命名混为一类。
|
||||
|
||||
## 改造边界
|
||||
|
||||
- 只改前端入口、文案、测试断言和稳定设计/业务文档。
|
||||
- 不改后端权限、审批、付款、OCR、合同、采购或资产状态机。
|
||||
- 不做公网部署,除非用户后续单独批准。
|
||||
|
||||
## 页面迁移
|
||||
|
||||
- `采购`:原高级入口改为 `筛选`,保留供应商、法体、成本中心和范围筛选。
|
||||
- `合同`:页头保留 `新增合同`、`到期列表`、`导出`、`筛选`;到期日与测试数据切换进入高级筛选。
|
||||
- `项目`:页头使用 `合同`、`显示测试数据`、`新建项目`;新建表单改为明确的 `新建项目` 面板。
|
||||
- `付款`:原入口改为 `新建批次`,批次创建能力不变。
|
||||
- `应付账款`:导出直接作为页头 `导出` 下拉,不再包在工具面板。
|
||||
- `票据`:页头使用 `上传票据`、`绑定`、`导出`,上传和绑定各自打开明确面板。
|
||||
@@ -0,0 +1,89 @@
|
||||
# 统一菜单命名并移除剩余台账工具
|
||||
|
||||
## Goal
|
||||
|
||||
把 wave1 未覆盖的业务页面继续收敛到成熟后台惯例:全系统不再使用泛化的 `台账工具` 按钮,菜单栏统一使用短模块名,避免同一层级混用 `报销`、`采购申请`、`合同台账` 这类不同粒度名称。
|
||||
|
||||
## What I Already Know
|
||||
|
||||
- 产品面向国内小于 10 人的科技初创公司,首屏要低复杂度、少解释文案、动作位置稳定。
|
||||
- wave1 已完成 `报销` 和 `资产` 页面去 `台账工具`,并新增列表/详情/编辑薄模板规则。
|
||||
- 当前仍有 `台账工具` 残留在 `采购`、`合同`、`项目`、`付款`、`应付账款`、`票据`。
|
||||
- 当前菜单命名残留不一致:`报销`、`采购申请`、`合同台账`、`资产台账` 等混用。
|
||||
- 用户已确认 wave2 规则:菜单统一为短模块名,页面内按具体上下文显示详情或单据名。
|
||||
|
||||
## Scope
|
||||
|
||||
- 移除剩余业务页面中的用户可见 `台账工具` 文案和按钮。
|
||||
- 将原有能力迁移到明确动作:`筛选`、`导出`、`统计`、`新增`、`上传`、`绑定`、`创建批次`、`更多` 或详情页操作区。
|
||||
- 统一 PC 导航、服务端导航配置和页面路由标题里的模块命名。
|
||||
- 更新 `docs/产品设计规则.md` 和前端 spec,禁止后续再新增泛化 `台账工具`。
|
||||
- 更新相关 Playwright 断言,新增或调整防回归检查。
|
||||
|
||||
## Requirements
|
||||
|
||||
- 菜单栏统一短模块名:
|
||||
- `报销`
|
||||
- `采购`
|
||||
- `合同`
|
||||
- `项目`
|
||||
- `资产`
|
||||
- `付款`
|
||||
- `应付账款`
|
||||
- `票据`
|
||||
- 页面标题也优先使用短模块名;详情页、审批对象、单据正文可以继续使用具体名称如 `采购申请`、`合同详情`、`采购详情`。
|
||||
- 不删除原功能,只把入口迁移到具体、可理解的位置。
|
||||
- 不改变后端业务逻辑、权限模型、审批规则、付款状态机、OCR 规则或数据结构。
|
||||
- 不做公网部署,除非用户后续另行批准。
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [x] `client/src/pages/**` 中普通用户页面不再出现可点击的 `台账工具`。
|
||||
- [x] PC 菜单和服务端导航返回的业务模块名统一为短模块名。
|
||||
- [x] 采购、合同、项目、付款、应付账款、票据的原工具能力仍可通过明确动作访问。
|
||||
- [x] `docs/产品设计规则.md` 与 frontend spec 均记录禁用 `台账工具` 和菜单命名规则。
|
||||
- [x] `cd client && npm run typecheck` 通过。
|
||||
- [x] `cd client && npm run build` 通过。
|
||||
- [x] 相关聚焦 Playwright 或静态检查通过。
|
||||
|
||||
## Out Of Scope
|
||||
|
||||
- 不部署公网。
|
||||
- 不重做页面视觉大布局和详情页信息架构。
|
||||
- 不改审批、付款、OCR、资产流转、合同归档等业务状态机。
|
||||
- 不一次性处理非业务菜单,如后台管理子页面、审计、配置页面的深层命名。
|
||||
|
||||
## Test Plan
|
||||
|
||||
- `rg -n "台账工具" client/src/pages client/src/components server/src/services/workspaceSettings.js docs/产品设计规则.md .trellis/spec/hyb-oa/frontend-react-vite-design.md`
|
||||
- `cd client && npm run typecheck`
|
||||
- `cd client && npm run build`
|
||||
- 聚焦运行受影响的菜单/视觉/确认类 Playwright 测试。
|
||||
- `git diff --check`
|
||||
- `python3 ./.trellis/scripts/task.py validate 05-31-unified-menu-remove-ledger-tools-wave2`
|
||||
- `node scripts/qa/check-trellis-governance.mjs`
|
||||
|
||||
## Validation Results
|
||||
|
||||
- `rg -n "台账工具|showLedgerTools|showBatchTools|ledger-tools|合同台账|资产台账|票据中心|AP 运营|ERP 集成" client/src server/src/services/workspaceSettings.js client/src/features/navigation/schema.ts`:无匹配。
|
||||
- `cd client && npm run typecheck`:通过。
|
||||
- `cd client && npm run build`:通过。
|
||||
- `E2E_BASE_URL=http://127.0.0.1:5173 npx playwright test tests/e2e/r103-cross-page-ui-consistency.spec.ts tests/e2e/pc-finance-admin-visual-wave4.spec.ts tests/e2e/visual-shell.spec.ts --workers=1 --reporter=list`:12 passed。
|
||||
- `git diff --check`:通过。
|
||||
- `python3 ./.trellis/scripts/task.py validate 05-31-unified-menu-remove-ledger-tools-wave2`:通过。
|
||||
- `node scripts/qa/check-trellis-governance.mjs`:通过,有 `implement_non_spec_context` 提醒,原因为 `implement.jsonl` 引用了业务事实源 `docs/产品设计规则.md`。
|
||||
|
||||
## Technical Notes
|
||||
|
||||
- 设计裁决:`frontend-design` skill;成熟后台参考 Ant Design / Ant Design Pro 的命名和动作位置。
|
||||
- 重点页面:
|
||||
- `client/src/pages/PurchaseRequestsPage.tsx`
|
||||
- `client/src/pages/ContractsRegistryPage.tsx`
|
||||
- `client/src/pages/ProjectsPage.tsx`
|
||||
- `client/src/pages/PaymentBatchesPage.tsx`
|
||||
- `client/src/pages/ApOperationsPage.tsx`
|
||||
- `client/src/pages/InvoicePoolPage.tsx`
|
||||
- 菜单配置:
|
||||
- `client/src/components/navigation/NavLinks.tsx`
|
||||
- `client/src/features/navigation/schema.ts`
|
||||
- `server/src/services/workspaceSettings.js`
|
||||
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"id": "unified-menu-remove-ledger-tools-wave2",
|
||||
"name": "unified-menu-remove-ledger-tools-wave2",
|
||||
"title": "统一菜单命名并移除剩余台账工具",
|
||||
"description": "移除采购、合同、项目、付款、应付账款和票据页面剩余的泛化台账工具入口,并统一菜单与页面标题为短模块名。",
|
||||
"status": "in_progress",
|
||||
"dev_type": null,
|
||||
"scope": "frontend",
|
||||
"package": null,
|
||||
"priority": "P2",
|
||||
"creator": "shunli",
|
||||
"assignee": "shunli",
|
||||
"createdAt": "2026-05-31",
|
||||
"completedAt": null,
|
||||
"branch": null,
|
||||
"base_branch": "main",
|
||||
"worktree_path": null,
|
||||
"commit": null,
|
||||
"pr_url": null,
|
||||
"subtasks": [],
|
||||
"children": [],
|
||||
"parent": null,
|
||||
"relatedFiles": [],
|
||||
"notes": "",
|
||||
"meta": {}
|
||||
}
|
||||
在新工单中引用
屏蔽一个用户