|
@@ -17,12 +17,8 @@ public class APIUtil {
|
|
Map<String, String> headers = new HashMap<String, String>();
|
|
Map<String, String> headers = new HashMap<String, String>();
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Access-Token", token);
|
|
headers.put("Access-Token", token);
|
|
- System.out.println(JSONObject.toJSON(param));//TODO
|
|
|
|
String result = HttpUtils.httpPostRequest(url, param, headers);
|
|
String result = HttpUtils.httpPostRequest(url, param, headers);
|
|
JSONObject resultJson = JSONObject.parseObject(result);
|
|
JSONObject resultJson = JSONObject.parseObject(result);
|
|
- if (resultJson.toString().length() < 500) {
|
|
|
|
- System.out.println(JSONObject.toJSON(resultJson)); //TODO
|
|
|
|
- }
|
|
|
|
return resultJson;
|
|
return resultJson;
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
e.printStackTrace();
|
|
e.printStackTrace();
|
|
@@ -41,12 +37,8 @@ public class APIUtil {
|
|
Map<String, String> headers = new HashMap<String, String>();
|
|
Map<String, String> headers = new HashMap<String, String>();
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Access-Token", token);
|
|
headers.put("Access-Token", token);
|
|
- System.out.println(JSONObject.toJSON(param)); //TODO
|
|
|
|
String result = HttpUtils.httpGetRequest(url, headers, param);
|
|
String result = HttpUtils.httpGetRequest(url, headers, param);
|
|
JSONObject resultJson = JSONObject.parseObject(result);
|
|
JSONObject resultJson = JSONObject.parseObject(result);
|
|
- if (resultJson.toString().length() < 500) {
|
|
|
|
- System.out.println(JSONObject.toJSON(resultJson)); //TODO
|
|
|
|
- }
|
|
|
|
return resultJson;
|
|
return resultJson;
|
|
|
|
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|