Jelajahi Sumber

Signed-off-by: 1004749546@qq.com <1004749546@qq.com>
首页修改

1004749546@qq.com 4 tahun lalu
induk
melakukan
1812a15c23
1 mengubah file dengan 10 tambahan dan 2 penghapusan
  1. 10 2
      pages/index/index.vue

+ 10 - 2
pages/index/index.vue

@@ -76,7 +76,7 @@
 						name: '洗车机',
 						name: '洗车机',
 						latitude: '34.29318',
 						latitude: '34.29318',
 						longitude: '118.94712',
 						longitude: '118.94712',
-						status: 1
+						status: 2
 					},
 					},
 					{
 					{
 						id: '11',
 						id: '11',
@@ -229,8 +229,16 @@
 			createMarker(point) {
 			createMarker(point) {
 				let latitude = point.latitude;
 				let latitude = point.latitude;
 				let longitude = point.longitude;
 				let longitude = point.longitude;
+				let iconPath = ''
+				if (point.status===0) {
+					iconPath = '/static/img/store-dky.png'
+				} else if (point.status===1) {
+					iconPath = '/static/img/store.png'
+				} else {
+					iconPath = '/static/img/store-zt.png'
+				}
 				let marker = {
 				let marker = {
-					iconPath: point.status ? "/static/img/store.png": '/static/img/store-zt.png',
+					iconPath: iconPath,
 					id: point.id || 0,
 					id: point.id || 0,
 					name: point.name || '',
 					name: point.name || '',
 					latitude: latitude,
 					latitude: latitude,