|
@@ -149,9 +149,10 @@
|
|
|
</video>
|
|
|
</view>
|
|
|
<view class="bottom-button-box">
|
|
|
- <view @click="shadeTypeClick()">语音广播</view>
|
|
|
- <view @click="evacuationButton(1)" v-if="isEvacuate">执行疏散</view>
|
|
|
- <view @click="evacuationButton(2)" v-if="!isEvacuate">结束疏散</view>
|
|
|
+ <view class="voice" @click="shadeTypeClick()">语音广播</view>
|
|
|
+ <view class="plan" v-if="planStatus" @click="closePlan()">结束预案</view>
|
|
|
+ <view class="evacuate" @click="evacuationButton(1)" v-if="isEvacuate">执行疏散</view>
|
|
|
+ <view class="evacuate" @click="evacuationButton(2)" v-if="!isEvacuate">结束疏散</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
<!-- 语音广播-->
|
|
@@ -218,7 +219,8 @@ import {
|
|
|
firedeviceStatus,
|
|
|
firedeviceStatusTiming,
|
|
|
firedeviceStart,
|
|
|
- firedeviceCancel
|
|
|
+ firedeviceCancel,
|
|
|
+ closeRiskPlan
|
|
|
} from '@/api/index.js'
|
|
|
import {
|
|
|
getBuildOrFloorList,
|
|
@@ -347,6 +349,8 @@ export default {
|
|
|
fireCode:null,// //灭火设备code
|
|
|
fireStartType:false, //灭火启动状态
|
|
|
outfireData: {}, //一键灭火
|
|
|
+ groupId:null,
|
|
|
+ planStatus:false,
|
|
|
}
|
|
|
},
|
|
|
onLoad(option) {
|
|
@@ -357,6 +361,7 @@ export default {
|
|
|
this.$set(this,'floorId',obj.floorId);
|
|
|
this.$set(this,'subId',obj.subId);
|
|
|
this.$set(this.itemData,'subjectId',obj.subId);
|
|
|
+ this.$set(this,'groupId',obj.groupId);
|
|
|
this.$set(this,'pageType',2);
|
|
|
this.confirmBtn();
|
|
|
this.riskPlanId(obj.groupId);
|
|
@@ -417,6 +422,33 @@ export default {
|
|
|
this.$set(this,'urlList',[]);
|
|
|
this.treeselectByUser();
|
|
|
},
|
|
|
+ //结束预案
|
|
|
+ closePlan(){
|
|
|
+ let self = this;
|
|
|
+ uni.showModal({
|
|
|
+ content: '传感器数据监测异常,确定要强制结束预案?关闭报警后,3分钟内系统不再触发预案报警,请核实确认后再执行此操作?',
|
|
|
+ cancelColor:"#999",
|
|
|
+ confirmColor:"#0183FA",
|
|
|
+ success: function (res) {
|
|
|
+ if (res.confirm) {
|
|
|
+ self.closeRiskPlan();
|
|
|
+ } else if (res.cancel) {
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ async closeRiskPlan(){
|
|
|
+ const {data} = await closeRiskPlan({id:this.groupId});
|
|
|
+ if(data.code == 200){
|
|
|
+ this.planStatus=false;
|
|
|
+ uni.showToast({
|
|
|
+ title: '操作成功',
|
|
|
+ icon:"none",
|
|
|
+ mask:true,
|
|
|
+ duration: 2000
|
|
|
+ });
|
|
|
+ }
|
|
|
+ },
|
|
|
//全屏疏散页面
|
|
|
goAllPage() {
|
|
|
let obj = {
|
|
@@ -681,6 +713,10 @@ export default {
|
|
|
for(let o=0;o<self.fjListArray.length;o++){
|
|
|
for(let i=0;i<data.data.length;i++){
|
|
|
if(data.data[i].subId == self.fjListArray[o].subId){
|
|
|
+ console.log('预案')
|
|
|
+ console.log(data.data[i])
|
|
|
+ self.planStatus=true;//如果有预案发生
|
|
|
+ self.$set(this,'groupId',data.data[i].groupId)
|
|
|
self.fjListArray[o].subName.replace('(预案发生)')
|
|
|
self.fjListArray[o].subName = '(预案发生) '+self.fjListArray[o].subName
|
|
|
}
|
|
@@ -1994,13 +2030,15 @@ export default {
|
|
|
font-size: 28rpx;
|
|
|
}
|
|
|
|
|
|
- view:nth-child(1) {
|
|
|
+ .voice {
|
|
|
border-top-left-radius: 50rpx;
|
|
|
border-bottom-left-radius: 50rpx;
|
|
|
background: #FF9C00;
|
|
|
}
|
|
|
-
|
|
|
- view:nth-child(2) {
|
|
|
+ .plan{
|
|
|
+ background: #21A743;
|
|
|
+ }
|
|
|
+ .evacuate{
|
|
|
border-top-right-radius: 50rpx;
|
|
|
border-bottom-right-radius: 50rpx;
|
|
|
background: #0183FA;
|