Pārlūkot izejas kodu

[Fix 0000] 修复布尔台故障诊断设备无法正确读取的问题

houzekong 1 nedēļu atpakaļ
vecāks
revīzija
150b33f27a

+ 2 - 2
src/views/vent/monitorManager/dedustMonitor/components/AlarmHistory.vue

@@ -2,7 +2,7 @@
   <div class="alarm-history">
     <AlarmHistoryTable
       columns-type="alarm"
-      device-type="sys_surface_juejin"
+      :device-type="deviceType"
       :device-list-api="workFaceDeviceList.bind(null, { id: deviceId })"
       :list="list"
       :sys-id="deviceId"
@@ -15,7 +15,7 @@
   import { workFaceDeviceList } from '../../../deviceManager/comment/warningTabel/warning.api';
   import { defHttp } from '/@/utils/http/axios';
 
-  const props = defineProps({
+  defineProps({
     deviceType: {
       type: String,
       required: true,

+ 28 - 0
src/views/vent/monitorManager/dedustMonitor/components/AlarmHistoryBet.vue

@@ -0,0 +1,28 @@
+<template>
+  <div class="alarm-history">
+    <AlarmHistoryTable columns-type="alarm" :device-type="deviceType" designScope="alarm-history" />
+  </div>
+</template>
+<script setup lang="ts">
+  import AlarmHistoryTable from '../../comment/WorkFaceAlarmHistoryTable.vue';
+  // import { workFaceDeviceList } from '../../../deviceManager/comment/warningTabel/warning.api';
+  // import { defHttp } from '/@/utils/http/axios';
+
+  defineProps({
+    deviceType: {
+      type: String,
+      required: true,
+    },
+    deviceId: {
+      type: String,
+      required: true,
+    },
+  });
+
+  // const list = (params) => defHttp.get({ url: '/safety/managesysAutoLog/list', params });
+</script>
+<style lang="less" scoped>
+  .alarm-history {
+    pointer-events: auto;
+  }
+</style>

+ 13 - 3
src/views/vent/monitorManager/dedustMonitor/index.vue

@@ -41,12 +41,13 @@
             :deviceId="optionValue"
             :device-type="deviceType"
           />
-          <AlarmHistory
+          <component
             v-if="activeKey == 'faultRecord'"
+            :is="AlarmHistoryComponent"
             ref="handlerHistoryTable"
             class="vent-margin-t-20"
             :deviceId="optionValue"
-            :device-type="deviceType"
+            :device-type="calcDeviceType"
           />
         </div>
       </div>
@@ -61,7 +62,6 @@
   import BottomMenu from '/@/views/vent/comment/components/bottomMenu.vue';
   import DedustHistory from './components/DedustHistory.vue';
   import HandleHistory from './components/HandleHistory.vue';
-  import AlarmHistory from './components/AlarmHistory.vue';
   import { useRouter } from 'vue-router';
   import { useSystemSelect } from '/@/hooks/vent/useSystemSelect';
   import { useGlobSetting } from '/@/hooks/setting';
@@ -77,6 +77,16 @@
         return defineAsyncComponent(() => import('./components/DedustHome.vue'));
     }
   });
+  const AlarmHistoryComponent = computed(() => {
+    // const sysOrgCode = 'sdmtjtbltmk';
+    switch (sysOrgCode) {
+      // 布尔台
+      case 'sdmtjtbetmk':
+        return defineAsyncComponent(() => import('./components/AlarmHistoryBet.vue'));
+      default:
+        return defineAsyncComponent(() => import('./components/AlarmHistory.vue'));
+    }
+  });
 
   const { currentRoute } = useRouter();
   const activeKey = ref('monitor');