Browse Source

1. 主风机替换模型,并添加动画
2. 新增新的行人风门
3. 联动控制功能优化

hongrunxia 8 months ago
parent
commit
9bc8f1c7fc

BIN
public/model/glft/ztfj/ztfj-xj_2024-06-20.glb


+ 1 - 1
src/utils/threejs/main.worker.ts

@@ -54,7 +54,7 @@ export function initModalWorker() {
     'ztfj/fbm_2023-06-02.glb',
     'ztfj/ztfj-fc_2023-06-02.glb',
     'ztfj/ztfj_2023-12-12.glb',
-    'ztfj/ztfj-xj_2024-06-20.glb',
+    'ztfj/ztfj-xj_2024-07-12.glb',
     'fire/laneway_2024-03-04.glb',
     'fire/laneway-device_2024-03-19.glb',
     'fire/chamber_2023-06-02.glb',

+ 3 - 2
src/views/vent/deviceManager/comment/warningTabel/BaseModal.vue

@@ -4,7 +4,7 @@
       <template #monitor="{ model, field }">
         <div class="vent-flex-row-between">
           <Select ref="selectRef" disabled v-model:value="pointData" :options="option" style="width: calc(100% - 65px)" />
-          <a-button class="vent-margin-b-5" type="primary" @click="selectPoint(model['deviceType'])" style="position: absolute; right: 0; top: 1px"
+          <a-button class="vent-margin-b-5" type="primary" @click="selectPoint(model['strtype'])" style="position: absolute; right: 0; top: 1px"
             >选择</a-button
           >
         </div>
@@ -71,7 +71,8 @@
         }
       });
       pointData.value = [data.record['monitorId']];
-      await setFieldsValue({ relId: data.record['relId'] || data.record['id'], monitorId: '' });
+      const relId = data.isUpdate ? data.record['relId'] : data.record['relId'] || data.record['id'];
+      await setFieldsValue({ relId, monitorId: '' });
     }
   });
 

+ 2 - 0
src/views/vent/deviceManager/comment/warningTabel/BaseModal1.vue

@@ -50,6 +50,7 @@
     isUpdate.value = unref(data.isUpdate);
     title.value = unref(data.title);
     await resetFields();
+    debugger;
     if (data.isUpdate) {
       await setFieldsValue({ ...data.record });
       pointData.value = [data.record['monitorId']];
@@ -63,6 +64,7 @@
       //   }
       // })
     } else if (data.record) {
+      // 新增
       await setFieldsValue({ relId: data.record['relId'] || data.record['id'], monitorId: '' });
     }
   });

+ 1 - 0
src/views/vent/deviceManager/comment/warningTabel/index3.vue

