|
|
@@ -2,28 +2,27 @@
|
|
|
<div class="page">
|
|
|
<HeaderComponent title="M2出料"></HeaderComponent>
|
|
|
<div class="content_page">
|
|
|
- <M1Tank title="M2" :valveArr="valveArr_M2" :waterLevelValue="30" :pressureValue="0.444"
|
|
|
- :temperatureValue="110" :iconSize="400" :weightValue="100" class="m2Flow_m1Tank"></M1Tank>
|
|
|
- <S1Tank title="S1" :fanStatus="fanStatus" :valveArr="valveArr_S1" :pressureValue="0.444"
|
|
|
- :waterLevelValue="30" :temperatureValue="20" :iconSize="300" :weightValue="100" class="m2Flow_s1Tank">
|
|
|
+ <M1Tank title="M2" :valveArr="valveMap.M2" :waterLevelValue="30"
|
|
|
+ :pressureValue="sensorHelper.getDataArrByCode('M2yl')[0]" :temperatureValue="110" :iconSize="400"
|
|
|
+ :weightValue="100" class="m2Flow_m1Tank"></M1Tank>
|
|
|
+ <S1Tank title="S1" :fanStatus="fanStatus" :valveArr="valveMap.S1" :iconSize="300"
|
|
|
+ :pressureValue="sensorHelper.getDataArrByCode('S1yl')[0]" :waterLevelValue="30"
|
|
|
+ :temperatureValue="sensorHelper.getDataArrByCode('S1wd')[0]" class="m2Flow_s1Tank">
|
|
|
</S1Tank>
|
|
|
- <S1Tank title="S2" :fanStatus="fanStatus" :valveArr="valveArr_S2" :pressureValue="0.444"
|
|
|
- :waterLevelValue="30" :temperatureValue="20" :iconSize="300" :weightValue="100" class="m2Flow_s2Tank">
|
|
|
+ <S1Tank title="S2" :fanStatus="fanStatus" :valveArr="valveMap.S2" :iconSize="300"
|
|
|
+ :pressureValue="sensorHelper.getDataArrByCode('S2yl')[0]" :waterLevelValue="30"
|
|
|
+ :temperatureValue="sensorHelper.getDataArrByCode('S2wd')[0]" class="m2Flow_s2Tank">
|
|
|
</S1Tank>
|
|
|
<S1Tank title="S3" :fanStatus="fanStatus" :valveArr="valveArr_S3" :pressureValue="0.444"
|
|
|
:waterLevelValue="30" :temperatureValue="20" :iconSize="300" :weightValue="100" class="m2Flow_s3Tank">
|
|
|
</S1Tank>
|
|
|
<WaterTank title="P1" :tankType="3" class="m2Flow_p1Tank" :iconSize="300"></WaterTank>
|
|
|
|
|
|
- <!-- <J1Tank title="J2" :valveArr="valveArr_J2" :iconSize="300" class="m2Flow_j1Tank"></J1Tank> -->
|
|
|
<div class="pumps">
|
|
|
- <!-- lb9 -->
|
|
|
+ <!-- lb6 -->
|
|
|
<div class="lb6_pos">
|
|
|
- <Pump title="出料泵" :hz="5000" :pumpStatus="正转" :iconSize="100"></Pump>
|
|
|
+ <Pump title="出料泵" :pumpDataArr="pumpHelper.getDataArrByCode('LB6')" :iconSize="100"></Pump>
|
|
|
</div>
|
|
|
- <!-- <div class="lb7_pos">
|
|
|
- <Pump title="换热进液泵" :hz="5000" :pumpStatus="正转" :iconSize="100"></Pump>
|
|
|
- </div> -->
|
|
|
</div>
|
|
|
<div class="icon_others">
|
|
|
<div class="other1">
|
|
|
@@ -62,24 +61,6 @@
|
|
|
:striped-flow="getValveAndStatus('N12') && getValveOrStatus('N22', 'N23', 'N24')"
|
|
|
:duration="progressConfig.duration" class="progress_materials progress_pos2_2" />
|
|
|
|
|
|
- <!-- m2-换热进液泵-j2 -->
|
|
|
- <!-- <el-progress :percentage="100" :stroke-width="progressConfig.strokeWidth" :show-text="false"
|
|
|
- :striped="getValveAndStatus('N15') && getValveOrStatus('N16', 'N17')"
|
|
|
- :striped-flow="getValveAndStatus('N15') && getValveOrStatus('N16', 'N17')"
|
|
|
- :duration="progressConfig.duration" class="progress_red progress_pos3" />
|
|
|
- <el-progress :percentage="100" :stroke-width="progressConfig.strokeWidth" :show-text="false"
|
|
|
- :striped="getValveAndStatus('N15', 'D4') && getValveOrStatus('N16', 'N17')"
|
|
|
- :striped-flow="getValveAndStatus('N15', 'D4') && getValveOrStatus('N16', 'N17')"
|
|
|
- :duration="progressConfig.duration" class="progress_red progress_pos4 rotate_270" />
|
|
|
- <el-progress :percentage="100" :stroke-width="progressConfig.strokeWidth" :show-text="false"
|
|
|
- :striped="getValveAndStatus('N15', 'D4') && getValveOrStatus('N16', 'N17')"
|
|
|
- :striped-flow="getValveAndStatus('N15', 'D4') && getValveOrStatus('N16', 'N17')" :duration="20"
|
|
|
- class="progress_red progress_pos5" />
|
|
|
- <el-progress :percentage="100" :stroke-width="progressConfig.strokeWidth" :show-text="false"
|
|
|
- :striped="getValveAndStatus('N15', 'D4') && getValveOrStatus('N16', 'N17')"
|
|
|
- :striped-flow="getValveAndStatus('N15', 'D4') && getValveOrStatus('N16', 'N17')" :duration="30"
|
|
|
- class="progress_red progress_pos6 rotate_90" /> -->
|
|
|
-
|
|
|
<!-- 喷淋塔相关管道 -->
|
|
|
<el-progress :percentage="100" :stroke-width="progressConfig.strokeWidth" :show-text="false"
|
|
|
:striped="getValveOrStatus('D16')" :striped-flow="getValveOrStatus('D16')" :duration="20"
|
|
|
@@ -138,13 +119,16 @@
|
|
|
|
|
|
<!-- 通向m1流程页面的管道 -->
|
|
|
<el-progress :percentage="100" :stroke-width="progressConfig.strokeWidth" :show-text="false"
|
|
|
- :striped="getValveOrStatus('D6', 'D7')" :striped-flow="getValveOrStatus('D6', 'D7')"
|
|
|
+ :striped="getValveOrStatus('D6', 'D7') && getValveAndStatus('N10')"
|
|
|
+ :striped-flow="getValveOrStatus('D6', 'D7') && getValveAndStatus('N10')"
|
|
|
:duration="progressConfig.duration" class="progress_materials progress_pos15_1" />
|
|
|
<el-progress :percentage="100" :stroke-width="progressConfig.strokeWidth" :show-text="false"
|
|
|
- :striped="getValveAndStatus('D7')" :striped-flow="getValveAndStatus('D7')"
|
|
|
+ :striped="getValveAndStatus('D7') && getValveAndStatus('N10')"
|
|
|
+ :striped-flow="getValveAndStatus('D7') && getValveAndStatus('N10')"
|
|
|
:duration="progressConfig.duration" class="progress_materials progress_pos15_2" />
|
|
|
<el-progress :percentage="100" :stroke-width="progressConfig.strokeWidth" :show-text="false"
|
|
|
- :striped="getValveOrStatus('D5', 'D6', 'D7')" :striped-flow="getValveOrStatus('D5', 'D6', 'D7')"
|
|
|
+ :striped="getValveOrStatus('D5', 'D6', 'D7') && getValveAndStatus('N10')"
|
|
|
+ :striped-flow="getValveOrStatus('D5', 'D6', 'D7') && getValveAndStatus('N10')"
|
|
|
:duration="progressConfig.duration" class="progress_materials progress_pos16 rotate_90" />
|
|
|
|
|
|
<!-- 通向换热流程的管道 -->
|
|
|
@@ -177,13 +161,25 @@
|
|
|
import M1Tank from '@/components/DCS/M1TankComponent.vue';
|
|
|
import S1Tank from '@/components/DCS/S1TankComponent.vue';
|
|
|
import WaterTank from '@/components/DCS/WaterTankComponent.vue';
|
|
|
-import J1Tank from '@/components/DCS/J1TankComponent.vue';
|
|
|
import Pump from '@/components/DCS/PumpComponent.vue';
|
|
|
import { useValveHelper } from '@/hooks/useValveHelper'
|
|
|
import { useRouter } from 'vue-router'
|
|
|
-import { computed } from 'vue';
|
|
|
+import { computed, onMounted, onBeforeUnmount } from 'vue';
|
|
|
|
|
|
+import { stompClient } from '@/utils/ws/stompClient';
|
|
|
+import { updateZTPageConfig } from '@/api/dcs/configurePage';
|
|
|
const router = useRouter()
|
|
|
+
|
|
|
+const pageCode = 'm2OutMaterial';
|
|
|
+const pageParams = {
|
|
|
+ "M2": ['N12', 'N13', 'N14', 'N15', 'N16', 'N17', 'N18', 'N20'],
|
|
|
+ "S1": ['N10', 'D5', 'D11', 'N22', 'D16', 'D8'],
|
|
|
+ "S2": ['D6', 'D9', 'D17', 'D12', 'N23', 'N10'],
|
|
|
+ "S3": ['D7', 'D10', 'D13', 'N24', 'N10'],
|
|
|
+ "PUMP": ['LB6'],
|
|
|
+ "SENSORS": ['M2yl', 'M2cz', 'M2wd', 'S1yl', 'S1cz', 'S1wd', 'S2yl', 'S2cz', 'S2wd', 'S3yl', 'S3cz', 'S3wd'],
|
|
|
+}
|
|
|
+
|
|
|
//M1罐阀门状态
|
|
|
const valveArr_M2 = [
|
|
|
{
|
|
|
@@ -223,7 +219,6 @@ const valveArr_M2 = [
|
|
|
// value: [true],
|
|
|
// },
|
|
|
]
|
|
|
-
|
|
|
//S1罐阀门状态
|
|
|
const valveArr_S1 = [
|
|
|
{
|
|
|
@@ -254,6 +249,10 @@ const valveArr_S1 = [
|
|
|
]
|
|
|
//S2罐阀门状态
|
|
|
const valveArr_S2 = [
|
|
|
+ {
|
|
|
+ code: 'N10',
|
|
|
+ value: [true],
|
|
|
+ },
|
|
|
{
|
|
|
code: 'D6',
|
|
|
value: [true, false, false],
|
|
|
@@ -278,46 +277,126 @@ const valveArr_S2 = [
|
|
|
]
|
|
|
//S3罐阀门状态
|
|
|
const valveArr_S3 = [
|
|
|
+ {
|
|
|
+ code: 'N10',
|
|
|
+ value: [true],
|
|
|
+ },
|
|
|
{
|
|
|
code: 'D7',
|
|
|
value: [false, true, false],
|
|
|
},
|
|
|
{
|
|
|
code: 'D10',
|
|
|
- value: [true, false, false],
|
|
|
+ value: [false, true, false],
|
|
|
},
|
|
|
{
|
|
|
code: 'D13',
|
|
|
- value: [true, false, false],
|
|
|
+ value: [false, true, false],
|
|
|
},
|
|
|
{
|
|
|
code: 'N24',
|
|
|
- value: [true],
|
|
|
+ value: [false],
|
|
|
},
|
|
|
|
|
|
]
|
|
|
-
|
|
|
-const valveArr_J2 = [
|
|
|
- // {
|
|
|
- // code: 'D3',
|
|
|
- // value: [true, false, true],
|
|
|
- // },
|
|
|
+//传感器状态
|
|
|
+const sensorArr = [
|
|
|
{
|
|
|
- code: 'D4',
|
|
|
- value: [true, false, true],
|
|
|
- }
|
|
|
+ code: 'M2yl',
|
|
|
+ value: [0.5],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'M2cz',
|
|
|
+ value: [100],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'M2wd',
|
|
|
+ value: [30],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'S1yl',
|
|
|
+ value: [0.6],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'S1cz',
|
|
|
+ value: [100],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'S1wd',
|
|
|
+ value: [30],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'S2yl',
|
|
|
+ value: [0.3],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'S2cz',
|
|
|
+ value: [100],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'S2wd',
|
|
|
+ value: [30],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'S3yl',
|
|
|
+ value: [0.5],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'S3cz',
|
|
|
+ value: [100],
|
|
|
+ },
|
|
|
+ {
|
|
|
+ code: 'S3wd',
|
|
|
+ value: [30],
|
|
|
+ },
|
|
|
+]
|
|
|
+const pumpArr = [
|
|
|
+ {
|
|
|
+ code: 'LB9',
|
|
|
+ value: [0, 3],
|
|
|
+ },
|
|
|
]
|
|
|
+
|
|
|
+const valveMap = reactive({
|
|
|
+ M2: valveArr_M2,
|
|
|
+ S1: valveArr_S1,
|
|
|
+ S2: valveArr_S2,
|
|
|
+ S3: valveArr_S3,
|
|
|
+ PUMP: pumpArr,
|
|
|
+ SENSORS: sensorArr,
|
|
|
+})
|
|
|
+onMounted(() => {
|
|
|
+ updateZTPageConfig(pageCode, pageParams).then(res => {
|
|
|
+ // console.log('页面配置成功:', res);
|
|
|
+ }).catch(err => {
|
|
|
+ console.log('页面配置失败:', err);
|
|
|
+ });
|
|
|
+ stompClient.subscribeToPage(pageCode, (data) => {
|
|
|
+ valveMap.M2 = Object.values(data.M2)
|
|
|
+ valveMap.S1 = Object.values(data.S1)
|
|
|
+ valveMap.S2 = Object.values(data.S2)
|
|
|
+ valveMap.S3 = Object.values(data.S3)
|
|
|
+ valveMap.PUMP = Object.values(data.PUMP)
|
|
|
+ valveMap.SENSORS = Object.values(data.SENSORS)
|
|
|
+ });
|
|
|
+});
|
|
|
+
|
|
|
+onBeforeUnmount(() => {
|
|
|
+ // 页面销毁时取消订阅
|
|
|
+ stompClient.unsubscribeFromPage(pageCode);
|
|
|
+});
|
|
|
+
|
|
|
//所有阀门状态
|
|
|
-const valveArr = [...new Set([
|
|
|
- ...valveArr_M2,
|
|
|
- ...valveArr_S1,
|
|
|
- ...valveArr_S2,
|
|
|
- ...valveArr_S3,
|
|
|
- ...valveArr_J2
|
|
|
-])];
|
|
|
+const valveArr = computed(() => [...new Set([
|
|
|
+ ...valveMap.M2,
|
|
|
+ ...valveMap.S1,
|
|
|
+ ...valveMap.S2,
|
|
|
+ ...valveMap.S3,
|
|
|
+])]);
|
|
|
|
|
|
const { getValveAndStatus, getValveOrStatus } = useValveHelper(valveArr)
|
|
|
-
|
|
|
+const pumpHelper = useValveHelper(computed(() => valveMap.PUMP))
|
|
|
+const sensorHelper = useValveHelper(computed(() => valveMap.SENSORS))
|
|
|
//搅拌电机运行状态
|
|
|
const fanStatus = true;
|
|
|
|
|
|
@@ -387,8 +466,7 @@ const pumpStatus_N18 = computed(() => {
|
|
|
|
|
|
.pumps {
|
|
|
|
|
|
- .lb6_pos,
|
|
|
- .lb7_pos {
|
|
|
+ .lb6_pos {
|
|
|
z-index: 15;
|
|
|
}
|
|
|
|
|
|
@@ -399,13 +477,6 @@ const pumpStatus_N18 = computed(() => {
|
|
|
transform: translate(-50%, -50%);
|
|
|
}
|
|
|
|
|
|
- .lb7_pos {
|
|
|
- position: absolute;
|
|
|
- top: 23%;
|
|
|
- left: 69.6%;
|
|
|
- transform: translate(-50%, -50%);
|
|
|
- }
|
|
|
-
|
|
|
}
|
|
|
|
|
|
//其他图标
|
|
|
@@ -520,34 +591,6 @@ const pumpStatus_N18 = computed(() => {
|
|
|
width: 7.3%;
|
|
|
}
|
|
|
|
|
|
- .progress_pos3 {
|
|
|
- position: absolute;
|
|
|
- top: 23.1%;
|
|
|
- left: 58%;
|
|
|
- width: 11.3%;
|
|
|
- }
|
|
|
-
|
|
|
- .progress_pos4 {
|
|
|
- position: absolute;
|
|
|
- top: 18.1%;
|
|
|
- left: 66.5%;
|
|
|
- width: 5.3%;
|
|
|
- }
|
|
|
-
|
|
|
- .progress_pos5 {
|
|
|
- position: absolute;
|
|
|
- top: 13.1%;
|
|
|
- left: 69%;
|
|
|
- width: 18.9%;
|
|
|
- }
|
|
|
-
|
|
|
- .progress_pos6 {
|
|
|
- position: absolute;
|
|
|
- top: 40%;
|
|
|
- left: 73.6%;
|
|
|
- width: 28.3%;
|
|
|
- }
|
|
|
-
|
|
|
//喷淋塔相关管道
|
|
|
.progress_pos7_1 {
|
|
|
position: absolute;
|