Files
zkxw/openspec/changes/lab-sample-processing-data/design.md
zlwu 5fe1193a2c feat(lab-sample): 实验室样本处理三表台账与部门字段 ACL
按造血/单个核/间充质聚合展示,部门员工只改本部门、主管可改全部,并支持筛选与 Excel 导出;同步纠正采集接受人串权与严格菜单守卫。
2026-11-12 12:48:05 +08:00

24 lines
1.3 KiB
Markdown
Raw Permalink 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.
## Context
附件三张表字段覆盖市场采集信息、实验室接收/处理与质检结果。系统内对应源主要为:
- 市场:`biz_protocol_party_customer`、`biz_protocol_collection_info`、`biz_collection_hospital`、`biz_protocol_sample`
- 生产/接收:`biz_sample_reception`、`biz_sample_production_reception`
- 质检:生产接收传染四项、储存证质检 payload、检查项结果;缺口进补充表
## Decisions
1. **数据集**:`hsc`(造血)、`ubmc`(单个核)、`msc`(脐带间充质),以样本类型名 / 编码前缀识别。
2. **权限码**:
- 列表:`lab:sample-processing:list`(三子页共用读)
- 部门编辑:`lab:sample-processing:market:edit` / `production:edit` / `qc:edit`
- 主管:`lab:sample-processing:manager`(可编辑全部部门字段)
3. **读写**:列表聚合只读源表 + 补充 JSON;更新时按字段 `source` 回写源表或补充表,服务端强制部门 ACL。
4. **UI**:P01 列表 + 筛选 + 导出;行内编辑弹窗按部门分区,无权字段只读。
5. **Figma**:MCP 授权不可用,按现有 Fresh Mint 列表页实现;合入后用户做视觉验收。
## Risks
- 历史 Excel 手工列与系统字段不完全一一对应,未映射列落补充表,避免阻断上线。
- 菜单种子不自动授权角色,需管理员分配。