From bedad38ca3abfe2d3ccc0fc9866e499b55bbf98f Mon Sep 17 00:00:00 2001 From: chenqi Date: Mon, 23 Mar 2026 18:38:16 +0800 Subject: [PATCH] =?UTF-8?q?fix(doctorstation):=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E8=80=97=E6=9D=90=E4=BB=B7=E6=A0=BC=E8=8E=B7=E5=8F=96=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 优先从priceList获取药品/诊疗价格 - 添加耗材类型直接从retailPrice或price字段获取价格 - 支持耗材价格字段为空时返回默认值 - 修复价格显示格式化问题 --- .../doctorstation/components/adviceBaseList.vue | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/openhis-ui-vue3/src/views/doctorstation/components/adviceBaseList.vue b/openhis-ui-vue3/src/views/doctorstation/components/adviceBaseList.vue index 2e4d4171..e8616383 100644 --- a/openhis-ui-vue3/src/views/doctorstation/components/adviceBaseList.vue +++ b/openhis-ui-vue3/src/views/doctorstation/components/adviceBaseList.vue @@ -327,11 +327,24 @@ function fetchFromApi(searchKey) { } // 从priceList列表中获取价格 - 与V1.3一致 +// 🔧 Bug #220 修复:增强价格获取逻辑,支持耗材直接价格字段 function getPriceFromInventory(row) { + // 优先从priceList获取(药品/诊疗) if (row.priceList && row.priceList.length > 0) { const price = row.priceList[0].price || 0; return Number(price).toFixed(2) + ' 元'; } + + // 耗材类型:直接从retailPrice或price字段获取 + if (row.adviceType === 4) { + const price = row.retailPrice !== undefined && row.retailPrice !== null + ? row.retailPrice + : (row.price !== undefined && row.price !== null ? row.price : null); + if (price !== null && price !== '') { + return Number(price).toFixed(2) + ' 元'; + } + } + return '-'; }