fix: 人情账单,增加借款时长。
This commit is contained in:
@@ -35,4 +35,8 @@ public class InstallmentHistoryVo extends InstallmentHistory
|
||||
@ApiModelProperty(value="剩余利息)")
|
||||
private Double outstandingInterest;
|
||||
|
||||
|
||||
@ApiModelProperty(value="借款天数")
|
||||
private String loanDays;
|
||||
|
||||
}
|
||||
|
||||
@@ -19,6 +19,7 @@ import javax.annotation.Resource;
|
||||
import java.text.DecimalFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@@ -61,6 +62,13 @@ public class InstallmentHistoryServiceImpl implements IInstallmentHistoryService
|
||||
//修改名称加卡号
|
||||
DecimalFormat decimalFormat = new DecimalFormat("#.##");
|
||||
for (InstallmentHistoryVo installmentHistory : installmentHistoryVoList) {
|
||||
String daysBetween="";
|
||||
if(installmentHistory.getCloseDate()!=null){
|
||||
daysBetween = DateUtils.timeDistance(installmentHistory.getCloseDate(),installmentHistory.getInstallmentDate());
|
||||
}else {
|
||||
daysBetween = DateUtils.timeDistance(new Date(),installmentHistory.getInstallmentDate());
|
||||
}
|
||||
installmentHistory.setLoanDays(daysBetween);
|
||||
if(installmentHistory.getBankCode()!=null){
|
||||
installmentHistory.setBankNameCode(installmentHistory.getBankName()+"("+ StringUtils.getLastNumberChars(4,installmentHistory.getBankCode()+")"));
|
||||
}else {
|
||||
|
||||
Reference in New Issue
Block a user