Browse Source

[完善]完善水源道路页面修改中心点和按钮

master
邵佳豪 4 years ago
parent
commit
364b8e0a14
  1. 4
      src/app/ui/water-road/water-road.component.html
  2. 4
      src/app/ui/water-road/water-road.component.scss
  3. 13
      src/app/ui/water-road/water-road.component.ts

4
src/app/ui/water-road/water-road.component.html

@ -12,8 +12,8 @@
</div>
</div> -->
<div class="editbtn" (click)="opendialog()">
<p style="margin-top: 20px;"><mat-icon>create</mat-icon></p>
<p style="font-size: 16px;color: #fff;">编辑</p>
<p><mat-icon>create</mat-icon></p>
<p style="color: #fff;">编辑</p>
</div>
</div>

4
src/app/ui/water-road/water-road.component.scss

@ -25,12 +25,14 @@
bottom: 0.439453rem;
width: 0.976563rem;
height: 0.976563rem;
// line-height: 0.976563rem;
line-height: 0.859375rem;
background: linear-gradient(360deg, #FC7045 0%, #FF4923 100%);
box-shadow: 0px 2px 10px #D8A798;
border-radius: 50%;
opacity: 1;
p{
height: 0.175781rem;
font-size: 0.15625rem;
color: #fff;
}
}

13
src/app/ui/water-road/water-road.component.ts

@ -54,7 +54,15 @@ export class WaterRoadComponent implements OnInit {
{lng:108.158521,lat: 22.61322},
{lng:107.925062,lat: 22.565038},
{lng:108.180494,lat: 22.501616},
{lng:107.743222,lat: 22.535121}]
{lng:107.743222,lat: 22.535121},
{lng:108.373809,lat: 22.764746},
{lng:108.378895,lat: 22.761877},
{lng:108.383337,lat: 22.766467},
{lng:108.37647,lat: 22.763341},
{lng:108.37662,lat: 22.767397},
{lng:108.378916,lat: 22.758513},
{lng:108.379045,lat: 22.765695},
{lng:108.384731,lat: 22.760096},]
let Arr = []
arr.forEach(item=>{
let viaMarker = new AMap.Marker({
@ -66,6 +74,7 @@ export class WaterRoadComponent implements OnInit {
})
this.map = new AMap.Map('map',{
center: [108.377865, 22.763499], //初始地图中心点
zoom: 16
});
@ -73,7 +82,7 @@ export class WaterRoadComponent implements OnInit {
console.log(e.lnglat.getLng() + ',' + e.lnglat.getLat())
});
this.map.setCity('南宁市')
// this.map.setCity('南宁市')
this.map.add(Arr);//火源标点

Loading…
Cancel
Save