代码优化
This commit is contained in:
parent
1b71e843bf
commit
a80ee2ebea
|
|
@ -178,8 +178,8 @@
|
|||
<el-option
|
||||
v-for="item in options"
|
||||
:key="item.value"
|
||||
:label="item.iotTypeId + ''"
|
||||
:value="item.iotTypeName"
|
||||
:value="item.iotTypeId + ''"
|
||||
:label="item.iotTypeName"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
|
|
|||
|
|
@ -94,7 +94,9 @@
|
|||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<template v-else> 暂无数据 </template>
|
||||
<template v-else>
|
||||
{{ loadingData ? '数据加载中...' : 暂无数据 }}
|
||||
</template>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="停留点">
|
||||
<template v-if="parkList.length > 0">
|
||||
|
|
@ -222,18 +224,20 @@ export default {
|
|||
activeIndex: '',
|
||||
// 停留点信息
|
||||
parkList: [],
|
||||
warningList: [],
|
||||
loadingData: true,
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.handleQuery()
|
||||
},
|
||||
created() {},
|
||||
mounted() {
|
||||
Promise.all([this.getIotDeviceLocation()])
|
||||
Promise.all([this.getIotDeviceLocation(), this.handleQuery()])
|
||||
.then((res) => {
|
||||
this.loadingData = false
|
||||
this.initMap()
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err)
|
||||
this.loadingData = false
|
||||
})
|
||||
|
||||
// this.getIotDeviceLocation()
|
||||
|
|
@ -247,9 +251,12 @@ export default {
|
|||
this.trackAni.cancel()
|
||||
}
|
||||
// 2. 清除地图上面的标点覆盖物 并清除地图实例
|
||||
|
||||
if (this.map) {
|
||||
this.map.clearOverlays()
|
||||
this.map.destroy()
|
||||
this.map = null
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
|
|
@ -468,8 +475,10 @@ export default {
|
|||
},
|
||||
/** 时间选择器 */
|
||||
onChangeTime(val) {
|
||||
if (val) {
|
||||
this.tripParams.beginTime = val[0]
|
||||
this.tripParams.endTime = val[1]
|
||||
}
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ module.exports = {
|
|||
// target: `http://10.40.92.81:8080`, //韩/
|
||||
// target: `http://192.168.2.81:28080`,//旭/
|
||||
// target: `http://192.168.2.248:28080`, //帅
|
||||
target: `http://192.168.2.246:49080`, //福
|
||||
target: `http://192.168.2.225:49080`, //福
|
||||
|
||||
//******** 注意事项 ********* */
|
||||
//1.全局替换qrUrl二维码扫码提供的网址-发布服务器的地址target;
|
||||
|
|
|
|||
Loading…
Reference in New Issue