瀏覽代碼

1. 完成巷道阻力故障诊断接口对接
2. 优化通风预警监测数据实时请求功能

hongrunxia 2 月之前
父節點
當前提交
4aafcea07a

+ 2 - 2
.env.development

@@ -6,8 +6,8 @@ VITE_PUBLIC_PATH = /
 
 # 跨域代理,您可以配置多个 ,请注意,没有换行符
 #VITE_PROXY = [["/jeecgboot","http://localhost:8080/jeecg-boot"],["/upload","http://localhost:3300/upload"]]
-VITE_PROXY = [["/jeecgsystem","http://182.92.126.35:9999"],["/upload","http://182.92.126.35:9999/upload"],["/documents", "http://182.92.126.35:9050"],["/modelreq", "http://182.92.126.35:9999"],["/webRtc", "http://182.92.126.35:8051"]]
-# VITE_PROXY = [["/jeecgsystem","http://192.168.183.88:9999"],["/upload","http://192.168.183.88:9999/upload"],["/documents", "http://192.168.183.88:9050"],["/modelreq", "http://192.168.183.88:9999"],["/webRtc", "http://192.168.183.88:8051"]]
+# VITE_PROXY = [["/jeecgsystem","http://182.92.126.35:9999"],["/upload","http://182.92.126.35:9999/upload"],["/documents", "http://182.92.126.35:9050"],["/modelreq", "http://182.92.126.35:9999"],["/webRtc", "http://182.92.126.35:8051"]]
+VITE_PROXY = [["/jeecgsystem","http://192.168.183.88:9999"],["/upload","http://192.168.183.88:9999/upload"],["/documents", "http://192.168.183.88:9050"],["/modelreq", "http://192.168.183.88:9999"],["/webRtc", "http://192.168.183.88:8051"]]
 # VITE_PROXY = [["/jeecgsystem","http://10.10.150.72:9999"],["/upload","http://localhost:3300/upload"],["/documents", "http://10.10.150.72:9050"],["/modelreq", "http://10.10.150.72:9999"],["/webRtc", "http://192.168.183.216:8051"]]
 #VITE_PROXY = [["/jeecgsystem","http://192.168.1.8:9999"],["/upload","http://localhost:3300/upload"]]
 

+ 4 - 2
src/layouts/default/header/index.vue

@@ -2,7 +2,8 @@
   <Header
     v-if="
       ((!getShowFullHeader && !currentRoute.path.endsWith('home')) || currentRoute.path.startsWith('/micro-vent-3dModal/modelchannel/')) &&
-      !noHeadeLink.includes(currentRoute.path)
+      !noHeadeLink.includes(currentRoute.path) &&
+      currentRoute.path !== homePath
     "
     :class="[
       ...getHeaderClass,
@@ -129,7 +130,7 @@
 
       const { getShowTopMenu, getShowHeaderTrigger, getSplit, getIsMixMode, getMenuWidth, getIsMixSidebar } = useMenuSetting();
       const { getUseErrorHandle, getShowSettingButton, getSettingButtonPosition } = useRootSetting();
-      const { title, sysOrgCode } = useGlobSetting();
+      const { title, sysOrgCode, homePath } = useGlobSetting();
       const {
         getHeaderTheme,
         getShowFullScreen,
@@ -254,6 +255,7 @@
         noHeadeLink,
         showUserDropdown,
         sysOrgCode,
+        homePath,
       };
     },
   });

+ 3 - 5
src/router/guard/permissionGuard.ts

