From 8a84c8e9e646f234006c6bbf4607776a4c4ed6b4 Mon Sep 17 00:00:00 2001 From: hanbaoshan <hanbaoshan@aiotlink.com> Date: 星期二, 29 十二月 2020 19:16:05 +0800 Subject: [PATCH] 轨迹图查询条件判空处理 --- src/pages/panoramicView/components/TracePlot.vue | 20 +++++++++++++++----- 1 files changed, 15 insertions(+), 5 deletions(-) diff --git a/src/pages/panoramicView/components/TracePlot.vue b/src/pages/panoramicView/components/TracePlot.vue index a422c66..9ee705b 100644 --- a/src/pages/panoramicView/components/TracePlot.vue +++ b/src/pages/panoramicView/components/TracePlot.vue @@ -15,7 +15,7 @@ </div> <div class="check-target" :style="{height:fixedH+'px'}"> <div class="controller"> - <el-checkbox v-model="isHideAll" @change="hideAllChange">闅愯棌鍏ㄩ儴</el-checkbox> + <!-- <el-checkbox v-model="isHideAll" @change="hideAllChange">闅愯棌鍏ㄩ儴</el-checkbox> --> <el-checkbox v-model="isInvert" @change="invertChange">鍙嶉��</el-checkbox> </div> <div class="target-list"> @@ -65,6 +65,7 @@ //this.$moment().format("YYYY-MM-DD HH:mm:ss") ], timer: null, + intervalTime: 5000, colorArr: ['#F4DA40', '#0092BC', '#97D700', '#D0006F', '#D86018', '#653279', '#A45A2A', '#004B87', '#008C95', '#AA0061'], searchStartTimeStamp: 0, searchEndTimeStamp: 0, @@ -80,9 +81,7 @@ mounted () { this.searchData(); this.getPanorama(); - this.timer = setInterval(() => { - this.searchData(); - }, 7000); + }, beforeDestroy () { console.log('beforeDestroy') @@ -190,6 +189,14 @@ // } }, searchData () { + if(!this.searchTime){ + this.$notify({ + type:'warning', + message:'璇烽�夋嫨鏃堕棿!' + }); + clearInterval(this.timer); + return; + } let _this = this; var param = { page: 1, @@ -278,7 +285,10 @@ }) } console.log(new Date().getTime(), _this.actObj) - _this.drawTracePath() + _this.drawTracePath(); + _this.timer = setTimeout(()=>{ + _this.searchData() + },_this.intervalTime) }) } } -- Gitblit v1.8.0