Преглед изворни кода

Merge branch 'master' of http://182.92.126.35:3000/hrx/mky-vent-base

lxh пре 3 месеци
родитељ
комит
d50e8767d8

+ 1 - 1
src/views/vent/home/billboard/billboard.data.ts

@@ -400,7 +400,7 @@ export const VENTILATION_STATUS_TREE_CONFIG = {
       suffix: '(Pa)',
     },
     {
-      prefix: '风机漏风率:',
+      prefix: '外部漏风率:',
       prop: 'leakage',
       suffix: '%',
     },

+ 4 - 4
src/views/vent/home/billboard/index.vue

@@ -94,7 +94,7 @@
           BaseCard,
           {
             title: el.orgname || '/',
-            onOpen: () => openHandler(el.ip, el.orgcode),
+            onOpen: () => openHandler(el.ip, el.orgname),
           },
           {
             default: () =>
@@ -114,7 +114,7 @@
             BaseCard,
             {
               title: el.orgname || '/',
-              onOpen: () => openHandler(el.ip, el.orgcode),
+              onOpen: () => openHandler(el.ip, el.orgname),
             },
             {
               default: () =>
@@ -158,10 +158,10 @@
   };
 
   // 页面跳转
-  function openHandler(ip: string, orgcode) {
+  function openHandler(ip: string, orgname: string) {
     // const url = `http://localhost:3100/login`;
     if (props.billboardType == 'Warning') {
-      const newPage = router.resolve({ path: '/monitorChannel/device-monitor/warningHistory', query: { orgcode } });
+      const newPage = router.resolve({ path: '/monitorChannel/device-monitor/warningHistory/home', query: { orgname } });
       window.open(newPage.href, '_blank');
     } else {
       const url = `http://${ip}:8092${routePathMap[props.billboardType]}`;

+ 5 - 5
src/views/vent/home/clique/components/risk-warn.vue

@@ -60,7 +60,7 @@
                 <span class="value" :class="`value${centerData.fire}`">{{ parseLevel(centerData.fire) }}</span>
               </div>
             </div>
-            <div class="item item2">
+            <!-- <div class="item item2">
               <div class="icon-box">
                 <div class="icon"></div>
               </div>
@@ -68,7 +68,7 @@
                 <span class="title">设备监测</span>
                 <span class="value" :class="`value${centerData.sb}`">{{ parseLevel(centerData.sb) }}</span>
               </div>
-            </div>
+            </div> -->
             <div class="item item3">
               <div class="icon-box">
                 <div class="icon"></div>
@@ -624,7 +624,7 @@
 
             .item1 {
               top: 85px;
-              left: 100px;
+              left: 15px;
 
               .icon {
                 background-image: url('/@/assets/images/vent/alarm/icon-fire.svg');
@@ -643,8 +643,8 @@
             }
 
             .item3 {
-              top: 68px;
-              left: 247px;
+              top: 85px;
+              left: 182px;
 
               .icon {
                 background-image: url('/@/assets/images/vent/alarm/icon-gas.svg');

+ 1 - 1
src/views/vent/home/clique/dustComponents/dialog-modal.vue

@@ -96,7 +96,7 @@
 
   let windLfList = reactive([
     { label: '有效风量率', value: '0' },
-    { label: '矿井漏风率', value: '0' },
+    { label: '外部漏风率', value: '0' },
   ]);
 
   // 选取各项数据是引用的索引,有些矿井存在多个关键阻力路线等,需要轮播

+ 250 - 250
src/views/vent/home/clique/index.vue

@@ -51,304 +51,304 @@
   </div>
 </template>
 <script lang="ts" setup>
-import { ref, reactive, nextTick, onMounted, onUnmounted } from 'vue';
-import mineWind from './components/mine-wind.vue';
-import riskWarn from './components/risk-warn.vue';
-// import fileShare from './components/file-share.vue';
-import BillboardEntry from './components/billboard-entry.vue';
-import windRoad from './components/wind-road-middle.vue';
-import sceneKey from './components/scene-key.vue';
-import iconLight from './components/icon-light.vue';
-import dialogModal from './components/dialog-modal.vue';
-import { getHomeData, getList } from './clique.api';
-const dialogModalRef = ref();
-let mainTitle = ref('国能神东一通三防管控平台');
-// let mainTitle = ref('国家能源神东煤炭集团');
-// let mainTitle = ref('XXXX集团');
-const isShowDialog = ref(false);
-const dialogTitle = ref('');
+  import { ref, reactive, nextTick, onMounted, onUnmounted } from 'vue';
+  import mineWind from './components/mine-wind.vue';
+  import riskWarn from './components/risk-warn.vue';
+  // import fileShare from './components/file-share.vue';
+  import BillboardEntry from './components/billboard-entry.vue';
+  import windRoad from './components/wind-road-middle.vue';
+  import sceneKey from './components/scene-key.vue';
+  import iconLight from './components/icon-light.vue';
+  import dialogModal from './components/dialog-modal.vue';
+  import { getHomeData, getList } from './clique.api';
+  const dialogModalRef = ref();
+  let mainTitle = ref('国能神东一通三防管控平台');
+  // let mainTitle = ref('国家能源神东煤炭集团');
+  // let mainTitle = ref('XXXX集团');
+  const isShowDialog = ref(false);
+  const dialogTitle = ref('');
 
-//矿井通风状态数据
-let airKjStatus = reactive<any[]>([]);
+  //矿井通风状态数据
+  let airKjStatus = reactive<any[]>([]);
 
-//风险分析与预警数据
-let earlyWarn = ref<any[]>([]);
+  //风险分析与预警数据
+  let earlyWarn = ref<any[]>([]);
 
-//通防综合监测数据
-let compositeData = ref<any[]>([]);
+  //通防综合监测数据
+  let compositeData = ref<any[]>([]);
 
-//地图区域详情数据
-let centerDetail = ref({});
+  //地图区域详情数据
+  let centerDetail = ref({});
 
-//文件共享中心数据
-let shareData = reactive<any[]>([]);
+  //文件共享中心数据
+  let shareData = reactive<any[]>([]);
 
-let warningList = ref([]);
+  let warningList = ref([]);
 
-//通风巷道长度统计数据
-let roadData = reactive({
-  totallength: 0,
-  data: [],
-  data1: [],
-});
+  //通风巷道长度统计数据
+  let roadData = reactive({
+    totallength: 0,
+    data: [],
+    data1: [],
+  });
 
-let orgcode = ref('');
+  let orgcode = ref('');
 
-// https获取监测数据
-let timer: null | NodeJS.Timeout = null;
-function getMonitor() {
-  timer = setTimeout(async () => {
-    await getHomeDataList();
-    await getLists();
-    if (timer) {
-      timer = null;
-    }
-    getMonitor();
-  }, 10000);
-}
+  // https获取监测数据
+  let timer: null | NodeJS.Timeout = null;
+  function getMonitor() {
+    timer = setTimeout(async () => {
+      await getHomeDataList();
+      await getLists();
+      if (timer) {
+        timer = null;
+      }
+      getMonitor();
+    }, 10000);
+  }
 
-//获取公司端首页数据
-async function getHomeDataList() {
-  let res = await getHomeData();
-  if (res && res.length > 0) {
-    earlyWarn.value = res;
-    roadData.totallength = res.reduce((len, r) => {
-      return r.sys_data ? len + r.sys_data.totallength : len;
-    }, 0);
-    roadData.data.length = 0;
-    roadData.data1.length = 0;
-    airKjStatus.length = 0;
-    const warningListTemp: { orgcode: string; isWarning: boolean }[] = [];
-    res.forEach((el) => {
-      airKjStatus.push({
-        deviceName: el.sys_data.deviceName,
-        jf: el.sys_data.zongjinfeng,
-        xf: el.sys_data.xufengliang,
-        hf: el.sys_data.zonghuifeng,
-        isWarning: el.sys_data.zongjinfeng < el.sys_data.xufengliang,
-      });
+  //获取公司端首页数据
+  async function getHomeDataList() {
+    let res = await getHomeData();
+    if (res && res.length > 0) {
+      earlyWarn.value = res;
+      roadData.totallength = res.reduce((len, r) => {
+        return r.sys_data ? len + r.sys_data.totallength : len;
+      }, 0);
+      roadData.data.length = 0;
+      roadData.data1.length = 0;
+      airKjStatus.length = 0;
+      const warningListTemp: { orgcode: string; isWarning: boolean }[] = [];
+      res.forEach((el) => {
+        airKjStatus.push({
+          deviceName: el.sys_data.deviceName,
+          jf: el.sys_data.zongjinfeng,
+          xf: el.sys_data.xufengliang,
+          hf: el.sys_data.zonghuifeng,
+          isWarning: el.sys_data.zongjinfeng < el.sys_data.xufengliang,
+        });
 
-      //临时添加,前端判断,后期后端加上预警再处理
-      if (el.sys_data.zongjinfeng < el.sys_data.xufengliang) {
-        warningListTemp.push({ orgcode: el.orgcode, isWarning: true });
-      } else {
-        warningListTemp.push({ orgcode: el.orgcode, isWarning: false });
-      }
+        //临时添加,前端判断,后期后端加上预警再处理
+        if (el.sys_data.zongjinfeng < el.sys_data.xufengliang) {
+          warningListTemp.push({ orgcode: el.orgcode, isWarning: true });
+        } else {
+          warningListTemp.push({ orgcode: el.orgcode, isWarning: false });
+        }
 
-      roadData.data.push(el.sys_data.flength);
-      // roadData.data.push(el.sys_data.totallength);
-      roadData.data1.push(el.sys_data.deviceName);
-    });
-    warningList.value = warningListTemp;
-    compositeData.value = res.reduce((arr, e) => {
-      return [...arr, ...e.majorpath_data];
-    }, []);
-    centerDetail.value = res.filter((v) => v.orgcode == orgcode.value)[0];
+        roadData.data.push(el.sys_data.flength);
+        // roadData.data.push(el.sys_data.totallength);
+        roadData.data1.push(el.sys_data.deviceName);
+      });
+      warningList.value = warningListTemp;
+      compositeData.value = res.reduce((arr, e) => {
+        return [...arr, ...e.majorpath_data];
+      }, []);
+      centerDetail.value = res.filter((v) => v.orgcode == orgcode.value)[0];
+    }
+  }
+  //获取文件共享中心数据
+  async function getLists() {
+    let res = await getList();
+    if (res.length != 0) {
+      shareData.length = 0;
+      res.forEach((el) => {
+        shareData.push({ title: el.sysOrgName, value: el.tolalNum, value1: el.approveNum });
+      });
+    }
   }
-}
-//获取文件共享中心数据
-async function getLists() {
-  let res = await getList();
-  if (res.length != 0) {
-    shareData.length = 0;
-    res.forEach((el) => {
-      shareData.push({ title: el.sysOrgName, value: el.tolalNum, value1: el.approveNum });
+
+  function showDetail(code, label, leftV, topV) {
+    if (code) {
+      orgcode.value = code;
+      dialogTitle.value = label;
+      isShowDialog.value = true;
+      getHomeDataList();
+    }
+    nextTick(() => {
+      const tooltipDom = document.getElementById('detailModal') as HTMLElement;
+      tooltipDom.style.left = leftV;
+      tooltipDom.style.top = topV;
     });
   }
-}
+  function closeDialog() {
+    isShowDialog.value = false;
+  }
 
-function showDetail(code, label, leftV, topV) {
-  if (code) {
-    orgcode.value = code;
-    dialogTitle.value = label;
-    isShowDialog.value = true;
+  onMounted(() => {
     getHomeDataList();
-  }
-  nextTick(() => {
-    const tooltipDom = document.getElementById('detailModal') as HTMLElement;
-    tooltipDom.style.left = leftV;
-    tooltipDom.style.top = topV;
+    getLists();
+    getMonitor();
+  });
+  onUnmounted(() => {
+    if (timer) {
+      clearTimeout(timer);
+      timer = null;
+    }
   });
-}
-function closeDialog() {
-  isShowDialog.value = false;
-}
-
-onMounted(() => {
-  getHomeDataList();
-  getLists();
-  getMonitor();
-});
-onUnmounted(() => {
-  if (timer) {
-    clearTimeout(timer);
-    timer = null;
-  }
-});
 </script>
 <style lang="less" scoped>
-@font-face {
-  font-family: 'douyuFont';
-  src: url('../../../../assets/font/douyuFont.otf');
-}
-
-// @font-face {
-//   font-family: 'yjsz';
-//   src: url('../../../../assets/font/yjsz.TTF');
-// }
-.company-home {
-  width: 100%;
-  height: 100%;
-  position: relative;
-  background: url('../../../../assets/images/company/home-pageBg.png') no-repeat center;
-  background-size: 100% 100%;
-
-  .top-bg {
-    width: 100%;
-    height: 97px;
-    background: url('../../../../assets/images/company/top-bg.png') no-repeat center;
-    position: absolute;
-    z-index: 1;
-
-    .main-title {
-      height: 96px;
-      color: #fff;
-      font-family: 'douyuFont';
-      font-size: 20px;
-      letter-spacing: 2px;
-      display: flex;
-      justify-content: center;
-      align-items: center;
-    }
+  @font-face {
+    font-family: 'douyuFont';
+    src: url('../../../../assets/font/douyuFont.otf');
   }
 
-  .company-content {
-    position: absolute;
-    left: 0;
-    top: 0;
+  // @font-face {
+  //   font-family: 'yjsz';
+  //   src: url('../../../../assets/font/yjsz.TTF');
+  // }
+  .company-home {
     width: 100%;
     height: 100%;
-    background: url('../../../../assets/images/company/content-bg.png') no-repeat;
+    position: relative;
+    background: url('../../../../assets/images/company/home-pageBg.png') no-repeat center;
     background-size: 100% 100%;
 
-    .area-content {
+    .top-bg {
+      width: 100%;
+      height: 97px;
+      background: url('../../../../assets/images/company/top-bg.png') no-repeat center;
       position: absolute;
-      top: 45px;
+      z-index: 1;
+
+      .main-title {
+        height: 96px;
+        color: #fff;
+        font-family: 'douyuFont';
+        font-size: 20px;
+        letter-spacing: 2px;
+        display: flex;
+        justify-content: center;
+        align-items: center;
+      }
+    }
+
+    .company-content {
+      position: absolute;
+      left: 0;
+      top: 0;
       width: 100%;
-      height: calc(100% - 45px);
-      padding: 0px 20px 20px 20px;
-      box-sizing: border-box;
-      display: flex;
-      justify-content: space-between;
+      height: 100%;
+      background: url('../../../../assets/images/company/content-bg.png') no-repeat;
+      background-size: 100% 100%;
 
-      .left-area {
-        width: 23%;
-        height: 100%;
-        margin-right: 15px;
+      .area-content {
+        position: absolute;
+        top: 45px;
+        width: 100%;
+        height: calc(100% - 45px);
+        padding: 0px 20px 20px 20px;
+        box-sizing: border-box;
         display: flex;
-        flex-direction: column;
         justify-content: space-between;
-        align-items: center;
-        position: relative;
-        z-index: 1;
 
-        .area-card {
-          width: 100%;
-          height: calc(60% - 15px);
-          margin-bottom: 15px;
-          background: url('../../../../assets/images/company/area-card.png') no-repeat;
-          background-size: 100% 100%;
-        }
+        .left-area {
+          width: 23%;
+          height: 100%;
+          margin-right: 15px;
+          display: flex;
+          flex-direction: column;
+          justify-content: space-between;
+          align-items: center;
+          position: relative;
+          z-index: 1;
 
-        .area-card1 {
-          width: 100%;
-          height: 40%;
-          background: url('../../../../assets/images/company/area-card1.png') no-repeat;
-          background-size: 100% 100%;
-        }
-      }
+          .area-card {
+            width: 100%;
+            height: calc(60% - 15px);
+            margin-bottom: 15px;
+            background: url('../../../../assets/images/company/area-card.png') no-repeat;
+            background-size: 100% 100%;
+          }
 
-      .center-area {
-        width: 1000px;
-        height: 100%;
-        position: relative;
-        z-index: 0;
+          .area-card1 {
+            width: 100%;
+            height: 40%;
+            background: url('../../../../assets/images/company/area-card1.png') no-repeat;
+            background-size: 100% 100%;
+          }
+        }
 
-        .center-bg {
-          position: absolute;
-          bottom: 240px;
-          left: 50%;
-          transform: translate(-50%, 0);
-          width: 1128px;
-          height: 630px;
-          background: url('../../../../assets/images/company/home-dz.png') no-repeat center;
-          background-size: contain;
-          background-position: 50% 50px;
+        .center-area {
+          width: 1000px;
+          height: 100%;
+          position: relative;
           z-index: 0;
 
-          .bg-map {
-            width: 1086px;
-            height: 610px;
-            left: 30px;
-            top: 60px;
-            background: url('../../../../assets/images/company/home-map.png') no-repeat center;
+          .center-bg {
+            position: absolute;
+            bottom: 240px;
+            left: 50%;
+            transform: translate(-50%, 0);
+            width: 1128px;
+            height: 630px;
+            background: url('../../../../assets/images/company/home-dz.png') no-repeat center;
             background-size: contain;
-            // background-position: 0px 70px;
-            position: relative;
+            background-position: 50% 50px;
             z-index: 0;
+
+            .bg-map {
+              width: 1086px;
+              height: 610px;
+              left: 30px;
+              top: 60px;
+              background: url('../../../../assets/images/company/home-map.png') no-repeat center;
+              background-size: contain;
+              // background-position: 0px 70px;
+              position: relative;
+              z-index: 0;
+            }
           }
-        }
 
-        .area-card2 {
-          position: absolute;
-          right: 0;
-          top: 62px;
-          width: 568px;
-          height: 437px;
-          background: url('../../../../assets/images/company/area-card2.png') no-repeat;
-          background-size: 100% 100%;
-          // pointer-events: auto;
-        }
+          .area-card2 {
+            position: absolute;
+            right: 0;
+            top: 62px;
+            width: 568px;
+            height: 437px;
+            background: url('../../../../assets/images/company/area-card2.png') no-repeat;
+            background-size: 100% 100%;
+            // pointer-events: auto;
+          }
 
-        .area-card3 {
-          position: absolute;
-          right: 0;
-          bottom: 0px;
-          width: 100%;
-          height: 269px;
-          background: url('../../../../assets/images/company/area-card3.png') no-repeat;
-          background-size: 100% 100%;
+          .area-card3 {
+            position: absolute;
+            right: 0;
+            bottom: 0px;
+            width: 100%;
+            height: 269px;
+            background: url('../../../../assets/images/company/area-card3.png') no-repeat;
+            background-size: 100% 100%;
+          }
         }
-      }
 
-      .right-area {
-        width: 23%;
-        height: 100%;
-        margin-left: 15px;
-        display: flex;
-        flex-direction: column;
-        justify-content: space-between;
-        align-items: center;
-        position: relative;
-        z-index: 1;
+        .right-area {
+          width: 23%;
+          height: 100%;
+          margin-left: 15px;
+          display: flex;
+          flex-direction: column;
+          justify-content: space-between;
+          align-items: center;
+          position: relative;
+          z-index: 1;
 
-        // pointer-events: auto;
-        .area-card {
-          width: 100%;
-          height: calc(60% - 15px);
-          margin-bottom: 15px;
-          background: url('../../../../assets/images/company/area-card.png') no-repeat;
-          background-size: 100% 100%;
-        }
+          // pointer-events: auto;
+          .area-card {
+            width: 100%;
+            height: calc(60% - 15px);
+            margin-bottom: 15px;
+            background: url('../../../../assets/images/company/area-card.png') no-repeat;
+            background-size: 100% 100%;
+          }
 
-        .area-card1 {
-          width: 100%;
-          height: 40%;
-          background: url('../../../../assets/images/company/area-card1.png') no-repeat;
-          background-size: 100% 100%;
+          .area-card1 {
+            width: 100%;
+            height: 40%;
+            background: url('../../../../assets/images/company/area-card1.png') no-repeat;
+            background-size: 100% 100%;
+          }
         }
       }
     }
   }
-}
 </style>

+ 6 - 6
src/views/vent/monitorManager/alarmMonitor/common.data.ts

@@ -31,11 +31,11 @@ export function getMonitorComponent() {
   const { sysOrgCode } = useGlobSetting();
   let typeMenuListGas;
   switch (sysOrgCode) {
-    case 'sdmtjtdltmk': //大柳塔
-      typeMenuListGas = [{ name: '预警监测' }, { name: '预警指标' },];
+    case 'sdmtjtbetmk': //布尔台
+      typeMenuListGas = [{ name: '预警监测' }, { name: '预警指标' }, { name: '瓦斯参数' }];
       return typeMenuListGas;
     default:
-      typeMenuListGas = [{ name: '预警监测' }, { name: '预警指标' }, { name: '瓦斯参数' },];
+      typeMenuListGas = [{ name: '预警监测' }, { name: '预警指标' }];
       return typeMenuListGas;
   }
 }
@@ -255,7 +255,7 @@ export const columns = [
     },
   },
   { rowIndex: 1, dataIndex: 'strinstallpos', title: '名称', type: '1', align: 'center' },
-  { rowIndex: 2, dataIndex: 'warnLevel_str',width:80, title: '状态', type: '1', align: 'center' },
+  { rowIndex: 2, dataIndex: 'warnLevel_str', width: 80, title: '状态', type: '1', align: 'center' },
   { rowIndex: 3, dataIndex: 'readTime', title: '时间', type: '1', align: 'center' },
 ];
 //外因火灾-烟雾传感器table列
@@ -271,7 +271,7 @@ export const columnsSmoke = [
     },
   },
   { rowIndex: 1, dataIndex: 'strinstallpos', title: '名称', type: '1', align: 'center' },
-  { rowIndex: 2, dataIndex: 'val', width:80, title: '值', type: '1', align: 'center' },
-  { rowIndex: 3, dataIndex: 'warnLevel_str', width:80,title: '状态', type: '1', align: 'center' },
+  { rowIndex: 2, dataIndex: 'val', width: 80, title: '值', type: '1', align: 'center' },
+  { rowIndex: 3, dataIndex: 'warnLevel_str', width: 80, title: '状态', type: '1', align: 'center' },
   { rowIndex: 4, dataIndex: 'readTime', title: '时间', type: '1', align: 'center' },
 ];

+ 61 - 65
src/views/vent/monitorManager/alarmMonitor/common/gasParamter.vue

@@ -1,99 +1,95 @@
 <template>
-    <div class="gasParamter">
-        <a-table :columns="columns" :data-source="tableData" :pagination="false" :scroll="{ y: 700 }" class="tableW">
-            <template #bodyCell="{ column, text }">
-                <!-- <template v-if="column.dataIndex === 'name'">
+  <div class="gasParamter">
+    <a-table :columns="columns" :data-source="tableData" :pagination="false" :scroll="{ y: 700 }" class="tableW">
+      <template #bodyCell="{ column, text }">
+        <!-- <template v-if="column.dataIndex === 'name'">
                     <a href="javascript:;">{{ text }}</a>
                 </template> -->
-            </template>
-        </a-table>
-        <!-- <div class="description">
+      </template>
+    </a-table>
+    <!-- <div class="description">
             ZWY300/355 : Z-泵站,W-瓦斯抽放,Y-移动式,270/300-流量(m³/min),355-功率(KW),抽放混合量160~230m³/min,抽放瓦斯浓度0.5~1.2%,抽放瓦斯量0.8~3m³/min。
         </div> -->
-    </div>
+  </div>
 </template>
 
 <script setup lang="ts">
-import { ref, reactive } from 'vue'
-let tableData = ref<any[]>([
+  import { ref, reactive } from 'vue';
+  let tableData = ref<any[]>([
     { name: '相对瓦斯涌出量', value: '8.18m³/t', address: '1475移动式瓦斯抽采泵站', work: '16219-1综放工作面', code: '2Be1-405' },
     { name: '综采最大涌出量', value: '2.51m³/min', address: '六采区进风大巷移动式瓦斯抽采泵站', work: '16120油页岩工作面', code: 'ZWY120/160G' },
     { name: '掘进最大涌出量', value: '0.59m³/min', address: '', work: '', code: '' },
-])
+  ]);
 
-let columns = reactive([
+  let columns = reactive([
     {
-        title: '瓦斯参数',
-        children: [
+      title: '瓦斯参数',
+      children: [
+        {
+          title: '瓦斯等级鉴定',
+          children: [
             {
-                title: '瓦斯等级鉴定',
-                children: [
-                    {
-                        title: '绝对瓦斯涌出量',
-                        dataIndex: 'name',
-                        key: 'name',
-                        align: 'center',
-                    },
-                    {
-                        title: '20.65m³/min',
-                        dataIndex: 'value',
-                        key: 'value',
-                        align: 'center'
-                    },
-                ]
+              title: '绝对瓦斯涌出量',
+              dataIndex: 'name',
+              key: 'name',
+              align: 'center',
             },
             {
-                title: '瓦斯抽放',
-                children: [
-                    {
-                        title: '抽放泵站地点',
-                        dataIndex: 'address',
-                        key: 'address',
-
-                        align: 'center'
-                    },
-                    {
-                        title: '抽放工作面',
-                        dataIndex: 'work',
-                        key: 'work',
-
-                        align: 'center'
-                    },
-                    {
-                        title: '设备型号',
-                        dataIndex: 'code',
-                        key: 'code',
+              title: '20.65m³/min',
+              dataIndex: 'value',
+              key: 'value',
+              align: 'center',
+            },
+          ],
+        },
+        {
+          title: '瓦斯抽放',
+          children: [
+            {
+              title: '抽放泵站地点',
+              dataIndex: 'address',
+              key: 'address',
 
-                        align: 'center'
-                    },
-                ]
+              align: 'center',
             },
+            {
+              title: '抽放工作面',
+              dataIndex: 'work',
+              key: 'work',
 
+              align: 'center',
+            },
+            {
+              title: '设备型号',
+              dataIndex: 'code',
+              key: 'code',
 
-        ],
+              align: 'center',
+            },
+          ],
+        },
+      ],
     },
-
-])
-
+  ]);
 </script>
 
 <style lang="less" scoped>
-.gasParamter {
+  .gasParamter {
     width: 100%;
     height: 100%;
     padding: 20px;
     box-sizing: border-box;
 
     .tableW {
-        width: 100% !important;
+      width: 100% !important;
     }
-    .description{
-        margin: 10px;
-        color: #fff;
+    .description {
+      margin: 10px;
+      color: #fff;
     }
-}
+  }
 
-:deep(.zxm-table-thead > tr > th:last-child) {
+  :deep(.zxm-table-thead > tr > th:last-child) {
     border-right: 1px solid #91e9fe !important;
-}
-</style>
+  }
+</style>

Разлика између датотеке није приказан због своје велике величине
+ 550 - 532
src/views/vent/monitorManager/alarmMonitor/warn/gasWarn.vue


+ 45 - 47
src/views/vent/monitorManager/mainFanMonitor/components/conditionAssistance.vue

@@ -36,8 +36,8 @@
         <a-spin :spinning="loadding" tip="正在计算,请稍等。。。">
           <div ref="chartRef" class="info-echarts" style="width: 450px; height: 375px"></div>
           <div v-if="resultObj" class="result-tip">
-            工况点为
-            <span style="color: #9a60b4; padding: 0 10px; font-weight: 600">{{ parseInt(resultObj.Hz) }}Hz</span>
+            最佳工况点为
+            <span style="color: #9a60b4; padding: 0 10px; font-weight: 600">{{ parseInt(resultObj.Hz) }}°</span>
             <span style="color: #c60000; padding: 0 10px; font-weight: 600">{{ formatNum(resultObj.x) }} m³/s</span>
             <span style="color: #c60000; padding: 0 10px; font-weight: 600">{{ formatNum(resultObj.y) }} Pa</span></div
           >
@@ -56,11 +56,11 @@
       </div>
     </div>
     <div class="setting-box">
-      <div class="left-buttons">
-        <!-- <div class="btn btn1" @click="edit('info')">编辑风机信息</div> -->
-        <!-- <div class="btn btn1" @click="edit('line')">编辑特性曲线</div> -->
-        风机当前角度:<span>{{ selectData.bladeAngle }} &nbsp;°</span>
-      </div>
+      <!-- <div class="left-buttons"> -->
+      <!-- <div class="btn btn1" @click="edit('info')">编辑风机信息</div> -->
+      <!-- <div class="btn btn1" @click="edit('line')">编辑特性曲线</div> -->
+      <!-- 风机当前角度:<span>{{ selectData.bladeAngle }} &nbsp;°</span> -->
+      <!-- </div> -->
       <!-- <div class="border-clip"></div> -->
       <div class="right-inputs">
         <div class="vent-flex-row">
@@ -83,7 +83,7 @@
   //ts语法
   import { ref, onMounted, reactive, nextTick, defineProps, defineEmits, watch } from 'vue';
   import echarts from '/@/utils/lib/echarts';
-  import { option, initData, fanInfoData, fanInfo, getSchamas, getSchamas1, lineFormData } from '../main.data.ts';
+  import { setOption, initData, fanInfoData, fanInfo, getSchamas, getSchamas1, lineFormData } from '../main.data.ts';
   import { BasicModal, useModalInner } from '/@/components/Modal';
   import { BasicForm, useForm } from '/@/components/Form/index';
   import { Input } from 'ant-design-vue';
@@ -101,6 +101,10 @@
       type: Object,
       default: () => {},
     },
+    m3: {
+      type: Number,
+      default: 670.8,
+    },
   });
   const emit = defineEmits(['close', 'register', 'openModal']);
   type AssistanceItemType = {
@@ -114,10 +118,12 @@
   };
   const columns = ref([]);
   const isMock = true;
+  let option = reactive({});
   // 注册 modal
   const [register, { closeModal }] = useModalInner(() => {
     nextTick(() => {
       computeAssistance();
+      option = setOption(props.deviceType);
       if (option['xAxis']) option['xAxis']['data'] = xData;
       option['series'] = yDataList;
       initEcharts();
@@ -160,7 +166,7 @@
   });
 
   function computeAssistance() {
-    const assistanceData = initData();
+    const assistanceData = initData(props.deviceType);
     lineNum = 0;
     const assistanceDataList = [];
     const lineEquationList: string[] = [];
@@ -175,22 +181,29 @@
     }
     lineEquation.value = lineEquationList;
     lineNum = assistanceDataList.length;
-    const xDataMin =
-      Math.min.apply(
+    // const xDataMin =
+    //   Math.min.apply(
+    //     Math,
+    //     assistanceDataList.map((item) => {
+    //       return item.min;
+    //     })
+    //   ) - 10;
+    let xDataMin = Math.min.apply(
+      Math,
+      assistanceDataList.map((item) => {
+        return item.min;
+      })
+    );
+    xDataMin = Number((xDataMin - xDataMin / 10).toFixed(0));
+    let xDataMax =
+      Math.max.apply(
         Math,
         assistanceDataList.map((item) => {
-          return item.min;
+          return item.max;
         })
-      ) - 10;
-    // const xDataMax = Math.max.apply(Math, assistanceDataList.map(item => { return item.max }))
-    let xDataMax;
-    if (sysOrgCode == 'sdmtjtdltmk') {
-      // 大柳塔井特殊处理
-      xDataMax = 260;
-    } else {
-      xDataMax = 230;
-      // xDataMax = 260;
-    }
+      ) + 10;
+    xDataMax = Number(xDataMax.toFixed(0));
+
     fanInfoData.flfw = `${xDataMin}~${xDataMax}`;
     const computeItem = (item: AssistanceItemType) => {
       const min = item.min;
@@ -212,7 +225,7 @@
       const element: AssistanceItemType = assistanceData[key];
       const yData: number[] = computeItem(element);
       const series = {
-        name: `${element['Hz']}Hz`,
+        name: `${element['Hz']}°`,
         type: 'line',
         smooth: true,
         showSymbol: false,
@@ -285,25 +298,6 @@
 
   function reSetLine() {
     let minIndex = -1;
-    // for (let i = 0; i < yDataList.length; i++) {
-    //   if (i !== lineNum && i != lineNum + 1) {
-    //     if (yDataList[i]['lineStyle']) yDataList[i]['lineStyle']['color'] = '#ffffff88';
-    //     if (yDataList[i]['lineStyle']) yDataList[i]['lineStyle']['width'] = 1;
-    //     if (yDataList[i]['endLabel'] && yDataList[i]['endLabel']['color']) yDataList[i]['endLabel']['color'] = '#39E9FE99';
-    //     if (yDataList[i]['endLabel'] && yDataList[i]['endLabel']['backgroundColor']) yDataList[i]['endLabel']['backgroundColor'] = 'transparent';
-    //     if (yDataList[i]['z']) yDataList[i]['z'] = 1;
-    //   }
-    //   if (`${resultObj.value.Hz}Hz` == yDataList[i]['name']) {
-    //     minIndex = i;
-    //   }
-    // }
-    // if (minIndex != -1) {
-    //   yDataList[minIndex]['lineStyle']['color'] = '#9A60B4';
-    //   yDataList[minIndex]['lineStyle']['width'] = 2;
-    //   yDataList[minIndex]['endLabel']['color'] = '#9A60B4';
-    //   yDataList[minIndex]['endLabel']['backgroundColor'] = '#111';
-    //   yDataList[minIndex]['z'] = 999;
-    // }
     for (let i = 0; i < yDataList.length; i++) {
       if (i !== lineNum && i != lineNum + 1) {
         if (yDataList[i]['lineStyle']) yDataList[i]['lineStyle']['color'] = '#ffffff88';
@@ -315,7 +309,7 @@
         if (yDataList[i]['z']) yDataList[i]['z'] = 1;
       }
 
-      if (resultObj.value && `${resultObj.value.Hz}Hz` == yDataList[i]['name']) {
+      if (resultObj.value && `${resultObj.value.Hz}°` == yDataList[i]['name']) {
         minIndex = i;
       }
     }
@@ -338,7 +332,7 @@
       y: number;
       Hz: number;
     };
-    const assistanceData = initData();
+    const assistanceData = initData(props.deviceType);
     const paList = new Map<number, ItemType>(); // key 是最近距离
     const getIntersectionPoint = (a, b, c, R, min, max) => {
       const obj: { x: undefined | number; y: undefined | number } = { x: undefined, y: undefined };
@@ -584,6 +578,10 @@
           color: #f1f1f1cc;
         }
       }
+      .info-item {
+        padding: 8px 0px;
+        margin: 4px 0;
+      }
     }
     .center-box {
       margin: 0 10px;
@@ -609,7 +607,7 @@
     border: 1px solid #00d8ff22;
     display: flex;
     align-items: center;
-    justify-content: space-between;
+    justify-content: center;
 
     .right-inputs {
       display: flex;
@@ -633,10 +631,10 @@
       border-right: 1px solid #8b8b8b77;
     }
     .input-title {
-      width: 80px;
+      width: 120px;
     }
     .input-box {
-      width: 200px !important;
+      width: 300px !important;
       background: transparent !important;
       border-color: #00d8ff44 !important;
       margin-right: 20px;

+ 261 - 91
src/views/vent/monitorManager/mainFanMonitor/main.data.ts

@@ -4,6 +4,7 @@ import { rules } from '/@/utils/helper/validator';
 import { reactive } from 'vue';
 import type { EChartsOption } from 'echarts';
 import { useGlobSetting } from '/@/hooks/setting';
+import { cloneDeep } from 'lodash-es';
 
 type CtrlLockOpenType = {
   CtrlLockOpen: boolean | undefined;
@@ -809,78 +810,163 @@ export const assistanceData = {
   },
 };
 
-export const option = reactive<EChartsOption>({
-  title: {
-    text: '风机运行工况辅助曲线图',
-    textStyle: {
-      color: '#BF954D',
-    },
-    left: 'center',
-    top: 0,
-  },
-  // backgroundColor: '#39deff',
-  tooltip: {
-    trigger: 'axis',
-    axisPointer: {
-      type: 'cross',
-      label: {
-        backgroundColor: '#6a7985',
+export const setOption = (deviceType?) => {
+  debugger;
+  let yMax = 4500;
+  const { sysOrgCode } = useGlobSetting();
+  // const sysOrgCode = 'sdmtjtdltmk';
+  if (sysOrgCode == 'sdmtjtdltmk') {
+    // 这里判断白家渠还是五当沟
+    if (deviceType == 'fanmain_bjq') {
+      yMax = 5500;
+    } else if (deviceType == 'fanmain_wdg') {
+      yMax = 1200;
+    }
+  } else {
+    yMax = 4500;
+  }
+  return reactive<EChartsOption>({
+    title: {
+      text: '风机运行工况辅助曲线图',
+      textStyle: {
+        color: '#BF954D',
       },
-    },
-  },
-  toolbox: {
-    show: true,
-  },
-  grid: {
-    left: 8,
-    right: 50,
-    bottom: 0,
-    containLabel: true,
-  },
-  xAxis: {
-    type: 'category',
-    name: 'm³/s',
-    nameTextStyle: {
-      fontWeight: 600,
-      fontSize: 13,
-    },
-    splitLine: { show: true, lineStyle: { color: 'rgba(21,80,126,.5)' } },
-    axisLabel: {
-      margin: 20,
-      fontSize: 14,
-      color: '#f1f1f199',
-    },
-    boundaryGap: false,
-    data: [],
-  },
-  yAxis: {
-    type: 'value',
-    axisLine: {
-      show: true,
-      lineStyle: {
-        color: '#006c9d',
+      left: 'center',
+      top: 0,
+    },
+    // backgroundColor: '#39deff',
+    tooltip: {
+      trigger: 'axis',
+      axisPointer: {
+        type: 'cross',
+        label: {
+          backgroundColor: '#6a7985',
+        },
       },
     },
-    splitLine: { show: true, lineStyle: { color: 'rgba(21,80,126,.5)' } },
-    axisLabel: {
+    toolbox: {
       show: true,
-      fontSize: 14,
-      formatter: '{value}',
-      color: '#0071A5',
     },
-    min: 0,
-    max: 4100,
-    name: 'Pa',
-    nameTextStyle: {
-      fontWeight: 600,
-      fontSize: 13,
+    grid: {
+      left: 8,
+      right: 50,
+      bottom: 0,
+      containLabel: true,
+    },
+    xAxis: {
+      type: 'category',
+      name: 'm³/s',
+      nameTextStyle: {
+        fontWeight: 600,
+        fontSize: 13,
+      },
+      splitLine: { show: true, lineStyle: { color: 'rgba(21,80,126,.5)' } },
+      axisLabel: {
+        margin: 20,
+        fontSize: 14,
+        color: '#f1f1f199',
+      },
+      boundaryGap: false,
+      data: [],
+    },
+    yAxis: {
+      type: 'value',
+      axisLine: {
+        show: true,
+        lineStyle: {
+          color: '#006c9d',
+        },
+      },
+      splitLine: { show: true, lineStyle: { color: 'rgba(21,80,126,.5)' } },
+      axisLabel: {
+        show: true,
+        fontSize: 14,
+        formatter: '{value}',
+        color: '#0071A5',
+      },
+      min: 0,
+      max: yMax, //武当沟
+      name: 'Pa',
+      nameTextStyle: {
+        fontWeight: 600,
+        fontSize: 13,
+      },
     },
-  },
-  series: [],
-});
+    series: [],
+  });
+};
+// export const option = reactive<EChartsOption>({
+//   title: {
+//     text: '风机运行工况辅助曲线图',
+//     textStyle: {
+//       color: '#BF954D',
+//     },
+//     left: 'center',
+//     top: 0,
+//   },
+//   // backgroundColor: '#39deff',
+//   tooltip: {
+//     trigger: 'axis',
+//     axisPointer: {
+//       type: 'cross',
+//       label: {
+//         backgroundColor: '#6a7985',
+//       },
+//     },
+//   },
+//   toolbox: {
+//     show: true,
+//   },
+//   grid: {
+//     left: 8,
+//     right: 50,
+//     bottom: 0,
+//     containLabel: true,
+//   },
+//   xAxis: {
+//     type: 'category',
+//     name: 'm³/s',
+//     nameTextStyle: {
+//       fontWeight: 600,
+//       fontSize: 13,
+//     },
+//     splitLine: { show: true, lineStyle: { color: 'rgba(21,80,126,.5)' } },
+//     axisLabel: {
+//       margin: 20,
+//       fontSize: 14,
+//       color: '#f1f1f199',
+//     },
+//     boundaryGap: false,
+//     data: [],
+//   },
+//   yAxis: {
+//     type: 'value',
+//     axisLine: {
+//       show: true,
+//       lineStyle: {
+//         color: '#006c9d',
+//       },
+//     },
+//     splitLine: { show: true, lineStyle: { color: 'rgba(21,80,126,.5)' } },
+//     axisLabel: {
+//       show: true,
+//       fontSize: 14,
+//       formatter: '{value}',
+//       color: '#0071A5',
+//     },
+//     min: 0,
+//     // max: 5500, //白家渠
+//     max: 1200, //武当沟
+//     name: 'Pa',
+//     nameTextStyle: {
+//       fontWeight: 600,
+//       fontSize: 13,
+//     },
+//   },
+//   series: [],
+// });
 
-export const initData = () => {
-  const { sysOrgCode } = useGlobSetting();
+export const initData1 = () => {
   const assistanceData = {
     '30': {
       angle: 0,
@@ -916,7 +1002,7 @@ export const initData = () => {
       b: 43.462342,
       c: 91.09167409999964,
       min: 102.3,
-      max: 182.2,
+      max: 180.2,
     },
     '34': {
       angle: 0,
@@ -925,7 +1011,7 @@ export const initData = () => {
       b: 43.479966000000005,
       c: 88.91811639999969,
       min: 105.4,
-      max: 184.0,
+      max: 182.0,
     },
     '35': {
       angle: 0,
@@ -934,7 +1020,7 @@ export const initData = () => {
       b: 43.49759,
       c: 86.74367749999965,
       min: 108.5,
-      max: 185.5,
+      max: 184.5,
     },
     '36': {
       angle: 0,
@@ -961,7 +1047,7 @@ export const initData = () => {
       b: 43.550462,
       c: 80.21507359999941,
       min: 117.8,
-      max: 192.0,
+      max: 193.0,
     },
     '39': {
       angle: 0,
@@ -970,7 +1056,7 @@ export const initData = () => {
       b: 43.568086,
       c: 78.0371098999999,
       min: 120.9,
-      max: 194.6,
+      max: 195.6,
     },
     '40': {
       angle: 0,
@@ -1042,7 +1128,7 @@ export const initData = () => {
       b: 43.709078,
       c: 60.58167709999998,
       min: 138.7,
-      max: 218.8,
+      max: 217.8,
     },
     '48': {
       angle: 0,
@@ -1051,7 +1137,7 @@ export const initData = () => {
       b: 43.726702,
       c: 58.39578259999962,
       min: 140.8,
-      max: 220.2,
+      max: 219.2,
     },
     '49': {
       angle: 0,
@@ -1060,7 +1146,7 @@ export const initData = () => {
       b: 43.744326,
       c: 56.20900689999962,
       min: 143.9,
-      max: 225.6,
+      max: 221.6,
     },
     '50': {
       angle: 0,
@@ -1069,12 +1155,12 @@ export const initData = () => {
       b: 43.76195,
       c: 54.021349999999984,
       min: 146.0,
-      max: 230.0,
+      max: 223.0,
     },
   };
   const num = 21;
-  const a = -0.17624, //-0.17624,
-    m = 2770.6411125432646,
+  const a = -0.17624; //-0.17624,
+  const m = 2770.6411125432646,
     n = -124.15442010894235;
   let i = 21;
   const data = [];
@@ -1082,27 +1168,111 @@ export const initData = () => {
     i -= 1;
     const p = i;
     const item = assistanceData[key];
-    if (sysOrgCode == 'sdmtjtdltmk') {
-      // 大柳塔井整体向右下移动
-      item['min'] = item['min'] + 20;
-      item['max'] = item['max'] + 20;
-      item['b'] = 2 * a * (n + p) + 3;
-      item['c'] = a * (n + p) * (n + p) + m - i * 60;
-    } else {
-      item['b'] = 2 * a * (n + p);
-      item['c'] = a * (n + p) * (n + p) + m - i * 50;
-      // item['min'] = item['min'] + 20;
-      // item['max'] = item['max'] + 20;
-      // item['b'] = 2 * a * (n + p) + 3;
-      // item['c'] = a * (n + p) * (n + p) + m - i * 60;
-    }
-
+    item['b'] = 2 * a * (n + p);
+    item['c'] = a * (n + p) * (n + p) + m - i * 50;
+    // if (sysOrgCode == 'sdmtjtdltmk') {
+    //   // 大柳塔井整体向右下移动
+    //   item['min'] = item['min'] + 20;
+    //   item['max'] = item['max'] + 20;
+    //   item['b'] = 2 * a * (n + p) + 3;
+    //   item['c'] = a * (n + p) * (n + p) + m - i * 60;
+    // } else {
+    //   item['b'] = 2 * a * (n + p);
+    //   item['c'] = a * (n + p) * (n + p) + m - i * 50;
+    //   // //白家渠
+    //   // a = -0.13424;
+    //   // item['a'] = Math.round((a + 0.002 * (num - i)) * 10000) / 10000;
+    //   // item['min'] = item['min'] + 50 + (num - i) * 2;
+    //   // item['max'] = item['max'] + 65 + (num - i) * 3.5;
+    //   // item['b'] = 2 * item['a'] * (n + p) + 8.8;
+    //   // item['c'] = item['a'] * (n + p) * (n + p) + m - i * 60;
+    //   // //武当沟
+    //   // a = -0.17724;
+    //   // item['a'] = Math.round((a - 0.002 * (num - i)) * 10000) / 10000;
+    //   // item['min'] = item['min'] - 40 - (num - i) * 1;
+    //   // item['max'] = item['max'] - 60 - (num - i) * 0.5;
+    //   // item['b'] = 2 * item['a'] * (n + p) - 16.5;
+    //   // item['c'] = item['a'] * (n + p) * (n + p) + m - i * 40;
+    // }
     data.push(item);
   }
   console.log(data);
   return data;
 };
 
+// 大柳塔武当沟
+export const initData = (deviceType?) => {
+  const { sysOrgCode } = useGlobSetting();
+  // const sysOrgCode = 'sdmtjtdltmk';
+  if (sysOrgCode == 'sdmtjtdltmk') {
+    // 这里判断白家渠还是五当沟
+    return initDataDlt(deviceType);
+  } else {
+    return initData1();
+  }
+};
+// 大柳塔白家渠
+export const initDataDlt = (deviceType?) => {
+  if (deviceType == 'fanmain_bjq') {
+    const num = 2;
+    const obj = {
+      angle: 0,
+      Hz: -0,
+      a: -0.0656,
+      b: 17.398283350755946,
+      c: 3241.38254718147,
+      min: 300,
+      max: 1100.0,
+    };
+    const a = -0.0656,
+      m = 17.398283350755946,
+      n = 3241.38254718147;
+
+    const maxList = [339.4, 359.4, 379.4, 399.4, 419.4];
+    const minList = [143, 152, 161, 170, 180];
+    const data = [];
+    for (let i = -2; i <= num; i++) {
+      const item = cloneDeep(obj);
+      item['Hz'] = 0 + i * 3;
+      item['c'] = n + 5 * i;
+      item['b'] = m + i * 2;
+      item['max'] = maxList[i + 2];
+      item['min'] = minList[i + 2];
+      data.push(item);
+    }
+    return data;
+  } else if (deviceType == 'fanmain_wdg') {
+    // 武当沟
+    const num = 2;
+    const obj = {
+      angle: 0,
+      Hz: -0,
+      a: -0.1424,
+      b: 26.316238660115914,
+      c: -370.62808803303426,
+      min: 300,
+      max: 1100.0,
+    };
+    const a = -0.1424,
+      m = 26.086238660115914,
+      n = -370.62808803303426;
+
+    const maxList = [138, 148, 158, 168, 178];
+    const minList = [90, 95, 100, 105, 110];
+    const data = [];
+    for (let i = -2; i <= num; i++) {
+      const item = cloneDeep(obj);
+      item['Hz'] = 0 + i * 3;
+      item['c'] = n + 1 * i;
+      item['b'] = m + i * 1.3;
+      item['max'] = maxList[i + 2];
+      item['min'] = minList[i + 2];
+      data.push(item);
+    }
+    return data;
+  }
+};
+
 export const fanInfoData = reactive({
   fj: '一号回风井',
   xh: 'FBCDZ No.29',

+ 5 - 1
src/views/vent/monitorManager/warningMonitor/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <customHeader>预警历史监控系统</customHeader>
+  <customHeader>{{ orgname }}预警历史监控系统</customHeader>
   <div class="data-statistics">
     <div class="statistics-box" v-for="(item, index) in statisticsList" :key="index">
       <div class="left-box">
@@ -271,7 +271,11 @@
     statisticsList[4].valueT = res.synthesizeSWarnInfo.totalNum || 0;
     statisticsList[4].valueB = res.synthesizeSWarnInfo.maxWarnLevel || '';
   }
+
+  const orgname = ref<any>('');
+
   onMounted(async () => {
+    orgname.value = route.query.orgname;
     getEachMineWarnCountInfoList();
   });
 

+ 4 - 3
src/views/vent/monitorManager/windowMonitor/index.vue

@@ -17,7 +17,7 @@
   </div>
   <div class="scene-box">
     <div class="top-box">
-      <div class="top-center">
+      <div class="top-center" style="display: flex">
         <div class="row" v-if="Number(selectData.nwindownum) > 1">
           <div v-if="hasPermission('window:control')" class="button-box" @click="setArea(1)">设定前窗面积</div>
           <div v-if="hasPermission('window:control')" class="button-box" @click="setArea(2)">设定后窗面积</div>
@@ -32,12 +32,13 @@
         <div class="row" v-if="Number(selectData.nwindownum) == 1">
           <div v-if="hasPermission('window:control')" class="button-box" @click="setArea(1)">设定风窗面积</div>
           <div v-if="hasPermission('window:fltk')" class="button-box" @click="setArea(7)">风窗自主调控</div>
+
           <!-- 展会功能 -->
           <!-- <div v-if="hasPermission('window:ldkz')" class="button-box" @click="setArea(3)">自主联动控制开启</div>
           <div v-if="hasPermission('window:ldkz')" class="button-box" @click="setArea(4)">自主联动控制停止</div> -->
         </div>
         <template v-if="hasPermission('window:showAngle')">
-          <div class="row" v-if="selectData.nwindownum > 1">
+          <div class="row" v-if="Number(selectData.nwindownum) > 1">
             <div v-if="hasPermission('window:control')" class="button-box" @click="setAngle(1)">设定前窗角度</div>
             <div v-if="hasPermission('window:control')" class="button-box" @click="setAngle(2)">设定后窗角度</div>
             <div v-if="hasPermission('window:fltk')" class="button-box" @click="setArea(7)">前窗自主调控</div>
@@ -46,7 +47,7 @@
             <!-- <div v-if="hasPermission('window:ldkz')" class="button-box" @click="setArea(3)">自主联动控制开启</div>
             <div v-if="hasPermission('window:ldkz')" class="button-box" @click="setArea(4)">自主联动控制停止</div> -->
           </div>
-          <div class="row" v-if="selectData.nwindownum == 1">
+          <div class="row" v-if="Number(selectData.nwindownum) == 1">
             <div v-if="hasPermission('window:control')" class="button-box" @click="setAngle(1)">设定风窗角度</div>
             <div v-if="hasPermission('window:fltk')" class="button-box" @click="setArea(7)">风窗自主调控</div>
             <!-- 展会功能 -->

+ 278 - 0
src/views/vent/monitorManager/windowMonitor/shuangdaoFcBlt.threejs.ts

@@ -0,0 +1,278 @@
+import * as THREE from 'three';
+import { getTextCanvas, renderVideo } from '/@/utils/threejs/util';
+import gsap from 'gsap';
+
+class doubleWindow {
+  model;
+  modelName = 'sdFc';
+  group: THREE.Object3D = new THREE.Object3D();
+  animationTimer;
+  isLRAnimation = true;
+  direction = 1;
+  windowsActionArr = {
+    frontWindow: <THREE.Mesh[]>[],
+    backWindow: <THREE.Mesh[]>[],
+  };
+  constructor(model) {
+    this.model = model;
+    // this.group.name = 'ddFc';
+  }
+  // // 重置摄像头
+  // const resetCamera = () => {
+  //   this.model.camera.position.set(30.328, 58.993, 148.315);
+  //   this.model.camera.rotation.set(-27.88, 14.35, 7.47);
+  //   this.model.orbitControls?.update();
+  //   this.model.camera.updateProjectionMatrix();
+  // };
+
+  addLight = () => {};
+
+  // 设置模型位置
+  setModalPosition() {
+    this.group?.scale.set(22, 22, 22);
+    this.group?.position.set(-35, 25, 15);
+  }
+
+  addMonitorText(selectData) {
+    if (!this.group) {
+      return;
+    }
+    const screenDownText = VENT_PARAM['modalText']
+      ? VENT_PARAM['modalText']
+      : History_Type['type'] == 'remote'
+      ? `国能神东煤炭集团监制`
+      : '煤炭科学技术研究院有限公司研制';
+
+    const screenDownTextX = 125 - (screenDownText.length - 10) * 10;
+    const textArr = [
+      {
+        text: `远程定量调节自动风窗`,
+        font: 'normal 30px Arial',
+        color: '#009900',
+        strokeStyle: '#002200',
+        x: 120,
+        y: 90,
+      },
+      {
+        text: `${selectData.OpenDegree ? '开度值(%)' : selectData.forntArea ? '过风面积(㎡)' : '过风面积(㎡)'}:`,
+        font: 'normal 30px Arial',
+        color: '#009900',
+        strokeStyle: '#002200',
+        x: 5,
+        y: 145,
+      },
+      {
+        text: selectData.OpenDegree
+          ? Number(`${selectData.OpenDegree}`).toFixed(2)
+          : selectData.forntArea
+          ? Number(`${selectData.forntArea}`).toFixed(2)
+          : '-',
+        font: 'normal 30px Arial',
+        color: '#009900',
+        strokeStyle: '#002200',
+        x: 330,
+        y: 145,
+      },
+      {
+        text: `${selectData.frontRearDP ? '风窗压差(Pa)' : selectData.windSpeed ? '风速(m/s)' : '通信状态'}:`,
+        font: 'normal 30px Arial',
+        color: '#009900',
+        strokeStyle: '#002200',
+        x: 5,
+        y: 200,
+      },
+      {
+        text: `${
+          selectData.frontRearDP
+            ? selectData.frontRearDP
+            : selectData.windSpeed
+            ? selectData.windSpeed
+            : selectData.netStatus == '0'
+            ? '断开'
+            : '连接'
+        }`,
+        font: 'normal 30px Arial',
+        color: '#009900',
+        strokeStyle: '#002200',
+        x: 330,
+        y: 200,
+      },
+      {
+        text: `${selectData.fWindowM3 ? '过风量(m³/min)' : '风窗道数'}: `,
+        font: 'normal 30px Arial',
+        color: '#009900',
+        strokeStyle: '#002200',
+        x: 5,
+        y: 256,
+      },
+      {
+        text: `${selectData.fWindowM3 ? selectData.fWindowM3 : selectData.nwindownum}`,
+        font: 'normal 30px Arial',
+        color: '#009900',
+        strokeStyle: '#002200',
+        x: 330,
+        y: 256,
+      },
+      {
+        text: screenDownText,
+        font: 'normal 28px Arial',
+        color: '#009900',
+        strokeStyle: '#002200',
+        x: screenDownTextX,
+        y: 303,
+      },
+    ];
+
+    getTextCanvas(726, 546, textArr, '').then((canvas: HTMLCanvasElement) => {
+      const textMap = new THREE.CanvasTexture(canvas); // 关键一步
+      const textMaterial = new THREE.MeshBasicMaterial({
+        // 关于材质并未讲解 实操即可熟悉                 这里是漫反射类似纸张的材质,对应的就有高光类似金属的材质.
+        map: textMap, // 设置纹理贴图
+        transparent: true,
+        side: THREE.DoubleSide, // 这里是双面渲染的意思
+      });
+      textMap.dispose();
+      textMaterial.blending = THREE.CustomBlending;
+      const monitorPlane = this.group?.getObjectByName('monitorText');
+      if (monitorPlane) {
+        monitorPlane.material = textMaterial;
+      } else {
+        const planeGeometry = new THREE.PlaneGeometry(726, 546); // 平面3维几何体PlaneGeometry
+        const planeMesh = new THREE.Mesh(planeGeometry, textMaterial);
+        planeMesh.name = 'monitorText';
+        planeMesh.scale.set(0.002, 0.002, 0.002);
+        planeMesh.position.set(4.19, 0.448, -0.27);
+        this.group?.add(planeMesh);
+      }
+    });
+  }
+
+  /* 提取风门序列帧,初始化前后门动画 */
+  initAnimation() {
+    const meshArr01: THREE.Object3D[] = [];
+    const meshArr02: THREE.Object3D[] = [];
+    const fcObj = this.group.getObjectByName('sdFc')?.getObjectByName('FengChuang_2')?.getObjectByName('FengChuang');
+    const leftObjNames = ['FCshanye03', 'FCshanye04'];
+    const rightObjNames = ['FCshanye05', 'FCshanye06'];
+    debugger;
+    leftObjNames.filter((name) => {
+      const obj = fcObj?.getObjectByName(name);
+      if (obj) {
+        obj.rotateOnAxis(new THREE.Vector3(0, 1, 0), 0);
+        meshArr01.push(obj);
+      }
+    });
+    rightObjNames.filter((name) => {
+      const obj = fcObj?.getObjectByName(name);
+      if (obj) {
+        obj.rotateOnAxis(new THREE.Vector3(0, 1, 0), 0);
+        meshArr02.push(obj);
+      }
+    });
+    this.windowsActionArr.frontWindow = meshArr01;
+    this.windowsActionArr.backWindow = meshArr02;
+  }
+
+  play(rotationParam, flag) {
+    if (this.windowsActionArr.frontWindow.length <= 0 || this.windowsActionArr.backWindow.length <= 0) {
+      return;
+    }
+    if (flag === 1) {
+      // 前风窗动画
+      this.windowsActionArr.frontWindow.forEach((mesh) => {
+        gsap.to(mesh.rotation, {
+          y: THREE.MathUtils.degToRad(rotationParam.frontDeg1),
+          duration: (1 / 9) * Math.abs(rotationParam.frontDeg1 - mesh.rotation.y),
+          overwrite: true,
+        });
+      });
+    } else if (flag === 2) {
+      // 后风窗动画
+      this.windowsActionArr.backWindow.forEach((mesh) => {
+        gsap.to(mesh.rotation, {
+          y: THREE.MathUtils.degToRad(rotationParam.backDeg1),
+          duration: (1 / 9) * Math.abs(rotationParam.backDeg1 - mesh.rotation.y),
+          overwrite: true,
+        });
+      });
+    } else if (flag === 0) {
+      ([...this.windowsActionArr.frontWindow, ...this.windowsActionArr.backWindow] as THREE.Mesh[]).forEach((mesh) => {
+        gsap.to(mesh.rotation, {
+          y: 0,
+          overwrite: true,
+        });
+      });
+    }
+  }
+
+  /* 点击风窗,风窗全屏 */
+  mousedownModel(intersects: THREE.Intersection<THREE.Object3D<THREE.Event>>[]) {
+    this.isLRAnimation = false;
+    if (this.animationTimer) {
+      clearTimeout(this.animationTimer);
+      this.animationTimer = null;
+    }
+    // 判断是否点击到视频
+    intersects.find((intersect) => {
+      const mesh = intersect.object;
+      if (mesh.name === 'player1') {
+        if (new Date().getTime() - this.playerStartClickTime1 < 400) {
+          // 双击,视频放大
+          if (this.player1) {
+            this.player1.requestFullscreen();
+          }
+        }
+        this.playerStartClickTime1 = new Date().getTime();
+        return true;
+      }
+      return false;
+    });
+  }
+
+  mouseUpModel() {
+    // 10s后开始摆动
+    if (!this.animationTimer && !this.isLRAnimation) {
+      this.animationTimer = setTimeout(() => {
+        this.isLRAnimation = true;
+      }, 10000);
+    }
+  }
+
+  /* 风门动画 */
+  render() {
+    if (!this.model) {
+      return;
+    }
+    if (this.isLRAnimation && this.group) {
+      // 左右摇摆动画
+      if (Math.abs(this.group.rotation.y) >= 0.2) {
+        this.direction = -this.direction;
+        this.group.rotation.y += 0.00002 * 30 * this.direction;
+      } else {
+        this.group.rotation.y += 0.00002 * 30 * this.direction;
+      }
+    }
+  }
+
+  mountedThree(playerDom) {
+    return new Promise((resolve) => {
+      this.model.setGLTFModel('sdFc-d').then((gltf) => {
+        const fcModal = gltf[0];
+        fcModal.name = 'sdFc';
+        this.group?.add(fcModal);
+        this.setModalPosition();
+        this.initAnimation();
+        this.addLight();
+        resolve(null);
+      });
+    });
+  }
+
+  destroy() {
+    this.model.clearGroup(this.group);
+    this.windowsActionArr.frontWindow = undefined;
+    this.model = null;
+    this.group = null;
+  }
+}
+export default doubleWindow;

+ 5 - 2
src/views/vent/monitorManager/windowMonitor/window.threejs.ts

@@ -226,7 +226,7 @@ export const setModelType = (type) => {
 
 export const mountedThree = (playerDom) => {
   const { sysOrgCode } = useGlobSetting();
-  // const sysOrgCode = 'sdmtjtswmk';
+  // const sysOrgCode = 'sdmtjtbltmk';
   return new Promise(async (resolve) => {
     model = new UseThree('#window3D');
     if (!model || !model.renderer || !model.camera) return;
@@ -246,9 +246,12 @@ export const mountedThree = (playerDom) => {
       singleWindowObj = new singleWindow(model);
     }
 
-    if (sysOrgCode === 'sdmtjtswmk' || sysOrgCode === 'sdmtjtbltmk') {
+    if (sysOrgCode === 'sdmtjtswmk') {
       const doubleWindow = await import('./shuangdaoFcSw.threejs');
       if (doubleWindow) doubleWindowObj = new doubleWindow.default(model);
+    } else if (sysOrgCode === 'sdmtjtbltmk') {
+      const doubleWindow = await import('./shuangdaoFcBlt.threejs');
+      if (doubleWindow) doubleWindowObj = new doubleWindow.default(model);
     } else {
       doubleWindowObj = new doubleWindow(model);
     }

Неке датотеке нису приказане због велике количине промена