Browse Source

收益明细

master
张彭杰 1 year ago
parent
commit
30c16fb61e
2 changed files with 17 additions and 1 deletions
  1. 7
      dating-agency-mall-server/src/main/java/com/qniao/dam/api/query/walletaccount/user/response/UsePageWalletAccountRecordByOperatorVo.java
  2. 11
      dating-agency-mall-server/src/main/java/com/qniao/dam/query/walletaccount/impl/WalletAccountQueryServiceImpl.java

7
dating-agency-mall-server/src/main/java/com/qniao/dam/api/query/walletaccount/user/response/UsePageWalletAccountRecordByOperatorVo.java

@ -5,6 +5,7 @@ import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.qniao.dam.domian.aggregate.product.constant.ProductSubCategoryEnum;
import com.qniao.dam.domian.aggregate.walletaccount.constant.TradeTypeEnum;
import com.qniao.dau.domian.aggregate.matchmaker.constant.MatchmakerLevelEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
@ -34,9 +35,15 @@ public class UsePageWalletAccountRecordByOperatorVo {
@ApiModelProperty("手机号")
private String phone;
@ApiModelProperty("红娘用户ID")
private Long matchmakerUserId;
@ApiModelProperty("红娘身份类型")
private ProductSubCategoryEnum matchmakerType;
@ApiModelProperty("红娘等级")
private MatchmakerLevelEnum matchmakerLevel;
@ApiModelProperty("交易金额")
private BigDecimal tradeAmount;

11
dating-agency-mall-server/src/main/java/com/qniao/dam/query/walletaccount/impl/WalletAccountQueryServiceImpl.java

@ -12,6 +12,7 @@ import com.qniao.dam.domian.aggregate.walletaccount.constant.IdentityTypeEnum;
import com.qniao.dam.domian.aggregate.walletaccount.constant.TradeTypeEnum;
import com.qniao.dam.infrastructure.persistent.dao.domain.WalletAccountRecordDao;
import com.qniao.dam.infrastructure.persistent.dao.view.WalletAccountViewDao;
import com.qniao.dam.query.matchmaker.MatchmakerQueryService;
import com.qniao.dam.query.walletaccount.WalletAccountQueryService;
import com.qniao.dam.domain.aggregate.walletaccount.entity.WalletAccount;
import com.qniao.dam.infrastructure.persistent.dao.domain.WalletAccountDao;
@ -35,6 +36,8 @@ public class WalletAccountQueryServiceImpl implements WalletAccountQueryService
private WalletAccountViewDao walletAccountViewDao;
@Resource
private WalletAccountRecordDao walletAccountRecordDao;
@Resource
private MatchmakerQueryService matchmakerQueryService;
@Override
public WalletAccount queryByUserId(Long userId) {
@ -94,7 +97,13 @@ public class WalletAccountQueryServiceImpl implements WalletAccountQueryService
@Override
public IPage<UsePageWalletAccountRecordByOperatorVo> pageWalletAccountRecordByOperator(PageUtil pageUtil, UsePageWalletAccountRecordByOperatorQueryParams queryParams) {
return walletAccountViewDao.pageWalletAccountRecordByOperator(pageUtil.toPageWithoutOrders(),queryParams);
IPage<UsePageWalletAccountRecordByOperatorVo> page = walletAccountViewDao.pageWalletAccountRecordByOperator(pageUtil.toPageWithoutOrders(), queryParams);
if (page.getRecords().size() > 0) {
page.getRecords().forEach(record -> {
record.setMatchmakerLevel(matchmakerQueryService.queryLevelByUserId(record.getMatchmakerUserId()));
});
}
return page;
}
private BigDecimal countUnavailableWithdrawBalance(Long walletAccountId, LocalDate date, int month) {

Loading…
Cancel
Save