@@ -39,7 +39,6 @@ const whitePathList: PageEnum[] = [LOGIN_PATH, OAUTH2_LOGIN_PAGE_PATH, SYS_FILES
 const glob = useGlobSetting();
 
 export function createPermissionGuard(router: Router) {
-  debugger;
   const userStore = useUserStoreWithOut();
   const permissionStore = usePermissionStoreWithOut();
   const { doAutoLogin, doTokenLogin, validateRoute, tokenValidateRoute } = useAutoLogin();
@@ -57,9 +56,8 @@ export function createPermissionGuard(router: Router) {
       userStore.getUserInfo.homePath !== (glob.homePath || PageEnum.BASE_HOME)
     ) {
       // mountMicroApp(userStore.getUserInfo.homePath);
-      next(userStore.getUserInfo.homePath);
       document.title = '首页';
-      return;
+      return next(userStore.getUserInfo.homePath);
     }
 
     // 如果符合自动登录的相关条件则直接执行自动登录,覆盖原有的登录信息
@@ -260,8 +258,8 @@ export function createPermissionGuard(router: Router) {
       router.addRoute(route as unknown as RouteRecordRaw);
     });
 
-    router.addRoute(PAGE_NOT_FOUND_ROUTE as unknown as RouteRecordRaw); //
-    router.addRoute(QIANKUN_ROUTE as unknown as RouteRecordRaw);
+    router.addRoute(PAGE_NOT_FOUND_ROUTE as unknown as RouteRecordRaw);
+    // router.addRoute(QIANKUN_ROUTE as unknown as RouteRecordRaw);
 
     permissionStore.setDynamicAddedRoute(true);
 

+ 3 - 3
src/router/routes/basic.ts

@@ -77,7 +77,7 @@ export const QIANKUN_ROUTE: AppRouteRecordRaw = {
     },
     {
       path: '/micro-vent-3dModal/dashboard/analysis',
-      name: 'dashboard-analysis',
+      name: 'micro-vent-3dModal-dashboard-analysis',
       component: () => import('/@/views/vent/monitorManager/deviceMonitor/index.vue'),
       meta: {
         title: '通防综合管控',
@@ -88,7 +88,7 @@ export const QIANKUN_ROUTE: AppRouteRecordRaw = {
     },
     {
       path: '/micro-vent-3dModal/modelchannel/model3D/home',
-      name: 'model3D-home',
+      name: 'micro-vent-3dModal-modelchannel-model3D',
       component: () => import('/@/views/vent/home/colliery/index.vue'),
       meta: {
         title: '通防综合管控',
@@ -100,7 +100,7 @@ export const QIANKUN_ROUTE: AppRouteRecordRaw = {
     {
       path: '/micro-need-air/:path(.*)*',
       name: QIANKUN_ROUTE_NAME,
-      component: QIANKUN_COMPONENT,
+      component: LAYOUT,
       meta: {
         title: '需风量分析系统',
         hideBreadcrumb: true,

+ 1 - 0
src/router/routes/index.ts

@@ -89,6 +89,7 @@ export const basicRoutes = [
   LoginRoute,
   RootRoute,
   ventModelRedirect,
+  QIANKUN_ROUTE,
   // ...mainOutRoutes,
   REDIRECT_ROUTE,
   PAGE_NOT_FOUND_ROUTE,

+ 2 - 2
src/store/modules/user.ts

@@ -150,7 +150,7 @@ export const useUserStore = defineStore({
         const { token, userInfo } = data;
         // save token
         this.setToken(token);
-        this.setTenant(userInfo.loginTenantId);
+        // this.setTenant(userInfo.loginTenantId);
         return this.afterLoginAction(goHome, data);
       } catch (error) {
         return Promise.reject(error);
@@ -414,7 +414,7 @@ export const useUserStore = defineStore({
       const { token, userInfo } = data;
       // save token
       this.setToken(token);
-      this.setTenant(userInfo.loginTenantId);
+      // this.setTenant(userInfo.loginTenantId);
       await this.afterLoginAction(goHome, data);
       return;
     },

+ 3 - 0
src/views/vent/monitorManager/alarmMonitor/alarm.api.ts

@@ -10,6 +10,7 @@ enum Api {
   sysTypeWarnList = '/ventanaly-device/safety/ventanalyAlarmLog/sysTypeWarn',
   sysWarn = '/ventanaly-device/safety/ventanalyAlarmLog/sysWarn',
   getReferenceValue = '/safety/managesysDevice/getReferenceValue',
+  realTimeNetCal = '/ventanaly-model/Vmodel/VentanalyAirthmeticJson/windTimenetcal',
 }
 /**
  * 列表接口
@@ -44,3 +45,5 @@ export const sysWarn = (params) => defHttp.post({ url: Api.sysWarn, params });
 
 //根据煤层ID查询指标参数
 export const getReferenceValue = (params) => defHttp.get({ url: Api.getReferenceValue, params });
+
+export const realTimeNetCal = (params) => defHttp.post({ url: Api.realTimeNetCal, params });

+ 62 - 0
src/views/vent/monitorManager/alarmMonitor/alarm.data.ts

@@ -29,6 +29,68 @@ export const formConfig = {
   ],
 };
 
+export const ventTunColumns: BasicColumn[] = [
+  {
+    title: '巷道名称',
+    dataIndex: 'strName',
+    width: 120,
+    align: 'center',
+  },
+  {
+    title: '断面积',
+    dataIndex: 'fArea',
+    width: 80,
+    align: 'center',
+  },
+  {
+    title: '风速(m/s)',
+    dataIndex: 'fRealV',
+    width: 80,
+    align: 'center',
+  },
+  {
+    title: '风量(m³/min)',
+    dataIndex: 'fRealQMin',
+    width: 80,
+    align: 'center',
+  },
+  {
+    title: '按需分风风阻',
+    dataIndex: 'oldHTotal',
+    width: 80,
+    align: 'center',
+  },
+  {
+    title: '实时解算风阻',
+    dataIndex: 'dHTotal',
+    width: 80,
+    align: 'center',
+  },
+
+  {
+    title: '风阻分析',
+    dataIndex: 'analyse',
+    customRender: ({ record }) => {
+      if (record) {
+        const p = ((record['dHTotal'] - record['oldHTotal']) / record['oldHTotal']) * 100;
+        if (p == 0) {
+          return '正常';
+        } else if (p > 0 && p <= 1) {
+          return '低风险';
+        } else if (p > 1 && p <= 3) {
+          return '一般风险';
+        } else if (p > 3 && p <= 5) {
+          return '较大风险';
+        } else {
+          return '重大风险';
+        }
+      }
+    },
+    width: 100,
+    align: 'center',
+  },
+];
+
 export const levelColumns: BasicColumn[] = [
   {
     title: '设备名称',

+ 166 - 134
src/views/vent/monitorManager/alarmMonitor/warn/ventilateWarn.vue

@@ -1,10 +1,10 @@
 <template>
   <customHeader :options="options" @change="getSelectRow" :optionValue="optionValue"> 通风监测预警 </customHeader>
   <div class="ventilateWarn">
-          <div v-if="showToggle=='all'"  class="icon-toggle" @click="handlerToggle">
-            <img v-if="monitor" src="@/assets/images/vent/monitor-toggle.png" alt="">
-            <img v-else  src="@/assets/images/vent/report-toggle.png" alt="">
-          </div>
+    <div v-if="showToggle == 'all'" class="icon-toggle" @click="handlerToggle">
+      <img v-if="monitor" src="@/assets/images/vent/monitor-toggle.png" alt="" />
+      <img v-else src="@/assets/images/vent/report-toggle.png" alt="" />
+    </div>
     <div class="ventilate-top">
       <a-button
         v-if="!hasPermission('ventilateWarn:return')"
@@ -25,39 +25,51 @@
         </div>
       </div>
       <div class="ventilate-content">
-        <div class="work-nav">
-          <div class="nav" v-for="(item, index) in ventilateTopList" :key="index">
-            <div class="pic" v-if="item.imgSrc"></div>
-            <div class="content" v-if="item.label && item.value">
-              <span>{{ item.label }}</span>
-              <span>{{ item.value }}</span>
-            </div>
-            <div
-              :style="{ color: item.text == '正常' ? 'var(--vent-table-action-link)' : '#ff2313' }"
-              style="width: 100%; padding: 0px 10px; text-align: center; font-weight: bold"
-              v-if="item.text"
-            >
-              {{ item.text }}
-            </div>
-            <div class="percent" v-if="item.list.length != 0">
-              <div class="title">{{ item.label }}</div>
-              <div class="value">
-                <div class="content-box" v-for="(items, ind) in item.list" :key="ind">
-                  <span style="color: #b3b8cc">{{ `${items.label} :` }}</span>
-                  <span style="color: var(--vent-table-action-link); margin-left: 10px">{{ items.value }}</span>
+        <a-spin :spinning="loading">
+          <div class="work-nav">
+            <div class="nav" v-for="(item, index) in ventilateTopList" :key="index">
+              <div class="pic" v-if="item.imgSrc"></div>
+              <div class="content" v-if="item.label && item.value">
+                <span>{{ item.label }}</span>
+                <span>{{ item.value }}</span>
+              </div>
+              <div
+                :style="{ color: item.text == '正常' ? 'var(--vent-table-action-link)' : '#ff2313' }"
+                style="width: 100%; padding: 0px 10px; text-align: center; font-weight: bold"
+                v-if="item.text"
+              >
+                {{ item.text }}
+              </div>
+              <div class="percent" v-if="item.list.length != 0">
+                <div class="title">{{ item.label }}</div>
+                <div class="value">
+                  <div class="content-box" v-for="(items, ind) in item.list" :key="ind">
+                    <span style="color: #b3b8cc">{{ `${items.label} :` }}</span>
+                    <span style="color: var(--vent-table-action-link); margin-left: 10px">{{ items.value }}</span>
+                  </div>
                 </div>
               </div>
             </div>
           </div>
-        </div>
-        <div class="bot-area">
-          <div class="title-t">
-            <div class="text-t">通风信息状态监测</div>
-          </div>
-          <div class="echart-boxd">
-            <echartLine :echartDataGq="echartDataFc1" :maxY="maxY" :echartDw="echartDw" />
+          <div class="bot-area">
+            <div class="title-t">
+              <div class="text-t">通风信息状态监测</div>
+            </div>
+            <div class="echart-boxd">
+              <echartLine :echartDataGq="echartDataFc1" :maxY="maxY" :echartDw="echartDw" />
+            </div>
           </div>
-        </div>
+        </a-spin>
+      </div>
+      <div class="tun-box">
+        <MonitorTable
+          ref="tunMonitorRef"
+          :columns="ventTunColumns"
+          :dataSource="ventTunDataSource"
+          :isShowSelect="false"
+          :scroll="{ y: 300 }"
+          title="巷道阻力分析"
+        />
       </div>
     </div>
     <div class="ventilate-bottom">
@@ -69,28 +81,34 @@
 </template>
 
 <script setup lang="ts">
-  import { ref, reactive, onMounted, onUnmounted,computed } from 'vue';
+  import { ref, reactive, onMounted, onUnmounted, computed } from 'vue';
   import { useSystemSelect } from '/@/hooks/vent/useSystemSelect';
   import { usePermission } from '/@/hooks/web/usePermission';
   import { useGlobSetting } from '/@/hooks/setting';
   import { useRouter } from 'vue-router';
   import { sysTypeWarnList, sysWarn, getDevice } from '../common.api';
   import { ventilateTopList } from '../common.data';
+  import MonitorTable from '../../comment/MonitorTable.vue';
   import CustomHeader from '/@/components/vent/customHeader.vue';
   import echartLine from '../common/echartLine.vue';
   import MeasurePoint from '../common/measurePoint.vue';
+  import { ventTunColumns } from '../alarm.data';
+  import { realTimeNetCal } from '../alarm.api';
   // import moment from 'moment';
 
-  let monitor=ref(true)
-  let toggleData=reactive<any>({})
+  let monitor = ref(true);
+  let toggleData = reactive<any>({});
   const { hasPermission } = usePermission();
   const { options, optionValue, getSelectRow, getSysDataSource } = useSystemSelect('sys_surface_caimei'); // 参数为场景类型(设备类型管理中可以查询到)
   let router = useRouter();
   //左侧数据列表
   let menuList = reactive<any[]>([]);
+  const ventTunDataSource = ref([]);
   //当前左侧激活菜单的索引
   let activeIndex1 = ref(0);
   let maxY = ref<any>(0);
+  const loading = ref(false);
+  const currentDeviceId = ref('');
   let echartDw = ref('(m³/min)');
   //通风图表数据
   const echartDataFc1 = reactive<any>({
@@ -110,43 +128,40 @@
   });
   let cardListTf = ref<any[]>([]);
   const chartListTf = ref<any[]>([]);
-   let showToggle=ref('')
+  let showToggle = ref('');
   //点击切换实时\报表数据
-  let handlerToggle=()=>{
-    monitor.value=!monitor.value
-    ventilateTopList[0].value =monitor.value ? toggleData.jin : toggleData.faceIntM3;
-    ventilateTopList[1].value = monitor.value ? toggleData.hui : toggleData.faceRetM3 ;
-    if(monitor.value && toggleData.history.length != 0){
-          toggleData.history.forEach((v) => {
-            echartDataFc1.maxData.data.push(parseFloat(v.jin));
-            echartDataFc1.minData.data.push(parseFloat(v.hui));
-            if (ventilateTopList[2].value && ventilateTopList[2].value != '--') {
-              echartDataFc1.aveValue.data.push(ventilateTopList[2].value);
-            } else {
-              echartDataFc1.aveValue.data.push(0);
-            }
-            echartDataFc1.xData.push(v.time);
-          });
-        }else {
-        toggleData.history_report.forEach((v) => {
-            echartDataFc1.maxData.data.push(parseFloat(v.faceIntM3));
-            echartDataFc1.minData.data.push(parseFloat(v.faceRetM3));
-            echartDataFc1.aveValue.data.push(0);
-            echartDataFc1.xData.push(v.time);
-          });
+  let handlerToggle = () => {
+    monitor.value = !monitor.value;
+    ventilateTopList[0].value = monitor.value ? toggleData.jin : toggleData.faceIntM3;
+    ventilateTopList[1].value = monitor.value ? toggleData.hui : toggleData.faceRetM3;
+    if (monitor.value && toggleData.history.length != 0) {
+      toggleData.history.forEach((v) => {
+        echartDataFc1.maxData.data.push(parseFloat(v.jin));
+        echartDataFc1.minData.data.push(parseFloat(v.hui));
+        if (ventilateTopList[2].value && ventilateTopList[2].value != '--') {
+          echartDataFc1.aveValue.data.push(ventilateTopList[2].value);
+        } else {
+          echartDataFc1.aveValue.data.push(0);
         }
-  }
+        echartDataFc1.xData.push(v.time);
+      });
+    } else {
+      toggleData.history_report.forEach((v) => {
+        echartDataFc1.maxData.data.push(parseFloat(v.faceIntM3));
+        echartDataFc1.minData.data.push(parseFloat(v.faceRetM3));
+        echartDataFc1.aveValue.data.push(0);
+        echartDataFc1.xData.push(v.time);
+      });
+    }
+  };
   // https获取监测数据
   let timer: null | NodeJS.Timeout = null;
-  function getMonitor(deviceID, flag?) {
+  function getMonitor(flag?) {
     timer = setTimeout(
       async () => {
-        await getSysWarnList(deviceID, 'vent');
+        await getSysWarnList(currentDeviceId.value, 'vent');
         await getWindDeviceList();
-        if (timer) {
-          timer = null;
-        }
-        getMonitor(deviceID);
+        getMonitor(false);
       },
       flag ? 0 : 1000
     );
@@ -168,14 +183,19 @@
           strtype: el.deviceType,
         });
       });
-      getMonitor(menuList[0].deviceID, true);
+      currentDeviceId.value = menuList[0].deviceID;
+      // getMonitor(, true);
     }
   }
   //菜单选项切换
   function cardClick(ind, item) {
     activeIndex1.value = ind;
-    clearTimeout(timer);
-    getMonitor(item.deviceID, true);
+    if (timer) clearTimeout(timer);
+    loading.value = true;
+    setTimeout(() => {
+      currentDeviceId.value = item.deviceID;
+      getMonitor(true);
+    }, 1000);
   }
   //获取预警详情弹窗右侧数据
   function getSysWarnList(id, type) {
@@ -185,57 +205,57 @@
       echartDataFc1.aveValue.data.length = 0;
       echartDataFc1.xData.length = 0;
       if (JSON.stringify(res) != '{}') {
-        toggleData=Object.assign({},res)
+        toggleData = Object.assign({}, res);
         ventilateTopList[2].value = res.xufengliang || '--';
         ventilateTopList[3].text = res.warnFlag ? res.warnDes : '正常';
-        if(showToggle.value=='monitor'){
-          ventilateTopList[0].value =res.jin
-          ventilateTopList[1].value =res.hui
-          if(res.history.length != 0){
-          res.history.forEach((v) => {
-            echartDataFc1.maxData.data.push(parseFloat(v.jin));
-            echartDataFc1.minData.data.push(parseFloat(v.hui));
-            if (ventilateTopList[2].value && ventilateTopList[2].value != '--') {
-              echartDataFc1.aveValue.data.push(ventilateTopList[2].value);
-            } else {
-              echartDataFc1.aveValue.data.push(0);
-            }
-            echartDataFc1.xData.push(v.time);
-          });
-        }
-        }else if(showToggle.value=='report'){
-          ventilateTopList[0].value =res.faceIntM3;
-          ventilateTopList[1].value =res.faceRetM3 ;
-          if(res.history_report.length != 0){
+        if (showToggle.value == 'monitor') {
+          ventilateTopList[0].value = res.jin;
+          ventilateTopList[1].value = res.hui;
+          if (res.history.length != 0) {
+            res.history.forEach((v) => {
+              echartDataFc1.maxData.data.push(parseFloat(v.jin));
+              echartDataFc1.minData.data.push(parseFloat(v.hui));
+              if (ventilateTopList[2].value && ventilateTopList[2].value != '--') {
+                echartDataFc1.aveValue.data.push(ventilateTopList[2].value);
+              } else {
+                echartDataFc1.aveValue.data.push(0);
+              }
+              echartDataFc1.xData.push(v.time);
+            });
+          }
+        } else if (showToggle.value == 'report') {
+          ventilateTopList[0].value = res.faceIntM3;
+          ventilateTopList[1].value = res.faceRetM3;
+          if (res.history_report.length != 0) {
             res.history_report.forEach((v) => {
-            echartDataFc1.maxData.data.push(parseFloat(v.faceIntM3));
-            echartDataFc1.minData.data.push(parseFloat(v.faceRetM3));
-            echartDataFc1.aveValue.data.push(0);
-            echartDataFc1.xData.push(v.time);
-          });
+              echartDataFc1.maxData.data.push(parseFloat(v.faceIntM3));
+              echartDataFc1.minData.data.push(parseFloat(v.faceRetM3));
+              echartDataFc1.aveValue.data.push(0);
+              echartDataFc1.xData.push(v.time);
+            });
           }
-        }else {
-          ventilateTopList[0].value =monitor.value ? res.jin : res.faceIntM3;
-          ventilateTopList[1].value = monitor.value ? res.hui : res.faceRetM3 ;
-          if(monitor.value && res.history.length != 0){
-          res.history.forEach((v) => {
-            echartDataFc1.maxData.data.push(parseFloat(v.jin));
-            echartDataFc1.minData.data.push(parseFloat(v.hui));
-            if (ventilateTopList[2].value && ventilateTopList[2].value != '--') {
-              echartDataFc1.aveValue.data.push(ventilateTopList[2].value);
-            } else {
+        } else {
+          ventilateTopList[0].value = monitor.value ? res.jin : res.faceIntM3;
+          ventilateTopList[1].value = monitor.value ? res.hui : res.faceRetM3;
+          if (monitor.value && res.history.length != 0) {
+            res.history.forEach((v) => {
+              echartDataFc1.maxData.data.push(parseFloat(v.jin));
+              echartDataFc1.minData.data.push(parseFloat(v.hui));
+              if (ventilateTopList[2].value && ventilateTopList[2].value != '--') {
+                echartDataFc1.aveValue.data.push(ventilateTopList[2].value);
+              } else {
+                echartDataFc1.aveValue.data.push(0);
+              }
+              echartDataFc1.xData.push(v.time);
+            });
+          } else {
+            res.history_report.forEach((v) => {
+              echartDataFc1.maxData.data.push(parseFloat(v.faceIntM3));
+              echartDataFc1.minData.data.push(parseFloat(v.faceRetM3));
               echartDataFc1.aveValue.data.push(0);
-            }
-            echartDataFc1.xData.push(v.time);
-          });
-        }else {
-          res.history_report.forEach((v) => {
-            echartDataFc1.maxData.data.push(parseFloat(v.faceIntM3));
-            echartDataFc1.minData.data.push(parseFloat(v.faceRetM3));
-            echartDataFc1.aveValue.data.push(0);
-            echartDataFc1.xData.push(v.time);
-          });
-        }
+              echartDataFc1.xData.push(v.time);
+            });
+          }
         }
 
         let max1 = echartDataFc1.maxData.data.reduce((acr, cur) => {
@@ -307,10 +327,17 @@
       chartListTf.value = chartTfList;
     }
   }
+  function getRealTimeNetData() {
+    const res = realTimeNetCal({ modelID: '8110' });
+    if (res && res['result']) ventTunDataSource.value = res['result']['tuns'];
+  }
+
   onMounted(() => {
     const { sysOrgCode, sysDataType } = useGlobSetting();
-  showToggle.value=sysDataType
+    showToggle.value = sysDataType;
     getMenuList();
+    getMonitor();
+    getRealTimeNetData();
   });
   onUnmounted(() => {
     if (timer) {
@@ -345,28 +372,29 @@
     --image-xufengliang: url('/@/assets/images/fire/xufengliang.png');
     --border-image-1: linear-gradient(to bottom, #2d74a0, #2d74a0, #2d74a0);
     --border-image-2: linear-gradient(to bottom, transparent, #024688, transparent);
-    position:reactive;
+    position: reactive;
     width: 100%;
     height: 100%;
     padding: 80px 10px 15px 10px;
     box-sizing: border-box;
 
     .ventilate-top {
+      width: 100%;
       display: flex;
       justify-content: space-between;
       height: 50%;
       margin-bottom: 15px;
       background: var(--image-border) no-repeat center;
       background-size: 100% 100%;
-
+      padding-right: 15px;
       .alarm-menu {
         height: 100%;
-        width: 15%;
+        // width: 200px;
         padding: 10px;
         box-sizing: border-box;
 
         .card-btn {
-          width: 100%;
+          width: 240px;
           height: 100%;
           overflow-y: auto;
 
@@ -440,9 +468,10 @@
 
       .ventilate-content {
         height: 100%;
-        width: 85%;
+        width: 1300px;
         padding: 10px 0px;
         box-sizing: border-box;
+        margin-right: 10px;
 
         .work-nav {
           height: 30%;
@@ -490,7 +519,7 @@
               border-image: var(--border-image-2) 1 1 1;
             }
 
-            /** 
+            /**
             &:nth-child(5) {
               flex: 1.4;
               height: 100%;
@@ -524,8 +553,8 @@
             }*/
 
             .pic {
-              width: 30%;
-              height: 82%;
+              width: 90px;
+              height: 90px;
             }
 
             .content {
@@ -591,12 +620,15 @@
 
           .echart-boxd {
             width: 100%;
-            height: calc(100% - 30px);
+            height: 250px;
           }
         }
       }
     }
-
+    .tun-box {
+      width: 600px;
+      height: 300px;
+    }
     .ventilate-bottom {
       height: calc(50% - 15px);
       background: var(--image-border) no-repeat center;
@@ -612,15 +644,15 @@
         box-sizing: border-box;
       }
     }
-    .icon-toggle{
-    position: absolute;
-    right: 220px;
-    top: 17px;
-    img{
-      width: 26px;
-      height: 26px;
-      cursor: pointer;
+    .icon-toggle {
+      position: absolute;
+      right: 220px;
+      top: 17px;
+      img {
+        width: 26px;
+        height: 26px;
+        cursor: pointer;
+      }
     }
   }
-  }
 </style>

+ 12 - 8
src/views/vent/monitorManager/comment/MonitorTable.vue

@@ -81,7 +81,7 @@
 
   const ventTableRef = ref();
 
-  const tableMaxHeight = 150;
+  const tableMaxHeight = props.scroll.y ? props.scroll.y : 350;
   const columns = ref([])
   const tableScroll = props.scroll.y ?  ref({y: props.scroll.y}) : ref({})
    //注册table数据
@@ -98,7 +98,7 @@
       showTableSetting: false,
       showIndexColumn: true,
       showActionColumn: props.isShowActionColumn,
-      maxHeight: tableMaxHeight,
+      minHeight: tableMaxHeight,
       bordered: false,
       scroll: tableScroll,
       rowKey: 'deviceID',
@@ -127,7 +127,7 @@
       },
     },
   });
-  const [registerTable, { reload, setLoading, setSelectedRowKeys, getSelectRowKeys, getForm }, { rowSelection, selectedRowKeys,  }] = tableContext;
+  const [registerTable, { reload, setLoading, setSelectedRowKeys, getSelectRowKeys, getForm, setPagination }, { rowSelection, selectedRowKeys,  }] = tableContext;
   watch(
     () => {
       return props.dataSource;
@@ -142,7 +142,9 @@
         list.push(toRaw(item));
       });
       dataTableSource.value = list;
-      if(ventTableRef.value) setLoading(false)
+      if(ventTableRef.value) {
+        setLoading(false)
+      }
     },
     {
       immediate: true
@@ -184,9 +186,6 @@
     }
     }
   )
-
-
- 
   
   watch(
     selectedRowKeys,
@@ -200,13 +199,18 @@
     { immediate: false }
   );
 
+  function resetPagination() {
+     if(ventTableRef.value) setPagination({current: 1, pageSize: 50, total:0})
+  }
+
   defineExpose({
     doRequest,
     setSelectedRowKeys,
     getSelectRowKeys,
     setLoading,
     reload,
-    getForm
+    getForm,
+    resetPagination
   });
 
   onMounted(() => {

+ 2 - 0
src/views/vent/monitorManager/deviceMonitor/components/device/index.vue

@@ -716,6 +716,7 @@
       clearTimeout(startMonitorTimer);
     }
     dataSource.value = [];
+    monitorTable.value.resetPagination()
     if (!startMonitorTimer) {
       startMonitorTimer = setTimeout(() => {
         expandedKeys.value = keys;
@@ -723,6 +724,7 @@
         treeNodeTitle.value = e.node.title;
 
         if (e.node.children?.length < 1 && timer) {
+          
           getMonitor(true);
         }
       }, 1000);

+ 49 - 0
src/views/vent/monitorManager/gateMonitor/gate.threejs.qd.ts

@@ -334,6 +334,55 @@ class Fm3 {
             if (this.backDamperClosedMesh) this.backDamperClosedMesh.visible = true;
           };
           break;
+        case 5: // 打开前后门
+          handler = () => {
+            this.clipActionArr.frontDoor.paused = true;
+            this.clipActionArr.frontDoor.reset();
+            this.clipActionArr.frontDoor.time = 1.2;
+            this.clipActionArr.frontDoor.timeScale = timeScale;
+            // this.clipActionArr.frontDoor.clampWhenFinished = true;
+            this.clipActionArr.frontDoor.play();
+            this.fmClock.start();
+            // 显示打开前门文字
+            if (this.frontDamperOpenMesh) this.frontDamperOpenMesh.visible = true;
+            if (this.frontDamperClosedMesh) this.frontDamperClosedMesh.visible = false;
+
+            this.clipActionArr.backDoor.paused = true;
+            this.clipActionArr.backDoor.reset();
+            this.clipActionArr.backDoor.time = 1.2;
+            this.clipActionArr.backDoor.timeScale = timeScale;
+            // this.clipActionArr.backDoor.clampWhenFinished = true;
+            this.clipActionArr.backDoor.play();
+            this.fmClock.start();
+            if (this.backDamperOpenMesh) this.backDamperOpenMesh.visible = true;
+            if (this.backDamperClosedMesh) this.backDamperClosedMesh.visible = false;
+          };
+          break;
+        case 6: // 关闭前后门
+          handler = () => {
+            this.clipActionArr.frontDoor.paused = true;
+            this.clipActionArr.frontDoor.reset(); //
+            this.clipActionArr.frontDoor.time = 4;
+            this.clipActionArr.frontDoor.timeScale = -timeScale;
+            // this.clipActionArr.frontDoor.clampWhenFinished = true;
+            this.clipActionArr.frontDoor.play();
+            this.fmClock.start();
+
+            if (this.frontDamperOpenMesh) this.frontDamperOpenMesh.visible = false;
+            if (this.frontDamperClosedMesh) this.frontDamperClosedMesh.visible = true;
+
+            this.clipActionArr.backDoor.paused = true;
+            this.clipActionArr.backDoor.reset();
+            this.clipActionArr.backDoor.time = 4;
+            this.clipActionArr.backDoor.timeScale = -timeScale;
+            // this.clipActionArr.backDoor.clampWhenFinished = true;
+            this.clipActionArr.backDoor.play();
+            this.fmClock.start();
+
+            if (this.backDamperOpenMesh) this.backDamperOpenMesh.visible = false;
+            if (this.backDamperClosedMesh) this.backDamperClosedMesh.visible = true;
+          };
+          break;
         default:
       }
       handler();

+ 48 - 40
src/views/vent/monitorManager/gateMonitor/gate.threejs.two.yj.ts

@@ -394,46 +394,54 @@ class FmTwoYj {
             if (this.backDamperClosedMesh) this.backDamperClosedMesh.visible = true;
           };
           break;
-        // case 5: // 打开前后门
-        //   handler = () => {
-        //     this.clipActionArr.backDoor.paused = true;
-        //     this.clipActionArr.frontDoor.paused = true;
-
-        //     this.clipActionArr.frontDoor.reset();
-        //     this.clipActionArr.frontDoor.time = 0;
-        //     this.clipActionArr.frontDoor.timeScale = 0.01;
-        //     this.clipActionArr.frontDoor.clampWhenFinished = true;
-        //     this.clipActionArr.frontDoor.play();
-
-        //     this.clipActionArr.backDoor.reset();
-        //     this.clipActionArr.backDoor.time = 0;
-        //     this.clipActionArr.backDoor.timeScale = 0.01;
-        //     this.clipActionArr.backDoor.clampWhenFinished = true;
-        //     this.clipActionArr.backDoor.play();
-        //     this.frontClock.start();
-        //     this.backClock.start();
-        //   };
-        //   break;
-        // case 6: // 关闭前后门
-        //   handler = () => {
-        //     debugger;
-        //     this.clipActionArr.backDoor.paused = true;
-        //     this.clipActionArr.frontDoor.paused = true;
-
-        //     this.clipActionArr.frontDoor.reset();
-        //     this.clipActionArr.frontDoor.time = 4;
-        //     this.clipActionArr.frontDoor.timeScale = -0.01;
-        //     this.clipActionArr.frontDoor.clampWhenFinished = true;
-        //     this.clipActionArr.frontDoor.play();
-        //     this.clipActionArr.backDoor.reset();
-        //     this.clipActionArr.backDoor.time = 4;
-        //     this.clipActionArr.backDoor.timeScale = -0.01;
-        //     this.clipActionArr.backDoor.clampWhenFinished = true;
-        //     this.clipActionArr.backDoor.play();
-        //     this.frontClock.start();
-        //     this.backClock.start();
-        //   };
-        //   break;
+        case 5: // 打开前后门
+          handler = () => {
+            this.clipActionArr.frontDoor.paused = true;
+            this.clipActionArr.frontDoor.reset();
+            this.clipActionArr.frontDoor.time = 1.2;
+            this.clipActionArr.frontDoor.timeScale = timeScale;
+            // this.clipActionArr.frontDoor.clampWhenFinished = true;
+            this.clipActionArr.frontDoor.play();
+            this.fmClock.start();
+            // 显示打开前门文字
+            if (this.frontDamperOpenMesh) this.frontDamperOpenMesh.visible = true;
+            if (this.frontDamperClosedMesh) this.frontDamperClosedMesh.visible = false;
+
+            this.clipActionArr.backDoor.paused = true;
+            this.clipActionArr.backDoor.reset();
+            this.clipActionArr.backDoor.time = 1.2;
+            this.clipActionArr.backDoor.timeScale = timeScale;
+            // this.clipActionArr.backDoor.clampWhenFinished = true;
+            this.clipActionArr.backDoor.play();
+            this.fmClock.start();
+            if (this.backDamperOpenMesh) this.backDamperOpenMesh.visible = true;
+            if (this.backDamperClosedMesh) this.backDamperClosedMesh.visible = false;
+          };
+          break;
+        case 6: // 关闭前后门
+          handler = () => {
+            this.clipActionArr.frontDoor.paused = true;
+            this.clipActionArr.frontDoor.reset(); //
+            this.clipActionArr.frontDoor.time = 5.5;
+            this.clipActionArr.frontDoor.timeScale = -timeScale;
+            // this.clipActionArr.frontDoor.clampWhenFinished = true;
+            this.clipActionArr.frontDoor.play();
+            this.fmClock.start();
+
+            if (this.frontDamperOpenMesh) this.frontDamperOpenMesh.visible = false;
+            if (this.frontDamperClosedMesh) this.frontDamperClosedMesh.visible = true;
+
+            this.clipActionArr.backDoor.paused = true;
+            this.clipActionArr.backDoor.reset();
+            this.clipActionArr.backDoor.time = 5.5;
+            this.clipActionArr.backDoor.timeScale = -timeScale;
+            // this.clipActionArr.backDoor.clampWhenFinished = true;
+            this.clipActionArr.backDoor.play();
+            this.fmClock.start();
+
+            if (this.backDamperOpenMesh) this.backDamperOpenMesh.visible = false;
+            if (this.backDamperClosedMesh) this.backDamperClosedMesh.visible = true;
+          };
         default:
       }
 

+ 2 - 6
src/views/vent/monitorManager/gateMonitor/index.vue

@@ -39,12 +39,8 @@
         >
         <div v-if="hasPermission('btn:control')" class="button-box" @click="playAnimation(3)">打开后门</div>
         <div v-if="hasPermission('btn:control')" class="button-box" @click="playAnimation(4)">关闭后门</div>
-        <div v-if="!hasPermission('btn:controlWindow') && selectData.deviceType != 'gate_ss'" class="button-box" @click="playAnimation(5)"
-          >同时打开</div
-        >
-        <div v-if="!hasPermission('btn:controlWindow') && selectData.deviceType != 'gate_ss'" class="button-box" @click="playAnimation(6)"
-          >同时关闭</div
-        >
+        <div v-if="selectData['isShowGatesContrl']" class="button-box" @click="playAnimation(5)">同时打开</div>
+        <div v-if="selectData['isShowGatesContrl']" class="button-box" @click="playAnimation(6)">同时关闭</div>
         <div v-if="hasPermission('btn:controlWindow')" class="button-box" @click="playAnimation(10)">A窗控制</div>
         <div v-if="hasPermission('btn:controlWindow')" class="button-box" @click="playAnimation(11)">B窗控制</div>
       </div>