mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-05-15 15:28:41 +08:00
优化结算订单逻辑
This commit is contained in:
@@ -892,10 +892,15 @@ public class TempService {
|
|||||||
|
|
||||||
// 查询订单详情
|
// 查询订单详情
|
||||||
OrderDetail orderDetail = orderBasicInfoService.getOrderDetailByOrderCode(orderBasicInfo.getOrderCode());
|
OrderDetail orderDetail = orderBasicInfoService.getOrderDetailByOrderCode(orderBasicInfo.getOrderCode());
|
||||||
|
|
||||||
programLogic.updateOrderBasicInfoAndOrderDetail(data, orderBasicInfo, orderDetail);
|
programLogic.updateOrderBasicInfoAndOrderDetail(data, orderBasicInfo, orderDetail);
|
||||||
|
|
||||||
// 计算订单折扣
|
// 计算订单折扣
|
||||||
programLogic.calculateOrderDiscountsV2(orderBasicInfo, orderDetail);
|
programLogic.calculateOrderDiscountsV2(orderBasicInfo, orderDetail);
|
||||||
|
|
||||||
|
logger.info("testSettleOrderLogic, orderCode:{}, 支付金额:{}, 消费金额:{}, 折扣金额:{}, 退款金额:{}, 结算金额:{}",
|
||||||
|
orderBasicInfo.getOrderCode(), orderBasicInfo.getPayAmount(), orderBasicInfo.getOrderAmount(),
|
||||||
|
orderBasicInfo.getDiscountAmount(), orderBasicInfo.getRefundAmount(), orderBasicInfo.getSettleAmount());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -927,8 +927,8 @@ public abstract class AbstractProgramLogic implements InitializingBean {
|
|||||||
MemberDiscountVO memberDiscountVO = memberGroupService.queryMemberDiscountV2(merchantId, stationId, memberId);
|
MemberDiscountVO memberDiscountVO = memberGroupService.queryMemberDiscountV2(merchantId, stationId, memberId);
|
||||||
if (memberDiscountVO == null) {
|
if (memberDiscountVO == null) {
|
||||||
// 如果没有优惠,则优惠后金额 等于优惠前金额
|
// 如果没有优惠,则优惠后金额 等于优惠前金额
|
||||||
afterDiscountServiceAmount = orderDetail.getTotalServiceAmount();
|
|
||||||
afterDiscountElectricityAmount = orderDetail.getTotalElectricityAmount();
|
afterDiscountElectricityAmount = orderDetail.getTotalElectricityAmount();
|
||||||
|
afterDiscountServiceAmount = orderDetail.getTotalServiceAmount();
|
||||||
} else {
|
} else {
|
||||||
// 集团会员的订单,记录集团编号
|
// 集团会员的订单,记录集团编号
|
||||||
orderBasicInfo.setGroupCode(memberDiscountVO.getGroupCode());
|
orderBasicInfo.setGroupCode(memberDiscountVO.getGroupCode());
|
||||||
|
|||||||
Reference in New Issue
Block a user