排序 赠送 优惠券使用记录

This commit is contained in:
wangw 2025-03-19 11:44:56 +08:00
parent 339ac96d08
commit bcebe8e312
2 changed files with 2 additions and 1 deletions

View File

@ -70,6 +70,7 @@ public class ShopUserController {
queryWrapper.eq(ShopUserFlow::getBizCode, bizCode); queryWrapper.eq(ShopUserFlow::getBizCode, bizCode);
} }
queryWrapper.orderBy(ShopUserFlow::getCreateTime, false); queryWrapper.orderBy(ShopUserFlow::getCreateTime, false);
queryWrapper.orderBy(ShopUserFlow::getId, true);
return CzgResult.success(shopUserFlowService.page(PageUtil.buildPage(), queryWrapper)); return CzgResult.success(shopUserFlowService.page(PageUtil.buildPage(), queryWrapper));
} }

View File

@ -524,7 +524,7 @@ public class PayServiceImpl implements PayService {
//更新会员余额 并生成流水 //更新会员余额 并生成流水
shopUserService.updateMoney(shopUser.getShopId(), shopUserMoneyEditDTO); shopUserService.updateMoney(shopUser.getShopId(), shopUserMoneyEditDTO);
userFlowService.updateRefund(inFlow.getId(), refPayParam.getRefAmount()); userFlowService.updateRefund(inFlow.getId(), refPayParam.getRefAmount());
if (giftFlow != null && (giftFlow.getAmount().subtract(refPayParam.getRefAmount())).compareTo(BigDecimal.ZERO) > 0) { if (giftFlow != null && (giftFlow.getAmount().subtract(giftFlow.getRefundAmount())).compareTo(BigDecimal.ZERO) > 0) {
ShopUserMoneyEditDTO giftFlowEdit = new ShopUserMoneyEditDTO() ShopUserMoneyEditDTO giftFlowEdit = new ShopUserMoneyEditDTO()
.setId(shopUser.getId()) .setId(shopUser.getId())
.setMoney(giftFlow.getAmount()) .setMoney(giftFlow.getAmount())