增加充电失败订单入库
This commit is contained in:
parent
bf1b6f7049
commit
e284cee23d
@ -375,6 +375,11 @@ public class XhpcPileOrderController extends BaseController {
|
|||||||
if(cacheOrderData.getTotalPowerQuantity()==0 || totalPowerQuantity.compareTo(new BigDecimal(0.1))<1 || money.compareTo(new BigDecimal(0.1))<1){
|
if(cacheOrderData.getTotalPowerQuantity()==0 || totalPowerQuantity.compareTo(new BigDecimal(0.1))<1 || money.compareTo(new BigDecimal(0.1))<1){
|
||||||
xhpcChargeOrder.setStatus(3);
|
xhpcChargeOrder.setStatus(3);
|
||||||
xhpcChargeOrder.setUpdateTime(new Date());
|
xhpcChargeOrder.setUpdateTime(new Date());
|
||||||
|
int startSoc1 = cacheOrderData.getStartSoc();
|
||||||
|
int endSoc1 = cacheOrderData.getEndSoc();
|
||||||
|
|
||||||
|
xhpcChargeOrder.setStartSoc(startSoc1 + "");
|
||||||
|
xhpcChargeOrder.setEndSoc(endSoc1 + "");
|
||||||
xhpcChargeOrderService.updateXhpcChargeOrder(xhpcChargeOrder);
|
xhpcChargeOrderService.updateXhpcChargeOrder(xhpcChargeOrder);
|
||||||
xhpcRealTimeOrderService.addZeroHistoryOrder(xhpcChargeOrder);
|
xhpcRealTimeOrderService.addZeroHistoryOrder(xhpcChargeOrder);
|
||||||
logger.info("*********************电量为0订单号>>>>>orderNo:" + orderNo);
|
logger.info("*********************电量为0订单号>>>>>orderNo:" + orderNo);
|
||||||
|
|||||||
@ -1313,7 +1313,10 @@ public class XhpcRealTimeOrderServiceImpl extends BaseService implements IXhpcRe
|
|||||||
logger.info("<<<<<<<<<<<<<<<<订单结束回调成功>>>>>>>>>订单号:>>>"+orderNo+">>>>>");
|
logger.info("<<<<<<<<<<<<<<<<订单结束回调成功>>>>>>>>>订单号:>>>"+orderNo+">>>>>");
|
||||||
logger.info("<<<<<<<<<<<<<<<<订单结束回调成功>>>>>>>>>订单号:>>>"+orderNo+">>>>>>>>");
|
logger.info("<<<<<<<<<<<<<<<<订单结束回调成功>>>>>>>>>订单号:>>>"+orderNo+">>>>>>>>");
|
||||||
logger.info("<<<<<<<<<<<<<<<<订单结束回调成功>>>>>>>>>订单号:>>>"+orderNo+">>>>>>>>");
|
logger.info("<<<<<<<<<<<<<<<<订单结束回调成功>>>>>>>>>订单号:>>>"+orderNo+">>>>>>>>");
|
||||||
if(!"40".equals(xhpcHistoryOrder.getStopReasonEvcs())){
|
try {
|
||||||
|
int startSoc = Integer.parseInt(xhpcHistoryOrder.getStartSoc());
|
||||||
|
int endSoc = Integer.parseInt(xhpcHistoryOrder.getEndSoc());
|
||||||
|
if(!"40".equals(xhpcHistoryOrder.getStopReasonEvcs()) || startSoc>95 || endSoc>95){
|
||||||
XhpcWorkHistoryOrderDto xhpcWorkHistoryOrderDto =new XhpcWorkHistoryOrderDto();
|
XhpcWorkHistoryOrderDto xhpcWorkHistoryOrderDto =new XhpcWorkHistoryOrderDto();
|
||||||
BeanUtils.copyProperties(xhpcHistoryOrder,xhpcWorkHistoryOrderDto);
|
BeanUtils.copyProperties(xhpcHistoryOrder,xhpcWorkHistoryOrderDto);
|
||||||
String nameByCode = StopReasonEnum.getNameByCode(xhpcHistoryOrder.getStopReasonEvcs());
|
String nameByCode = StopReasonEnum.getNameByCode(xhpcHistoryOrder.getStopReasonEvcs());
|
||||||
@ -1321,6 +1324,9 @@ public class XhpcRealTimeOrderServiceImpl extends BaseService implements IXhpcRe
|
|||||||
xhpcHistoryOrderService.insertXhpcWorkHistoryOrderDto(xhpcWorkHistoryOrderDto);
|
xhpcHistoryOrderService.insertXhpcWorkHistoryOrderDto(xhpcWorkHistoryOrderDto);
|
||||||
logger.info("<<<<<<<<<<<<<<<<入库成功>>>>>>>>>订单号:>>>");
|
logger.info("<<<<<<<<<<<<<<<<入库成功>>>>>>>>>订单号:>>>");
|
||||||
}
|
}
|
||||||
|
}catch (Exception e){
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1482,6 +1488,8 @@ public class XhpcRealTimeOrderServiceImpl extends BaseService implements IXhpcRe
|
|||||||
xhpcHistoryOrder.setInternetSerialNumber(xhpcChargeOrder.getInternetSerialNumber());
|
xhpcHistoryOrder.setInternetSerialNumber(xhpcChargeOrder.getInternetSerialNumber());
|
||||||
xhpcHistoryOrder.setType(2);
|
xhpcHistoryOrder.setType(2);
|
||||||
xhpcHistoryOrder.setStatus(0);
|
xhpcHistoryOrder.setStatus(0);
|
||||||
|
xhpcHistoryOrder.setStartSoc(xhpcChargeOrder.getStartSoc());
|
||||||
|
xhpcHistoryOrder.setEndSoc(xhpcChargeOrder.getEndSoc());
|
||||||
Date date = new Date();
|
Date date = new Date();
|
||||||
xhpcHistoryOrder.setCreateTime(date);
|
xhpcHistoryOrder.setCreateTime(date);
|
||||||
Map<String, Object> pushOrder = redisService.getCacheMap("pushOrder:"+xhpcChargeOrder.getSerialNumber());
|
Map<String, Object> pushOrder = redisService.getCacheMap("pushOrder:"+xhpcChargeOrder.getSerialNumber());
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user