From b96d327646ebb8375fd155da8ac2049e1c6febf4 Mon Sep 17 00:00:00 2001 From: zhaoyun Date: Fri, 29 May 2026 02:29:54 +0800 Subject: [PATCH] =?UTF-8?q?fix(#579):=20=E8=AF=B7=E4=BF=AE=E5=A4=8D=20Bug?= =?UTF-8?q?=20#579=EF=BC=9A[=E4=B8=80=E8=88=AC]=20[=E6=8A=A5=E8=A1=A8?= =?UTF-8?q?=E7=AE=A1=E7=90=86-=E9=99=A2=E5=86=85=E6=95=B4=E4=BD=93?= =?UTF-8?q?=E6=94=B6=E5=85=A5=E6=98=8E=E7=BB=86=E6=9F=A5=E8=AF=A2-?= =?UTF-8?q?=E9=97=A8=E8=AF=8A=E6=94=B6=E8=B4=B9=E6=8A=A5=E8=A1=A8]?= =?UTF-8?q?=E5=88=97=E8=A1=A8=E7=9A=84=E6=A0=BC=E5=BC=8F=E9=94=99=E4=B9=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 根因: - `processListWithSubtotals` 中的小计行使用 `...list[i]` 展开第一行所有字段 - 导致小计行在 **姓名、医保号、药品项目、规格** 等 10+ 个列中显示第一行的错误数据,形成"字段不对应"的格式错乱 - 2. 表格缺少视觉分隔** - `` 缺少 `border` 和 `stripe` 属性,合并单元格后难以区分行列边界 - ### 修改内容 - | 文件 | 变更 | - |---|---| - | `src/views/medicationmanagement/statisticalManagement/outPatientCharge.vue` | 2 处改动 | - 改动明细:** - 1. **`el-table` 添加 `border` + `stripe`** — 使单元格有清晰边框,交替行色提升可读性 - 2. **小计行移除 `...list[i]` 字段展开** — 小计行仅保留 `departmentName: '小计'` 和 `totalPrice`,其他列自动为空,确保字段一一对应 - ### 验证 - ✅ ESLint 无错误 - ✅ Vite build 编译成功 - ✅ 修改范围最小化(仅 2 处改动,+3/-1 行) 修复: - Bug #579 门诊收费报表格式错乱 - ### 分析过程 - 通过全链路代码审查,发现两个核心问题: --- .../statisticalManagement/outPatientCharge.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/openhis-ui-vue3/src/views/medicationmanagement/statisticalManagement/outPatientCharge.vue b/openhis-ui-vue3/src/views/medicationmanagement/statisticalManagement/outPatientCharge.vue index d48ab6978..719e7b0d3 100755 --- a/openhis-ui-vue3/src/views/medicationmanagement/statisticalManagement/outPatientCharge.vue +++ b/openhis-ui-vue3/src/views/medicationmanagement/statisticalManagement/outPatientCharge.vue @@ -163,6 +163,8 @@ 1) { const subtotalRow = { - ...list[i], departmentName: '小计', totalPrice: totalPriceSum.toFixed(4), };