|
@@ -1,10 +1,9 @@
|
|
|
<template>
|
|
|
<view>
|
|
|
- <view class="timeBox flex justify-between align-center padding-lr-sm">
|
|
|
+ <view class="timeBox flex justify-between align-center padding-lr-sm">
|
|
|
<view class="time">2021-01-18 15:16:45</view>
|
|
|
<button class="cu-btn radius bg-red sm">未处理</button>
|
|
|
</view>
|
|
|
-
|
|
|
<view>
|
|
|
<view class="basic-info">
|
|
|
<view class="info-tit margin-left-xs">
|
|
@@ -14,60 +13,55 @@
|
|
|
<view class="info-content">
|
|
|
<view class="info-one-info ">
|
|
|
<text>设备名称:</text>
|
|
|
- <text>三楼赛特威尔测试烟感二</text>
|
|
|
+ <text>{{getData.device_name}}</text>
|
|
|
</view>
|
|
|
|
|
|
<view>
|
|
|
<text>设备地址:</text>
|
|
|
- <text>上海市青浦区徐泾镇徐乐路208号</text>
|
|
|
+ <text>{{getData.unitinfo}}</text>
|
|
|
</view>
|
|
|
<view>
|
|
|
<text>告警信息:</text>
|
|
|
- <text>烟雾拆卸报警</text>
|
|
|
+ <text>{{getData.alarm_information}}</text>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
- <!-- 处理状态start -->
|
|
|
+
|
|
|
+ <!-- 处理内容start -->
|
|
|
<view class="processStatus">
|
|
|
<view class="info-tit margin-left-xs">
|
|
|
<text class="cuIcon-titles margin-right-xs"></text>
|
|
|
处理内容
|
|
|
</view>
|
|
|
-
|
|
|
+
|
|
|
<view class="padding-lr padding-bottom-lg">
|
|
|
<form action="">
|
|
|
-
|
|
|
- <radio-group name="gender" class="">
|
|
|
+ <radio-group name="gender" class="" @change="RadioChange">
|
|
|
<label class="margin-right">
|
|
|
- <radio value="单个处理" checked /><text>单个处理</text>
|
|
|
+ <radio value="0" checked /><text>单个处理</text>
|
|
|
</label>
|
|
|
<label>
|
|
|
- <radio value="批量处理" /><text>批量处理</text>
|
|
|
+ <radio value="1" /><text>批量处理</text>
|
|
|
</label>
|
|
|
</radio-group>
|
|
|
-
|
|
|
<view class="cu-form-group">
|
|
|
-
|
|
|
- <textarea class="JTxtArea lg"
|
|
|
- :maxlength="50"
|
|
|
- :data-maxnum="reason.length+'/50'" placeholder="备注信息,最多可输入50个字..."
|
|
|
- auto-height
|
|
|
- @input="inputReason"
|
|
|
- :value="reason"></textarea>
|
|
|
-
|
|
|
+ <textarea class="JTxtArea lg" :maxlength="50" :data-maxnum="reason.length+'/50'"
|
|
|
+ placeholder="备注信息,最多可输入50个字..." auto-height v-model="msg" @input="inputReason"
|
|
|
+ :value="reason"></textarea>
|
|
|
+
|
|
|
</view>
|
|
|
<view class="btn-area">
|
|
|
- <button class="bg-orange round missReport margin-top" @click="videoMissSubmit()">误 报 </button>
|
|
|
- <button class="bg-blue round missReport margin-top " @click="videoSubmit()">非 误 报 </button>
|
|
|
+ <button class="bg-orange round missReport margin-top" @click="alarmSubmit(1)">误 报
|
|
|
+ </button>
|
|
|
+ <button class="bg-blue round missReport margin-top " @click="alarmSubmit(0)">非 误 报 </button>
|
|
|
</view>
|
|
|
</form>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <!-- 处理状态end -->
|
|
|
+ <!-- 处理内容end -->
|
|
|
</view>
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
+
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
@@ -75,106 +69,122 @@
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
- radio: 'A',
|
|
|
- radio: 'B',
|
|
|
modalName: null,
|
|
|
reason: '',
|
|
|
- type: '0',
|
|
|
- detailMessage: {},
|
|
|
- detailMessage2: {},
|
|
|
+ type: 1,
|
|
|
msg: '',
|
|
|
- msg2: '',
|
|
|
- flag:false,
|
|
|
- companyCode:0
|
|
|
-
|
|
|
+ getData: {},
|
|
|
+ radioOne: 0,
|
|
|
}
|
|
|
},
|
|
|
onLoad: function(option) {
|
|
|
-
|
|
|
-
|
|
|
+ this.type = option.type;
|
|
|
+ this.getDetailData({
|
|
|
+ "type": option.type,
|
|
|
+ "id": option.id
|
|
|
+ })
|
|
|
},
|
|
|
methods: {
|
|
|
+ async getDetailData(params = {}) {
|
|
|
+ const res = await this.$myRequest({
|
|
|
+ url: 'ComprehensiveAlarm/getAlarmDetails',
|
|
|
+ data: params,
|
|
|
+ showLoading: true
|
|
|
+ })
|
|
|
+ this.getData = res.data.data[0];
|
|
|
+ console.log(this.getData)
|
|
|
+ },
|
|
|
+
|
|
|
async powerSubmitRes(params = {}) {
|
|
|
const res = await this.$myRequest({
|
|
|
- url: 'IntegratedAlarm/setAlarmHandle',
|
|
|
+ url: 'ComprehensiveAlarm/setAlarmHandling',
|
|
|
data: params
|
|
|
- })
|
|
|
-
|
|
|
- if(res.data.flag){
|
|
|
- uni.showToast({
|
|
|
- title: "提交成功",
|
|
|
- });
|
|
|
- }
|
|
|
-
|
|
|
- setTimeout(() => {
|
|
|
- uni.navigateTo({
|
|
|
- url: '/pages/processList/processList?companyCode=' + this.companyCode + '&type='+this.type+'',
|
|
|
- });
|
|
|
- }, 1000);
|
|
|
-
|
|
|
-
|
|
|
- },
|
|
|
- videoSubmit() {
|
|
|
- if(!this.msg2){
|
|
|
- uni.showToast({
|
|
|
- title: "请输入处理内容",
|
|
|
- icon:"none"
|
|
|
- });
|
|
|
- }else{
|
|
|
- this.powerSubmitRes({
|
|
|
- "alarmStatus": 0,
|
|
|
- "type": 2,
|
|
|
- "deviceCode": this.detailMessage2.deviceCode,
|
|
|
- "companyCode": this.companyCode,
|
|
|
- "id": this.detailMessage2.id,
|
|
|
- "handlerContent": this.msg2
|
|
|
- })
|
|
|
-
|
|
|
+ })
|
|
|
+ if (res.data.flag) {
|
|
|
+ uni.showToast({
|
|
|
+ title: "提交成功",
|
|
|
+ });
|
|
|
+ setTimeout(() => {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: '/pages/processList/processList?type=' + this.type,
|
|
|
+ });
|
|
|
+ }, 1000);
|
|
|
}
|
|
|
+ },
|
|
|
|
|
|
+
|
|
|
+ //拼接公共搜索条件
|
|
|
+ // getSearchParamObj() {
|
|
|
+ // let queryParam = {};
|
|
|
+ // queryParam.id=this.getData.id;
|
|
|
+ // return queryParam;
|
|
|
|
|
|
- },
|
|
|
- videoMissSubmit() {
|
|
|
- if(!this.msg2){
|
|
|
- uni.showToast({
|
|
|
- title: "请输入处理内容",
|
|
|
- icon:"none"
|
|
|
- });
|
|
|
- }else{
|
|
|
- this.powerSubmitRes({
|
|
|
- "alarmStatus": 1,
|
|
|
- "type": 2,
|
|
|
- "deviceCode": this.detailMessage2.deviceCode,
|
|
|
- "companyCode": this.companyCode,
|
|
|
- "id": this.detailMessage2.id,
|
|
|
- "handlerContent": this.msg2
|
|
|
- })
|
|
|
- }
|
|
|
- },
|
|
|
+
|
|
|
+ // },
|
|
|
|
|
|
- submit() {
|
|
|
- uni.makePhoneCall({
|
|
|
- phoneNumber: '15122423833' //仅为示例
|
|
|
- });
|
|
|
- },
|
|
|
+ alarmSubmit(query) {
|
|
|
+ if (!this.msg) {
|
|
|
+ uni.showToast({
|
|
|
+ title: "请输入处理内容",
|
|
|
+ icon: "none"
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+
|
|
|
+ let queryParam = {};
|
|
|
+ queryParam.id=this.getData.id;
|
|
|
+ queryParam.type=this.getData.dwtype;
|
|
|
+ queryParam.device_code=this.getData.device_code;
|
|
|
+ queryParam.if_batch=this.radioOne;
|
|
|
+ queryParam.clwb=query;
|
|
|
+ queryParam.ncmb=this.getData.ncmd;
|
|
|
+ queryParam.clnr=this.msg;
|
|
|
+
|
|
|
+ if (this.getData.dwtype == 1) {
|
|
|
+ queryParam.data3=this.getData.data3;
|
|
|
+ queryParam.data5=this.getData.data5;
|
|
|
+ this.powerSubmitRes(queryParam)
|
|
|
+ }
|
|
|
+ if (this.getData.dwtype == 2||this.getData.dwtype == 7) {
|
|
|
+ queryParam.data1=this.getData.data1;
|
|
|
+ this.powerSubmitRes(queryParam)
|
|
|
+ }
|
|
|
+ if (this.getData.dwtype == 3) {
|
|
|
+ queryParam.data2=this.getData.data2;
|
|
|
+ this.powerSubmitRes(queryParam)
|
|
|
+ }
|
|
|
+ if (this.getData.dwtype == 6) {
|
|
|
+ queryParam.data2=this.getData.data2;
|
|
|
+ queryParam.data4=this.getData.data4;
|
|
|
+ this.powerSubmitRes(queryParam)
|
|
|
+ }
|
|
|
+ if (this.getData.dwtype == 2) {
|
|
|
+ queryParam.data1=this.getData.data1;
|
|
|
+ this.powerSubmitRes(queryParam)
|
|
|
+ }
|
|
|
+ if (this.getData.dwtype == 2) {
|
|
|
+ queryParam.data1=this.getData.data1;
|
|
|
+ this.powerSubmitRes(queryParam)
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
RadioChange(e) {
|
|
|
- this.radio = e.detail.value
|
|
|
+ this.radioOne = e.detail.value;
|
|
|
+ console.log(this.radioOne)
|
|
|
},
|
|
|
textareaAInput(e) {
|
|
|
this.textareaAValue = e.detail.value
|
|
|
},
|
|
|
- // textarea
|
|
|
inputReason(e) {
|
|
|
this.reason = e.detail.value;
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
}
|
|
|
}
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss">
|
|
|
-
|
|
|
+
|
|
|
</style>
|