mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-21 03:25:12 +08:00
getMemberBalanceChangesV2接口加字段
This commit is contained in:
@@ -458,11 +458,11 @@ public class MemberService {
|
||||
// 累计赠送金额
|
||||
vo.setAccumulatedRechargeGift(memberWalletVO.getAccumulatedRechargeGift());
|
||||
|
||||
// 累计消费金额
|
||||
vo.setTotalConsumption(memberWalletVO.getAccumulatedConsumptionAmount());
|
||||
// 累计充值金额
|
||||
vo.setAccumulatedRechargeAmount(memberWalletVO.getTotalRechargeAmount());
|
||||
|
||||
// 总充值
|
||||
vo.setTotalRechargeAmount(memberWalletVO.getTotalRechargeAmount());
|
||||
// 累计消费金额
|
||||
vo.setAccumulatedConsumptionAmount(memberWalletVO.getAccumulatedConsumptionAmount());
|
||||
|
||||
// 根据日期查询会员钱包变动明细 分页
|
||||
// 获取分页信息
|
||||
@@ -485,19 +485,19 @@ public class MemberService {
|
||||
List<MemberWalletLogVO> list = memberBasicInfoService.getMemberWalletDetail(dto);
|
||||
|
||||
// 总支出
|
||||
// BigDecimal totalConsumption = list.stream()
|
||||
// .map(MemberWalletLogVO::getOrderAmount)
|
||||
// .filter(Objects::nonNull)
|
||||
// .reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
// vo.setTotalConsumption(totalConsumption);
|
||||
BigDecimal totalConsumption = list.stream()
|
||||
.map(MemberWalletLogVO::getOrderAmount)
|
||||
.filter(Objects::nonNull)
|
||||
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
vo.setTotalConsumption(totalConsumption);
|
||||
|
||||
// 总充值
|
||||
// BigDecimal totalRechargeAmount = list.stream()
|
||||
// .filter(x -> StringUtils.equals(x.getType(), "1"))
|
||||
// .filter(x -> StringUtils.equals(x.getSubType(), "10") || StringUtils.equals(x.getSubType(), "11"))
|
||||
// .map(MemberWalletLogVO::getAmount)
|
||||
// .reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
// vo.setTotalRechargeAmount(totalRechargeAmount);
|
||||
BigDecimal totalRechargeAmount = list.stream()
|
||||
.filter(x -> StringUtils.equals(x.getType(), "1"))
|
||||
.filter(x -> StringUtils.equals(x.getSubType(), "10") || StringUtils.equals(x.getSubType(), "11"))
|
||||
.map(MemberWalletLogVO::getAmount)
|
||||
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
vo.setTotalRechargeAmount(totalRechargeAmount);
|
||||
|
||||
// PageInfo<MemberWalletLogVO> pageInfo = new PageInfo<>(list);
|
||||
// 获取 type 和 subType 的对应信息
|
||||
|
||||
Reference in New Issue
Block a user