先拓企业站
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

34 lines
605 B

<script>
import commonMixin from '../base/mixins/common.js'
export default {
name: 'bm-triffic',
render (h) {},
mixins: [commonMixin('layer')],
props: {
predictDate: {
type: Object
}
},
watch: {
'pridictDate.weekday' () {
this.reload()
},
'pridictDate.hour' () {
this.reload()
},
pridictDate () {
this.reload()
}
},
methods: {
load () {
const {pridictDate, BMap, map} = this
this.originInstance = new BMap.TrafficLayer({
pridictDate
})
map.addTileLayer(this.originInstance)
}
}
}
</script>