计算金额

This commit is contained in:
wangw 2025-10-27 21:15:30 +08:00
parent fb191b0539
commit d6c7402b11
1 changed files with 12 additions and 13 deletions

View File

@ -13,29 +13,28 @@ public class DistributionCenterTopVO {
/**
* 总收益
*/
private BigDecimal totalIncome;
private String totalIncome;
/**
* 待入账
*/
private BigDecimal pendingIncome;
private String pendingIncome;
/**
* 已提现
*/
private BigDecimal cashOutAmount;
private String cashOutAmount;
public BigDecimal getTotalIncome() {
return totalIncome == null ? BigDecimal.ZERO : totalIncome;
public String getTotalIncome() {
return totalIncome == null ? "0" : totalIncome;
}
public String getPendingIncome() {
return pendingIncome == null ? "0" : pendingIncome;
}
public BigDecimal getPendingIncome() {
return pendingIncome == null ? BigDecimal.ZERO : pendingIncome;
public String getCashOutAmount() {
return cashOutAmount == null ? "0" : cashOutAmount;
}
public BigDecimal getCashOutAmount() {
return cashOutAmount == null ? BigDecimal.ZERO : cashOutAmount;
}
public BigDecimal getUnCashOutAmount() {
return getTotalIncome().subtract(getPendingIncome()).subtract(getCashOutAmount());
public String getUnCashOutAmount() {
return new BigDecimal(getTotalIncome()).subtract(new BigDecimal(getPendingIncome())).subtract(new BigDecimal(getCashOutAmount())).toString();
}
}