|
@@ -643,7 +643,7 @@ public class SceneFileBuildServiceImpl extends ServiceImpl<ISceneFileBuildMapper
|
|
paramMap.add("params",params);
|
|
paramMap.add("params",params);
|
|
HttpEntity<Object> formEntity = new HttpEntity<>(paramMap,headers);
|
|
HttpEntity<Object> formEntity = new HttpEntity<>(paramMap,headers);
|
|
ResponseEntity<Result> responseEntity = restTemplate.postForEntity(v3controlUrl+api, formEntity, Result.class);
|
|
ResponseEntity<Result> responseEntity = restTemplate.postForEntity(v3controlUrl+api, formEntity, Result.class);
|
|
- if (responseEntity.getStatusCode() != HttpStatus.OK || responseEntity.getBody().getCode() != HttpStatus.OK.value()) {
|
|
|
|
|
|
+ if (responseEntity.getStatusCode().value() != HttpStatus.OK.value() || responseEntity.getBody().getCode() != ServerCode.SUCCESS.code()) {
|
|
log.error("正顺场景请求V3服务器失败, params:{}, result:{}",params, JSON.toJSONString(responseEntity));
|
|
log.error("正顺场景请求V3服务器失败, params:{}, result:{}",params, JSON.toJSONString(responseEntity));
|
|
throw new BusinessException(ErrorCode.SYSTEM_BUSY);
|
|
throw new BusinessException(ErrorCode.SYSTEM_BUSY);
|
|
}
|
|
}
|
|
@@ -1580,7 +1580,7 @@ public class SceneFileBuildServiceImpl extends ServiceImpl<ISceneFileBuildMapper
|
|
private ResultData rebuildV3SceneToMini(ScenePro scenePro){
|
|
private ResultData rebuildV3SceneToMini(ScenePro scenePro){
|
|
log.info("v3场景重算,请求v3服务器,url:{}",v3controlUrl+"api/scene/rebuildScene?num=" + scenePro.getNum());
|
|
log.info("v3场景重算,请求v3服务器,url:{}",v3controlUrl+"api/scene/rebuildScene?num=" + scenePro.getNum());
|
|
ResponseEntity<Result> responseEntity = restTemplate.getForEntity(v3controlUrl+"api/scene/rebuildScene?num=" + scenePro.getNum(), Result.class);
|
|
ResponseEntity<Result> responseEntity = restTemplate.getForEntity(v3controlUrl+"api/scene/rebuildScene?num=" + scenePro.getNum(), Result.class);
|
|
- if (responseEntity.getStatusCode() != HttpStatus.OK || responseEntity.getBody().getCode() != HttpStatus.OK.value()) {
|
|
|
|
|
|
+ if (responseEntity.getStatusCode().value() != HttpStatus.OK.value() || responseEntity.getBody().getCode() != ServerCode.SUCCESS.code()) {
|
|
log.error("请求V3服务器重算场景失败, num:{}, result:{}",scenePro.getNum(), JSON.toJSONString(responseEntity));
|
|
log.error("请求V3服务器重算场景失败, num:{}, result:{}",scenePro.getNum(), JSON.toJSONString(responseEntity));
|
|
throw new BusinessException(ErrorCode.SYSTEM_BUSY);
|
|
throw new BusinessException(ErrorCode.SYSTEM_BUSY);
|
|
}
|
|
}
|