lxf 1 year ago
parent
commit
792cdb61d2

+ 8 - 6
src/views/group/BOM/classification/index.vue

@@ -197,12 +197,14 @@ const clickDelete = (row) => {
     confirmButtonText: "确定",
     cancelButtonText: "取消",
     type: "warning",
-  }).then(() => {
-    proxy.post("/bomClassify/delete", { id: row.id }).then(() => {
-      ElMessage({ message: "删除成功", type: "success" });
-      getList();
-    });
-  });
+  })
+    .then(() => {
+      proxy.post("/bomClassify/delete", { id: row.id }).then(() => {
+        ElMessage({ message: "删除成功", type: "success" });
+        getList();
+      });
+    })
+    .catch(() => {});
 };
 </script>
 

+ 8 - 6
src/views/group/BOM/management/index.vue

@@ -448,12 +448,14 @@ const clickDelete = (row) => {
     confirmButtonText: "确定",
     cancelButtonText: "取消",
     type: "warning",
-  }).then(() => {
-    proxy.post("/bom/delete", { id: row.id }).then(() => {
-      ElMessage({ message: "删除成功", type: "success" });
-      getList();
-    });
-  });
+  })
+    .then(() => {
+      proxy.post("/bom/delete", { id: row.id }).then(() => {
+        ElMessage({ message: "删除成功", type: "success" });
+        getList();
+      });
+    })
+    .catch(() => {});
 };
 const clickCancel = (status) => {
   openDialog.value = false;

+ 8 - 6
src/views/group/order/management/index.vue

@@ -365,12 +365,14 @@ const clickDelete = (row) => {
     confirmButtonText: "确定",
     cancelButtonText: "取消",
     type: "warning",
-  }).then(() => {
-    proxy.post("/orderInfo/delete", { id: row.id }).then(() => {
-      ElMessage({ message: "删除成功", type: "success" });
-      getList();
-    });
-  });
+  })
+    .then(() => {
+      proxy.post("/orderInfo/delete", { id: row.id }).then(() => {
+        ElMessage({ message: "删除成功", type: "success" });
+        getList();
+      });
+    })
+    .catch(() => {});
 };
 const openLogs = ref(false);
 const loadingLogs = ref(false);

+ 8 - 6
src/views/group/product/classification/index.vue

@@ -197,12 +197,14 @@ const clickDelete = (row) => {
     confirmButtonText: "确定",
     cancelButtonText: "取消",
     type: "warning",
-  }).then(() => {
-    proxy.post("/skuClassify/delete", { id: row.id }).then(() => {
-      ElMessage({ message: "删除成功", type: "success" });
-      getList();
-    });
-  });
+  })
+    .then(() => {
+      proxy.post("/skuClassify/delete", { id: row.id }).then(() => {
+        ElMessage({ message: "删除成功", type: "success" });
+        getList();
+      });
+    })
+    .catch(() => {});
 };
 </script>
 

+ 8 - 6
src/views/group/product/groupSKU/index.vue

@@ -238,12 +238,14 @@ const clickDelete = (row) => {
     confirmButtonText: "确定",
     cancelButtonText: "取消",
     type: "warning",
-  }).then(() => {
-    proxy.post("/sku/delete", { id: row.id }).then(() => {
-      ElMessage({ message: "删除成功", type: "success" });
-      getList();
-    });
-  });
+  })
+    .then(() => {
+      proxy.post("/sku/delete", { id: row.id }).then(() => {
+        ElMessage({ message: "删除成功", type: "success" });
+        getList();
+      });
+    })
+    .catch(() => {});
 };
 const clickCancel = (status) => {
   openDialog.value = false;

+ 8 - 6
src/views/group/selling-price/price-system/index.vue

@@ -223,12 +223,14 @@ const clickDelete = (row) => {
     confirmButtonText: "确定",
     cancelButtonText: "取消",
     type: "warning",
-  }).then(() => {
-    proxy.post("/priceSystem/delete", { id: row.id }).then(() => {
-      ElMessage({ message: "删除成功", type: "success" });
-      getList();
-    });
-  });
+  })
+    .then(() => {
+      proxy.post("/priceSystem/delete", { id: row.id }).then(() => {
+        ElMessage({ message: "删除成功", type: "success" });
+        getList();
+      });
+    })
+    .catch(() => {});
 };
 </script>
 

+ 10 - 8
src/views/group/subsidiary/business-division/index.vue

@@ -457,7 +457,7 @@ const submitForm = () => {
 };
 const clickUpdate = (row) => {
   modalType.value = "edit";
-  proxy.post('/department/detail',{id:row.id}).then(res => {
+  proxy.post("/department/detail", { id: row.id }).then((res) => {
     formData.data = res;
     if (formData.data.wlnBrand) {
       formData.data.wlnBrandArr = formData.data.wlnBrand.split(",");
@@ -471,19 +471,21 @@ const clickUpdate = (row) => {
     }
     btnDisabled.value = false;
     openDialog.value = true;
-  })
+  });
 };
 const clickDelete = (row) => {
   ElMessageBox.confirm("你是否确认此操作", "提示", {
     confirmButtonText: "确定",
     cancelButtonText: "取消",
     type: "warning",
-  }).then(() => {
-    proxy.post("/department/delete", { id: row.id }).then(() => {
-      ElMessage({ message: "删除成功", type: "success" });
-      getList();
-    });
-  });
+  })
+    .then(() => {
+      proxy.post("/department/delete", { id: row.id }).then(() => {
+        ElMessage({ message: "删除成功", type: "success" });
+        getList();
+      });
+    })
+    .catch(() => {});
 };
 </script>
 

+ 10 - 10
src/views/system/dept2/index.vue

@@ -365,21 +365,21 @@ const recursive = (data) => {
 };
 
 const listDelete = (row) => {
-  // 弹窗提示是否删除
   ElMessageBox.confirm(proxy.t("common.thisOperationWillPermanentlyDeleteTheData"), proxy.t("common.prompt"), {
     confirmButtonText: proxy.t("common.confirm"),
     cancelButtonText: proxy.t("common.cancel"),
     type: "warning",
-  }).then(() => {
-    // 删除
-    proxy.post("/tenantDept/" + row.deptId, {}, "delete").then((res) => {
-      ElMessage({
-        message: proxy.t("common.deleteSuccess"),
-        type: "success",
+  })
+    .then(() => {
+      proxy.post("/tenantDept/" + row.deptId, {}, "delete").then((res) => {
+        ElMessage({
+          message: proxy.t("common.deleteSuccess"),
+          type: "success",
+        });
+        getList();
       });
-      getList();
-    });
-  });
+    })
+    .catch(() => {});
 };
 const showType = (type) => {
   return type == 0 ? proxy.t("dept.company") : type == 1 ? proxy.t("dept.businessCenter") : type == 2 ? proxy.t("dept.department") : proxy.t("dept.group");