From a7a86324ae4e519b8ee0a3fa3038f3afa2e14dec Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Thu, 04 Feb 2021 13:49:35 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.0.105:10010/r/jfpt-Vue
---
public/map/index.html | 17 +++++++----------
1 files changed, 7 insertions(+), 10 deletions(-)
diff --git a/public/map/index.html b/public/map/index.html
index 8edea66..1de1918 100644
--- a/public/map/index.html
+++ b/public/map/index.html
@@ -1,11 +1,3 @@
-<!--
- * @Description: 地图
- * @Version: 1.0
- * @Author: yangsx
- * @Date: 2019-11-28 09:50:16
- * @LastEditors: song
- * @LastEditTime: 2021-02-01 17:14:21
- -->
<!DOCTYPE html>
<html lang="zh">
@@ -42,6 +34,7 @@
<script>
var _framework = null;
var _AppEvent = null;
+ var locationObj = null
function init(openId) {
if (openId && _AppEvent != null) {
@@ -55,6 +48,7 @@
_framework.onSiderContainerShow();
_framework.resize();
_AppEvent = AppEvent;
+ _AppEvent.addAppEventListener("mapLoad", mapLoad);
if (openId) showFun(openId);
}
);
@@ -64,9 +58,12 @@
_AppEvent.dispatchAppEvent(_AppEvent.RUN_WIDGET, id);
}
- function dw(x,y) {
- _AppEvent.dispatchAppEvent("goto", {x:x,y:y});
+ function mapLoad(map) {
+ if(locationObj) {
+ map.centerAndZoom(new esri.geometry.Point(locationObj.x,locationObj.y, new esri.SpatialReference({ wkid: 4326 })), 14);
+ }
}
+
</script>
</head>
--
Gitblit v1.9.3