|
|
@@ -488,17 +488,12 @@ public class OtcTradeOrderServiceImpl implements OtcTradeOrderService {
|
|
|
log.error("发送短信异常", e);
|
|
|
}
|
|
|
List<BigDecimal> amountList = new ArrayList<>();
|
|
|
- try {
|
|
|
- List<OrderPolicyDO> orderPolicyList = orderPolicyMapper.selectList(OrderPolicyDO::getOrderId, orderId);
|
|
|
- if (!orderPolicyList.isEmpty()) {
|
|
|
- orderPolicyList.forEach(item -> {
|
|
|
- amountList.add(item.getAmount());
|
|
|
- policyApi.updatePolicySurplusNum(item.getId(), tradeOrderDO.getVoyageId(), item.getPreUseNum());
|
|
|
- });
|
|
|
- }
|
|
|
-
|
|
|
- }catch (Exception e){
|
|
|
- log.error("政策执行异常", e);
|
|
|
+ List<OrderPolicyDO> orderPolicyList = orderPolicyMapper.selectList(OrderPolicyDO::getOrderId, orderId);
|
|
|
+ if (!orderPolicyList.isEmpty()) {
|
|
|
+ orderPolicyList.forEach(item -> {
|
|
|
+ amountList.add(item.getAmount());
|
|
|
+ policyApi.updatePolicySurplusNum(item.getPolicyId(), tradeOrderDO.getVoyageId(), item.getPreUseNum());
|
|
|
+ });
|
|
|
}
|
|
|
BigDecimal amount = amountList.stream().reduce(BigDecimal.ZERO, BigDecimal::add);
|
|
|
int orderStatus = TradeOrderStatusEnum.UNPAID.getStatus();
|