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 add31a486..7928c1a08 100755 --- a/openhis-ui-vue3/src/views/doctorstation/components/examination/examinationApplication.vue +++ b/openhis-ui-vue3/src/views/doctorstation/components/examination/examinationApplication.vue @@ -584,20 +584,16 @@ async function loadPackageDetails(row, treeNode, resolve) { url: `/system/check-type/package/${row.packageId}/details`, method: 'get' }); - if (res.code === 200) { - const list = parsePackageDetailsPayload(res); - const children = list.map((child) => ({ - ...child, - name: child.name || child.itemName, - unit: child.unit || '次', - price: child.price ?? child.unitPrice ?? child.itemPrice ?? 0, - quantity: row.quantity || 1, - isPackageDetail: true - })); - resolve(children); - } else { - resolve([]); - } + const list = parsePackageDetailsPayload(res); + const children = list.map((child) => ({ + ...child, + name: child.name || child.itemName, + unit: child.unit || '次', + price: child.price ?? child.unitPrice ?? child.itemPrice ?? 0, + quantity: row.quantity || 1, + isPackageDetail: true + })); + resolve(children); } catch (err) { console.error('加载套餐明细失败:', err); resolve([]); @@ -1489,7 +1485,7 @@ async function handleItemSelect(checked, item, cat) { packageName: item.packageName || null, packageDetailsLoading: false, packageId: item.packageId || null, - hasChildren: !!(item.packageId) // #426修复: 树形表格懒加载展开标记 + hasChildren: !!(item.packageId || item.packageName) // #426修复: 树形表格懒加载展开标记,支持 packageName 解析 }; selectedItems.value.push(newRow); // 必须用数组里的响应式行,不能继续改局部 newRow:push 后列表内是 proxy,改 raw 对象不会触发右侧卡片更新(会一直卡在「加载中」)