wandequan пре 3 година
родитељ
комит
8e9d2d093c

BIN
public/static/package/quality/excel.xls


BIN
public/static/package/quality/excel.xlsx


+ 11 - 3
src/components/DataLayer/IconLibraryManagement.vue

@@ -120,7 +120,9 @@ export default {
                 type: "success",
                 message: "图标上传增加成功!",
               });
-              getIcon(); // icon 更新
+              getIcon().then(() => {
+                that.changeIconType(that.selectValue);
+              }); // icon 更新
               resolve();
             } else {
               that.$checkRequestCode(result);
@@ -156,7 +158,10 @@ export default {
                   type: "success",
                   message: "图标删除成功!",
                 });
-                getIcon(); // icon 更新
+                // icon 更新
+                getIcon().then(() => {
+                  that.changeIconType(that.selectValue);
+                });
               } else {
                 that.$checkRequestCode(result);
               }
@@ -190,7 +195,10 @@ export default {
                 type: "success",
                 message: "图标信息更新成功!",
               });
-              getIcon(); // icon 更新
+              // icon 更新
+              getIcon().then((result) => {
+                that.changeIconType(that.selectValue);
+              });
               resolve();
             } else {
               that.$checkRequestCode(result);

+ 1 - 1
src/components/DataQualityInspection/Rules/ImportExcelQualityInspectionRules.vue

@@ -38,7 +38,7 @@ export default {
       elink.href = this.downloadExampleFileUrl;
       elink.setAttribute(
         "download",
-        this.downloadExampleFileType + "示例文件.xlsx"
+        this.downloadExampleFileType + "示例文件.xls"
       );
       elink.style.display = "none";
       document.body.appendChild(elink);

+ 20 - 15
src/views/Home.vue

@@ -325,22 +325,27 @@ export default {
     // 获取icon
     getIcon() {
       let that = this;
-      icon
-        .getIcon()
-        .then((result) => {
-          if (result.code == 200) {
-            that.$store.commit("setIconList", result.content);
-          } else {
-            result.message = "标注图片获取失败,请重试!";
-            that.$checkRequestCode(result);
-          }
-        })
-        .catch((err) => {
-          that.$message({
-            type: "error",
-            message: err,
+      return new Promise((resolve, reject) => {
+        icon
+          .getIcon()
+          .then((result) => {
+            if (result.code == 200) {
+              that.$store.commit("setIconList", result.content);
+              resolve();
+            } else {
+              result.message = "标注图片获取失败,请重试!";
+              that.$checkRequestCode(result);
+              reject();
+            }
+          })
+          .catch((err) => {
+            that.$message({
+              type: "error",
+              message: err,
+            });
+            reject();
           });
-        });
+      });
     },
 
     // 跳转模块