diff --git a/src/views/vehicle/car.vue b/src/views/vehicle/car.vue
index aabf8fa..1be1236 100644
--- a/src/views/vehicle/car.vue
+++ b/src/views/vehicle/car.vue
@@ -4,6 +4,7 @@
返回
+ {{msg}}
@@ -203,6 +204,7 @@ export default {
},
data() {
return {
+ vinId:null,
carList:[],
total:0,
form:{
@@ -244,6 +246,8 @@ export default {
marker: null,
lineArr: [],
vin:null,
+ carMsg:[],
+ vehicle:null
};
},
mounted() {
@@ -253,12 +257,13 @@ export default {
this.getList()
this.listCarType()
this.listFence()
+ this.vehicle = setInterval(this.listRealTime,1000)
},
methods: {
// 在这里执行后台拉取数据的操作
listRealTime(){
listRealTime(this.vin).then(res=>{
-
+ this.carMsg.push(res.data)
})
},
/*重置表单*/
@@ -305,6 +310,7 @@ export default {
},
/*地图展示*/
realTimeTrajectory(carVin){
+ this.vinId = carVin
this.vin = carVin
realTime(this.vin).then(res=>{
if(res.code !== 200){
@@ -315,6 +321,7 @@ export default {
this.isShow = false
this.isList = true
this.initMap()
+ alert(this.vinId)
this.startAnimation()
},
/*刷新*/