pengjun 2 years ago
parent
commit
8136178e56
  1. 225
      src/components/sumDoctorCheck/SumSug.vue

225
src/components/sumDoctorCheck/SumSug.vue

@ -32,7 +32,7 @@
</div>
<div style="width:50%;">
<el-table id="tableSuggestion" row-key="id" :data="sumDoctorCheck.suggestionList" width="100%" :height="sumHeight"
border size="small">
border size="small" ref="tableSuggestion">
<el-table-column type="index" width="20" align="center">
</el-table-column>
<el-table-column prop="suggestionTitle" label="建议">
@ -42,113 +42,118 @@
<el-input v-model="scope.row.suggestionTitle" placeholder="请输入建议标题" :ref="scope.row.id" :id="scope.row.id"
:disabled="sumBtnDisabled()">
</el-input>
<el-button type="danger" :icon="scope.row.collapse ? 'el-icon-arrow-down' : 'el-icon-arrow-up'"
style="min-width:21px;height:21px;padding:2px;" @click="btnCollapse(scope.$index)"
:disabled="sumBtnDisabled()"></el-button>
<el-button v-show="checkPagePriv(pagePriv.privs, '删除建议')" type="danger" icon="el-icon-delete"
style="margin-left: 2px;min-width:21px;height:21px;padding:2px;" @click="delSugHead(scope.$index)"
:disabled="sumBtnDisabled()"></el-button>
</div>
<div style="display: flex;margin-top: 2px;">
<div style="width:60px;">诊断</div>
<el-select v-model="scope.row.diagnosisIds" multiple placeholder="请选择" style="width: 100%;"
:disabled="sumBtnDisabled()" @change="changeDiagnosis" filterable>
<el-option v-for="item in diagnosises" :key="item.id" :value="item.id" :label="item.displayName"
:disabled="disabledDiagnosis(item.id, scope.$index)" />
</el-select>
<el-tooltip content="新增医学解释" placement="top">
<el-button v-show="checkPagePriv(pagePriv.privs, '新增医学解释')" type="success" icon="el-icon-plus"
style="min-width:21px;height:21px;padding:2px;" @click="addSug(scope.$index, 0)"
:disabled="sumBtnDisabled()">
</el-button>
</el-tooltip>
<el-tooltip content="新增常见原因" placement="top">
<el-button v-show="checkPagePriv(pagePriv.privs, '新增常见原因')" type="danger" icon="el-icon-plus"
style="margin-left: 2px;min-width:21px;height:21px;padding:2px;" @click="addSug(scope.$index, 1)"
:disabled="sumBtnDisabled()">
</el-button>
</el-tooltip>
<el-tooltip content="新增健康指导" placement="top">
<el-button v-show="checkPagePriv(pagePriv.privs, '新增健康指导')" type="danger" icon="el-icon-plus"
style="margin-left: 2px;min-width:21px;height:21px;padding:2px;" @click="addSug(scope.$index, 2)"
:disabled="sumBtnDisabled()">
</el-button>
</el-tooltip>
</div>
<div style="display: flex;margin-top: 2px;">
<div style="width:60px;">医学解释</div>
<el-table :id="'0_sug' + scope.row.id" row-key="displayOrder" style="margin-left: 10px;"
:data="scope.row.medicalInterpretations" border @row-click="rowClickSug0" :show-header="false">
<el-table-column width="30">
<template slot-scope="scope2">
<div>{{ scope2.$index + 1 }}).</div>
</template>
</el-table-column>
<el-table-column prop="suggestionContent" label="建议" min-width="200">
<template slot-scope="scope2">
<el-input type="textarea" v-model="scope2.row.suggestionContent" placeholder="请输入建议内容"
:disabled="sumBtnDisabled()" :autosize="{ minRows: 1, maxRows: 10 }">
</el-input>
</template>
</el-table-column>
<el-table-column label="操作" width="25">
<template slot-scope="scope2">
<el-button v-show="checkPagePriv(pagePriv.privs, '删除医学解释')" type="danger"
style="min-width:21px;height:21px;padding:2px;" icon="el-icon-delete"
@click="delSug(scope.row.medicalInterpretations, scope2.$index)" :disabled="sumBtnDisabled()"
size="small"></el-button>
</template>
</el-table-column>
</el-table>
</div>
<div style="display: flex;margin-top: 2px;">
<div style="width:60px;">常见原因</div>
<el-table :id="'1_sug' + scope.row.id" row-key="displayOrder" style="margin-left: 10px;"
:data="scope.row.commonReasons" border @row-click="rowClickSug1" :show-header="false">
<el-table-column width="30">
<template slot-scope="scope2">
<div>{{ scope2.$index + 1 }}).</div>
</template>
</el-table-column>
<el-table-column prop="suggestionContent" label="建议" min-width="200">
<template slot-scope="scope2">
<el-input type="textarea" v-model="scope2.row.suggestionContent" placeholder="请输入建议内容"
:disabled="sumBtnDisabled()" :autosize="{ minRows: 1, maxRows: 10 }">
</el-input>
</template>
</el-table-column>
<el-table-column label="操作" width="25">
<template slot-scope="scope2">
<el-button v-show="checkPagePriv(pagePriv.privs, '删除常见原因')" type="danger"
style="min-width:21px;height:21px;padding:2px;" icon="el-icon-delete"
@click="delSug(scope.row.commonReasons, scope2.$index)" :disabled="sumBtnDisabled()"
size="small"></el-button>
</template>
</el-table-column>
</el-table>
</div>
<div style="display: flex;margin-top: 2px;">
<div style="width:60px;">健康指导</div>
<el-table :id="'2_sug' + scope.row.id" row-key="displayOrder" style="margin-left: 10px;"
:data="scope.row.healthGuidances" border @row-click="rowClickSug2" :show-header="false">
<el-table-column width="30">
<template slot-scope="scope2">
<div>{{ scope2.$index + 1 }}).</div>
</template>
</el-table-column>
<el-table-column prop="suggestionContent" label="建议" min-width="200">
<template slot-scope="scope2">
<el-input type="textarea" v-model="scope2.row.suggestionContent" placeholder="请输入健康指导"
:disabled="sumBtnDisabled()" :autosize="{ minRows: 1, maxRows: 10 }">
</el-input>
</template>
</el-table-column>
<el-table-column label="操作" width="25">
<template slot-scope="scope2">
<el-button v-show="checkPagePriv(pagePriv.privs, '删除健康指导')" type="danger"
style="min-width:21px;height:21px;padding:2px;" icon="el-icon-delete"
@click="delSug(scope.row.healthGuidances, scope2.$index)" :disabled="sumBtnDisabled()"
size="small"></el-button>
</template>
</el-table-column>
</el-table>
<div v-show="!scope.row.collapse">
<div style="display: flex;margin-top: 2px;">
<div style="width:60px;">诊断</div>
<el-select v-model="scope.row.diagnosisIds" multiple placeholder="请选择" style="width: 100%;"
:disabled="sumBtnDisabled()" @change="changeDiagnosis" filterable>
<el-option v-for="item in diagnosises" :key="item.id" :value="item.id" :label="item.displayName"
:disabled="disabledDiagnosis(item.id, scope.$index)" />
</el-select>
</div>
<div style="display: flex;margin-top: 2px;">
<div style="width:60px;">医学解释</div>
<el-tooltip content="新增医学解释" placement="top">
<el-button v-show="checkPagePriv(pagePriv.privs, '新增医学解释')" type="success" icon="el-icon-plus"
style="min-width:21px;height:21px;padding:2px;" @click="addSug(scope.$index, 0)"
:disabled="sumBtnDisabled()">
</el-button>
</el-tooltip>
<el-table :id="'0_sug' + scope.row.id" row-key="displayOrder" style="margin-left: 5px;"
:data="scope.row.medicalInterpretations" border @row-click="rowClickSug0" :show-header="false">
<el-table-column width="30">
<template slot-scope="scope2">
<div>{{ scope2.$index + 1 }}).</div>
</template>
</el-table-column>
<el-table-column prop="suggestionContent" label="建议" min-width="200">
<template slot-scope="scope2">
<el-input type="textarea" v-model="scope2.row.suggestionContent" placeholder="请输入建议内容"
:disabled="sumBtnDisabled()" :autosize="{ minRows: 1, maxRows: 10 }">
</el-input>
</template>
</el-table-column>
<el-table-column label="操作" width="25">
<template slot-scope="scope2">
<el-button v-show="checkPagePriv(pagePriv.privs, '删除医学解释')" type="danger"
style="min-width:21px;height:21px;padding:2px;" icon="el-icon-delete"
@click="delSug(scope.row.medicalInterpretations, scope2.$index)" :disabled="sumBtnDisabled()"
size="small"></el-button>
</template>
</el-table-column>
</el-table>
</div>
<div style="display: flex;margin-top: 2px;">
<div style="width:60px;">常见原因</div>
<el-tooltip content="新增常见原因" placement="top">
<el-button v-show="checkPagePriv(pagePriv.privs, '新增常见原因')" type="danger" icon="el-icon-plus"
style="min-width:21px;height:21px;padding:2px;" @click="addSug(scope.$index, 1)"
:disabled="sumBtnDisabled()">
</el-button>
</el-tooltip>
<el-table :id="'1_sug' + scope.row.id" row-key="displayOrder" style="margin-left: 5px;"
:data="scope.row.commonReasons" border @row-click="rowClickSug1" :show-header="false">
<el-table-column width="30">
<template slot-scope="scope2">
<div>{{ scope2.$index + 1 }}).</div>
</template>
</el-table-column>
<el-table-column prop="suggestionContent" label="建议" min-width="200">
<template slot-scope="scope2">
<el-input type="textarea" v-model="scope2.row.suggestionContent" placeholder="请输入建议内容"
:disabled="sumBtnDisabled()" :autosize="{ minRows: 1, maxRows: 10 }">
</el-input>
</template>
</el-table-column>
<el-table-column label="操作" width="25">
<template slot-scope="scope2">
<el-button v-show="checkPagePriv(pagePriv.privs, '删除常见原因')" type="danger"
style="min-width:21px;height:21px;padding:2px;" icon="el-icon-delete"
@click="delSug(scope.row.commonReasons, scope2.$index)" :disabled="sumBtnDisabled()"
size="small"></el-button>
</template>
</el-table-column>
</el-table>
</div>
<div style="display: flex;margin-top: 2px;">
<div style="width:60px;">健康指导</div>
<el-tooltip content="新增健康指导" placement="top">
<el-button v-show="checkPagePriv(pagePriv.privs, '新增健康指导')" type="danger" icon="el-icon-plus"
style="min-width:21px;height:21px;padding:2px;" @click="addSug(scope.$index, 2)"
:disabled="sumBtnDisabled()">
</el-button>
</el-tooltip>
<el-table :id="'2_sug' + scope.row.id" row-key="displayOrder" style="margin-left: 5px;"
:data="scope.row.healthGuidances" border @row-click="rowClickSug2" :show-header="false">
<el-table-column width="30">
<template slot-scope="scope2">
<div>{{ scope2.$index + 1 }}).</div>
</template>
</el-table-column>
<el-table-column prop="suggestionContent" label="建议" min-width="200">
<template slot-scope="scope2">
<el-input type="textarea" v-model="scope2.row.suggestionContent" placeholder="请输入健康指导"
:disabled="sumBtnDisabled()" :autosize="{ minRows: 1, maxRows: 10 }">
</el-input>
</template>
</el-table-column>
<el-table-column label="操作" width="25">
<template slot-scope="scope2">
<el-button v-show="checkPagePriv(pagePriv.privs, '删除健康指导')" type="danger"
style="min-width:21px;height:21px;padding:2px;" icon="el-icon-delete"
@click="delSug(scope.row.healthGuidances, scope2.$index)" :disabled="sumBtnDisabled()"
size="small"></el-button>
</template>
</el-table-column>
</el-table>
</div>
</div>
</div>
</template>
@ -231,6 +236,13 @@ export default {
})
},
btnCollapse(index) {
this.sumDoctorCheck.suggestionList[index]['collapse'] = !this.sumDoctorCheck.suggestionList[index]['collapse']
this.$nextTick(() => {
this.$refs['tableSuggestion'].doLayout()
})
},
//
getHaveSumData(patientRegisterId) {
this.sumDoctorCheck.summaryList = [];
@ -246,7 +258,7 @@ export default {
.then(async (res) => {
if (res.code > -1) {
let isGetExistData = res.data
if (res.data == 'Y') {
if (res.data == 'Y') {
try {
await this.$confirm('检测到该人员已经生成过总检信息。', '确认信息', {
distinguishCancelAndClose: true,
@ -256,7 +268,7 @@ export default {
isGetExistData = 'N'
} catch (error) {
//console.log()
}
}
}
this.summaryList(patientRegisterId, isGetExistData)
this.suggestionList(patientRegisterId, isGetExistData)
@ -335,6 +347,7 @@ export default {
// 使
this.sumDoctorCheck.suggestionList.forEach((e, i) => {
e.id = `suggestion_${i}`
e.collapse = true
if (e.medicalInterpretations) {
e.medicalInterpretations.forEach((e0, i0) => {
e0.sumSuggestionHeaderId = `suggestion_${i}`

Loading…
Cancel
Save