|
@@ -77,23 +77,18 @@ public class GeoAnalysisController extends JeecgController<GeoAnalysis, IGeoAnly
|
|
|
@ApiOperation(value = " 通过获取坐标串进行分析", notes = " 通过获取坐标串进行分析")
|
|
|
@GetMapping(value = "/DrawMap")
|
|
|
public Result<?> DrawMapByzb( DrawMapDto drawMapDto) throws JsonProcessingException {
|
|
|
- ObjectMapper mapper = new ObjectMapper();
|
|
|
+ //ObjectMapper mapper = new ObjectMapper();
|
|
|
HashMap<String,Object> wk=new HashMap<>();
|
|
|
List<Object> rings=new ArrayList<>();
|
|
|
rings.add(drawMapDto.getGeoJson());
|
|
|
-// GeometryVo geometryVo=new GeometryVo();
|
|
|
wk.put("wkid",4490);
|
|
|
-// geometryVo.setRings(rings);
|
|
|
-// geometryVo.setSpatialReference(wk);
|
|
|
-// String JsongeometryVo = mapper.writeValueAsString(geometryVo);
|
|
|
-// System.out.println(drawMapDto.getGeoJson());
|
|
|
-// System.out.println("111111111111"+JsongeometryVo);
|
|
|
String jsonString = "{\"rings\":[" + drawMapDto.getGeoJson() + "],\"spatialReference\":{\"wkid\":4490}}";
|
|
|
- System.out.println(jsonString);
|
|
|
+ //System.out.println(jsonString);
|
|
|
Geometry geometry = GeometryEngine.jsonToGeometry(jsonString).getGeometry();
|
|
|
String drawWkt = GeometryEngine.geometryToWkt(geometry, WktExportFlags.wktExportPolygon);
|
|
|
String[] split = drawMapDto.getAtableename().split(",");
|
|
|
ArrayList<ZYFXPZB> yj_kszlq = new ArrayList<>();
|
|
|
+ //省属地块,省直地块参数(atableename: sz_dkxx,ss_dkxx)
|
|
|
if (drawMapDto.getAtableename().contains(",")) {
|
|
|
for (String s : split) {
|
|
|
ZYFXPZB zyfxpzb = geoAnalysisService.SelectByTbs(drawMapDto.getTable(), s);
|
|
@@ -185,7 +180,6 @@ public class GeoAnalysisController extends JeecgController<GeoAnalysis, IGeoAnly
|
|
|
ArrayList<String> arr = new ArrayList<>();
|
|
|
ArrayList<DetailsResult> arrayList = new ArrayList<>();
|
|
|
ArrayList<CommonQueryConfig> list = geoAnalysisService.SelectByTable(table);
|
|
|
-
|
|
|
for (CommonQueryConfig commonQueryConfig : list) {
|
|
|
String fldalias = commonQueryConfig.getFldalias();
|
|
|
String unit = commonQueryConfig.getUnit();
|