From 3ce8cec3228bad3079226fa8de24f6e2fac99415 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=85=B4=E7=90=B3?= <1911390090@qq.com> Date: Wed, 14 May 2025 17:53:06 +0800 Subject: [PATCH] =?UTF-8?q?=E6=BF=80=E5=85=89=20=E5=B7=A5=E4=BD=9C?= =?UTF-8?q?=E6=A8=A1=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../FatigueWakesUp/components/DeviceParam.vue | 25 ++++++++++++------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/FatigueWakesUp/components/DeviceParam.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/FatigueWakesUp/components/DeviceParam.vue index 0ab3be7b..c4f5e477 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/FatigueWakesUp/components/DeviceParam.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/FatigueWakesUp/components/DeviceParam.vue @@ -270,19 +270,16 @@ export default { } let ask = await this.requestURL("ASKDF",options); - let workingMode = await this.requestURL("ASKMD"); - // if (result.data == 7) { - // this.activeName = "second"; - // this.tabClick(); - // } else { - console.log("工作模式") - console.log(workingMode.data) - this.formData.controlType = workingMode.data + "" || "0"; + //查询时间 - let resultTime = await this.requestURL("ASKTM"); + let resultTime = await this.requestURL2("ASKTM"); console.log("工作时长") console.log(resultTime.data) this.formData.onWorkStatus = resultTime.data || 0; + let workingMode = await this.requestURL2("ASKMD"); + console.log("工作模式") + console.log(workingMode.data) + this.formData.controlType = workingMode.data + "" || "0"; this.activeName = "first"; // } }, @@ -296,6 +293,16 @@ export default { //模式设定:SETMD;模式查询:ASKMD;时间设定:SETTM;时间查询:ASKTM;自定义设置:SETDF;自定义查询:ASKDF return result; }, + async requestURL2(functionId, options = {}) { + let result = await request({ + url: `/business/device/functions2/${this.deviceId}/${functionId}`, + method: "post", + data: options, + }); + if (result.code != 200) return Message.error(result?.msg); + //模式设定:SETMD;模式查询:ASKMD;时间设定:SETTM;时间查询:ASKTM;自定义设置:SETDF;自定义查询:ASKDF + return result; + }, async tabClick() { if (this.activeName == "second") { if (this.isMultiControl)