| | |
| | | vipPaymentLambdaQueryWrapper.in(VipPayment::getPayStatus,payStatus); |
| | | vipPaymentLambdaQueryWrapper.ge(StringUtils.hasLength(vipPaymentDto.getStartTime()), VipPayment::getInsertTime, vipPaymentDto.getStartTime()); |
| | | vipPaymentLambdaQueryWrapper.le(StringUtils.hasLength(vipPaymentDto.getEndTime()), VipPayment::getInsertTime, vipPaymentDto.getEndTime()); |
| | | if (vipPaymentDto.getIsRefund()==null){ |
| | | payStatus.add(3); |
| | | } |
| | | if (vipPaymentDto.getIsRefund()!=null&&vipPaymentDto.getIsRefund()==1){ |
| | | payStatus.add(3); |
| | | } |
| | |
| | | .le(StringUtils.hasLength(vipDetailDto.getUseEndTime()), VipDetail::getUseTime, vipDetailDto.getUseEndTime()) |
| | | .eq(vipDetailDto.getOperatorId() != null, VipDetail::getOperatorId, vipDetailDto.getOperatorId()) |
| | | .eq(vipDetailDto.getType() != null, VipDetail::getType, vipDetailDto.getType()) |
| | | .eq(vipDetailDto.getStatus() != null, VipDetail::getStatus, vipDetailDto.getStatus()).list(); |
| | | .eq(vipDetailDto.getStatus() != null, VipDetail::getStatus, vipDetailDto.getStatus()) |
| | | .orderByDesc(VipDetail::getInsertTime) |
| | | .list(); |
| | | |
| | | |
| | | // 使用 Stream + 手动拷贝提升性能和可读性(或使用 MapStruct) |
| | | vipDetailVOS = list.stream().map(vipDetail -> { |
| | |
| | | VipDetail vipDetailServiceById = vipDetailService.getById(userCoupon.getVipDetailId()); |
| | | vipDetailServiceById.setUseTime(new Date()); |
| | | vipDetailServiceById.setStatus(2); |
| | | vipDetailService.updateById(vipDetailServiceById); |
| | | } |
| | | |
| | | } |