fix(doctorstation): 修复诊断组件和住院办理功能的数据处理问题
- 修复诊断组件中el-popover模板语法错误,添加template标签 - 优化患者历史数据处理逻辑,确保数组类型安全并正确构建树形结构 - 完善住院办理流程中的组织机构数据获取和筛选逻辑 - 添加详细的控制台日志用于调试住院办理功能 - 修复办理住院按钮的禁用状态计算逻辑 - 优化患者卡片点击事件处理,确保就诊ID正确传递 - 添加诊断信息完整性检查并提供用户引导 - 修复检验申请组件中的监听器和暴露方法逻辑
This commit is contained in:
@@ -107,11 +107,12 @@
|
||||
trigger="manual"
|
||||
:width="800"
|
||||
>
|
||||
|
||||
<diagnosislist
|
||||
:diagnosisSearchkey="diagnosisSearchkey"
|
||||
@selectDiagnosis="handleSelsectDiagnosis"
|
||||
/>
|
||||
<template #default>
|
||||
<diagnosislist
|
||||
:diagnosisSearchkey="diagnosisSearchkey"
|
||||
@selectDiagnosis="handleSelsectDiagnosis"
|
||||
/>
|
||||
</template>
|
||||
<template #reference>
|
||||
<el-input v-model="scope.row.name" placeholder="请选择诊断" @input="handleChange"
|
||||
@focus="handleFocus(scope.row, scope.$index)" @blur="handleBlur(scope.row)" />
|
||||
@@ -374,29 +375,32 @@ function getTree() {
|
||||
const patientId = props.patientInfo?.patientId || '';
|
||||
getConditionDefinitionInfo(patientId).then((res) => {
|
||||
if (res.code == 200) {
|
||||
let list = [];
|
||||
list = res.data.patientHistoryList;
|
||||
list.children = [];
|
||||
// 确保数据结构正确,避免直接修改数组对象
|
||||
const patientHistoryList = Array.isArray(res.data.patientHistoryList) ? res.data.patientHistoryList : [];
|
||||
const doctorCommonUseList = Array.isArray(res.data.doctorCommonUseList) ? res.data.doctorCommonUseList : [];
|
||||
const userPersonalList = Array.isArray(res.data.userPersonalList) ? res.data.userPersonalList : [];
|
||||
const organizationList = Array.isArray(res.data.organizationList) ? res.data.organizationList : [];
|
||||
|
||||
// 手动构造树列表;
|
||||
tree.value[0] = {
|
||||
id: '1',
|
||||
name: '历史',
|
||||
children: list,
|
||||
children: patientHistoryList,
|
||||
};
|
||||
tree.value[1] = {
|
||||
id: '2',
|
||||
name: '常用',
|
||||
children: res.data.doctorCommonUseList,
|
||||
children: doctorCommonUseList,
|
||||
};
|
||||
tree.value[2] = {
|
||||
id: '3',
|
||||
name: '个人',
|
||||
children: res.data.userPersonalList,
|
||||
children: userPersonalList,
|
||||
};
|
||||
tree.value[3] = {
|
||||
id: '4',
|
||||
name: '科室',
|
||||
children: res.data.organizationList,
|
||||
children: organizationList,
|
||||
};
|
||||
console.log(tree.value);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user