|
|
|
@ -44,24 +44,43 @@ const FlightPlanAreaMap = (props) => {
|
|
|
|
|
setMode(mapControl.drawType) |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
//console.log("상현>>",mapAreaCoordList[0].coordList[0].lat);
|
|
|
|
|
console.log("상현>>",map); |
|
|
|
|
const NaverMapInit = () => { |
|
|
|
|
const mapOptions = { |
|
|
|
|
// center: new naver.maps.LatLng(36.56793936069445, 127.85101412107547),
|
|
|
|
|
center: new naver.maps.LatLng(37.520357, 126.610166), |
|
|
|
|
// zoom: 10,
|
|
|
|
|
zoom: 15, |
|
|
|
|
zoomControl: true, |
|
|
|
|
mapTypeId: naver.maps.MapTypeId.NORMAL, |
|
|
|
|
zoomControlOptions: { |
|
|
|
|
position: naver.maps.Position.LEFT_CENTER, |
|
|
|
|
style: naver.maps.ZoomControlStyle.SMALL |
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
setMap(new naver.maps.Map('map', mapOptions)); |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
if(!mapAreaCoordList[0].coordList[0].lat){ |
|
|
|
|
debugger |
|
|
|
|
const mapOptions = { |
|
|
|
|
center: new naver.maps.LatLng(mapAreaCoordList[0].coordList[0].lat, mapAreaCoordList[0].coordList[0].lon), |
|
|
|
|
// center: new naver.maps.LatLng(37.520357, 126.610166),
|
|
|
|
|
//center: new naver.maps.LatLng(, ),
|
|
|
|
|
// zoom: 10,
|
|
|
|
|
zoom: 15, |
|
|
|
|
zoomControl: true, |
|
|
|
|
mapTypeId: naver.maps.MapTypeId.NORMAL, |
|
|
|
|
zoomControlOptions: { |
|
|
|
|
position: naver.maps.Position.LEFT_CENTER, |
|
|
|
|
style: naver.maps.ZoomControlStyle.SMALL |
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
|
setMap(new naver.maps.Map('map', mapOptions)); |
|
|
|
|
} |
|
|
|
|
else if(!(mapAreaCoordList[0].coordList[0].lat)){
|
|
|
|
|
debugger |
|
|
|
|
const mapOptions = { |
|
|
|
|
// center: new naver.maps.LatLng(36.56793936069445, 127.85101412107547),
|
|
|
|
|
center: new naver.maps.LatLng(37.520357, 126.610166), |
|
|
|
|
// zoom: 10,
|
|
|
|
|
zoom: 15, |
|
|
|
|
zoomControl: true, |
|
|
|
|
mapTypeId: naver.maps.MapTypeId.NORMAL, |
|
|
|
|
zoomControlOptions: { |
|
|
|
|
position: naver.maps.Position.LEFT_CENTER, |
|
|
|
|
style: naver.maps.ZoomControlStyle.SMALL |
|
|
|
|
} |
|
|
|
|
}; |
|
|
|
|
setMap(new naver.maps.Map('map', mapOptions)); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
const handlerDrawType = val => { |
|
|
|
|
dispatch(drawTypeChangeAction(val)); |
|
|
|
|
};
|
|
|
|
|