浏览代码

术语命名维护-诊断添加科室类型

liucf 5 年之前
父节点
当前提交
86ee5ac061
共有 4 个文件被更改,包括 103 次插入11 次删除
  1. 1 0
      src/api/config.js
  2. 3 0
      src/api/icss.js
  3. 98 10
      src/components/icss/AddMedicalName.vue
  4. 1 1
      src/components/icss/MedicalMultRelation.vue

+ 1 - 0
src/api/config.js

@@ -217,6 +217,7 @@ export default {
     'relationContactDetail': 'api/knowledgeman/multContact/relationContactDetail', //知识库标准化-医学术语多层关联维护-详情
     'addMultRelation': 'api/knowledgeman/multContact/addRelation', //知识库标准化-医学术语多层关联维护-添加或者编辑
     'reloadLib': 'api/knowledgeman/reload/createFile', //术语命名-加载词库
+    'getDeptList': '/api/knowledgeman/concept/getConceptListByType', //术语命名-诊断-科室
 	  /*********预问诊相关接口**********/
 	  'questionList':'/api/precman/questionInfo_prec/page',     //预问诊-填写单列表
     'questionAdd':'/api/precman/questionInfo_prec/saveOrUpdate',      //预问诊-填写单添加

+ 3 - 0
src/api/icss.js

@@ -421,4 +421,7 @@ export default {
     reloadLib() {    //医学术语命名维护-加载词库
         return axios.post(urls.reloadLib)
     },
+    getDeptList(param) {    //医学术语命名维护-添加-获取科室
+        return axios.post(urls.getDeptList,param)
+    },
 }

+ 98 - 10
src/components/icss/AddMedicalName.vue

@@ -182,6 +182,16 @@
                 @input="inputAge"
               ></el-input>
             </el-form-item>
+            <el-form-item label="科室:" v-if="dioType" class="marT">
+                <el-select v-model="dept">
+                    <el-option v-for="(it,i) in deptList" :label="it.name" :value="it.name"></el-option>
+                </el-select>
+            </el-form-item>
+            <el-form-item label="类型:" v-if="dioType" class="marT">
+                <el-select v-model="dioType">
+                    <el-option v-for="(it,i) in dioTypeList" :label="it.name" :value="it.val"></el-option>
+                </el-select>
+            </el-form-item>
           </el-form> 
         </div>
         <div class="btn">
@@ -243,7 +253,11 @@ import pinyin from '../../js/Convert_Pinyin.js';
         unfit:false, //点确认时是否弹提示,
         saveDisable: false,  //保存按钮禁止点击
         options:[],
-        copy:null
+        copy:null,
+        dioTypeList:[],//更多信息-类型
+        dioType:'', //默认展示一类
+        deptList:[], //更多信息-科室
+        dept:'',  //默认展示全科
       }
     },
     created(){
@@ -263,9 +277,41 @@ import pinyin from '../../js/Convert_Pinyin.js';
         if(newVal && newVal != preVal){
           this.changeState(newVal);
         }
-      }
+      },
     },
     methods:{
+      // 诊断类型下--更多信息-类型
+      getDioType(flag){
+        api.getknowledgeList().then((res)=>{
+          const data = res.data;
+          if(data.code==0){
+            this.dioTypeList = data.data[2];
+            // 修改时无需赋值
+            if(!flag){
+              this.dioType = this.dioTypeList[0].val;
+            } 
+          }
+        })
+      },
+      // 诊断类型下--更多信息-科室
+      getDdeptList(conptId){
+        api.getDeptList({"type":1}).then((res)=>{
+          const data = res.data;
+          if(data.code==0){
+            this.deptList = data.data;
+            if(!conptId){
+              this.dept = "全科"; //默认展示全科
+            }else{
+              // 科室id转成name显示
+              this.deptList.map((v,i)=>{
+                if(v.conceptId==conptId){
+                  this.dept = v.name;
+                }
+              })
+            }
+          }
+        })
+      },
       changeState(val){
         let tmpAllwords = JSON.parse(JSON.stringify(this.synonymous));
         for(let i = 0;i < tmpAllwords.length;i++){
@@ -299,6 +345,13 @@ import pinyin from '../../js/Convert_Pinyin.js';
               this.showMore = result.data.isHasCommon;
               this.maxAge = result.data.maxAge;
               this.minAge = result.data.minAge;
+              const type = result.data.type;
+              if(type == '诊断'){
+                this.dioType = result.data.classify; //类型
+                const deptConptId = result.data.deptId;
+                this.getDioType(true);
+                this.getDdeptList(deptConptId);
+              } 
               // this.sexType = result.data.sexType;
               let sexType = result.data.sexType;
               this.sex.map((v,i)=>{
@@ -543,15 +596,40 @@ import pinyin from '../../js/Convert_Pinyin.js';
               sexCode = v.value;
             }
           })
-          params = {
-            'name':this.data.name,
-            'type':this.data.type,
-            'detailList':detailList,
-            'conceptId':this.copy?'':this.id,//复制当新增,把id置空
-            'sexType':sexCode,
-            'maxAge':this.maxAge,
-            'minAge':this.minAge
+          
+          if(this.dioType){
+            const deptList = this.deptList;
+            let conptId = null;
+            for(let i in deptList){
+              if(deptList[i].name == this.dept){
+                conptId = deptList[i].conceptId;
+              }
+            }
+            params = {
+              "addCptDiseaseExtVO": {
+                "classify": this.dioType,
+                "deptId": conptId
+              },
+              'name':this.data.name,
+              'type':this.data.type,
+              'detailList':detailList,
+              'conceptId':this.copy?'':this.id,//复制当新增,把id置空
+              'sexType':sexCode,
+              'maxAge':this.maxAge,
+              'minAge':this.minAge
+            }
+          }else{
+            params = {
+              'name':this.data.name,
+              'type':this.data.type,
+              'detailList':detailList,
+              'conceptId':this.copy?'':this.id,//复制当新增,把id置空
+              'sexType':sexCode,
+              'maxAge':this.maxAge,
+              'minAge':this.minAge
+            }
           }
+          
         }else{
           params = {
             'name':this.data.name,
@@ -589,6 +667,13 @@ import pinyin from '../../js/Convert_Pinyin.js';
             this.showMore = v.isHasCommon;
           }
         })
+        if(e == '诊断'){
+          this.getDioType();
+          this.getDdeptList();
+        }else{
+          this.dioType = '';
+          this.dept = '';
+        } 
       }
     }
   }
@@ -728,4 +813,7 @@ import pinyin from '../../js/Convert_Pinyin.js';
       margin: 0 35px;
      }
    }
+  /deep/ .marT{
+    margin-top: 20px;
+  }
 </style>

+ 1 - 1
src/components/icss/MedicalMultRelation.vue

@@ -2,7 +2,7 @@
     <div>
         <crumbs title="分诊人体图数据维护" minWidth="995px">
             <el-form :inline="true" class="demo-form-inline">
-                <el-form-item label="标准术语名词:">
+                <el-form-item label="医学标准术语:">
                     <el-input size="mini" v-model="filter.term" placeholder="输入术语"></el-input>
                 </el-form-item>
                 <el-form-item>