wyq il y a 3 ans
Parent
commit
519f9210d3

+ 29 - 27
src/components/icss/dept/DeptManage.vue

@@ -56,7 +56,9 @@
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="标准术语状态">
           <template slot-scope="scope">
-            <span v-if="scope.row.uniqueName && scope.row.uniqueName!=''">{{scope.row.status == 0?'禁用':'启用'}}</span>
+            <span
+              v-if="scope.row.uniqueName && scope.row.uniqueName!=''"
+            >{{scope.row.status == 0?'禁用':'启用'}}</span>
           </template>
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="操作">
@@ -117,14 +119,14 @@ export default {
       statusList: [
         { id: '', name: '全部' },
         { id: 1, name: '启用' },
-        { id: 0, name: '禁用' },
+        { id: 0, name: '禁用' }
       ],
       searched: false,
       filter: {
         hisName: '', // 医院诊断名称
         uniqueName: '', //标准诊断名称
         match: '',
-        status:''
+        status: ''
       },
       currentPage: 1,
       pageSize: config.pageSize,
@@ -269,7 +271,7 @@ export default {
         uniqueCode: '',
         type: 7,
         isMatch: this.filter.match,
-        status:this.filter.status
+        status: this.filter.status
       };
       return param;
     },
@@ -502,17 +504,17 @@ export default {
       inp.value = '';
     },
     importDeptRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importDeptRecord(formData, header).then(res => {
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -525,20 +527,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         //   this.$confirm(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //     confirmButtonText: '确定',

+ 23 - 25
src/components/icss/disease/ChemicalAndCommonMapping.vue

@@ -504,19 +504,17 @@ export default {
       inp.value = '';
     },
     importDiseaseRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importDiseaseRecord(formData, header).then(res => {
-        console.log(res);
-        
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -529,20 +527,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         // this.$alert(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //   confirmButtonText: '确定',

+ 25 - 26
src/components/icss/drug/DrugManage.vue

@@ -30,7 +30,6 @@
         <el-form-item label="医院药品名称:">
           <el-input size="mini" v-model="filter.hisName" placeholder="请输入" clearable></el-input>
         </el-form-item>
-        
       </el-form>
       <el-form class="secLine" :inline="true">
         <el-form-item>
@@ -147,7 +146,7 @@ export default {
         uniqueName: '', //标准诊断名称
         match: '',
         status: '',
-        formStatus:''
+        formStatus: ''
       },
       currentPage: 1,
       pageSize: config.pageSize,
@@ -287,7 +286,7 @@ export default {
         type: 5,
         isMatch: this.filter.match,
         status: this.filter.status,
-        formStatus:this.filter.formStatus,
+        formStatus: this.filter.formStatus
       };
       return param;
     },
@@ -521,17 +520,17 @@ export default {
       inp.value = '';
     },
     importDrugRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importDrugRecord(formData, header).then(res => {
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -544,20 +543,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         //   this.$confirm(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //     confirmButtonText: '确定',

+ 29 - 27
src/components/icss/fusion/Fusion.vue

@@ -55,7 +55,9 @@
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="标准术语状态">
           <template slot-scope="scope">
-            <span v-if="scope.row.uniqueName && scope.row.uniqueName!=''">{{scope.row.status == 0?'禁用':'启用'}}</span>
+            <span
+              v-if="scope.row.uniqueName && scope.row.uniqueName!=''"
+            >{{scope.row.status == 0?'禁用':'启用'}}</span>
           </template>
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="操作">
@@ -115,14 +117,14 @@ export default {
       statusList: [
         { id: '', name: '全部' },
         { id: 1, name: '启用' },
-        { id: 0, name: '禁用' },
+        { id: 0, name: '禁用' }
       ],
       searched: false,
       filter: {
         hisName: '', // 医院诊断名称
         uniqueName: '', //标准诊断名称
         match: '',
-        status:''
+        status: ''
       },
       currentPage: 1,
       pageSize: config.pageSize,
@@ -262,7 +264,7 @@ export default {
         uniqueCode: '',
         type: 8,
         isMatch: this.filter.match,
-        status:this.filter.status
+        status: this.filter.status
       };
       return param;
     },
@@ -494,17 +496,17 @@ export default {
       inp.value = '';
     },
     importFusionRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importFusionRecord(formData, header).then(res => {
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -517,20 +519,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         //   this.$confirm(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //     confirmButtonText: '确定',

+ 25 - 25
src/components/icss/lis/Lis.vue

@@ -515,36 +515,36 @@ export default {
             this.downloadUrl(res);
             this.getDataList();
           } else {
-            if (that.result != undefined) {
             let r = new FileReader();
             r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
-                that
-                  .$alert(`${code.msg}`, '提示', {
-                    confirmButtonText: '确定',
-                    // cancelButtonText: '取消',
-                    // cancelButtonClass: 'cancelSure',
-                    // confirmButtonClass: 'sure',
-                    // customClass: 'exportConfirm',
-                    type: 'warning'
-                  })
-                  .then(() => {})
-                  .catch(() => {});
+              if (this.result) {
+                const code = JSON.parse(this.result);
+                if (code.code === '00020004') {
+                  that
+                    .$alert(`${code.msg}`, '提示', {
+                      confirmButtonText: '确定',
+                      // cancelButtonText: '取消',
+                      // cancelButtonClass: 'cancelSure',
+                      // confirmButtonClass: 'sure',
+                      // customClass: 'exportConfirm',
+                      type: 'warning'
+                    })
+                    .then(() => {})
+                    .catch(() => {});
+                }
+              } else {
+                that.$alert(`导入成功`, '提示', {
+                  confirmButtonText: '确定',
+                  // cancelButtonText: '取消',
+                  // cancelButtonClass: 'cancelSure',
+                  // confirmButtonClass: 'sure',
+                  // customClass: 'exportConfirm',
+                  type: 'success'
+                });
+                that.getDataList();
               }
             };
             r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
           }
 
           // if (res.data.code === '00000001') {

+ 29 - 28
src/components/icss/nursing/nursing.vue

@@ -2,7 +2,6 @@
   <div>
     <crumbs title="护理关联维护" style="min-width: 980px" class="knowledgeTitle">
       <el-form :inline="true" class="demo-form-inline">
-        
         <el-form-item class="selectMedicine" label="标准术语状态:">
           <el-select size="mini" v-model="filter.status" placeholder="请选择" clearable>
             <el-option
@@ -56,7 +55,9 @@
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="标准术语状态">
           <template slot-scope="scope">
-            <span v-if="scope.row.uniqueName && scope.row.uniqueName!=''">{{scope.row.status == 0?'禁用':'启用'}}</span>
+            <span
+              v-if="scope.row.uniqueName && scope.row.uniqueName!=''"
+            >{{scope.row.status == 0?'禁用':'启用'}}</span>
           </template>
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="操作">
@@ -118,13 +119,13 @@ export default {
       statusList: [
         { id: '', name: '全部' },
         { id: 1, name: '启用' },
-        { id: 0, name: '禁用' },
+        { id: 0, name: '禁用' }
       ],
       filter: {
         hisName: '', // 医院诊断名称
         uniqueName: '', //标准诊断名称
         match: '',
-        status:''
+        status: ''
       },
       currentPage: 1,
       pageSize: config.pageSize,
@@ -270,7 +271,7 @@ export default {
         uniqueCode: '',
         type: 11,
         isMatch: this.filter.match,
-        status:this.filter.status
+        status: this.filter.status
       };
       return param;
     },
@@ -503,17 +504,17 @@ export default {
       inp.value = '';
     },
     importNurseRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importNurseRecord(formData, header).then(res => {
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -526,20 +527,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         //   this.$confirm(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //     confirmButtonText: '确定',

+ 29 - 27
src/components/icss/operation/Operation.vue

@@ -61,7 +61,9 @@
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="标准术语状态">
           <template slot-scope="scope">
-            <span v-if="scope.row.uniqueName && scope.row.uniqueName!=''">{{scope.row.status == 0?'禁用':'启用'}}</span>
+            <span
+              v-if="scope.row.uniqueName && scope.row.uniqueName!=''"
+            >{{scope.row.status == 0?'禁用':'启用'}}</span>
           </template>
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="操作">
@@ -123,14 +125,14 @@ export default {
       statusList: [
         { id: '', name: '全部' },
         { id: 1, name: '启用' },
-        { id: 0, name: '禁用' },
+        { id: 0, name: '禁用' }
       ],
       searched: false,
       filter: {
         hisName: '', // 医院诊断名称
         uniqueName: '', //标准诊断名称
         match: '',
-        status:''
+        status: ''
       },
       currentPage: 1,
       pageSize: config.pageSize,
@@ -270,7 +272,7 @@ export default {
         uniqueCode: '',
         type: 6,
         isMatch: this.filter.match,
-        status:this.filter.status
+        status: this.filter.status
       };
       return param;
     },
@@ -504,17 +506,17 @@ export default {
       inp.value = '';
     },
     importOperationRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importOperationRecord(formData, header).then(res => {
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -527,20 +529,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         //   this.$confirm(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //     confirmButtonText: '确定',

+ 29 - 27
src/components/icss/pacs/Pacs.vue

@@ -55,7 +55,9 @@
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="标准术语状态">
           <template slot-scope="scope">
-            <span v-if="scope.row.uniqueName && scope.row.uniqueName!=''">{{scope.row.status == 0?'禁用':'启用'}}</span>
+            <span
+              v-if="scope.row.uniqueName && scope.row.uniqueName!=''"
+            >{{scope.row.status == 0?'禁用':'启用'}}</span>
           </template>
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="操作">
@@ -116,14 +118,14 @@ export default {
       statusList: [
         { id: '', name: '全部' },
         { id: 1, name: '启用' },
-        { id: 0, name: '禁用' },
+        { id: 0, name: '禁用' }
       ],
       searched: false,
       filter: {
         hisName: '', // 医院诊断名称
         uniqueName: '', //标准诊断名称
         match: '',
-        status:''
+        status: ''
       },
       currentPage: 1,
       pageSize: config.pageSize,
@@ -268,7 +270,7 @@ export default {
         uniqueCode: '',
         type: 3,
         isMatch: this.filter.match,
-        status:this.filter.status
+        status: this.filter.status
       };
       return param;
     },
@@ -500,17 +502,17 @@ export default {
       inp.value = '';
     },
     importPacsRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importPacsRecord(formData, header).then(res => {
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -523,20 +525,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         //   this.$confirm(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //     confirmButtonText: '确定',

+ 29 - 27
src/components/icss/scale/ScaleManage.vue

@@ -55,7 +55,9 @@
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="标准术语状态">
           <template slot-scope="scope">
-            <span v-if="scope.row.uniqueName && scope.row.uniqueName!=''">{{scope.row.status == 0?'禁用':'启用'}}</span>
+            <span
+              v-if="scope.row.uniqueName && scope.row.uniqueName!=''"
+            >{{scope.row.status == 0?'禁用':'启用'}}</span>
           </template>
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="操作">
@@ -112,7 +114,7 @@ export default {
         hisName: '', // 医院诊断名称
         uniqueName: '', //标准诊断名称
         match: '',
-        status:''
+        status: ''
       },
       matchList: [
         { id: '', name: '全部' },
@@ -123,7 +125,7 @@ export default {
       statusList: [
         { id: '', name: '全部' },
         { id: 1, name: '启用' },
-        { id: 0, name: '禁用' },
+        { id: 0, name: '禁用' }
       ],
       currentPage: 1,
       pageSize: config.pageSize,
@@ -268,7 +270,7 @@ export default {
         uniqueCode: '',
         type: 10,
         isMatch: this.filter.match,
-        status:this.filter.status
+        status: this.filter.status
       };
       return param;
     },
@@ -501,17 +503,17 @@ export default {
       inp.value = '';
     },
     importScaleRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importScaleRecord(formData, header).then(res => {
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -524,20 +526,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         //   this.$confirm(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //     confirmButtonText: '确定',

+ 29 - 27
src/components/icss/tcmdisease/tcmdisease.vue

@@ -61,7 +61,9 @@
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="标准术语状态">
           <template slot-scope="scope">
-            <span v-if="scope.row.uniqueName && scope.row.uniqueName!=''">{{scope.row.status == 0?'禁用':'启用'}}</span>
+            <span
+              v-if="scope.row.uniqueName && scope.row.uniqueName!=''"
+            >{{scope.row.status == 0?'禁用':'启用'}}</span>
           </template>
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="操作">
@@ -119,12 +121,12 @@ export default {
         hisName: '', // 医院诊断名称
         uniqueName: '', //标准诊断名称
         match: '',
-        status:''
+        status: ''
       },
       statusList: [
         { id: '', name: '全部' },
         { id: 1, name: '启用' },
-        { id: 0, name: '禁用' },
+        { id: 0, name: '禁用' }
       ],
       matchList: [
         { id: '', name: '全部' },
@@ -276,7 +278,7 @@ export default {
         uniqueCode: '',
         type: 12,
         isMatch: this.filter.match,
-        status:this.filter.status
+        status: this.filter.status
       };
       return param;
     },
@@ -509,17 +511,17 @@ export default {
       inp.value = '';
     },
     importTcmRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importTcmRecord(formData, header).then(res => {
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -532,20 +534,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         //   this.$confirm(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //     confirmButtonText: '确定',

+ 29 - 27
src/components/icss/tcmdrome/tcmdrome.vue

@@ -61,7 +61,9 @@
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="标准术语状态">
           <template slot-scope="scope">
-            <span v-if="scope.row.uniqueName && scope.row.uniqueName!=''">{{scope.row.status == 0?'禁用':'启用'}}</span>
+            <span
+              v-if="scope.row.uniqueName && scope.row.uniqueName!=''"
+            >{{scope.row.status == 0?'禁用':'启用'}}</span>
           </template>
         </el-table-column>
         <el-table-column :resizable="false" prop="operate" label="操作">
@@ -119,12 +121,12 @@ export default {
         hisName: '', // 医院诊断名称
         uniqueName: '', //标准诊断名称
         match: '',
-        status:''
+        status: ''
       },
       statusList: [
         { id: '', name: '全部' },
         { id: 1, name: '启用' },
-        { id: 0, name: '禁用' },
+        { id: 0, name: '禁用' }
       ],
       matchList: [
         { id: '', name: '全部' },
@@ -276,7 +278,7 @@ export default {
         uniqueCode: '',
         type: 13,
         isMatch: this.filter.match,
-        status:this.filter.status
+        status: this.filter.status
       };
       return param;
     },
@@ -509,17 +511,17 @@ export default {
       inp.value = '';
     },
     importTcmdromeRecord(formData, header) {
-      let that = this
+      let that = this;
       api.importTcmdromeRecord(formData, header).then(res => {
         if (res.headers['content-disposition']) {
-            this.downloadUrl(res);
-            this.getDataList();
-          } else {
-            if (that.result != undefined) {
-            let r = new FileReader();
-            r.onload = function() {
-              const code = JSON.parse(that.result);
-              if (code.code === '00020007') {
+          this.downloadUrl(res);
+          this.getDataList();
+        } else {
+          let r = new FileReader();
+          r.onload = function() {
+            if (this.result) {
+              const code = JSON.parse(this.result);
+              if (code.code === '00020004') {
                 that
                   .$alert(`${code.msg}`, '提示', {
                     confirmButtonText: '确定',
@@ -532,20 +534,20 @@ export default {
                   .then(() => {})
                   .catch(() => {});
               }
-            };
-            r.readAsText(res.data);
-          } else {
-            that.$alert(`导入成功`, '提示', {
-              confirmButtonText: '确定',
-              // cancelButtonText: '取消',
-              // cancelButtonClass: 'cancelSure',
-              // confirmButtonClass: 'sure',
-              // customClass: 'exportConfirm',
-              type: 'success'
-            });
-            that.getDataList();
-          }
-          }
+            } else {
+              that.$alert(`导入成功`, '提示', {
+                confirmButtonText: '确定',
+                // cancelButtonText: '取消',
+                // cancelButtonClass: 'cancelSure',
+                // confirmButtonClass: 'sure',
+                // customClass: 'exportConfirm',
+                type: 'success'
+              });
+              that.getDataList();
+            }
+          };
+          r.readAsText(res.data);
+        }
         // if (res.data.code === '00000001') {
         //   this.$confirm(`医院术语字符数超出最大数量,请修改后再试`, '提示', {
         //     confirmButtonText: '确定',