Bläddra i källkod

Merge branch 'AIControl' of http://192.168.2.236:10080/zhouna/platformFront into AIControl

zhangxc 5 år sedan
förälder
incheckning
39f16174b2

+ 4 - 3
src/components/qualityControl/BaseFieldList.vue

@@ -143,7 +143,7 @@
       })
     },
     methods: {
-      moduleFormatter(item){
+      moduleFormatter(item){console.log(item)
         const field = this.fieldTypes.filter((it)=>it.val==item.modeId);
         return field[0]?field[0].name:'';
       },
@@ -161,11 +161,12 @@
         //获取枚举信息
         api.getQcTypes().then((res)=>{
           if(res.data.code==="0"){
-            this.getDataList();
             const data = res.data.data;
-            localStorage.setItem("qcFieldTypes",JSON.stringify(data[11]));
             localStorage.setItem("qcModuleTypes",JSON.stringify(data[12]));
             localStorage.setItem("qcHospitalTypes",JSON.stringify(data[13]));
+            this.hisTypes =data[13];
+            this.fieldTypes =data[12];
+            this.getDataList();
           }else{
             this.warning("获取枚举信息失败");
           }

+ 6 - 3
src/components/qualityControl/CombineFeildList.vue

@@ -103,10 +103,10 @@
     },
     created() {
       this.getAllTypes();
-      const _this=this;
+      /*const _this=this;
       setTimeout(function() {
         _this.getDataList();
-      },100);
+      },100);*/
     },
     watch:{
       'filter':{
@@ -136,15 +136,18 @@
         if(localStorage.getItem("qcModuleTypes")){
           this.hisTypes = JSON.parse(localStorage.getItem("qcHospitalTypes"));
           this.fieldTypes = JSON.parse(localStorage.getItem("qcModuleTypes"));
+          this.getDataList();
           return ;
         }
         //获取枚举信息
         api.getQcTypes().then((res)=>{
           if(res.data.code==="0"){
             const data = res.data.data;
-            localStorage.setItem("qcFieldTypes",JSON.stringify(data[11]));
             localStorage.setItem("qcModuleTypes",JSON.stringify(data[12]));
             localStorage.setItem("qcHospitalTypes",JSON.stringify(data[13]));
+            this.hisTypes =data[13];
+            this.fieldTypes =data[12];
+            this.getDataList();
           }else{
             this.warning("获取枚举信息失败");
           }