@@ -131,6 +131,7 @@
   const [register, { openModal, closeModal }] = useModal();
 
   function handleOpen(flag?, record?) {
+    debugger;
     if (record) {
       if (flag == 'update') {
         openModal(true, {

+ 1 - 0
src/views/vent/deviceManager/comment/warningTabel/warning.data.ts

@@ -436,6 +436,7 @@ export const monitorWarningFormSchemas = (param) =>
           labelField: 'strname',
           valueField: 'id',
           onChange: (e, option) => {
+            debugger;
             if (option) formModel['strtype'] = option['strtype'];
           },
         };

+ 1 - 1
src/views/vent/home/colliery/index.vue

@@ -118,7 +118,7 @@
   let warnData = ref<any>([]); //预警数据
   let deviceData = ref<any>({}); //设备监测数据
   let navList = reactive([
-    { name: '总风量(m³/min)', isShow: true, valList: [] },
+    { name: '总风量(m³/min)', isShow: true, valList: [] },
     { name: '需风量(m³/min)', isShow: true, valList: [] },
     // { name: '有效风量(m³/min)', isShow: true, valList: [] },
     { name: '等积孔(m²)', isShow: true, valList: [] },

+ 4 - 2
src/views/vent/monitorManager/mainFanMonitor/main.threejs.ts

@@ -216,8 +216,10 @@ export const playAnimate = async (selectData, duration?) => {
 
   if (modalType === 'mainWindRect') {
     mainObj = mainWindObj;
+    // bgGroup.visible = true;
   } else if (modalType === 'mainXjWindRect') {
     mainObj = mainXjWindObj;
+    // bgGroup.visible = false;
   }
 
   if (selectData && mainObj) {
@@ -337,12 +339,12 @@ export const setModelType = (type) => {
       setTimeout(async () => {
         resolve(null);
         // const position = mainWindObj.group.position;
-        const position = new THREE.Vector3(-0.45, 0.84, -10.35);
+        const position = new THREE.Vector3(12.96, 23.17, -23.16);
         const oldCameraPosition = { x: -332.39, y: 283.47, z: 438.61 };
         await animateCamera(
           oldCameraPosition,
           { x: -3.41, y: -29.01, z: 8.84 },
-          { x: -1.23, y: 75.15, z: 118.36 },
+          { x: 12.09, y: 105.51, z: 119.45 },
           { x: position.x, y: position.y, z: position.z },
           model,
           0.8

+ 5 - 5
src/views/vent/monitorManager/mainFanMonitor/mainWind.xj.threejs.ts

@@ -60,8 +60,8 @@ class mainXjWindRect {
         const mainCSS3D = new CSS3DObject(element);
         mainCSS3D.name = 'monitorText1';
         mainCSS3D.scale.set(0.09, 0.09, 0.09);
-        mainCSS3D.position.set(worldPosition.x + 34, worldPosition.y - 5, worldPosition.z - 35);
-        mainCSS3D.lookAt(worldPosition.x + 34, worldPosition.y + 5, worldPosition.z + 2);
+        mainCSS3D.position.set(worldPosition.x + 34, worldPosition.y - 35, worldPosition.z - 35);
+        mainCSS3D.lookAt(worldPosition.x + 34, worldPosition.y - 30, worldPosition.z + 2);
         this.group.add(mainCSS3D);
       }
     }
@@ -73,8 +73,8 @@ class mainXjWindRect {
         const mainCSS3D = new CSS3DObject(element);
         mainCSS3D.name = 'monitorText2';
         mainCSS3D.scale.set(0.09, 0.09, 0.09);
-        mainCSS3D.position.set(worldPosition.x + 34, worldPosition.y - 5, worldPosition.z - 20);
-        mainCSS3D.lookAt(worldPosition.x + 34, worldPosition.y + 5, worldPosition.z + 2);
+        mainCSS3D.position.set(worldPosition.x + 34, worldPosition.y - 35, worldPosition.z - 20);
+        mainCSS3D.lookAt(worldPosition.x + 34, worldPosition.y - 30, worldPosition.z + 2);
         this.group.add(mainCSS3D);
       }
     }
@@ -688,7 +688,7 @@ class mainXjWindRect {
         ztfjModal.position.set(4.64, 4.11, 1.52);
         this.group?.add(gltf[0].children[0]);
         // this.group?.position.set(4.77, 3.63, 0.63);
-        this.group?.position.set(-0.44, 19.88, 22.37);
+        this.group?.position.set(-0.44, 47.32, 22.37);
         this.initSmokeMass();
         await this.setSmokePosition();
 

+ 5 - 5
src/views/vent/monitorManager/nitrogen/index.vue

@@ -39,11 +39,11 @@
       pathName: 'yfj_history',
       isHover: false,
     },
-    {
-      title: '操作历史记录',
-      pathName: 'yfj_handler_history',
-      isHover: false,
-    },
+    // {
+    //   title: '操作历史记录',
+    //   pathName: 'yfj_handler_history',
+    //   isHover: false,
+    // },
     {
       title: '故障诊断历史记录',
       pathName: 'yfj_faultRecord',

+ 2 - 1
src/views/vent/monitorManager/safetyMonitor/index.vue

@@ -175,7 +175,8 @@
             :chartsColumns="chartsColumnsreal" chartsType="" :option="echartsOption" />
         </div> -->
       </a-tab-pane>
-      <a-tab-pane key="3" tab="报警历史">
+
+      <a-tab-pane key="3" tab="报警历史" v-if="!hasPermission('safety:hideWarning')">
         <div class="tab-item">
           <AlarmHistoryTable
             ref="alarmHistoryTable"

+ 7 - 3
src/views/vent/monitorManager/windrectMonitor/index.vue

@@ -615,9 +615,8 @@
   }
 
   function resetHandle() {
-    resetWind({}).then((res: any) => {
-      message.info(res);
-    });
+    modalType.value = 'resetWind';
+    modalIsShow.value = true;
   }
 
   function exportExcel(id) {
@@ -688,6 +687,11 @@
           }
           modalIsShow.value = false;
         });
+      } else if (type == 'resetWind') {
+        resetWind({}).then((res: any) => {
+          message.info(res);
+        });
+        modalIsShow.value = false;
       }
     } catch (error) {
       message.error('测风失败,请联系管理员。。。');