From 4c09ecad30a06bd552607d2e21c69ce7d86247a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=85=B4=E7=90=B3?= <1911390090@qq.com> Date: Tue, 6 May 2025 18:11:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=88=E6=B5=81=E5=8C=BA=E5=8F=82=E6=95=B0?= =?UTF-8?q?=E8=BF=87=E6=BB=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/Descriptions.vue | 22 ++++++++++++++++++- .../FatigueWakesUp/components/DeviceParam.vue | 6 ++++- 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/ruoyi-ui/src/views/JiHeExpressway/components/Descriptions.vue b/ruoyi-ui/src/views/JiHeExpressway/components/Descriptions.vue index fb28d8f2..9d35d2a6 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/components/Descriptions.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/components/Descriptions.vue @@ -76,6 +76,26 @@ export default { return (item) => getContent(this.data, item); }, getResolveList() { + // 要过滤掉的 property 类型列表 + const disallowedProperties = ['cellVoltage', 'chargeCurrent','solarVoltage','time','averageData']; + + return this.list.reduce((prev, data) => { + + if (disallowedProperties.includes(data.key)) { + return prev; // 如果在列表中,则跳过该数据项 + } + // 原有的 visible 函数或属性判断 + if (typeof data.visible === "function") { + if (!data.visible(data)) return prev; + } else if (data.visible === false) { + return prev; + } + prev.push(data); + + return prev; + }, []); + } + /* getResolveList() { return this.list.reduce((prev, data) => { if (typeof data.visible === "function") { if (!data.visible(data)) return prev; @@ -84,7 +104,7 @@ export default { prev.push(data); return prev; }, []); - }, + },*/ }, methods: { getStyle() { 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 8b26f20c..d39e9957 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 @@ -275,9 +275,13 @@ export default { // this.activeName = "second"; // this.tabClick(); // } else { - this.formData.controlType = result.data + "" || "1"; + console.log("工作模式") + console.log(result.data) + this.formData.controlType = result.data + "" || "0"; //查询时间 let resultTime = await this.requestURL("ASKTM"); + console.log("工作时长") + console.log(resultTime.data) this.formData.onWorkStatus = resultTime.data || 0; this.activeName = "first"; // }