将 AppendViewModal
从简单的体位列表展示改造为类似 register 页面的完整体位选择界面,包含过滤区域、体型结构交互、待选择区域和已选择区域。
┌─────────────────────────────────────────────────┐
│ Modal Header: "追加体位" │
├──────────────┬──────────────┬───────────────────┤
│ │ │ │
│ 过滤区域 │ 体型结构 │ 待选择区域 │
│ (6 cols) │ (6 cols) │ (12 cols) │
│ │ │ │
│ │ ├───────────────────┤
│ │ │ 已选择区域 │
│ │ │ │
└──────────────┴──────────────┴───────────────────┘
│ Modal Footer: 取消 / 确认追加 (n) │
└─────────────────────────────────────────────────┘
AppendViewModal (主容器)
├── AppendViewFilterBar (过滤条)
│ └── Segmented (协议/体位切换)
├── AppendBodyFilter (体型结构)
│ ├── HumanBody (人体)
│ └── AnimalBody (动物体)
├── AppendAvailableList (待选择列表)
│ └── AppendViewCard[] (体位卡片)
└── AppendSelectedList (已选择列表)
└── Card[] (已选体位卡片)
src/states/exam/appendViewSlice.ts (修改)
新增状态:
currentSelectionType
: 'protocol' | 'view' - 当前选择类型currentBodyPartId
: string | null - 当前身体部位ID新增 actions:
setSelectionType
: 切换协议/体位选择setCurrentBodyPart
: 设置当前身体部位src/pages/exam/components/AppendViewFilterBar.tsx (新建)
功能:
src/pages/exam/components/AppendBodyFilter.tsx (新建)
功能:
src/pages/exam/components/AppendAvailableList.tsx (新建)
功能:
src/pages/exam/components/AppendSelectedList.tsx (新建)
功能:
src/pages/exam/components/AppendViewModal.tsx (重构)
主要改动:
open
prop 变为 truecurrentBodyPartId
为当前检查的身体部位currentBodyPartId
高亮对应部位setCurrentBodyPart(bodyPartId)
fetchAvailableViewsThunk
获取该部位的体位toggleViewSelection(view)
selectedViews
appendViewsThunk
追加体位到 StudysetSelectionType(type)