Browse Source

推荐匹配修改

wyq 3 years ago
parent
commit
46289dfb0b
1 changed files with 9 additions and 6 deletions
  1. 9 6
      src/components/common/LtModal.vue

+ 9 - 6
src/components/common/LtModal.vue

@@ -165,7 +165,7 @@ import config from '@api/config.js';
 import utils from '@api/utils.js';
 export default {
   name: 'lt-modal',
-  props: ['modalVisiable', 'meal', 'detail', 'standard', 'type', 'data'],
+  props: ['modalVisiable', 'meal', 'detail', 'standard', 'type', 'data','tip'],
   data() {
     return {
       form: {
@@ -199,7 +199,7 @@ export default {
       getIndex: 6,
       ty: this.type,
       searchType: '',
-      title: '添加'
+      title: '添加',
     };
   },
   created() {
@@ -220,12 +220,15 @@ export default {
       this.form.form = this.data.form;
       this.form.source = this.data.source;
       this.form.hisCode = this.data.hisCode;
-      if (this.data.hisDetailName != '') {
+      let name
+      if (this.data.hisName !== '' && this.data.hisDetailName === '') {
+        this.ty = 1; // 1-化验大项、2-化验小项
+        name = this.data.hisName;
+      } else if (this.data.hisName !== '' && this.data.hisDetailName !== '') {
         this.ty = 2;
-      } else {
-        this.ty = 1;
+        name = this.data.hisDetailName;
       }
-      this.getTermMatching();
+      this.getTermMatching(this.ty,name);
       this.getRelatedMapping();
     }
   },