diff --git a/src/views/map/map.vue b/src/views/map/map.vue
index 36916a9..8646493 100644
--- a/src/views/map/map.vue
+++ b/src/views/map/map.vue
@@ -21,7 +21,7 @@
:zoom="16">
-
+
@@ -86,11 +86,18 @@ export default {
popupVisible: false,
n:10,
setTimeoutTimer:'',
- latitude:'',
- longitude:'',
+ latitude:'39.91092455',
+ longitude:'116.41338370',
name:'',
idleberths:'',
- julis:''
+ julis:'',
+ labelShow: false,
+ labelContent:'',
+ position:{
+ latitude:'39.91092455',
+ longitude:'116.41338370',
+ bgcolor: '#f00'
+ }
}
},
methods: {
@@ -158,7 +165,24 @@ export default {
this.latitude = datas.latitude
this.longitude = datas.longitude
+ this.position.latitude = datas.latitude
+ this.position.longitude = datas.longitude
this.idleberths = datas.idleberths
+ this.labelContent = datas.idleberths
+ if(datas.idleberths>10){
+ this.position.bgcolor = '#0f0'
+ }else if(datas.idleberths<=10&&datas.idleberths>0){
+ this.position.bgcolor = '#ff9e04'
+ }else if(datas.idleberths<=0){
+ this.position.bgcolor = '#f00'
+ }else{
+ this.position.bgcolor = '#0f0'
+ }
+
+
+
+
+
this.julis = this.dis
})
},
diff --git a/src/views/map/search.vue b/src/views/map/search.vue
index 61fbc66..3681aff 100644
--- a/src/views/map/search.vue
+++ b/src/views/map/search.vue
@@ -82,7 +82,7 @@ export default {
tzmap: function (i) {
console.log(i)
this.$router.push({
- name:'map',
+ path:'map',
query:{
name: i.name,
lng:i.longitude,