mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 11:05:18 +08:00
创建订单时不保存支付金额,在支付成功后保存支付金额
This commit is contained in:
@@ -1907,7 +1907,7 @@ public class OrderBasicInfoServiceImpl implements OrderBasicInfoService {
|
||||
.orderBasicInfo(orderBasicInfo)
|
||||
.orderDetail(orderDetail)
|
||||
.build();
|
||||
pileTransactionService.doCreateOrder(createOrderTransactionDTO);
|
||||
pileTransactionService.doCreateOrder(createOrderTransactionDTO); // 保存异常订单到订单主表
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2593,7 +2593,7 @@ public class OrderBasicInfoServiceImpl implements OrderBasicInfoService {
|
||||
.orderBasicInfo(orderBasicInfo)
|
||||
.orderDetail(orderDetail)
|
||||
.build();
|
||||
pileTransactionService.doCreateOrder(createOrderTransactionDTO);
|
||||
pileTransactionService.doCreateOrder(createOrderTransactionDTO); // 联联平台生成订单
|
||||
|
||||
// 组装结果集
|
||||
Map<String, Object> resultMap = Maps.newHashMap();
|
||||
@@ -3083,7 +3083,10 @@ public class OrderBasicInfoServiceImpl implements OrderBasicInfoService {
|
||||
orderInfo.setPayMode(dto.getPayMode());
|
||||
orderInfo.setPayStatus(OrderPayStatusEnum.paid.getValue());
|
||||
BigDecimal orderPayAmount = orderInfo.getPayAmount() == null ? BigDecimal.ZERO : orderInfo.getPayAmount();
|
||||
orderInfo.setPayAmount(orderPayAmount.add(payAmount));
|
||||
// 2024年3月25日12点26分 发现重复记录的情况
|
||||
if(orderPayAmount.compareTo(payAmount) != 0) {
|
||||
orderInfo.setPayAmount(orderPayAmount.add(payAmount));
|
||||
}
|
||||
orderInfo.setPayTime(new Date());
|
||||
|
||||
if (sendStartCharging) {
|
||||
@@ -3515,7 +3518,7 @@ public class OrderBasicInfoServiceImpl implements OrderBasicInfoService {
|
||||
.pileConnectorCode(dto.getPileSn() + dto.getConnectorCode())
|
||||
.startMode(dto.getStartMode())
|
||||
.payStatus(Constants.ZERO)
|
||||
.payAmount(dto.getChargeAmount()) // 支付完成后填入支付金额
|
||||
// .payAmount(dto.getChargeAmount()) // 支付完成后填入支付金额
|
||||
.payMode(dto.getPayMode())
|
||||
.plateNumber(plateNumber)
|
||||
.orderAmount(BigDecimal.ZERO)
|
||||
|
||||
Reference in New Issue
Block a user