浏览代码

接口修改

wyq 4 年之前
父节点
当前提交
1ad2608693

+ 2 - 2
src/api/config.js

@@ -575,7 +575,7 @@ export default {
     'zskDelRule': '/api/cdssman/klRule/clearRuleInfo',//删除规则
     'zskRuleDetail': '/api/cdssman/klRule/getByIdRuleInfo',//规则详情
     'zskTypeList': '/api/cdssman/klRulePlan/getMenu',//类型列表
-    'zskSearchConcept': '/api/cdssman/klDisease/searchConcept',//知识库搜索术语
+    'zskSearchConcept': '/api/cdssman/klDisease/searchConceptRuleClass',//知识库搜索术语
     'zskUpdateAll': '/api/cdssman/cache/clearRuleAll',//更新数据
     'zskgetDict': '/api/cdssman/kl/dictionary/getDictionarys',//
     //知识库树形图
@@ -625,7 +625,7 @@ export default {
     //术语集合
     'getConceptPage': '/api/cdssman/kl/conceptCollection/getPage',
     'getRecordById': '/api/cdssman/kl/conceptCollection/getRecordById',
-    'searchConcept': '/api/cdssman/klDisease/searchConcept',
+    'jhSearchConcept': '/api/cdssman/klDisease/addConceptClass',
     'deleteById': '/api/cdssman/kl/conceptCollection/deleteById',
     'saveOrUpdateRecord': '/api/cdssman/kl/conceptCollection/saveOrUpdateRecord',
 

+ 1 - 1
src/api/knowledgeLib.js

@@ -45,7 +45,7 @@ export default {
         return axios.post(urls.searchTreeItem, param);
     },
     getSearchConcept(param) {
-        return axios.post(urls.searchConcept, param);
+        return axios.post(urls.jhSearchConcept, param);
     },
     deleteById(param) {
         return axios.post(urls.deleteById, param);

+ 1 - 1
src/api/zskDiagBase.js

@@ -8,7 +8,7 @@ const urls = {
     'zskDiagBaseDetail':'/api/cdssman/klDiagnose/getByIdDiagnoseAll',
     'zskTypeList':'/api/cdssman/klRulePlan/getMenu',//类型列表
     'searchDiag':'/api/cdssman/klDiagnose/findDiaName',
-    'zskSearchConcept':'/api/cdssman/klDisease/searchConcept',//知识库搜索术语
+    'zskSearchConcept': '/api/cdssman/ klDisease/searchConceptRuleClass',//知识库搜索术语
     'zskgetDict':'/api/cdssman/kl/dictionary/getDictionarys',//获取枚举
     'updateDiagBase':'/api/cdssman/cache/reloadDiagnose'
 };

+ 0 - 4
src/components/knowledgeExtra/AddNewRule.vue

@@ -222,7 +222,6 @@
           :showMsg="showMsg"
           :showMsg2="showMsg2"
           :ruleTermCodeStr="ruleTermCodeStr"
-          :sign="sign"
           @subTypeChange="subTypeChange"
           @searchConcept="searchConcept"
           @addGroup="addGroup"
@@ -275,7 +274,6 @@ export default {
         parLenCode: '',
         klRuleByIdSub: []
       },
-      sign:1,
       rules: formRules
     };
   },
@@ -285,7 +283,6 @@ export default {
     const param = this.$route.params;
     let info = param.data;
     if (info) {
-      this.sign = 2
       this.parId = info.parId;
       this.isCopy = param.copy;
       this.title = '规则维护-' + (this.isCopy ? '复制' : '修改') + '规则';
@@ -640,7 +637,6 @@ export default {
         excludedConceptIds: [this.form.parRuleType],
         libType: this.form.parLenCode,
         name: val,
-        sign:this.sign
       };
       api
         .searchConcept(param)

+ 0 - 4
src/components/knowledgeExtra/AddNewRuleTable.vue

@@ -745,7 +745,6 @@ export default {
         ],
         libType: this.klRuleByIdSub[this.subConceptIdIndex].subLenCode,
         name: val,
-        sign:this.sign
       };
       api
         .searchConcept(param)
@@ -889,9 +888,6 @@ export default {
     ruleTermCodeStr: {
       default: null
     },
-    sign: {
-      default: null
-    },
   }
 };
 </script>

+ 13 - 6
src/components/knowledgeExtra/AddTermSet.vue

@@ -14,7 +14,7 @@
     font-size: 14px;
     color: #606266;
     position: relative;
-    left: 40px;
+    left: 34px;
     top: -10px;
   }
 
@@ -200,12 +200,12 @@
             </el-select>
           </el-form-item>
         </el-form>
-        <div class="remark">说明:{{form.collectionRemark}}</div>
+        <div class="remark">说明{{form.collectionRemark}}</div>
       </div>
       <div class="table_content" v-if="onshow">
         <div class="table_left">
           <div class="left_header">
-            <p class="tips">关联的术语({{form.concepts.length}})</p>
+            <h4 class="tips">关联的术语({{form.concepts.length}})</h4>
             <el-input v-model="searchtext" @input="searchList" placeholder="请搜索" class="inp"></el-input>
           </div>
 
