From 0915c490b85e6c300059edf00d5055665a380e9f Mon Sep 17 00:00:00 2001 From: WinUser01 Date: Mon, 20 Dec 2021 11:17:20 +0800 Subject: [PATCH] =?UTF-8?q?hyzp=5Fybqx-Commit036=EF=BC=9A=E5=9C=A8?= =?UTF-8?q?=E7=82=B9=E4=BD=8D=E5=9C=B0=E5=9B=BE=E4=B8=8A=EF=BC=8C=E7=82=B9?= =?UTF-8?q?=E5=87=BB=E7=82=B9=E4=BD=8D=E6=A0=87=E6=B3=A8=E5=B7=B2=E7=BB=8F?= =?UTF-8?q?=E8=83=BD=E5=A4=9F=E5=BC=B9=E5=87=BA=E7=82=B9=E4=BD=8D=E7=BB=9F?= =?UTF-8?q?=E8=AE=A1=E4=BF=A1=E6=81=AF=E5=AF=B9=E8=AF=9D=E6=A1=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/components/dioFun.dart | 3 +++ lib/pages/Works/DWDT/basic_map.dart | 10 +++++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/lib/components/dioFun.dart b/lib/components/dioFun.dart index 4fe3f96..d03290b 100644 --- a/lib/components/dioFun.dart +++ b/lib/components/dioFun.dart @@ -646,6 +646,9 @@ Future getStatisData({@required String statisType, String ip = '', String date = // print('map[\'etime\'] = ${map['etime']}'); } + //访问区县后台接口,需要统一添加区县代码参数 + map['qxdm'] = qxdm; + Dio dio = Dio(); String api = mapStatisType[statisType]['api']; print('api = ${api}'); diff --git a/lib/pages/Works/DWDT/basic_map.dart b/lib/pages/Works/DWDT/basic_map.dart index 32c740e..7506b62 100644 --- a/lib/pages/Works/DWDT/basic_map.dart +++ b/lib/pages/Works/DWDT/basic_map.dart @@ -58,7 +58,8 @@ class _BasicMapState extends State { // 注意:百度官方发布的城市中心点坐标是经度在前、纬度在后,必须对调才行,否则无法正确显示指定城市的地图 // BMFCoordinate BMFCoordinate(double latitude (纬度), double longitude (经度)) //中国领域一般经度大些 // center: BMFCoordinate(28.77914, 104.644079), //宜宾市翠屏白塔山 - center: BMFCoordinate(center_latitude, center_longitude), // 不同区县的中心纬度、经度坐标不一样 + center: BMFCoordinate(center_latitude, center_longitude), + // 不同区县的中心纬度、经度坐标不一样 showMapPoi: _showMapPoi, //设定地图是否显示底图poi标注(不包含室内图标注),默认true zoomLevel: g_zoomLevel, @@ -504,8 +505,11 @@ class _BasicMapState extends State { //还原按钮,重新设置中心位置、缩放级别 //myMapController.setCenterCoordinate(coordinate, animated); //没有myMapController.getCenterCoordinate,无法简单地获取当前中心坐标; - myMapController?.updateMapOptions( - BMFMapOptions(center: BMFCoordinate(28.77914, 104.644079))); + // myMapController?.updateMapOptions( + // BMFMapOptions(center: BMFCoordinate(28.77914, 104.644079))); + myMapController?.updateMapOptions(BMFMapOptions( + center: + BMFCoordinate(center_latitude, center_longitude))); // 不同区县的中心纬度、经度坐标不一样 myMapController?.updateMapOptions(BMFMapOptions(zoomLevel: g_zoomLevel)); }, ),