From 7286766b4e8bbc272bb4940807e9783c33c650e3 Mon Sep 17 00:00:00 2001 From: duxiaoning <17621883433@163.com> Date: Fri, 13 Jan 2023 16:07:22 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E8=AE=A2=E5=8D=95=E7=8A=B6?= =?UTF-8?q?=E6=80=81=EF=BC=8C=E4=BD=93=E6=A3=80=E6=A3=80=E9=AA=8C=E7=BB=93?= =?UTF-8?q?=E6=9E=9C=E4=BB=A5=E5=8F=8A=E6=8A=A5=E5=91=8A=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Feedback/Inspection/Report/index.vue | 201 ++++++++++++------ 1 file changed, 140 insertions(+), 61 deletions(-) diff --git a/src/views/Daichuli/Feedback/Inspection/Report/index.vue b/src/views/Daichuli/Feedback/Inspection/Report/index.vue index 43d41fa..2da2f74 100644 --- a/src/views/Daichuli/Feedback/Inspection/Report/index.vue +++ b/src/views/Daichuli/Feedback/Inspection/Report/index.vue @@ -2,37 +2,80 @@
- + - +
产品检验报告PDF
-
- +
+
-
+
- + - + - + - + - + @@ -40,28 +83,51 @@ -
+
- + - + - + - + - +
- + @@ -82,13 +148,23 @@ {{ scope.row.dataTime | formatDate }} --> - + - +
@@ -411,51 +487,54 @@ export default { }, // 提交检验结果以及报告结果 submitReport() { - // 更新订单状态 - const os = 2; //审核完成 - this.updateOrder(os); - // 上传报告 - const rpm = this.reportMsg; - const pp = this.pdfPath; - if (pp !== null || pp !== undefined) { - const pos = pp.lastIndexOf("/"); - const pdfName = pp.substr(pos + 1); - const rf = new FormData(); - rf.append("orderId", rpm.orderId); - rf.append("reportName", pdfName); - rf.append("reportPath", pp); - addReportMsg(rf).then((res) => { - // console.log(res); - if (res.code === 200) { - this.$message({ - type: "success", - message: "订单处理成功", + saveValidationRes(this.reportMsg).then((res) => { + if (res.code === 200) { + this.$message({ + message: "提交成功,检验完成", + type: "success", + }); + const os = 2; //审核完成 + this.updateOrder(os); + // 上传报告 + const rpm = this.reportMsg; + const pp = this.pdfPath; + if (pp !== null || pp !== undefined) { + const rpMsg = { + orderId: rpm.orderId, + path: pp, + }; + saveReport(rpMsg).then((res) => { + if (res.code === 200) { + this.$message({ + type: "success", + message: "订单处理成功", + }); + this.$router.push({ name: "待处理的检验订单" }); + } }); - updateOrderMsg({ - id: rpm.orderId, - auditId: rpm.userId, - auditName: localStorage.userName, - }); - disOrderStatus(rpm.orderId); - this.$router.push({ name: "待处理的检验订单" }); } - }); - } + } + }); }, // 重新检验 reExamine() { - const os = 8; + const os = 0; this.updateOrder(os); + this.$router.push({ path: "http://211.157.180.211:18085/" }); // this.$router.push(`http://10.0.3.157:18030/kjwebAdmin/#/Order/DJYOrder?orderid=${this.reportMsg.orderId}&token=WEB%2a1673425993482%40L3W7_ZZX-yg000087_06848633de364ec7b63c8f53f9e43b19`); }, // 更新订单状态 updateOrder(orderStatus) { - const rpm = this.reportMsg; - const up = new FormData(); - up.append("orderId", rpm.orderId); - up.append("orderStatus", orderStatus); - up.append("userId", rpm.userId); - updateOrderStage(up); + updateOrderStage( + qs.stringify( + { + orderId: this.orderId, + orderStatus: orderStatus, + userId: this.userId, + }, + { indices: false } + ) + ); }, pickValue() { cu.handleClick(); @@ -620,7 +699,7 @@ export default { background-color: #354595; } -/deep/.cstop .el-radio__input.is-checked+.el-radio__label { +/deep/.cstop .el-radio__input.is-checked + .el-radio__label { color: #606266; } @@ -643,7 +722,7 @@ export default { color: black; } -/deep/.el-tabs--card>.el-tabs__header .el-tabs__item.is-active { +/deep/.el-tabs--card > .el-tabs__header .el-tabs__item.is-active { color: white; background-color: #409eff; border-color: #409eff; @@ -655,7 +734,7 @@ export default { // display: block; } -/deep/.el-tabs--card>.el-tabs__header .el-tabs__nav { +/deep/.el-tabs--card > .el-tabs__header .el-tabs__nav { display: block; left: 41.5%; // transform: translateX(-50%); @@ -664,12 +743,12 @@ export default { position: relative; } -/deep/.el-tabs--card>.el-tabs__header { +/deep/.el-tabs--card > .el-tabs__header { border-bottom: 0; // border-bottom: 1px solid #E4E7ED; } -/deep/.el-tabs--card>.el-tabs__header .el-tabs__nav { +/deep/.el-tabs--card > .el-tabs__header .el-tabs__nav { border-bottom: 1px solid #e4e7ed; }