From 0fe10a58835988be66ed3ce2e04bfc4f95fb4eaa Mon Sep 17 00:00:00 2001 From: yangdelong <828900aaa> Date: 星期六, 29 五月 2021 10:18:45 +0800 Subject: [PATCH] 企业应急-事件处置-周边资源信息 --- src/components/base-page/enterprise-emergency/events-reported/ReportLocation.vue | 12 ++++++++++++ 1 files changed, 12 insertions(+), 0 deletions(-) diff --git a/src/components/base-page/enterprise-emergency/events-reported/ReportLocation.vue b/src/components/base-page/enterprise-emergency/events-reported/ReportLocation.vue index 7e8c447..3e8e096 100644 --- a/src/components/base-page/enterprise-emergency/events-reported/ReportLocation.vue +++ b/src/components/base-page/enterprise-emergency/events-reported/ReportLocation.vue @@ -37,6 +37,8 @@ import ReportLocationSection from './ReportLocationSection' import ReportLocationSearch from './ReportLocationSearch' +import iconUrl from '../../../../../public/assets/images/map/loc.png' + export default { name: 'ReportLocation', components: { @@ -82,6 +84,16 @@ console.log(e) this.LongLatPos.longPos = e.latlng.lng this.LongLatPos.latPos = e.latlng.lat + const as = [e.latlng.lat, e.latlng.lng] + // console.log(as) + const marker = window.L.marker(as, { + icon: window.L.icon({ + iconUrl: iconUrl, + iconSize: [30, 30], + iconAnchor: [15, 15] + }) + }) + window.map.addLayer(marker) }, // 鑾峰緱鐒︾偣 杩涜瀹氫綅 focusLocation () { -- Gitblit v1.8.0