| | |
| | | map.addOverLay(countriesOverlay1) |
| | | countriesOverlay.bringToBack(); |
| | | }); |
| | | |
| | | //map.setStyle("indigo"); |
| | | } |
| | | |
| | | function init(sel, transform) { |
| | |
| | | } |
| | | //地图上展示项目点 |
| | | function showProjectPoint(data){ |
| | | var projectIcon = new T.Icon({ |
| | | iconUrl: '/bjfw/images/icon/6.png', |
| | | iconSize: new T.Point(30, 30), |
| | | iconAnchor: new T.Point(6, 40), |
| | | }); |
| | | var projectIcon ; |
| | | for(let i =0;i<data.length;i++){ |
| | | if (data[i].status === '1'){ |
| | | projectIcon = new T.Icon({ |
| | | iconUrl: '/bjfw/images/icon/yellow.png', |
| | | iconSize: new T.Point(30, 30), |
| | | iconAnchor: new T.Point(6, 40), |
| | | }); |
| | | }else if (data[i].status === '2'){ |
| | | projectIcon = new T.Icon({ |
| | | iconUrl: '/bjfw/images/icon/blue.png', |
| | | iconSize: new T.Point(30, 30), |
| | | iconAnchor: new T.Point(6, 40), |
| | | }); |
| | | }else { |
| | | projectIcon = new T.Icon({ |
| | | iconUrl: '/bjfw/images/icon/red.png', |
| | | iconSize: new T.Point(30, 30), |
| | | iconAnchor: new T.Point(6, 40), |
| | | }); |
| | | } |
| | | |
| | | let lng = data[i].lng; |
| | | let lat = data[i].lat; |
| | | let marker = new T.Marker(new T.LngLat(lng, lat), { title: "场地位置",icon:projectIcon}); |