|
|
@ -16,7 +16,7 @@ |
|
|
|
<span>{{ node.label }}</span> |
|
|
|
</span> |
|
|
|
<span> |
|
|
|
<el-dropdown trigger="click" @command="(command)=>addNode(command,node,data)"> |
|
|
|
<el-dropdown v-if="!data.treeId" trigger="click" @command="(command)=>addNode(command,node,data)"> |
|
|
|
<span> |
|
|
|
<i class="el-icon-plus" /> |
|
|
|
</span> |
|
|
@ -133,12 +133,12 @@ export default { |
|
|
|
platform: this.platform |
|
|
|
} |
|
|
|
}) |
|
|
|
// this.tableData = |
|
|
|
this.collectData = this.handlePatientList(data.data) |
|
|
|
}, |
|
|
|
// 递归收藏患者 |
|
|
|
handlePatientList(arr) { |
|
|
|
arr.forEach(item => { |
|
|
|
if (!item.childs) { |
|
|
|
if (!item.childs && item.hisManagePatientEntity) { |
|
|
|
item.childs = [] |
|
|
|
} |
|
|
|
if (item.hisManagePatientEntity) { |
|
|
@ -175,12 +175,14 @@ export default { |
|
|
|
// }, |
|
|
|
levelClick(data) { |
|
|
|
this.curNode = data |
|
|
|
this.remark = data.remark || '' |
|
|
|
}, |
|
|
|
searchRemark(data) { |
|
|
|
// this.treeId = data.id |
|
|
|
// this.remark = data.hisManagePatientEntity ? data.hisManagePatientEntity.remark : '' |
|
|
|
// this.remarkId = data.hisManagePatientEntity ? data.hisManagePatientEntity.id : '' |
|
|
|
}, |
|
|
|
// 添加患者 |
|
|
|
handleAddPatient() { |
|
|
|
const params = { |
|
|
|
createDate: this.$moment().format('YYYY-MM-DD HH:mm:ss'), |
|
|
@ -225,7 +227,7 @@ export default { |
|
|
|
break |
|
|
|
} |
|
|
|
}, |
|
|
|
// 确定新增节点 |
|
|
|
// 确定新增节点/重命名 |
|
|
|
async confirmNode() { |
|
|
|
const params = { |
|
|
|
createDate: this.$moment().format('YYYY-MM-DD HH:mm:ss'), |
|
|
@ -238,9 +240,18 @@ export default { |
|
|
|
this.disabled = true |
|
|
|
if (this.curNode.patientId) { |
|
|
|
this.curNode.name = this.editName |
|
|
|
this.curNode.remark = this.editName |
|
|
|
await this.$http.post('/tree/addPatientTree', { ...this.curNode }) |
|
|
|
this.$message({ |
|
|
|
message: this.editMessage, |
|
|
|
type: 'success' |
|
|
|
}) |
|
|
|
} else { |
|
|
|
await this.$http.post('/tree/addTree', params) |
|
|
|
this.$message({ |
|
|
|
message: this.editMessage, |
|
|
|
type: 'success' |
|
|
|
}) |
|
|
|
} |
|
|
|
this.dialogFormVisible = false |
|
|
|
await this.findTree() |
|
|
@ -251,6 +262,7 @@ export default { |
|
|
|
this.deleteNode(node, data) |
|
|
|
} else { |
|
|
|
this.disabled = false |
|
|
|
console.log(this.curNode) |
|
|
|
this.editNode(node, data) |
|
|
|
} |
|
|
|
}, |
|
|
|