异步提交充电订单同步
This commit is contained in:
@ -1237,15 +1237,21 @@ public class OrderServiceImpl implements OrderService {
|
|||||||
carRepo.update(carPOLambdaUpdateWrapper);
|
carRepo.update(carPOLambdaUpdateWrapper);
|
||||||
|
|
||||||
if(renBatteryOrderSubPO!=null){
|
if(renBatteryOrderSubPO!=null){
|
||||||
Map<String, String> result = syncInteg.sendSubOrderId(renBatteryOrderSubPO.getSuborderId());
|
ThreadPoolUtils.getThreadPool().execute(() -> {
|
||||||
String status = result.get("code");
|
try {
|
||||||
if (status.equals("40001") || status.equals("40002") || status.equals("40003") || status.equals("40005") || status.equals("40006")){
|
Map<String, String> result = syncInteg.sendSubOrderId(renBatteryOrderSubPO.getSuborderId());
|
||||||
throw new BizException("此用户在租电APP还有未完成的订单,请联系用户完成租电订单或是驳回此租车订单");
|
String status = result.get("code");
|
||||||
}
|
if (status.equals("40001") || status.equals("40002") || status.equals("40003") || status.equals("40005") || status.equals("40006")){
|
||||||
|
log.warn("租电订单同步失败,用户在租电APP还有未完成的订单,subOrderId: {}", renBatteryOrderSubPO.getSuborderId());
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("异步同步租电订单异常,subOrderId: {}", renBatteryOrderSubPO.getSuborderId(), e);
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
return getOrderInfoByOrderNo(bindCarToOrderReq.getOrderNo());
|
return getOrderInfoByOrderNo(bindCarToOrderReq.getOrderNo());
|
||||||
} catch (Exception e){
|
} catch (Exception e){
|
||||||
log.warn("绑定车辆失败",e);
|
log.warn("绑定车辆失败",e);
|
||||||
|
|||||||
Reference in New Issue
Block a user