|
@@ -72,74 +72,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<LtModal v-if="modalVisiable" :disabled="saveDisable" @confirm="submitForm" @close="closeModal">
|
|
|
- <el-form
|
|
|
- :model="form"
|
|
|
- :rules="rules"
|
|
|
- label-position="right"
|
|
|
- label-width="120px"
|
|
|
- ref="relationForm"
|
|
|
- >
|
|
|
- <div class="AddChemicalAndCommonMappingBox clearfix">
|
|
|
- <div class="titleBox clearfix">
|
|
|
- <p class="title">医院术语</p>
|
|
|
- <p class="title">标准术语</p>
|
|
|
- </div>
|
|
|
- <div class="leftBox clearfix">
|
|
|
- <el-row>
|
|
|
- <el-col :span="16">
|
|
|
- <el-form-item label="诊断名称:" prop="hisName">
|
|
|
- <el-input v-model.trim="form.hisName" clearable style="minWidth: 240px"></el-input>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item label="诊断名称预览:">
|
|
|
- <span class="previewInfo" style="minWidth: 240px">{{form.hisName}}</span>
|
|
|
- </el-form-item>
|
|
|
- </el-col>
|
|
|
- </el-row>
|
|
|
- </div>
|
|
|
- <div class="midBox">
|
|
|
- <img class="midLogo" src="../../../images/relation.png" alt />
|
|
|
- <p class="midTitle">相互关联</p>
|
|
|
- </div>
|
|
|
- <div class="rightBox">
|
|
|
- <el-row>
|
|
|
- <el-col :span="16">
|
|
|
- <el-form-item label="诊断名称:" prop="searchText">
|
|
|
- <el-select
|
|
|
- style="width:100%;minWidth: 240px"
|
|
|
- v-model="form.searchText"
|
|
|
- filterable
|
|
|
- remote
|
|
|
- clearable
|
|
|
- :loading="showDrop"
|
|
|
- loading-text="加载中..."
|
|
|
- @change="changeWord"
|
|
|
- @focus="handleFocus"
|
|
|
- @visible-change="handleVisible"
|
|
|
- placeholder="搜索"
|
|
|
- :remote-method="searchTerms"
|
|
|
- reserve-keyword
|
|
|
- >
|
|
|
- <el-option
|
|
|
- v-for="item in uniqueNameList"
|
|
|
- :key="item.icd10Code"
|
|
|
- :label="item.name"
|
|
|
- :value="item"
|
|
|
- :title="item.name"
|
|
|
- ></el-option>
|
|
|
- </el-select>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item label="诊断名称预览:">
|
|
|
- <!-- <span class="previewInfo">{{!isEdit ? form.searchText.name : form.searchText}}</span> -->
|
|
|
- <span class="previewInfo" style="minWidth: 240px">{{form.searchText}}</span>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item label="ICD编码:">
|
|
|
- <span class="previewInfo" style="minWidth: 240px">{{form.icdCode}}</span>
|
|
|
- </el-form-item>
|
|
|
- </el-col>
|
|
|
- </el-row>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </el-form>
|
|
|
+ <LinkContent :form="form" ref="relationForm" labelName="诊断名称"/>
|
|
|
</LtModal>
|
|
|
</div>
|
|
|
</template>
|
|
@@ -149,6 +82,7 @@ import api from '@api/cdss.js';
|
|
|
import config from '@api/config.js';
|
|
|
import utils from '@api/utils.js';
|
|
|
import LtModal from '@base/LtModal';
|
|
|
+import LinkContent from '@base/LinkContent';
|
|
|
|
|
|
export default {
|
|
|
name: 'Disease', //化验大小项和公表维护
|
|
@@ -168,33 +102,18 @@ export default {
|
|
|
total: 0,
|
|
|
uploadInfo: '导入',
|
|
|
title: '诊断关联维护 | ',
|
|
|
- hospitaiName: '',
|
|
|
- hospitalId: '',
|
|
|
- isEdit: false,
|
|
|
- editId: '',
|
|
|
- uniqueNameList: [],
|
|
|
- form: {
|
|
|
+ modalVisiable:false, //弹窗显示状态
|
|
|
+ saveDisable:false, //确定按钮禁用状态
|
|
|
+ form:{
|
|
|
searchText: '', //搜索字段
|
|
|
hisName: '',
|
|
|
icdCode: ''
|
|
|
- },
|
|
|
-
|
|
|
- rules: {
|
|
|
- hisName: [
|
|
|
- { required: true, message: '请输入诊断名称', trigger: 'change' },
|
|
|
- { max: 80, message: '诊断名称最多80字', trigger: 'change' }
|
|
|
- ],
|
|
|
- searchText: [
|
|
|
- { required: true, message: '请选择诊断名称', trigger: 'change' }
|
|
|
- ]
|
|
|
- },
|
|
|
- saveDisable: false, //保存按钮禁止点击
|
|
|
- showDrop: false, //下拉框显示文字
|
|
|
- modalVisiable:false,
|
|
|
+ }
|
|
|
};
|
|
|
},
|
|
|
components:{
|
|
|
- LtModal
|
|
|
+ LtModal,
|
|
|
+ LinkContent
|
|
|
},
|
|
|
created() {
|
|
|
const { data } = this.$route.params;
|
|
@@ -547,71 +466,31 @@ export default {
|
|
|
let inp = document.getElementById('upFile');
|
|
|
inp.value = '';
|
|
|
},
|
|
|
- /********新增编辑弹窗**********/
|
|
|
-
|
|
|
- // 搜索列表
|
|
|
- searchTerms(query) {
|
|
|
- if (!query) {
|
|
|
- this.uniqueNameList = [];
|
|
|
- return;
|
|
|
- }
|
|
|
- this.showDrop = true;
|
|
|
- let params = {
|
|
|
- type: 4, //诊断
|
|
|
- inputStr: query,
|
|
|
- sex: 3,
|
|
|
- age: 0
|
|
|
- };
|
|
|
- api.retrievalSearch(params).then(res => {
|
|
|
- this.showDrop = false;
|
|
|
- if (res.data.code === '0') {
|
|
|
- this.uniqueNameList = res.data.data.diseaseNames;
|
|
|
+ showModal(){
|
|
|
+ this.modalVisiable=true
|
|
|
+ },
|
|
|
+ closeModal(){
|
|
|
+ this.modalVisiable=false
|
|
|
+ },
|
|
|
+ // 建立关联-参数处理
|
|
|
+ submitForm() {
|
|
|
+ console.log(this.$refs)
|
|
|
+ this.$refs.relationForm.$refs.innerForm.validate(valid => {
|
|
|
+ if (valid) {
|
|
|
+ const { searchText, hisName, icdCode } = this.form;
|
|
|
+ let params = {
|
|
|
+ hisName: hisName,
|
|
|
+ uniqueName: searchText,
|
|
|
+ icdCode: icdCode,
|
|
|
+ hospitalId: this.hospitalId
|
|
|
+ };
|
|
|
+ this.showSaveDialog(params);
|
|
|
+ } else {
|
|
|
+ console.log('error submit!!');
|
|
|
+ return false;
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
- changeWord(newValue) {
|
|
|
- this.form.searchText = newValue.name;
|
|
|
- this.form.icdCode = newValue.icd10Code;
|
|
|
- },
|
|
|
-
|
|
|
- handleVisible(flag) {
|
|
|
- if (!flag) {
|
|
|
- this.uniqueNameList = [];
|
|
|
- }
|
|
|
- },
|
|
|
- // 获取焦点
|
|
|
- handleFocus() {},
|
|
|
-
|
|
|
- // 初始化表单数据
|
|
|
- initForm() {
|
|
|
- this.form.hisName = '';
|
|
|
- this.form.searchText = '';
|
|
|
- this.form.icdCode = '';
|
|
|
- },
|
|
|
- showModal(){
|
|
|
- this.modalVisiable=true
|
|
|
- },
|
|
|
- closeModal(){
|
|
|
- this.modalVisiable=false
|
|
|
- },
|
|
|
- // 建立关联-参数处理
|
|
|
- submitForm() {
|
|
|
- this.$refs.relationForm.validate(valid => {
|
|
|
- if (valid) {
|
|
|
- const { searchText, hisName, icdCode } = this.form;
|
|
|
- let params = {
|
|
|
- hisName: hisName,
|
|
|
- uniqueName: searchText,
|
|
|
- icdCode: icdCode,
|
|
|
- hospitalId: this.hospitalId
|
|
|
- };
|
|
|
- this.showSaveDialog(params);
|
|
|
- } else {
|
|
|
- console.log('error submit!!');
|
|
|
- return false;
|
|
|
- }
|
|
|
- });
|
|
|
- },
|
|
|
// 建立关联-映射关系是否已存在
|
|
|
showSaveDialog(params) {
|
|
|
this.saveDisable = true; //提交保存按钮不可点击,返回结果时才可点击,防止频繁发送请求
|
|
@@ -657,30 +536,6 @@ export default {
|
|
|
this.saveDisable = false;
|
|
|
});
|
|
|
},
|
|
|
- // 关联已存在模态框
|
|
|
- showConfirmDialog(msg, resolve) {
|
|
|
- this.$alert(msg, '提示', {
|
|
|
- // customClass: 'confirmRealation',
|
|
|
- confirmButtonText: '是',
|
|
|
- // cancelButtonText: '否',
|
|
|
- // cancelButtonClass: 'cancelButton',
|
|
|
- type: 'warning'
|
|
|
- })
|
|
|
- .then(() => {
|
|
|
- resolve();
|
|
|
- })
|
|
|
- .catch(() => {
|
|
|
- this.saveDisable = false;
|
|
|
- this.warning('建立失败', 'error');
|
|
|
- });
|
|
|
- },
|
|
|
- warning(msg, type) {
|
|
|
- this.$message({
|
|
|
- showClose: true,
|
|
|
- message: msg,
|
|
|
- type: type || 'warning'
|
|
|
- });
|
|
|
- }
|
|
|
}
|
|
|
};
|
|
|
</script>
|
|
@@ -757,131 +612,4 @@ export default {
|
|
|
.contentsOther {
|
|
|
padding: 0 20px;
|
|
|
}
|
|
|
-/*********新增编辑***********/
|
|
|
- .topBack {
|
|
|
- top: 0;
|
|
|
- }
|
|
|
- .titleBox {
|
|
|
- padding: 0 0 10px 0px;
|
|
|
- }
|
|
|
- .title {
|
|
|
- width: 50%;
|
|
|
- float: left;
|
|
|
- font-size: 14px;
|
|
|
- }
|
|
|
- .leftBox,
|
|
|
- .midBox,
|
|
|
- .rightBox {
|
|
|
- width: 361px;
|
|
|
- float: left;
|
|
|
- min-height: 200px;
|
|
|
- font-size: 14px;
|
|
|
- }
|
|
|
- .midBox {
|
|
|
- width: 6%;
|
|
|
- padding: 50px 0 0 0;
|
|
|
- text-align: center;
|
|
|
- }
|
|
|
- .midTitle {
|
|
|
- width: 40px;
|
|
|
- margin: 0 auto;
|
|
|
- }
|
|
|
- .midLogo {
|
|
|
- margin: 0 auto;
|
|
|
- }
|
|
|
- .leftBox,
|
|
|
- .rightBox {
|
|
|
- border: 1px solid #dcdfe6;
|
|
|
- padding: 20px 10px;
|
|
|
- }
|
|
|
- .itemLabel {
|
|
|
- width: 100%;
|
|
|
- min-height: 50px;
|
|
|
- line-height: 50px;
|
|
|
- position: relative;
|
|
|
- }
|
|
|
- .itemLabelName,
|
|
|
- .searchInput,
|
|
|
- .searchName {
|
|
|
- float: left;
|
|
|
- color: #606266;
|
|
|
- }
|
|
|
- .itemLabelName {
|
|
|
- width: 150px;
|
|
|
- }
|
|
|
- .isRequired::before {
|
|
|
- content: '*';
|
|
|
- color: red;
|
|
|
- }
|
|
|
- .searchInput,
|
|
|
- .mealNameItem {
|
|
|
- padding: 0 5px;
|
|
|
- }
|
|
|
- .searchInput,
|
|
|
- .searchName {
|
|
|
- display: inline-block;
|
|
|
- height: 32px;
|
|
|
- line-height: 32px;
|
|
|
- border: 1px solid #a9a9a9;
|
|
|
- margin: 8px 0 0 0;
|
|
|
- }
|
|
|
-
|
|
|
- .searchName {
|
|
|
- text-align: center;
|
|
|
- border-left: none;
|
|
|
- cursor: pointer;
|
|
|
- padding: 0 12px;
|
|
|
- font-size: 16px;
|
|
|
- }
|
|
|
- .itemList {
|
|
|
- position: absolute;
|
|
|
- background: #fff;
|
|
|
- width: 162px;
|
|
|
- max-height: 150px;
|
|
|
- border: 1px solid #a9a9a9;
|
|
|
- left: 150px;
|
|
|
- top: 42px;
|
|
|
- z-index: 2;
|
|
|
- overflow-y: auto;
|
|
|
- }
|
|
|
- .itemList {
|
|
|
- width: calc(100% - 131px);
|
|
|
- }
|
|
|
- .mealNameItem {
|
|
|
- height: 30px;
|
|
|
- line-height: 30px;
|
|
|
- font-size: 14px;
|
|
|
- cursor: pointer;
|
|
|
- }
|
|
|
- .mealNameItem:hover {
|
|
|
- background: #f5f7fa;
|
|
|
- }
|
|
|
- .previewInfo {
|
|
|
- padding-left: 4px;
|
|
|
- display: inline-block;
|
|
|
- margin-top: 8px;
|
|
|
- // width: calc(100% - 160px);s
|
|
|
- line-height: 24px;
|
|
|
- overflow: hidden;
|
|
|
- word-wrap: break-word;
|
|
|
- word-break: break-all;
|
|
|
- }
|
|
|
- .sumbit {
|
|
|
- position: absolute;
|
|
|
- display: inline-block;
|
|
|
- width: 80px;
|
|
|
- height: 30px;
|
|
|
- line-height: 30px;
|
|
|
- border: 1px solid #a9a9a9;
|
|
|
- text-align: center;
|
|
|
- right: 100px;
|
|
|
- }
|
|
|
-.confirmRealation {
|
|
|
- .cancelButton {
|
|
|
- border: 1px solid #a9a9a9;
|
|
|
- span {
|
|
|
- color: #606266;
|
|
|
- }
|
|
|
- }
|
|
|
-}
|
|
|
</style>
|