@@ -188,6 +203,7 @@ import {
getScheduleRulelAccessList,
selectPhotoTimeGetJoggle,
selectPhotoTimeJoggle,
+ getPhotoTimeJoggle,
} from "@/utils/api/index";
export default {
props: {
@@ -195,7 +211,7 @@ export default {
},
data() {
return {
- loading: true,
+ loading: false,
isShow: false,
isShowset: false,
activeName: "1", //选项卡
@@ -244,12 +260,13 @@ export default {
this.accesslist = res.data.list;
console.log(this.accesslist);
this.selaccess = res.data.list[0].channelid;
- this.inquirebtn();
+ this.inquireRealbtn();
})
.catch((err) => {});
},
- //查询时间表
- inquirebtn() {
+ //changeSelect\选择通道
+ changeSelect() {
+ console.log(this.selaccess);
this.loading = true;
getSchedulenr({
channelid: this.selaccess,
@@ -265,8 +282,10 @@ export default {
this.$message.error("查询失败");
});
},
+ //查询时间表
+
//查询真是时间时间表
- inquireRealbtn() {
+ inquirebtn() {
console.log(this.selaccess, this.selfacilityId, this.newcmdzzid);
this.timeloading = true;
selectPhotoTimeGetJoggle({
@@ -278,11 +297,7 @@ export default {
this.$message.success("查询成功");
console.log(this.shedulenr);
this.newrequestId = res.data.requestId;
- // this.searchRealtime();
this.searchRealtime();
- this.timer = window.setInterval(() => {
- this.searchRealtime();
- }, 10000);
})
.catch((err) => {
this.$message.error("查询失败");
@@ -296,14 +311,28 @@ export default {
requestId: this.newrequestId,
}).then((res) => {
console.log(res);
- if (res.data.isNew == true) {
- this.shedulenr = res.data.list;
+ if (res.data.isNew == true && this.timernum < 10) {
+ clearInterval(this.timer);
+ this.timer = null;
+ this.inquirebtn();
+ this.timernum = 0;
+ } else if (res.data.isNew == false && this.timernum > 10) {
+ this.i = 0;
+ clearInterval(this.timer);
+ this.timer = null;
this.$message({
- message: "装置信息已更新",
- type: "success",
+ message: "时间表查询无响应,请稍后再试!",
+ type: "warning",
});
- clearInterval(this.timer);
}
+ // if (res.data.isNew == true) {
+ // this.shedulenr = res.data.list;
+ // this.$message({
+ // message: "装置信息已更新",
+ // type: "success",
+ // });
+ // clearInterval(this.timer);
+ // }
});
},
@@ -405,11 +434,11 @@ export default {
// 保存确定操作
submitForm() {
//this.getCheckedNodes();
- console.log("111111111111111111111");
+
console.log(this.deviceListData);
console.log(this.checkList);
console.log(this.scheduleid);
- console.log("22222222222222222");
+
if (this.checkList.length == 0) {
this.$message.error("请选择通道");
} else {
@@ -424,10 +453,12 @@ export default {
})
.then((res) => {
this.isShowset = false;
- this.$message.success("添加成功");
+ console.log(res);
+ //this.$message.success("添加成功");
console.log(this.checkList);
- this.$store.commit("SET_CHANNELID", this.checkList); //将通道保存在vuex中
- this.$store.commit("SET_TERMID", this.deviceListData.zzid); //将装置保存在vuex中
+ // this.$store.commit("SET_CHANNELID", this.checkList); //将通道保存在vuex中
+ // this.$store.commit("SET_TERMID", this.deviceListData.zzid); //将装置保存在vuex中
+ this.handlexfTime(this.deviceListData.zzid, this.checkList);
this.deviceList();
})
.catch((err) => {
@@ -435,6 +466,24 @@ export default {
});
}
},
+ //下发时间表
+ handlexfTime(termid, channelid) {
+ console.log("下发时间表");
+ console.log(termid);
+ console.log(channelid);
+ console.log("下发时间表结束");
+ getPhotoTimeJoggle({
+ channel: channelid,
+ termId: termid,
+ })
+ .then((res) => {
+ console.log(res);
+ if (res.code == 200) {
+ this.$message.success("拍照时间表设置下发成功");
+ }
+ })
+ .catch((err) => {});
+ },
closebtn() {
this.isShowset = false;
clearInterval(this.timer);
@@ -462,6 +511,10 @@ export default {
height: calc(100% - 16px);
}
}
+ .timebox {
+ //width: 410px;
+ margin: auto;
+ }
.flexonly {
display: flex;
flex-wrap: wrap;
@@ -469,8 +522,29 @@ export default {
}
.flexno {
display: flex;
- margin-top: 24px;
+ margin-top: 16px;
padding: 0px 8px;
+ flex-direction: column;
+ height: 294px;
+ .timehead {
+ display: flex;
+
+ line-height: 32px;
+ margin-bottom: 8px;
+ label {
+ margin-right: 6px;
+ width: 80px;
+ }
+ }
+ .timeShow {
+ display: flex;
+ }
+ }
+ .searchBtn {
+ font-size: 14px;
+ text-decoration-line: underline;
+ display: flex;
+ margin-left: auto;
}
.flexnr {
display: flex;
@@ -485,19 +559,18 @@ export default {
margin-right: 10px;
}
.w8 {
- width: 8%;
+ width: 80px;
+ margin-bottom: 8px;
}
.w80 {
- width: 90%;
+ width: 80%;
overflow-y: auto;
- height: 300px;
+ height: 250px;
}
.mr20 {
margin-right: 20px;
}
- .bt30 {
- margin-bottom: 30px;
- }
+
.deviceTable {
padding: 16px 8px 0 8px;
height: calc(100% - 16px);
diff --git a/src/views/realTimeMonitor/index.vue b/src/views/realTimeMonitor/index.vue
index db5f249..86bdfa2 100644
--- a/src/views/realTimeMonitor/index.vue
+++ b/src/views/realTimeMonitor/index.vue
@@ -54,7 +54,7 @@
>
-
+
选择通道监拍点
操作项
- 拍照时间表
-
-
+
主动拍照
@@ -118,7 +114,7 @@
-
+
主动录像
@@ -140,6 +136,9 @@
装置信息
+ 拍照时间表