|
|
|
@ -12,7 +12,8 @@ |
|
|
|
</el-input> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column v-if="height < 300" prop="occupationalAbnormalId" label="接害因素检查结论" min-width="130" align="center"> |
|
|
|
<el-table-column v-if="height < 300" prop="occupationalAbnormalId" label="接害因素检查结论" min-width="130" |
|
|
|
align="center"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-select v-model="scope.row.occupationalAbnormalId" size="small" clearable filterable |
|
|
|
:filter-method="filterMethod" :disabled="!checkPagePriv(pagePriv.privs, '职业健康检查结论')"> |
|
|
|
@ -44,19 +45,31 @@ |
|
|
|
<div> |
|
|
|
<el-dialog title="选择接害因素" :visible.sync="dialogPoison" width="400px" :close-on-click-modal="false" |
|
|
|
:append-to-body="true"> |
|
|
|
<div style="height: 320px;"> |
|
|
|
<el-select v-model="choosedPoison" size="small" style="width:380px;" clearable filterable |
|
|
|
<div style="height: 320px;display: flex;"> |
|
|
|
<el-select v-model="choosedPoison" size="small" style="width:350px;" clearable filterable |
|
|
|
:filter-method="filterMethod" value-key="id"> |
|
|
|
<el-option-group v-for="group in poison" :key="group.poisonTypeName" :label="group.poisonTypeName"> |
|
|
|
<el-option v-for="item in group.poisonDtos" :key="item.id" :label="item.displayName" :value="item" /> |
|
|
|
</el-option-group> |
|
|
|
</el-select> |
|
|
|
<el-tooltip content="添加接害因素字典库" placement="left-start"> |
|
|
|
<i class="el-icon-plus" @click="btnDictPoison" |
|
|
|
style="margin: 2px 0 0 5px; font-size: 24px;color: green;cursor:pointer;"></i> |
|
|
|
</el-tooltip> |
|
|
|
</div> |
|
|
|
<span slot="footer" class="dialog-footer"> |
|
|
|
<el-button type="primary" @click="btnOkPoison">确定</el-button> |
|
|
|
<el-button @click="dialogPoison = false">关闭</el-button> |
|
|
|
</span> |
|
|
|
</el-dialog> |
|
|
|
|
|
|
|
<!-- 接害因素字典库 --> |
|
|
|
<el-dialog title="" :visible.sync="dialogDictPoison" :close-on-click-modal="false" :append-to-body="true" fullscreen |
|
|
|
@close="closeDialogDictPoison"> |
|
|
|
<div style="margin-top: 10px;"> |
|
|
|
<DictPoison /> |
|
|
|
</div> |
|
|
|
</el-dialog> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
@ -65,8 +78,13 @@ import moment from "moment"; |
|
|
|
import { mapState } from "vuex"; |
|
|
|
import { getapi, postapi, putapi, deletapi } from "@/api/api"; |
|
|
|
import { getPagePriv, checkPagePriv, objCopy, deepCopy, arrayExistObj } from "../../utlis/proFunc"; |
|
|
|
|
|
|
|
import DictPoison from "../../views/basic-dictionary/ToxicFactors.vue" |
|
|
|
|
|
|
|
export default { |
|
|
|
components: {}, |
|
|
|
components: { |
|
|
|
DictPoison |
|
|
|
}, |
|
|
|
props: ["refFunc", "height"], |
|
|
|
data() { |
|
|
|
return { |
|
|
|
@ -80,6 +98,7 @@ export default { |
|
|
|
currRow: 0, |
|
|
|
choosedPoison: {}, |
|
|
|
dialogPoison: false, |
|
|
|
dialogDictPoison: false, |
|
|
|
}; |
|
|
|
}, |
|
|
|
|
|
|
|
@ -105,25 +124,6 @@ export default { |
|
|
|
//数据初始化 |
|
|
|
dictInit() { |
|
|
|
|
|
|
|
//职业病 接害因素 |
|
|
|
// postapi("/api/app/Poison/GetPoisonWithTypeList").then(res => { |
|
|
|
// if (res.code > -1) { |
|
|
|
// this.dict.poison = res.data; |
|
|
|
// this.poison = res.data; |
|
|
|
// this.dict.poisonList = [] |
|
|
|
// this.dict.poison.forEach(e => { |
|
|
|
// e.poisonDtos.forEach(e2 => { |
|
|
|
// this.dict.poisonList.push({ |
|
|
|
// poisonTypeName: e.poisonTypeName, |
|
|
|
// id: e2.id, |
|
|
|
// displayName: e2.displayName, |
|
|
|
// simpleCode: e2.simpleCode |
|
|
|
// }) |
|
|
|
// }); |
|
|
|
// }); |
|
|
|
// } |
|
|
|
// }) |
|
|
|
|
|
|
|
//职业病检查结论 |
|
|
|
postapi("/api/app/OccupationalAbnormal/GetList").then((res) => { |
|
|
|
if (res.code > -1) { |
|
|
|
@ -133,9 +133,9 @@ export default { |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
// 显示选择症状项目 |
|
|
|
btnDispPoison(index) { |
|
|
|
this.currRow = index |
|
|
|
// 刷新本页面接害因素字典 |
|
|
|
refreshPoison(){ |
|
|
|
let index = this.currRow |
|
|
|
this.poisonList = deepCopy(this.dict.poisonList) |
|
|
|
this.dataTransOpts.tableM.patient_poison.forEach((e, i) => { |
|
|
|
if (i != index) { |
|
|
|
@ -144,6 +144,12 @@ export default { |
|
|
|
} |
|
|
|
}); |
|
|
|
this.poison = this.madeSelectGroup(this.poisonList) |
|
|
|
}, |
|
|
|
|
|
|
|
// 显示选择症状项目 |
|
|
|
btnDispPoison(index) { |
|
|
|
this.currRow = index |
|
|
|
this.refreshPoison() |
|
|
|
this.dialogPoison = true |
|
|
|
}, |
|
|
|
|
|
|
|
@ -213,7 +219,33 @@ export default { |
|
|
|
this.dataTransOpts.tableM.patient_poison[this.currRow]['poisonName'] = this.choosedPoison.displayName |
|
|
|
this.dialogPoison = false |
|
|
|
// console.log('this.dataTransOpts.tableM.patient_poison', this.dataTransOpts.tableM.patient_poison) |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
// 显示接害因素维护 |
|
|
|
btnDictPoison() { |
|
|
|
this.dialogDictPoison = true |
|
|
|
}, |
|
|
|
|
|
|
|
closeDialogDictPoison() { |
|
|
|
//职业病 接害因素 |
|
|
|
postapi("/api/app/Poison/GetPoisonWithTypeList").then(res => { |
|
|
|
if (res.code > -1) { |
|
|
|
this.dict.poison = res.data; |
|
|
|
this.dict.poisonList = [] |
|
|
|
this.dict.poison.forEach(e => { |
|
|
|
e.poisonDtos.forEach(e2 => { |
|
|
|
this.dict.poisonList.push({ |
|
|
|
poisonTypeName: e.poisonTypeName, |
|
|
|
id: e2.id, |
|
|
|
displayName: e2.displayName, |
|
|
|
simpleCode: e2.simpleCode |
|
|
|
}) |
|
|
|
}); |
|
|
|
}); |
|
|
|
this.refreshPoison() |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|