fix(web-admin): 样本接收弹窗恢复展示协议附件

验收反馈要求协议附件可见;细胞存储分组恢复为知情同意书、孕妇健康调查表、协议附件三项。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
zlwuandCursor committed 2026-11-09 13:57:26 +08:00
1 parent e2a50b33fe
commit 67a209298c
2 files changed
+20 -3

No files matched your search

@@ -37,13 +37,17 @@ export function getConsentProtocolAttachment(
/**
* 样本接收弹窗:按来源返回质检需查看的协议附件分组。
* 细胞存储:仅知情同意书 / 孕妇健康调查表(不展示「协议附件」项)
* 细胞存储:知情同意书 / 孕妇健康调查表 / 协议附件
* 科研捐赠:知情同意书 / 传染病检测报告 / 其他附件
* 兼容 attachments 别名(协议详情字段名)。
*/
export function getSourceProtocolAttachmentGroups(
row: Record<string, unknown>
): ProtocolSourceAttachmentMeta[] {
const source = String(row.sourceType || 'cell_storage').trim()
const protocolFiles = normalizeAttachmentFiles(
row.protocolAttachmentFiles ?? row.attachments
)
if (source === 'research_donation') {
return [
{
@@ -68,6 +72,10 @@ export function getSourceProtocolAttachmentGroups(
{
label: '孕妇健康调查表',
files: normalizeAttachmentFiles(row.healthSurveyAttachmentFiles)
},
{
label: '协议附件',
files: protocolFiles
}
]
}