From c11f8e4b3aedba792771998301172cd0c123f9cc Mon Sep 17 00:00:00 2001
From: schry <2433098676@qq.com>
Date: Thu, 6 Jul 2023 18:05:36 +0800
Subject: [PATCH] =?UTF-8?q?=E5=AF=BC=E5=87=BA=E4=BA=A7=E5=93=81=E4=BF=A1?=
=?UTF-8?q?=E6=81=AF=E7=AA=97=E5=8F=A3=E6=89=A7=E8=A1=8C=E2=80=98=E7=BB=93?=
=?UTF-8?q?=E6=9E=9C=E5=85=A8=E9=83=A8=E5=AF=BC=E5=87=BA=E2=80=99=E6=93=8D?=
=?UTF-8?q?=E4=BD=9C=EF=BC=8C=E5=AF=BC=E5=87=BA=E7=9A=84=E6=96=87=E4=BB=B6?=
=?UTF-8?q?=E6=95=B0=E6=8D=AE=E4=B8=BA=E7=A9=BA?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/thrsys/thrProductsExport.js | 8 ++++++
.../thirdSys/product/thrProductsExport.vue | 4 +--
.../thirdSys/product/thrProductsSelect.vue | 28 +++++++++++++++++--
3 files changed, 35 insertions(+), 5 deletions(-)
diff --git a/src/api/thrsys/thrProductsExport.js b/src/api/thrsys/thrProductsExport.js
index dac0a27e..ad941681 100644
--- a/src/api/thrsys/thrProductsExport.js
+++ b/src/api/thrsys/thrProductsExport.js
@@ -31,3 +31,11 @@ export function exportExcel(query) {
});
}
+export function exportExcelAll(query) {
+ return axios({
+ url: "/udiwms/thrProducts/importLog/exportAll",
+ method: "post",
+ data: query
+ });
+}
+
diff --git a/src/views/thirdSys/product/thrProductsExport.vue b/src/views/thirdSys/product/thrProductsExport.vue
index 8b11fc1f..eddb7c33 100644
--- a/src/views/thirdSys/product/thrProductsExport.vue
+++ b/src/views/thirdSys/product/thrProductsExport.vue
@@ -34,8 +34,8 @@
{{ status[scope.row.status] }}
-
-
+
+
下载
diff --git a/src/views/thirdSys/product/thrProductsSelect.vue b/src/views/thirdSys/product/thrProductsSelect.vue
index 422cc234..9090365d 100644
--- a/src/views/thirdSys/product/thrProductsSelect.vue
+++ b/src/views/thirdSys/product/thrProductsSelect.vue
@@ -113,7 +113,7 @@ import {getInvbasdoc} from "@/api/thrsys/getErps";
import {getBasicThirdSys, filterDetailByKey} from "@/api/thrsys/basicThirdSys";
import {selectIp} from "@/api/system/systemParamConfig";
import thrProductsDetail from "./thrProductsDetail";
-import {exportExcel} from "@/api/thrsys/thrProductsExport"
+import {exportExcel,exportExcelAll} from "@/api/thrsys/thrProductsExport"
import {thrProductUpload} from "@/api/thrsys/smp"
export default {
@@ -155,6 +155,7 @@ export default {
},
thrProductsDetailVisible: false,
thisData: null,
+ multipleSelection: []
};
},
@@ -395,11 +396,32 @@ export default {
selectData.forEach((obj) => {
this.filterQuery.thrProductsEntities.push(obj);
});
- this.allExport();
+ exportExcel(this.filterQuery)
+ .then((response) => {
+ if (response.code == 20000) {
+ this.$message({
+ type: "success",
+ message: "导出成功,后台正在生成Json文件,请稍后刷新查看!",
+ });
+ this.$emit("cancelDialog", true);
+ } else {
+ this.$message({
+ type: "error",
+ message: response.message,
+ });
+ this.$emit("cancelDialog", true);
+ }
+ })
+ .catch(() => {
+ this.$message({
+ type: "error",
+ message: "上传失败",
+ });
+ });
},
allExport() {
this.filterQuery.thrProductsEntities=this.list;
- exportExcel(this.filterQuery)
+ exportExcelAll(this.filterQuery)
.then((response) => {
if (response.code == 20000) {
this.$message({