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)); }, ),