...
|
...
|
@@ -68,7 +68,7 @@ public class HikVisionArtemisPostUtils { |
68
|
68
|
//返回url地址
|
69
|
69
|
if (StringUtils.isNotEmpty(result)) {
|
70
|
70
|
JsonNode json = JacksonUtil.toJsonNode(result);
|
71
|
|
- if(json.get("code").equals("0")){
|
|
71
|
+ if(json.get("code").asText().equals("0")){
|
72
|
72
|
json = json.get("data");
|
73
|
73
|
String message = null;
|
74
|
74
|
if(null == json || json.get("url") == null){
|
...
|
...
|
@@ -82,8 +82,9 @@ public class HikVisionArtemisPostUtils { |
82
|
82
|
}
|
83
|
83
|
return json.get("url").textValue();
|
84
|
84
|
}else{
|
85
|
|
- String errorCode = json.get("code").toString();
|
86
|
|
- throw new TkDataValidationException(String.format(ErrorMessage.HIKVISION_API_ERROR.getMessage(),errorCode));
|
|
85
|
+ String errorCode = json.get("code").asText();
|
|
86
|
+ String msg = json.get("msg").asText();
|
|
87
|
+ throw new TkDataValidationException(String.format(ErrorMessage.HIKVISION_API_ERROR.getMessage(),msg,errorCode));
|
87
|
88
|
}
|
88
|
89
|
|
89
|
90
|
} else {
|
...
|
...
|
|