|
@@ -251,11 +251,15 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<!-- 调频 -->
|
|
|
- <div class="vent-flex-row input-box" v-if="modalType == 'frequency'">
|
|
|
- <div class="label">运行频率(单位):</div>
|
|
|
- <a-input-number size="small" v-model:value="frequencyVal" :min="30" :max="50" :step="0.1" />
|
|
|
+ <div class="vent-flex-row input-box" v-if="modalType == 'Fan1Frequency'">
|
|
|
+ <div class="label">主风机运行频率(Hz):</div>
|
|
|
+ <a-input-number size="small" v-model:value="fan1FrequencyVal" :min="30" :max="50" :step="0.1" />
|
|
|
+ </div>
|
|
|
+ <div class="vent-flex-row input-box" v-if="modalType == 'Fan2Frequency'">
|
|
|
+ <div class="label">备风机运行频率(Hz):</div>
|
|
|
+ <a-input-number size="small" v-model:value="fan2FrequencyVal" :min="30" :max="50" :step="0.1" />
|
|
|
</div>
|
|
|
- <div class="vent-flex-row input-box" v-if="modalType == 'needAir'">
|
|
|
+ <!-- <div class="vent-flex-row input-box" v-if="modalType == 'needAir'">
|
|
|
<div class="label">需风量(单位):</div>
|
|
|
<a-input-number size="small" v-model:value="frequencyVal" :min="30" :max="50" :step="0.1" />
|
|
|
</div>
|
|
@@ -298,7 +302,7 @@
|
|
|
<div class="label">风量下限(m³/min):</div>
|
|
|
<a-input-number size="small" v-model:value="modalTypeArr.rightBtnArr[3].max" :min="0" :max="50" :step="0.1" />
|
|
|
</div>
|
|
|
- </div>
|
|
|
+ </div> -->
|
|
|
<!-- 启动或停止 -->
|
|
|
<div class="" v-if="modalType == 'startSmoke'"> </div>
|
|
|
<div class="vent-flex-row input-box">
|
|
@@ -326,13 +330,13 @@
|
|
|
import { chartsColumns, chartsColumns1 } from './fanLocal.data';
|
|
|
import { deviceControlApi } from '/@/api/vent/index';
|
|
|
import LivePlayer from '@liveqing/liveplayer-v3';
|
|
|
- import { message } from 'ant-design-vue';
|
|
|
import { setDivHeight } from '/@/utils/event';
|
|
|
import { BorderBox8 as DvBorderBox8 } from '@kjgl77/datav-vue3';
|
|
|
import { getTableHeaderColumns } from '/@/hooks/web/useWebColumns';
|
|
|
import { SvgIcon } from '/@/components/Icon';
|
|
|
import { useRouter } from 'vue-router';
|
|
|
import { useModal } from '/@/components/Modal';
|
|
|
+import { message } from 'ant-design-vue';
|
|
|
|
|
|
const [registerModal, { openModal, closeModal }] = useModal();
|
|
|
const { currentRoute } = useRouter();
|
|
@@ -348,54 +352,62 @@
|
|
|
value: '一键倒机',
|
|
|
},
|
|
|
{
|
|
|
- key: 'windPower',
|
|
|
- value: '风电闭锁',
|
|
|
- },
|
|
|
- {
|
|
|
- key: 'gasPower',
|
|
|
- value: '瓦斯电闭锁',
|
|
|
- },
|
|
|
- {
|
|
|
- key: 'needAir',
|
|
|
- value: '需风量',
|
|
|
- },
|
|
|
- {
|
|
|
- key: 'diameter',
|
|
|
- value: '风筒直径',
|
|
|
- },
|
|
|
- {
|
|
|
- key: 'len',
|
|
|
- value: '风筒长度',
|
|
|
- },
|
|
|
- ],
|
|
|
- rightBtnArr: [
|
|
|
- {
|
|
|
- key: 'frequency',
|
|
|
- value: '调频',
|
|
|
- },
|
|
|
- {
|
|
|
- key: 'windPowerLimit',
|
|
|
- value: '风电闭锁限值',
|
|
|
- },
|
|
|
- {
|
|
|
- key: 'gasPowerLimit',
|
|
|
- value: '瓦斯电闭锁限值',
|
|
|
- },
|
|
|
- {
|
|
|
- key: 'airVolumeAlarm',
|
|
|
- value: '风量报警',
|
|
|
- min: 0,
|
|
|
- max: 100,
|
|
|
- },
|
|
|
- {
|
|
|
- key: 'disAirAlarm',
|
|
|
- value: '漏风率报警',
|
|
|
+ key: 'Fan1Frequency',
|
|
|
+ value: '主机调频',
|
|
|
},
|
|
|
{
|
|
|
- key: 'gasAlarm',
|
|
|
- value: '瓦斯报警',
|
|
|
+ key: 'Fan2Frequency',
|
|
|
+ value: '备机调频',
|
|
|
},
|
|
|
+ // {
|
|
|
+ // key: 'windPower',
|
|
|
+ // value: '风电闭锁',
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // key: 'gasPower',
|
|
|
+ // value: '瓦斯电闭锁',
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // key: 'needAir',
|
|
|
+ // value: '需风量',
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // key: 'diameter',
|
|
|
+ // value: '风筒直径',
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // key: 'len',
|
|
|
+ // value: '风筒长度',
|
|
|
+ // },
|
|
|
],
|
|
|
+ // rightBtnArr: [
|
|
|
+ // {
|
|
|
+ // key: 'frequency',
|
|
|
+ // value: '调频',
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // key: 'windPowerLimit',
|
|
|
+ // value: '风电闭锁限值',
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // key: 'gasPowerLimit',
|
|
|
+ // value: '瓦斯电闭锁限值',
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // key: 'airVolumeAlarm',
|
|
|
+ // value: '风量报警',
|
|
|
+ // min: 0,
|
|
|
+ // max: 100,
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // key: 'disAirAlarm',
|
|
|
+ // value: '漏风率报警',
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // key: 'gasAlarm',
|
|
|
+ // value: '瓦斯报警',
|
|
|
+ // },
|
|
|
+ // ],
|
|
|
});
|
|
|
const sensorList = ref<any[]>([
|
|
|
{
|
|
@@ -422,7 +434,8 @@
|
|
|
const player1 = ref();
|
|
|
const modalIsShow = ref<boolean>(false); // 是否显示模态框
|
|
|
const modalTitle = ref(''); // 模态框标题显示内容,根据设备操作类型决定
|
|
|
- const frequencyVal = ref(40); //频率
|
|
|
+ const fan1FrequencyVal = ref(40); //主机频率
|
|
|
+ const fan2FrequencyVal = ref(40); //备机频率
|
|
|
const mainWindIsShow1 = ref('open'); // 1#风机默认启动
|
|
|
const mainWindIsShow2 = ref('stop'); // 2#风机默认不启动
|
|
|
const passWord = ref('');
|
|
@@ -512,6 +525,7 @@
|
|
|
Object.assign(selectData, deviceBaseList.value, dataSource.value[selectRowIndex.value]);
|
|
|
addText(selectData);
|
|
|
// playAnimation(data, selectData.maxarea);
|
|
|
+ playSmoke(selectData)
|
|
|
if (timer) {
|
|
|
timer = null;
|
|
|
}
|
|
@@ -556,6 +570,7 @@
|
|
|
function showModal(obj) {
|
|
|
modalType.value = obj.key;
|
|
|
modalTitle.value = obj.value;
|
|
|
+ passWord.value = '';
|
|
|
modalIsShow.value = true;
|
|
|
};
|
|
|
|
|
@@ -573,13 +588,7 @@
|
|
|
};
|
|
|
|
|
|
function handleOk(e: MouseEvent) {
|
|
|
- if (passWord.value !== '123456') {
|
|
|
- message.warning('密码不正确,请重新输入');
|
|
|
- return;
|
|
|
- }
|
|
|
-
|
|
|
const handType = modalType.value;
|
|
|
- const frequency = frequencyVal.value;
|
|
|
const data = {
|
|
|
deviceid: selectData.deviceID,
|
|
|
devicetype: 'fanlocal_systeml_zj',
|
|
@@ -591,57 +600,78 @@
|
|
|
|
|
|
// 启动风机
|
|
|
if (mainWindIsShow1.value === 'open' && mainWindIsShow2.value === 'stop') {
|
|
|
- playSmoke(handType, 'top', frequency, 'open');
|
|
|
+ // playSmoke(handType, 'top', frequency, 'open');
|
|
|
data.paramcode = 'CtrlFan1Start';
|
|
|
deviceControlApi(data).then((res) => {
|
|
|
console.log('设备操作结果', res);
|
|
|
+ modalTitle.value = '';
|
|
|
+ modalIsShow.value = false;
|
|
|
+ }).catch((err) => {
|
|
|
+
|
|
|
});
|
|
|
} else if (mainWindIsShow2.value === 'open' && mainWindIsShow1.value === 'stop') {
|
|
|
- playSmoke(handType, 'down', frequency, 'open');
|
|
|
+ // playSmoke(handType, 'down', frequency, 'open');
|
|
|
data.paramcode = 'CtrlFan2Start';
|
|
|
deviceControlApi(data).then((res) => {
|
|
|
console.log('设备操作结果', res);
|
|
|
+ modalTitle.value = '';
|
|
|
+ modalIsShow.value = false;
|
|
|
+ }).catch((err) => {
|
|
|
+
|
|
|
});
|
|
|
} else if (mainWindIsShow1.value === 'stop' && mainWindIsShow2.value === 'stop') {
|
|
|
- playSmoke(handType, '', frequency, 'stop');
|
|
|
+ // playSmoke(handType, '', frequency, 'stop');
|
|
|
}
|
|
|
- } else if (handType === 'frequency') {
|
|
|
+ } else if (handType === 'Fan1Frequency' || handType === 'Fan2Frequency') {
|
|
|
// 调频
|
|
|
- playSmoke(handType, 'top', frequency, '');
|
|
|
- if (mainWindIsShow1.value === 'open') {
|
|
|
- data.paramcode = 'Fan1FreqHz';
|
|
|
- } else if (mainWindIsShow2.value === 'open') {
|
|
|
- data.paramcode = 'Fan2FreqHz';
|
|
|
+ // playSmoke(handType, 'top', fan1FrequencyVal, '');
|
|
|
+ if (handType === 'Fan1Frequency') {
|
|
|
+ data.paramcode = 'Fan1fHz';
|
|
|
+ data.value = fan1FrequencyVal.value;
|
|
|
+ } else if (handType === 'Fan2Frequency') {
|
|
|
+ data.paramcode = 'Fan2fHz';
|
|
|
+ data.value = fan2FrequencyVal.value;
|
|
|
}
|
|
|
- data.value = frequency;
|
|
|
+
|
|
|
deviceControlApi(data).then((res) => {
|
|
|
console.log('设备操作结果', res);
|
|
|
+ modalTitle.value = '';
|
|
|
+ modalIsShow.value = false;
|
|
|
+ }).catch((err) => {
|
|
|
+
|
|
|
});
|
|
|
} else if (handType === 'changeSmoke') {
|
|
|
|
|
|
// 一键倒机
|
|
|
if (mainWindIsShow1.value === 'open' && mainWindIsShow2.value === 'stop') {
|
|
|
- playSmoke('startSmoke', 'down', frequency, 'open');
|
|
|
+ // playSmoke('startSmoke', 'down', frequency, 'open');
|
|
|
data.paramcode = 'fanRun2';
|
|
|
deviceControlApi(data).then((res) => {
|
|
|
console.log('设备操作结果', res);
|
|
|
+ modalTitle.value = '';
|
|
|
+ modalIsShow.value = false;
|
|
|
+ }).catch((err) => {
|
|
|
+
|
|
|
});
|
|
|
mainWindIsShow1.value = 'stop';
|
|
|
mainWindIsShow2.value = 'open';
|
|
|
} else if (mainWindIsShow2.value === 'open' && mainWindIsShow1.value === 'stop') {
|
|
|
- playSmoke('startSmoke', 'top', frequency, 'open');
|
|
|
+ // playSmoke('startSmoke', 'top', frequency, 'open');
|
|
|
data.paramcode = 'fanRun1';
|
|
|
deviceControlApi(data).then((res) => {
|
|
|
console.log('设备操作结果', res);
|
|
|
+ modalTitle.value = '';
|
|
|
+ modalIsShow.value = false;
|
|
|
+ }).catch((err) => {
|
|
|
+
|
|
|
});
|
|
|
mainWindIsShow1.value = 'open';
|
|
|
mainWindIsShow2.value = 'stop';
|
|
|
} else if (mainWindIsShow1.value === 'stop' && mainWindIsShow2.value === 'stop') {
|
|
|
- playSmoke(handType, '', frequency, 'stop');
|
|
|
+ // playSmoke(handType, '', frequency, 'stop');
|
|
|
}
|
|
|
}
|
|
|
- modalTitle.value = '';
|
|
|
- modalIsShow.value = false;
|
|
|
+
|
|
|
};
|
|
|
|
|
|
function handleChangeSensor(value: string){
|
|
@@ -667,7 +697,7 @@
|
|
|
await getMonitor(true);
|
|
|
|
|
|
addCssText();
|
|
|
- playSmoke('startSmoke', 'top', frequencyVal.value, 'open');
|
|
|
+ // playSmoke('startSmoke', 'top', frequencyVal.value, 'open');
|
|
|
});
|
|
|
});
|
|
|
document.body.addEventListener('mousedown', addPlayVideo, false);
|