From 0ed1212ebbf42553c9b89718885d40b5f4da1f1f Mon Sep 17 00:00:00 2001 From: selia-zx <1771203023@qq.com> Date: Tue, 2 Jun 2026 11:45:22 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=86=B7=E5=86=BB=E5=9B=9E?= =?UTF-8?q?=E6=B0=B4=E6=B8=A9=E5=BA=A6=E5=8F=96=E5=80=BC=E7=9A=84=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/monitor/centerairMonitor.vue | 25 +++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/src/views/components/monitor/centerairMonitor.vue b/src/views/components/monitor/centerairMonitor.vue index 50b168d..9fafdfe 100644 --- a/src/views/components/monitor/centerairMonitor.vue +++ b/src/views/components/monitor/centerairMonitor.vue @@ -433,6 +433,7 @@ export default { coolingTowerInlet: [], //冷却塔进水阀 coolingTowerOutlet: [], //冷却塔出水阀 freezingManifold: [], //冷冻总管 + allCapacity:[], //总冷量计 calorimeter: [], //机房热量计 isShowOn: false, //一键启停,false是Off,true显示On oneKeyButtonId: "", @@ -711,6 +712,7 @@ export default { this.coolingTowerInlet = []; this.coolingTowerOutlet = []; this.freezingManifold = []; + this.allCapacity = []; res.rows.forEach((row) => { switch (row.name) { @@ -746,10 +748,21 @@ export default { this.coolingTowerOutlet = this.processDeviceList(row.values); console.log("冷却塔出水阀列表", this.coolingTowerOutlet); break; + case "6": + this.allCapacity = row.values; + console.log("总冷量计列表", this.allCapacity); + /** 总冷量计数据就绪后,如果冷冻总管数据已有则重新计算,确保allCapacity可用 */ + if (this.freezingManifold.length > 0) { + this.freezingManifoldData(); + } + break; case "15": this.freezingManifold = row.values; console.log("冷冻总管", this.freezingManifold); - this.freezingManifoldData(); + /** 如果allCapacity已有数据则立即计算,否则等case "6"触发 */ + if (this.allCapacity.length > 0) { + this.freezingManifoldData(); + } break; case "25": this.calorimeter = row.values; @@ -1414,12 +1427,20 @@ export default { if (this.freezingManifold.length <= index) { return false; } + /** 先查找总冷量计回水温度的值,用于冷冻回水温度的条件判断 */ + const totalCoolingReturnItem = this.allCapacity.find(i => i.collectName === "总冷量计回水温度"); + const totalCoolingReturnValue = totalCoolingReturnItem ? totalCoolingReturnItem.collectValue : null; + console.log("totalCoolingReturnValue", totalCoolingReturnValue) + this.freezingManifold.forEach((item) => { if (item.collectName === "冷冻供水温度") { this.freezingOutTem = item.collectValue; console.log("item.collectName", item.collectName); } else if (item.collectName === "冷冻回水温度") { - this.freezingInTem = item.collectValue; + // 大于25℃取collectName=总冷量计回水温度的值,否则取collectName=冷冻回水温度的值 + this.freezingInTem = Number(item.collectValue) > 25 && totalCoolingReturnValue !== null + ? totalCoolingReturnValue + : item.collectValue; } else if (item.collectName === "冷冻供水压力") { this.freezingOutPre = item.collectValue; } else if (item.collectName === "冷冻回水压力") {