@@ -304,6 +304,7 @@ export default {
       lastList: [],
       sign: 1,
       searchtext: '',
+      len: null,
       form: {
         collectionLibType: '',
         collectionLibName: '',
@@ -376,7 +377,6 @@ export default {
           excludedConceptIds: [0],
           libType: this.form.collectionLibType,
           name: val,
-          sign: this.sign
         })
         .then(res => {
           if (res.data.code == '0') {
@@ -441,14 +441,13 @@ export default {
     },
     // 切换术语类型
     getConceptLibType() {
-      this.form.collectionLibName = '';
-      this.ruleTermTypeList = [];
       this.type.forEach(it => {
         let id = it.val.split('-');
         if (this.form.collectionLibType == id[0]) {
           this.form.conceptLibType = id[2];
         }
       });
+      this.clearData();
     },
     // 移除术语
     showDelDialog(row) {
@@ -502,6 +501,14 @@ export default {
           });
         }
       });
+    },
+    clearData() {
+      this.form.collectionLibName = '';
+      this.conceptText = '';
+      this.ruleTermTypeList = [];
+      this.form.concepts = [];
+      this.getList(this.form.concepts);
+      this.searchConcept();
     }
   },
   watch: {

+ 41 - 24
src/components/knowledgeExtra/TermSet.vue

@@ -34,7 +34,7 @@
     <div class="contents knowledgeContents">
       <el-table :data="list" border style="width: 100%">
         <el-table-column type="index" :index="indexMethod" label="编号" width="60"></el-table-column>
-        <el-table-column prop="collectionLibName" label="术语集合名称" ></el-table-column>
+        <el-table-column prop="collectionLibName" label="术语集合名称"></el-table-column>
         <el-table-column prop="conceptLibName" label="术语集合类型">
           <template slot-scope="scope">
             <span
@@ -42,23 +42,36 @@
             >{{item.val==scope.row.collectionLibType?item.name:''}}</span>
           </template>
         </el-table-column>
-        <el-table-column prop="collectionRemark" label="说明"></el-table-column>
+        <el-table-column prop="collectionRemark" label="说明">
+          <template slot-scope="scope">
+            <el-tooltip
+              v-if="scope.row.collectionRemark.length>80"
+              class="item"
+              effect="dark"
+              :content="scope.row.collectionRemark"
+              placement="top"
+            >
+              <span>{{scope.row.collectionRemark.slice(0,80)+'...'}}</span>
+            </el-tooltip>
+            <span v-if="scope.row.collectionRemark.length<81">{{scope.row.collectionRemark}}</span>
+          </template>
+        </el-table-column>
         <el-table-column prop="concatConceptLibName" label="基础术语名称" width="500">
           <template slot-scope="scope">
             <el-tooltip
-              v-if="scope.row.concatConceptLibName.length>80"
               class="item"
               effect="dark"
               :content="scope.row.concatConceptLibName"
               placement="top"
             >
-              <span>{{scope.row.concatConceptLibName.slice(0,80)+'...'}}</span>
+              <span
+                style="white-space:nowrap;overflow:hidden;text-overflow:ellipsis;"
+              >{{scope.row.concatConceptLibName}}</span>
             </el-tooltip>
-            <span v-if="scope.row.concatConceptLibName.length<81">{{scope.row.concatConceptLibName}}</span>
           </template>
         </el-table-column>
-        <el-table-column prop="modifier" label="操作人" ></el-table-column>
-        <el-table-column prop="gmtModified" label="操作时间" ></el-table-column>
+        <el-table-column prop="modifier" label="操作人"></el-table-column>
+        <el-table-column prop="gmtModified" label="操作时间"></el-table-column>
         <el-table-column label="操作" fixed="right">
           <template slot-scope="scope">
             <el-button type="text" size="small" @click="editData(scope.row.collectionId)">修改</el-button>
@@ -274,32 +287,36 @@ export default {
           this.warning('获取详情失败,请重试');
         });
     },
-    showDelDialog(row){
-        const param = {
-          id: row.collectionId
-        }
-        let waringTxt = '是否删除该集合内容,可能对现有系统造成影响'
-        this.showConfirmDialog(waringTxt,()=>{
-          api.deleteById(param).then((res)=>{
-            if(res.data.code=='0'){
-              if(!this.searched){
+    showDelDialog(row) {
+      const param = {
+        id: row.collectionId
+      };
+      let waringTxt = '是否删除该集合内容,可能对现有系统造成影响';
+      this.showConfirmDialog(waringTxt, () => {
+        api
+          .deleteById(param)
+          .then(res => {
+            if (res.data.code == '0') {
+              if (!this.searched) {
                 //未点确认时清空搜索条件
                 this.clearFilter();
               }
-              if(this.list.length==1){
+              if (this.list.length == 1) {
                 //当前在最后一页且只有一条数据时,删除后跳到前一页
-                this.currentPage = this.currentPage===1?1:this.currentPage-1;
+                this.currentPage =
+                  this.currentPage === 1 ? 1 : this.currentPage - 1;
               }
-              this.warning(res.data.msg||'操作成功','success');
+              this.warning(res.data.msg || '操作成功', 'success');
               this.getDataList();
-            }else{
+            } else {
               this.warning(res.data.msg);
             }
-          }).catch((error)=>{
-            this.warning(error);
           })
-        });
-      },
+          .catch(error => {
+            this.warning(error);
+          });
+      });
+    },
     clearFilter() {
       this.filter = {
         collectionRemark: '',