From 53e5ee331b4f9edc005facebc4d3efc4ab19521c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8D=80=E5=BD=A7?= <荀彧@gentronhealth.com> Date: Thu, 14 May 2026 18:08:55 +0800 Subject: [PATCH 01/26] =?UTF-8?q?Fix=20Bug=20#428:=20=E9=97=A8=E8=AF=8A?= =?UTF-8?q?=E5=8C=BB=E7=94=9F=E7=AB=99-=E6=A3=80=E6=9F=A5=E7=94=B3?= =?UTF-8?q?=E8=AF=B7=EF=BC=9A=E6=9C=AA=E5=AE=9E=E7=8E=B0=E5=88=86=E7=B1=BB?= =?UTF-8?q?=E8=81=94=E5=8A=A8=E6=A3=80=E6=9F=A5=E6=96=B9=E6=B3=95=E5=8F=8A?= =?UTF-8?q?=E5=A5=97=E9=A4=90=E6=98=8E=E7=BB=86=E5=B1=95=E7=A4=BA=E4=B8=8E?= =?UTF-8?q?=E5=8B=BE=E9=80=89=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1. handleMethodSelect 中新增/更新已选项时,设置 expanded=true 使套餐明细自动展开 2. toggleItemExpand 中改用 packageDetailsDisplay/carrier.packageDetails 判断是否已加载明细 (原代码检查非响应式的 item.packageDetails,导致重复加载或加载判断失效) Co-Authored-By: Claude Opus 4.7 --- .../examination/examinationApplication.vue | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/openhis-ui-vue3/src/views/doctorstation/components/examination/examinationApplication.vue b/openhis-ui-vue3/src/views/doctorstation/components/examination/examinationApplication.vue index dc50881a1..3ef285d68 100755 --- a/openhis-ui-vue3/src/views/doctorstation/components/examination/examinationApplication.vue +++ b/openhis-ui-vue3/src/views/doctorstation/components/examination/examinationApplication.vue @@ -1362,8 +1362,9 @@ async function handleMethodSelect(checked, method, cat) { existingItem.isPackage = true; existingItem.packageId = method.packageId; existingItem.packageName = method.packageName || existingItem.packageName; // #428修复: 确保 packageName 同步 + existingItem.expanded = true; // #428修复: 有套餐时默认展开,展示套餐明细 // 预加载套餐明细 - loadPackageDetailsForItem(existingItem); + await loadPackageDetailsForItem(existingItem); } updateMethodDisplay(); return; @@ -1399,9 +1400,10 @@ async function handleMethodSelect(checked, method, cat) { }; selectedItems.value.push(newItem); - // 如果是套餐,预加载套餐明细 + // 如果是套餐,预加载套餐明细并默认展开 if (newItem.isPackage && newItem.packageId) { - loadPackageDetailsForItem(newItem); + newItem.expanded = true; + await loadPackageDetailsForItem(newItem); } // 自动回填执行科室 @@ -1523,7 +1525,10 @@ async function handleItemSelect(checked, item, cat) { // Bug #384修复 + #426修复: 展开/收起项目卡片 async function toggleItemExpand(item) { item.expanded = !item.expanded; - if (item.expanded && (item.isPackage || item.packageName) && (!item.packageDetails || item.packageDetails.length === 0) && !item.packageDetailsLoading) { + const carrier = getPackageCarrier(item); + const hasDetails = Array.isArray(item.packageDetailsDisplay) && item.packageDetailsDisplay.length > 0 + || Array.isArray(carrier?.packageDetails) && carrier.packageDetails.length > 0; + if (item.expanded && (item.isPackage || item.packageName) && !hasDetails && !item.packageDetailsLoading) { await loadPackageDetailsForItem(item); } if (item.expanded && shouldShowPackageBody(item)) { From bc595e3843c6b873578b7403531373ca586a0b0b Mon Sep 17 00:00:00 2001 From: xiaoming <13564692840@163.com> Date: Thu, 14 May 2026 18:10:46 +0800 Subject: [PATCH 02/26] =?UTF-8?q?bug499=20=E3=80=90=E4=BD=8F=E9=99=A2?= =?UTF-8?q?=E5=8C=BB=E7=94=9F=E5=B7=A5=E4=BD=9C=E7=AB=99-=E6=A3=80?= =?UTF-8?q?=E6=9F=A5=E7=94=B3=E8=AF=B7=E3=80=91=E6=A3=80=E6=9F=A5=E7=94=B3?= =?UTF-8?q?=E8=AF=B7=E5=88=97=E8=A1=A8=E7=BC=BA=E5=A4=B1=E6=9F=A5=E8=AF=A2?= =?UTF-8?q?=E8=BF=87=E6=BB=A4=E5=8A=9F=E8=83=BD=EF=BC=8C=E4=B8=8D=E7=AC=A6?= =?UTF-8?q?=E5=90=88=E4=B8=B4=E5=BA=8A=E9=AB=98=E6=95=88=E6=A3=80=E7=B4=A2?= =?UTF-8?q?=E8=A6=81=E6=B1=82=20=E6=95=B0=E6=8D=AE=E5=BA=93=E8=AF=AD?= =?UTF-8?q?=E5=8F=A5=E6=8A=A5=E9=94=99=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../RequestFormManageAppMapper.xml | 25 ++++++++++--------- 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/openhis-server-new/openhis-application/src/main/resources/mapper/regdoctorstation/RequestFormManageAppMapper.xml b/openhis-server-new/openhis-application/src/main/resources/mapper/regdoctorstation/RequestFormManageAppMapper.xml index fafd10ae4..8a9479fdb 100755 --- a/openhis-server-new/openhis-application/src/main/resources/mapper/regdoctorstation/RequestFormManageAppMapper.xml +++ b/openhis-server-new/openhis-application/src/main/resources/mapper/regdoctorstation/RequestFormManageAppMapper.xml @@ -45,18 +45,6 @@ AND drf.create_time <= (#{endDate}::date + INTERVAL '1 day' - INTERVAL '1 second') - - AND CASE - WHEN MIN(wsr.status_enum) = 1 THEN 0 - WHEN MIN(wsr.status_enum) = 2 THEN 1 - WHEN MIN(wsr.status_enum) = 3 AND MAX(CASE WHEN wsr.performer_check_id IS NOT NULL THEN 1 ELSE 0 END) = 1 THEN 2 - WHEN MIN(wsr.status_enum) = 3 THEN 4 - WHEN MIN(wsr.status_enum) = 4 THEN 3 - WHEN MIN(wsr.status_enum) = 5 OR MIN(wsr.status_enum) = 6 OR MIN(wsr.status_enum) = 7 THEN 7 - WHEN MIN(wsr.status_enum) = 8 THEN 6 - ELSE NULL - END = #{status}::integer - AND (drf.prescription_no ILIKE '%' || #{keyword} || '%' OR EXISTS ( @@ -72,6 +60,19 @@ GROUP BY drf.id, drf.encounter_id, drf.prescription_no, drf.name, drf.desc_json, drf.requester_id, drf.create_time, ap.name + + HAVING CASE MIN(wsr.status_enum) + WHEN 1 THEN 0 + WHEN 2 THEN 1 + WHEN 3 THEN 4 + WHEN 4 THEN 4 + WHEN 5 THEN 5 + WHEN 6 THEN 5 + WHEN 7 THEN 5 + WHEN 8 THEN 6 + ELSE NULL + END = #{status}::integer + SELECT wsr.quantity, wsr.unit_code, - COALESCE(wad.NAME, wsr.content_json::jsonb->>'surgeryName') AS advice_name, + COALESCE( + wad.NAME, + wsr.content_json::jsonb->>'surgeryName', + '检验项目' + ) AS advice_name, aci.total_price FROM wor_service_request AS wsr LEFT JOIN wor_activity_definition AS wad ON wad.ID = wsr.activity_id @@ -88,6 +92,7 @@ AND aci.delete_flag = '0' WHERE wsr.delete_flag = '0' AND wsr.prescription_no = #{prescriptionNo} + ORDER BY wsr.id