Commit 81d07858 by 周海宝

Merge branch 'dev' into 'master'

Dev

See merge request !13
2 parents 61fecc4d c90a7266
......@@ -28,4 +28,15 @@ public class ResponseBody {
private String message;
private String msg;
@Override
public String toString() {
return "ResponseBody{" +
"success=" + success +
", result='" + result + '\'' +
", code=" + code +
", message='" + message + '\'' +
", msg='" + msg + '\'' +
'}';
}
}
......@@ -52,6 +52,7 @@ public class DeviceService {
}
public R getDevicesById(String device_id) {
log.info("开始查询{}",device_id);
ResponseBody responseBody = sendRequestService.sendRequestGet(getDevicesByIdUrl.replace("{device_id}", device_id));
if (responseBody != null && responseBody.isSuccess()) {
String result = responseBody.getResult();
......
......@@ -75,6 +75,7 @@ public class SendRequestService {
try {
JSONObject jsonObject = HttpUtil.sendGet(requesturl, null, headerParams);
responseBody = JSON.toJavaObject(jsonObject, ResponseBody.class);
log.info("请求涂鸦数据{}",responseBody);
} catch (IOException e) {
e.printStackTrace();
log.info("请求用户信息接口异常,异常信息{}", e.getMessage());
......@@ -99,6 +100,7 @@ public class SendRequestService {
try {
JSONObject jsonObject = HttpUtil.sendPut(requesturl, requestBody, headerParams);
responseBody = JSON.toJavaObject(jsonObject, ResponseBody.class);
log.info("请求涂鸦数据{}",responseBody);
} catch (IOException e) {
e.printStackTrace();
log.info("请求用户信息接口异常,异常信息{}", e.getMessage());
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!