优化点击获取图片

jc
fanluyan 1 year ago
parent 0117821a72
commit 10cd00ab87

@ -78,3 +78,6 @@
.el-image-viewer__actions {
background: rgba(0, 0, 0, 0.15);
}
.el-form-item__label{
padding: 0 6px 0 0;
}

@ -68,7 +68,7 @@
<div class="paramsDate setTimebtn">
<h3>操作项</h3>
<div class="buttonGroup">
<takePicButton v-if="showButton('pzShowBtn')"></takePicButton>
<takePicButton v-if="showButton('pzShowBtn')" ref="takepicRef"></takePicButton>
<takeVideoButton v-if="showButton('spShowBtn')"></takeVideoButton>
<deviceInfoButton></deviceInfoButton>
<scheduleButton v-if="showButton('pztimeShowBtn')"></scheduleButton>
@ -292,6 +292,10 @@ export default {
this.getDateTime();
},
methods: {
takepicFun(){
console.log("点击了我自己,准备取消轮巡")
this.$refs.takepicRef.clearFn();
},
//
showButton(key) {
if (this.roleUser !== "0") {

@ -203,10 +203,17 @@
<el-button
type="primary"
:disabled="channelsetLoading"
@click="handleConfim(true)"
:loading="channelLoading"
@click="handleConfim(false)"
> </el-button
> <el-button
type="primary"
:disabled="channelsetLoading"
@click="handleConfim(true)"
>保存并关闭</el-button
>
<!-- :loading="channelLoading" -->
</div>
</el-dialog>
</template>
@ -532,7 +539,8 @@ export default {
}
this.searchBtn();
},
handleConfim() {
handleConfim(flag) {
console.log("点击了确定");
console.log(this.channelForm);
@ -727,7 +735,7 @@ export default {
{ name: "type21", value: 0 },
];
console.log(params);
this.setTermFn(params);
this.setTermFn(params,flag);
} else {
this.$message({
duration: 1500,
@ -738,7 +746,7 @@ export default {
}
});
},
setTermFn(val) {
setTermFn(val,flag) {
setTermCamera({
termId: this.areaData.id,
list: val,
@ -747,16 +755,17 @@ export default {
console.log(res);
this.requestid = res.data.requestId;
this.getTakechannelStatus();
this.getTakechannelStatus(flag);
clearInterval(this.setTimer);
this.setTimer = window.setInterval(() => {
this.getTakechannelStatus();
this.getTakechannelStatus(flag);
this.setNum++;
}, 1000);
})
.catch((err) => {});
},
getTakechannelStatus() {
getTakechannelStatus(flag) {
console.log("aaaaaaaaaaaaaaaaaaaaaa",flag)
getTermCameraRequest({ requestid: this.requestid })
.then((res) => {
console.log(res);
@ -764,6 +773,10 @@ export default {
window.clearInterval(this.setTimer);
this.setTimer = null;
this.setNum = 0;
if(flag){
this.isShow = false;
}
//this.isShow = false;
this.channelLoading = false;
this.$message({
@ -774,6 +787,9 @@ export default {
});
} else if (this.setNum > 3) {
// this.isShow = false;
if(flag){
this.isShow = false;
}
window.clearInterval(this.setTimer);
this.setTimer = null;
this.setNum = 0;
@ -1050,6 +1066,7 @@ export default {
.el-slider {
width: 200px;
margin-right: 12px;
margin-left: 10px;
.el-slider__runway {
height: 8px;
margin: 12px 0;

@ -329,6 +329,7 @@ export default {
this.$store.commit("protocol", this.currentData.protocol); //currentDatavuex
this.$store.commit("cmdId", this.currentData.cmdid); //currentDatavuex
this.$parent.getCurrentData();
//this.$refs.tree.scrollTo(data);
// localStorage.setItem("currentData", JSON.stringify(this.currentData));
},

@ -246,6 +246,7 @@ export default {
new Date(val.date).getTime(),
this.termId
); // id termid
this.$message({
duration: 1500,
showClose: true,
@ -264,10 +265,15 @@ export default {
});
},
clearFn() {
console.log("我要取消了轮巡")
clearInterval(this.statusTimer);
this.statusTimer = null;
this.statusNum = 0;
this.picLoading = false;
console.log("我要取消了轮巡1111111111111111111111111111111")
clearInterval(this.picPimer);
this.picPimer = null;
this.picNum = 0;
},
},
destroyed() {

@ -120,13 +120,13 @@ export default {
console.log("杆塔");
this.LineFlag = false;
this.towerFlag = true;
this.terminalPhoto = [];
this.protocolInfo = this.treeSelectData.protocol;
console.log("asddddddddddddddddddddd", this.treeSelectData);
this.towertitle = this.treeSelectData.name;
this.$nextTick(() => {
this.$refs.areaRef.getChannelList();
this.$refs.areaRef.takepicFun();
});
}
},

Loading…
Cancel
Save