From b57a2f7286a5de1f21100f6ac3bf6f8078b9025a Mon Sep 17 00:00:00 2001 From: wangsixiang <2970484253@qq.com> Date: Mon, 11 Nov 2024 15:46:22 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E7=A9=BA=E8=B0=83=E6=8E=A7?= =?UTF-8?q?=E5=88=B6=EF=BC=8C=E8=AF=8A=E6=96=AD=E6=8C=89=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../IntegratedCabinet/components/AirConditioning.vue | 10 ++++++---- .../maintenanceOperations/smart/abnormal/index.vue | 9 +++++++-- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/AirConditioning.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/AirConditioning.vue index ce1a4744..a3e5bac6 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/AirConditioning.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/AirConditioning.vue @@ -137,14 +137,16 @@ data: { openingPoint:this.openingPoint, controlObject:this.controlObject, - }, - }).then(result => { + } + }).then(result => { if (result.code != 200) { return Message.error("操作失败"); } - Message.success("操作成功"); + this.$message({ + type: "success", + message: "操作成功", + }); }).catch(error => { - Message.error("请求失败,请稍后再试"); }); }, diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/abnormal/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/abnormal/index.vue index 0efd02ab..cf263692 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/abnormal/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/abnormal/index.vue @@ -63,6 +63,7 @@ type="text" v-if="scope.row.status === '0'" style="color: #00d1ff" + :disabled="isDiagnosing" @click="diagnosis(scope.row)" >诊断 @@ -119,6 +120,7 @@ export default { }, data() { return { + isDiagnosing: false, WarningType:{ 1: '交通流预警', 2: '气象预警' @@ -175,14 +177,16 @@ export default { // }).this.$confirm(`诊断结果:`+deviceTypeCount) // }, diagnosis(row) { - const self = this; + const self = this; + this.isDiagnosing = true; request({ url: `/business/switch/deviceDiagnostics`, method: "post", data: { ...row, } - }).then((result) => { + }).then((result) => { + this.isDiagnosing = false; if (result.code != 200) { return Message.error(result?.msg); } @@ -191,6 +195,7 @@ export default { type: "warning" }); }).catch((error) => { + this.isDiagnosing = false; console.error("请求失败:", error); }); },