Commit b5f199a4 authored by libin's avatar libin

钱包

parent 7c8f87d1
......@@ -4,6 +4,10 @@ import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.math.BigDecimal;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
/**
* @author libin
......@@ -42,14 +46,16 @@ public class SellingWalletVo {
@ApiModelProperty(value = "售价")
private BigDecimal price;
@ApiModelProperty(value = "创建时间", hidden = true )
@ApiModelProperty(value = "创建时间", hidden = true)
private Long crtTime;
@ApiModelProperty(value = "更新时间", hidden = true )
@ApiModelProperty(value = "更新时间", hidden = true)
private Long updTime;
@ApiModelProperty("是否入账:0-未入账;1-已入账")
private Integer waiting;
@ApiModelProperty("'类别:0-正;1-负(退款时)")
private Integer status;
/**
* 所获佣金
......
package com.github.wxiaoqi.security.admin.vo;
import com.alibaba.fastjson.JSON;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.beans.BeanUtils;
import java.math.BigDecimal;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/**
* @author libin
......
......@@ -15,6 +15,7 @@ import tk.mybatis.mapper.entity.Example;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Optional;
......@@ -40,6 +41,11 @@ public class MyWalletCathBiz extends BaseBiz<MyWalletCathMapper, MyWalletCath> {
List<MyWalletCath> walletCaths = walletCathPage.getData();
if (CollectionUtils.isEmpty(walletCaths)){
walletCathPageVo.setPageNum(pageNo);
walletCathPageVo.setPageSize(pageSize);
walletCathPageVo.setTotalCount(0);
walletCathPageVo.setTotalPage(0);
walletCathPageVo.setWalletCaths(Collections.EMPTY_LIST);
return walletCathPageVo;
}
......
......@@ -33,14 +33,14 @@ public class MyWalletDetailBiz extends BaseBiz<MyWalletDetailMapper, MyWalletDet
Example.Criteria criteria = example.createCriteria();
criteria.andEqualTo("userId",userId);
PageDataVO<WalletDetailPageVo> walletDetailPageVoPageDataVO = PageDataVO.pageInfo(pageNo, pageSize, () -> mapper.selectByExample(example));
List<WalletDetailPageVo> walletDetails = walletDetailPageVoPageDataVO.getData();
PageDataVO<MyWalletDetail> walletDetailPageVoPageDataVO = PageDataVO.pageInfo(pageNo, pageSize, () -> mapper.selectByExample(example));
List<MyWalletDetail> walletDetails = walletDetailPageVoPageDataVO.getData();
if (CollectionUtils.isEmpty(walletDetails)){
return walletDetailPageVo;
}
List<WalletDetailPageVo> walletDetailPageVoList = new ArrayList<>();
WalletDetailPageVo walletDetail;
for (WalletDetailPageVo walletDetailPage : walletDetails) {
for (MyWalletDetail walletDetailPage : walletDetails) {
walletDetail = new WalletDetailPageVo();
BeanUtils.copyProperties(walletDetailPage,walletDetail);
walletDetailPageVoList.add(walletDetail);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment