Browse Source

[Fix 0000] 修复首页数据阻力路线错误的问题

ruienger 1 month ago
parent
commit
4e32af6b98

+ 5 - 5
src/views/vent/home/configurable/configurable.api.ts

@@ -62,12 +62,12 @@ export const list = (params) => {
     });
     res.sys_majorpath.forEach((e) => {
       const { drag_1, drag_2, drag_3, drag_total } = e.majorpath;
-      const { retM3_merge = { value: '1' } } = e.readData;
-      const m3_merge = parseInt(retM3_merge.value);
+      const { zuli = { value: '1' } } = e.readData;
+      const drag_merge = parseInt(zuli.value);
       e.piechart = [
-        { val: drag_1, valMock: floor((drag_1 / drag_total) * m3_merge), label: '进风区' },
-        { val: drag_2, valMock: floor((drag_2 / drag_total) * m3_merge), label: '用风区' },
-        { val: drag_3, valMock: floor((drag_3 / drag_total) * m3_merge), label: '回风区' },
+        { val: drag_1, valMock: floor((drag_1 / drag_total) * drag_merge), label: '进风区' },
+        { val: drag_2, valMock: floor((drag_2 / drag_total) * drag_merge), label: '用风区' },
+        { val: drag_3, valMock: floor((drag_3 / drag_total) * drag_merge), label: '回风区' },
       ];
     });
     res.device_arr = Object.values(res.device);

+ 6 - 6
src/views/vent/home/configurable/configurable.data.ts

@@ -1454,19 +1454,19 @@ export const testConfigVentRealtime: Config[] = [
           items: [
             {
               label: '风量(m³/min)',
-              value: '${Fan1StartStatus}',
               trans: {
-                '1': '${Fan1_FanFlow}',
-                '0': '${Fan2_FanFlow}',
+                '0': '${readData.Fan2_FanFlow}',
+                '1': '${readData.Fan1_FanFlow}',
               },
+              value: '${readData.Fan1StartStatus}',
             },
             {
               label: '负压(Pa)',
-              value: '${Fan1StartStatus}',
               trans: {
-                '1': '${Fan1FanPre}',
-                '0': '${Fan2FanPre}',
+                '0': '${readData.Fan2FanPre}',
+                '1': '${readData.Fan1FanPre}',
               },
+              value: '${readData.Fan1StartStatus}',
             },
             {
               label: '漏风率(%)',