1

我已经使用 wms 自定义图块创建了地图,现在当我想获取特定纬度经度的数据时,我需要在地理服务器层的 GetfeatureInfo 中传递边界框参数,我在 Flutter Gis 中很新,我该如何实现?我在 Google 和 stackoverflow 中查找了答案,但找不到任何相关信息。我的代码如下

FlutterMap(
            options: MapOptions(
              center: LatLng(18.5204, 73.8567),
              zoom: 12.0,
              onTap: (point) {
                Alert(
                  context: context,
                  // type: AlertType.success,
                  title: "Information List",
                  desc: "Pipe Diameter : 900",
                  buttons: [
                    DialogButton(
                      child: Text(
                        "Completed",
                        style: TextStyle(color: Colors.white, fontSize: 15),
                      ),
                      onPressed: () => Navigator.pop(context),

                      width: 120,
                    ),
                    DialogButton(
                      child: Text(
                        "Incompleted",
                        style: TextStyle(color: Colors.white, fontSize: 15),
                      ),
                      onPressed: () => Navigator.pop(context),
                      // onPressed: () => Navigator.of(context).push(new MaterialPageRoute(builder: (context) => Home())),
                      width: 120,
                    ),
                  ],
                ).show();
              },
              // swPanBoundary: LatLng(56.6877, 11.5089),
              // nePanBoundary: LatLng(56.7378, 11.6644),
            ),
            layers: [
              TileLayerOptions(
                urlTemplate:
                    "http://www.google.cn/maps/vt?lyrs=m@189&gl=cn&x={x}&y={y}&z={z}",
                maxZoom: 50,
                subdomains: ['a', 'b', 'c'],
              ),
              TileLayerOptions(
                wmsOptions: WMSTileLayerOptions(
                  baseUrl:
                      'http://103.224.247.79:8181/geoserver/pmc_drain_work/wms/?',
                  layers: ['pmc_drain_work:chambers_zone_$zone'],
                ),
                maxZoom: 50,
                backgroundColor: Colors.transparent,
              )
4

0 回答 0