| | |
| | | |
| | | import Editable from '@components/plugin/Editable' |
| | | import PathDrag from '@components/plugin/PathDrag' |
| | | import CanvasIcon from '@components/plugin/CanvasMarkers' |
| | | import MagicMarker from '@components/plugin/MagicMarker' |
| | | import WmtsSupport from '@components/plugin/wmts_plugins' |
| | | |
| | | import MapConfig from '@/conf/MapConfig' |
| | | import DashFlow from '@components/plugin/PathDashFlow' |
| | | import CanvasMarkers from '@components/plugin/CanvasMarkers' |
| | | import FullScreen from '@components/plugin/FullScreen' |
| | | |
| | | let map = null |
| | | const L = window.L |
| | | const initMap = (div) => { |
| | |
| | | Editable.init(L) // 图层编辑 |
| | | PathDrag.init(L) // 路径拖拽 |
| | | MagicMarker.init(L) // 动画Marker |
| | | CanvasIcon.init(L) // 使用canvas绘制Marker |
| | | WmtsSupport.init(L) // 扩展,使支持WMTS |
| | | // CustomPopup.init(L) // 自定义弹出框 |
| | | DashFlow.DashFlow(L) // 流动线图 |
| | | CanvasMarkers.init(L)// 画布图层 |
| | | // Leaflet扩展代码 |
| | | // 全屏 |
| | | FullScreen.init(L) |
| | | |
| | | map = L.map(div, MapConfig.mapOptions) |
| | | |
| | |
| | | }) |
| | | |
| | | window.map = map |
| | | |
| | | initTileLayersHelper(map) |
| | | return map |
| | | } |
| | | |
| | |
| | | * @param L |
| | | */ |
| | | const initTileLayersHelper = (map) => { |
| | | return new ServiceLayerHelper({ map }) |
| | | var serviceLayerHelper = new ServiceLayerHelper({ map }) |
| | | return serviceLayerHelper |
| | | } |
| | | |
| | | /** |