更新实时轨迹2

master
tangwenkang 2023-12-03 14:32:13 +08:00
parent f3d20ec9d6
commit 4e8bb66df8
1 changed files with 10 additions and 6 deletions

View File

@ -253,8 +253,18 @@ export default {
this.getList()
this.listCarType()
this.listFence()
this.realMsg()
},
methods: {
realMsg(){
setInterval(() => {
//
listRealTime(this.vin).then(res=>{
this.lineArr.push(res.longitude.replace(/"/g, "") +","+res.latitude.replace(/"/g, ""))
})
}, 1000); //
},
/*重置表单*/
resetForm() {
this.form = { // form
@ -308,12 +318,6 @@ export default {
this.isList = true
this.initMap()
this.startAnimation()
setInterval(() => {
//
listRealTime(this.vin).then(res=>{
this.lineArr.push(res.longitude.replace(/"/g, "") +","+res.latitude.replace(/"/g, ""))
})
}, 1000); //
},
/*刷新*/
refreshTable(){