diff --git a/pages/maps/index.vue b/pages/maps/index.vue index 77352c4..f569ccb 100644 --- a/pages/maps/index.vue +++ b/pages/maps/index.vue @@ -187,26 +187,31 @@ monitorRender() {// 监测点位渲染 this.soilStationList.forEach((item, index) => { let iconPath = ''; - let width = 35; - let height = 35; + let width = 32; + let height = 47; // 根据设备类型设置不同的图标 - switch(item.type) { - case 'soil': - iconPath = this.baseUrl + '/icon/device/soil.png'; - width = 32; - height = 47; - break; - case 'camera': - iconPath = this.baseUrl + '/icon/device/cam.png'; - width = 45; - height = 45; - break; - default: - iconPath = this.baseUrl + '/icon/device/default.png'; - } + // switch(item.type) { + // case 'soil': + // iconPath = this.baseUrl + '/icon/device/soil.png'; + // width = 32; + // height = 47; + // break; + // case 'camera': + // iconPath = this.baseUrl + '/icon/device/cam.png'; + // width = 45; + // height = 45; + // break; + // case '10_flowmeter': + // iconPath = this.baseUrl + '/icon/device/liuliang.png'; + // width = 45; + // height = 45; + // break; + // default: + // iconPath = this.baseUrl + '/icon/device/default.png'; + // } const markerItem = { id: item.id, - iconPath: iconPath, + iconPath: this.baseUrl +'/' + item.mapIcon, latitude: Number(item.latitude), longitude: Number(item.longitude), width: width,