liujie
6 天以前 79501f59e629cc3f52a2ca66e1610591ba7802e3
UserQYTTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/util/GDMapGeocodingUtil.java
@@ -20,7 +20,7 @@
@Component
public class GDMapGeocodingUtil {
    private String key = "ba2915f8d8c1428df72e964a5f94f167";
    private String key = "ea7326a77175aba0e9435859b17bca36";
    @Autowired
    private RestTemplate restTemplate;
@@ -105,9 +105,9 @@
     */
    public Map<String, String> geocode(String lon, String lan) throws Exception{
        String url = "https://restapi.amap.com/v3/geocode/regeo?key=" + key + "&location=" + lon + "," + lan;
        System.err.println("根据经纬度获取行政区域信息[请求]---->" + url);
//        System.err.println("根据经纬度获取行政区域信息[请求]---->" + url);
        String forObject = restTemplate.getForObject(url, String.class);
        System.err.println("根据经纬度获取行政区域信息[响应]---->" + forObject);
//        System.err.println("根据经纬度获取行政区域信息[响应]---->" + forObject);
        JSONObject jsonObject = JSON.parseObject(forObject);
        Map<String, String> map = new HashMap<>();
        if(jsonObject.getString("status").equals("1")){