|
|
@ -21,9 +21,9 @@ const Gis = (props) => { |
|
|
|
const loadMap = () => { |
|
|
|
const map = new AMap.Map(MAPID, { |
|
|
|
resizeEnable: true, |
|
|
|
center: [115.912663, 28.543149],//地图中心点,初始定位加载显示楼块
|
|
|
|
zoom: 15,//地图显示的缩放级别
|
|
|
|
zooms: [10, 12], |
|
|
|
center: [115.99255, 28.503617],//地图中心点,初始定位加载显示楼块
|
|
|
|
zoom: 8,//地图显示的缩放级别
|
|
|
|
zooms: [8, 18], |
|
|
|
pitch: 0, // 地图俯仰角度,有效范围 0 度- 83 度
|
|
|
|
viewMode: '3D', // 地图模式
|
|
|
|
mapStyle: 'amap://styles/fb26776387242721c2fc32e2cb1daccc', |
|
|
@ -42,8 +42,8 @@ const Gis = (props) => { |
|
|
|
}; |
|
|
|
|
|
|
|
return ( |
|
|
|
<div style={{ position: 'absolute', width: '100%', backgroundColor: '#101824', height: '100%', minHeight: 700 }}> |
|
|
|
<div id={MAPID} style={{ width: '100%', height: '100%', background: "#101824", minHeight: 700 }} /> |
|
|
|
<div style={{ position: 'absolute', width: '100%', height: '100%' }}> |
|
|
|
<div id={MAPID} style={{ width: '100%', height: '100%',}} /> |
|
|
|
{mapObj ? <Bounds map={mapObj} /> : ''} |
|
|
|
</div > |
|
|
|
) |
|
|
|