@@ -1,11 +1,12 @@ | |||
package cn.com.taiji.settlew.api.report; | |||
import cn.com.taiji.common.manager.ManagerException; | |||
import cn.com.taiji.common.model.dao.Pagination; | |||
import cn.com.taiji.common.web.ApiResponse; | |||
import cn.com.taiji.settlew.api.MyValidController; | |||
import cn.com.taiji.settlew.manager.report.ClearDayManager; | |||
import cn.com.taiji.settlew.model.CommonExportResponse; | |||
import cn.com.taiji.settlew.model.report.ClearReportListRequest; | |||
import cn.com.taiji.settlew.model.report.ClearReportPageRequest; | |||
import cn.com.taiji.settlew.model.report.ClearReportResponse; | |||
import io.swagger.annotations.Api; | |||
import io.swagger.annotations.ApiOperation; | |||
@@ -33,12 +34,12 @@ public class ClearDayController extends MyValidController { | |||
@ApiOperation("查询") | |||
@PostMapping("/pageQuery") | |||
public ApiResponse<List<ClearReportResponse>> pageQuery(@Validated @RequestBody ClearReportListRequest req) throws ManagerException { | |||
return ApiResponse.of(manager.query(req)); | |||
public ApiResponse<Pagination> pageQuery(@Validated @RequestBody ClearReportPageRequest req){ | |||
return ApiResponse.of(manager.queryDailyClearReportPage(req)); | |||
} | |||
@ApiOperation("导出") | |||
@PostMapping("/export") | |||
public ApiResponse<CommonExportResponse> exportExcel(@Validated @RequestBody ClearReportListRequest req) throws ManagerException { | |||
public ApiResponse<CommonExportResponse> exportExcel(@Validated @RequestBody ClearReportPageRequest req) throws ManagerException { | |||
return ApiResponse.of(manager.export(req)); | |||
} | |||
} |
@@ -3,6 +3,8 @@ package cn.com.taiji.settlew.dao.jdbc.notice; | |||
import cn.com.taiji.common.model.dao.Pagination; | |||
import cn.com.taiji.settlew.dto.notice.ClearPushCompareDTO; | |||
import cn.com.taiji.settlew.dto.notice.ClearPushCompareQueryDTO; | |||
import cn.com.taiji.settlew.dto.report.ClearDailyReportDTO; | |||
import cn.com.taiji.settlew.model.report.ClearReportPageRequest; | |||
import java.util.List; | |||
@@ -27,4 +29,10 @@ public interface NoticeDao { | |||
*/ | |||
ClearPushCompareDTO queryClearPushCompareSum(ClearPushCompareQueryDTO page); | |||
Pagination queryDailyClearReportPage(ClearReportPageRequest pageRequest); | |||
List<ClearDailyReportDTO> queryDailyClearReportList(ClearReportPageRequest pageRequest); | |||
} |
@@ -5,6 +5,8 @@ import cn.com.taiji.common.model.dao.Pagination; | |||
import cn.com.taiji.settlew.dao.jdbc.BaseDataTemplate; | |||
import cn.com.taiji.settlew.dto.notice.ClearPushCompareDTO; | |||
import cn.com.taiji.settlew.dto.notice.ClearPushCompareQueryDTO; | |||
import cn.com.taiji.settlew.dto.report.ClearDailyReportDTO; | |||
import cn.com.taiji.settlew.model.report.ClearReportPageRequest; | |||
import org.springframework.jdbc.core.RowMapper; | |||
import org.springframework.stereotype.Service; | |||
@@ -25,6 +27,11 @@ public class NoticeJdbcDao extends BaseDataTemplate implements NoticeDao{ | |||
private static final RowMapper<ClearPushCompareDTO> CLEAR_PUSH_COMPARE_DTO_MAPPER = | |||
new EntityRowMapper<>(ClearPushCompareDTO.class); | |||
// 清分日报 | |||
private static final RowMapper<ClearDailyReportDTO> CLEAR_DAILY_REPORT_DTO_MAPPER = | |||
new EntityRowMapper<>(ClearDailyReportDTO.class); | |||
/** | |||
* ETC通行费-清分-推送-到账 分页查询 | |||
* @param page | |||
@@ -64,14 +71,6 @@ public class NoticeJdbcDao extends BaseDataTemplate implements NoticeDao{ | |||
} | |||
@Override | |||
public ClearPushCompareDTO queryClearPushCompareSum(ClearPushCompareQueryDTO page) { | |||
@@ -116,5 +115,59 @@ public class NoticeJdbcDao extends BaseDataTemplate implements NoticeDao{ | |||
return new ClearPushCompareDTO(); | |||
} | |||
@Override | |||
public Pagination queryDailyClearReportPage(ClearReportPageRequest page) { | |||
String startClearDate = page.getStartClearDate(); | |||
String endClearDate = page.getEndClearDate(); | |||
int currPage = page.getPageNo(); | |||
int pageSize = page.getPageSize(); | |||
StringBuilder sql = new StringBuilder(); | |||
List<Object> paramList = new ArrayList<>(); | |||
buildDailyClearReportSql(sql,paramList,startClearDate,endClearDate); | |||
return this.query(sql.toString(), pageSize, currPage, paramList, CLEAR_DAILY_REPORT_DTO_MAPPER); | |||
} | |||
@Override | |||
public List<ClearDailyReportDTO> queryDailyClearReportList(ClearReportPageRequest pageRequest) { | |||
String startClearDate = pageRequest.getStartClearDate(); | |||
String endClearDate = pageRequest.getEndClearDate(); | |||
StringBuilder sql = new StringBuilder(); | |||
List<Object> paramList = new ArrayList<>(); | |||
buildDailyClearReportSql(sql,paramList,startClearDate,endClearDate); | |||
// 转换参数 | |||
Object[] paramObj = paramList.toArray(); | |||
return this.query(sql.toString(), paramObj, CLEAR_DAILY_REPORT_DTO_MAPPER); | |||
} | |||
// 构建清分日报 查询SQL | |||
private void buildDailyClearReportSql(StringBuilder sql, List<Object> paramList,String startClearDate,String endClearDate) { | |||
sql.append(" SELECT CLEAR_DATE,CARD_TYPE,TRADE_TYPE," + | |||
" SUM(COUNT) COUNT," + // 清分文件,交易量 | |||
" SUM(AMOUNT) AMOUNT," + // 清分文件,交易额 | |||
" SUM(CASE WHEN ACCOUNT_TYPE = 'DISPUTE_NOPAY' THEN 0 ELSE COUNT END) AS SYSTEM_ACCOUNT_COUNT, " + //系统记账汇总,交易量 | |||
" SUM(CASE WHEN ACCOUNT_TYPE = 'DISPUTE_NOPAY' THEN 0 ELSE AMOUNT END) AS SYSTEM_ACCOUNT_AMOUNT," + // 系统记账汇总,交易额 | |||
" SUM(PUSHED_COUNT) PUSHED_TOTAL_COUNT," + //总实推交易量(笔) | |||
" SUM(PUSHED_AMOUNT) PUSHED_TOTAL_AMOUNT," + // 总实推交易额 | |||
" SUM(CASE WHEN ETC_CARD_TYPE = 'JZK' THEN COUNT ELSE 0 END) AS JZK_NEED_PUSH_COUNT," + //记账卡应推,交易量(笔) | |||
" SUM(CASE WHEN ETC_CARD_TYPE = 'JZK' THEN AMOUNT ELSE 0 END) AS JZK_NEED_PUSH_AMOUNT," + //记账卡应推,交易额 | |||
" SUM(CASE WHEN ETC_CARD_TYPE = 'JZK' THEN PUSHED_COUNT ELSE 0 END) AS JZK_ACTUAL_PUSH_COUNT," + //记账卡实推,交易量(笔) | |||
" SUM(CASE WHEN ETC_CARD_TYPE = 'JZK' THEN PUSHED_AMOUNT ELSE 0 END) AS JZK_ACTUAL_PUSH_AMOUNT," + //记账卡实推,交易额 | |||
" SUM(CASE WHEN ETC_CARD_TYPE = 'CZK' THEN COUNT ELSE 0 END) AS CZK_NEED_PUSH_COUNT," + //储值卡应推,交易量(笔) | |||
" SUM(CASE WHEN ETC_CARD_TYPE = 'CZK' THEN AMOUNT ELSE 0 END) AS CZK_NEED_PUSH_AMOUNT," + //储值卡应推,交易额 | |||
" SUM(CASE WHEN ETC_CARD_TYPE = 'CZK' THEN PUSHED_COUNT ELSE 0 END) AS CZK_ACTUAL_PUSH_COUNT, " + // 储值卡实推,交易量 | |||
" SUM(CASE WHEN ETC_CARD_TYPE = 'CZK' THEN PUSHED_AMOUNT ELSE 0 END) AS CZK_ACTUAL_PUSH_AMOUNT " + //储值卡实推,交易额 | |||
" from SETTLE_NOTICE where 1=1" ); | |||
if(startClearDate != null && !startClearDate.isEmpty()) { | |||
sql.append(" AND CLEAR_DATE >= ? "); | |||
paramList.add(startClearDate); | |||
} | |||
if(endClearDate != null && !endClearDate.isEmpty()) { | |||
sql.append(" AND CLEAR_DATE <= ? "); | |||
paramList.add(endClearDate); | |||
} | |||
sql.append(" GROUP BY CLEAR_DATE, CARD_TYPE , TRADE_TYPE ORDER BY CLEAR_DATE,CARD_TYPE "); | |||
} | |||
} |
@@ -0,0 +1,96 @@ | |||
package cn.com.taiji.settlew.dto.report; | |||
import cn.com.taiji.common.model.BaseDTO; | |||
import cn.com.taiji.core.entity.dict.settle.CardType; | |||
import cn.com.taiji.core.entity.dict.settle.TradeType; | |||
import io.swagger.annotations.ApiModelProperty; | |||
import lombok.Data; | |||
import javax.persistence.Column; | |||
/** | |||
* @description: 清分日报 信息 | |||
* @author: wangyan | |||
* @date Created in 2025/04/27 11:23 | |||
*/ | |||
@Data | |||
public class ClearDailyReportDTO extends BaseDTO { | |||
@ApiModelProperty(value = "流水类型") | |||
@Column(name = "TRADE_TYPE") | |||
private String tradeType; | |||
private String tradeTypeName; | |||
public String getTradeTypeName() { | |||
TradeType tradeType = TradeType.valueOf(getTradeType()); | |||
return tradeType.getValue(); | |||
} | |||
@ApiModelProperty(value = "清分日期") | |||
@Column(name = "CLEAR_DATE") | |||
private String clearDate; | |||
@ApiModelProperty(value = "卡类型") | |||
@Column(name = "CARD_TYPE") | |||
private String cardType; | |||
@ApiModelProperty(value = "清分机构") | |||
private String clearAgency; | |||
public String getClearAgency() { | |||
CardType cardType = CardType.valueOf(getCardType()); | |||
return cardType.getIssuerEnum().getValue(); | |||
} | |||
@ApiModelProperty(value = "清分文件,交易量") | |||
@Column(name = "COUNT") | |||
private Long count; | |||
@ApiModelProperty(value = "清分文件,交易额") | |||
@Column(name = "AMOUNT") | |||
private Long amount; | |||
@ApiModelProperty(value = "系统记账汇总,交易量") | |||
@Column(name = "SYSTEM_ACCOUNT_COUNT") | |||
private Long systemAccountCount; | |||
@ApiModelProperty(value = "系统记账汇总,交易额") | |||
@Column(name = "SYSTEM_ACCOUNT_AMOUNT") | |||
private Long systemAccountAmount; | |||
@ApiModelProperty(value = "清分记账对比结果") | |||
private String status; | |||
public String getStatus() { | |||
// 清分 和 系统记账汇总 FIXME 需要确认 是 amount 和 systemAccountAmount 的关系 还是 amount 和 pushTotalAmount 的关系 | |||
//{ label: '正常', value: 'NORMAL' },{ label: '异常', value: 'ERROR' },{ label: '重算中', value: 'RESUM' }, | |||
return (amount == null? 0 : amount.longValue()) == (pushTotalAmount == null ? 0 : pushTotalAmount.longValue()) ? "NORMAL" : "ERROR"; | |||
} | |||
@ApiModelProperty(value = "实推日") | |||
private String realPushTime; | |||
@ApiModelProperty(value = "总实推交易量(笔)") | |||
@Column(name = "PUSHED_TOTAL_COUNT") | |||
private Long pushTotalCount; | |||
@ApiModelProperty(value = "总实推交易额") | |||
@Column(name = "PUSHED_TOTAL_AMOUNT") | |||
private Long pushTotalAmount; | |||
@ApiModelProperty(value = "记账卡应推,交易量(笔)") | |||
@Column(name = "JZK_NEED_PUSH_COUNT") | |||
private Long jzkNeedPushCount; | |||
@ApiModelProperty(value = "记账卡应推,交易额") | |||
@Column(name = "JZK_NEED_PUSH_AMOUNT") | |||
private Long jzkNeedPushAmount; | |||
@ApiModelProperty(value = "记账卡实推,交易量(笔)") | |||
@Column(name = "JZK_ACTUAL_PUSH_COUNT") | |||
private Long jzkActualPushCount; | |||
@ApiModelProperty(value = "记账卡实推,交易额") | |||
@Column(name = "JZK_ACTUAL_PUSH_AMOUNT") | |||
private Long jzkActualPushAmount; | |||
@ApiModelProperty(value = "储值卡应推,交易量(笔)") | |||
@Column(name = "CZK_NEED_PUSH_COUNT") | |||
private Long czkNeedPushCount; | |||
@ApiModelProperty(value = "储值卡应推,交易额") | |||
@Column(name = "CZK_NEED_PUSH_AMOUNT") | |||
private Long czkNeedPushAmount; | |||
@ApiModelProperty(value = "储值卡实推,交易量(笔)") | |||
@Column(name = "CZK_ACTUAL_PUSH_COUNT") | |||
private Long czkActualPushCount; | |||
@ApiModelProperty(value = "储值卡实推,交易额") | |||
@Column(name = "CZK_ACTUAL_PUSH_AMOUNT") | |||
private Long czkActualPushAmount; | |||
} |
@@ -1,8 +1,10 @@ | |||
package cn.com.taiji.settlew.manager.report; | |||
import cn.com.taiji.common.manager.ManagerException; | |||
import cn.com.taiji.common.model.dao.Pagination; | |||
import cn.com.taiji.settlew.dto.report.ClearDailyReportDTO; | |||
import cn.com.taiji.settlew.model.CommonExportResponse; | |||
import cn.com.taiji.settlew.model.report.ClearReportListRequest; | |||
import cn.com.taiji.settlew.model.report.ClearReportPageRequest; | |||
import cn.com.taiji.settlew.model.report.ClearReportResponse; | |||
import java.util.List; | |||
@@ -14,7 +16,11 @@ import java.util.List; | |||
*/ | |||
public interface ClearDayManager { | |||
List<ClearReportResponse> query(ClearReportListRequest request); | |||
List<ClearReportResponse> query(ClearReportPageRequest request); | |||
CommonExportResponse export(ClearReportListRequest req) throws ManagerException; | |||
Pagination queryDailyClearReportPage(ClearReportPageRequest request); | |||
List<ClearDailyReportDTO> queryDailyClearReportList(ClearReportPageRequest request); | |||
CommonExportResponse export(ClearReportPageRequest req) throws ManagerException; | |||
} |
@@ -3,7 +3,10 @@ package cn.com.taiji.settlew.manager.report; | |||
import cn.com.taiji.common.manager.AbstractManager; | |||
import cn.com.taiji.common.manager.ManagerException; | |||
import cn.com.taiji.common.manager.pub.FileHelper; | |||
import cn.com.taiji.common.model.dao.Pagination; | |||
import cn.com.taiji.common.pub.AppEnv; | |||
import cn.com.taiji.common.pub.BeanTools; | |||
import cn.com.taiji.common.pub.LambdaTools; | |||
import cn.com.taiji.core.entity.dict.BucketFileBus; | |||
import cn.com.taiji.core.entity.dict.settle.AccountType; | |||
import cn.com.taiji.core.entity.dict.settle.CardType; | |||
@@ -12,10 +15,15 @@ import cn.com.taiji.core.entity.dict.settle.TradeType; | |||
import cn.com.taiji.core.entity.settle.notice.Notice; | |||
import cn.com.taiji.core.manager.tools.minio.MinioUtil; | |||
import cn.com.taiji.core.repo.jpa.settle.notice.NoticeRepo; | |||
import cn.com.taiji.settlew.dao.jdbc.notice.NoticeDao; | |||
import cn.com.taiji.settlew.dto.report.ClearDailyReportDTO; | |||
import cn.com.taiji.settlew.dto.report.EtcTollConfirmZfbDTO; | |||
import cn.com.taiji.settlew.model.CommonExportResponse; | |||
import cn.com.taiji.settlew.model.report.ClearReportListRequest; | |||
import cn.com.taiji.settlew.model.report.ClearReportPageRequest; | |||
import cn.com.taiji.settlew.model.report.ClearReportResponse; | |||
import cn.com.taiji.settlew.util.NumberConvert; | |||
import cn.com.taiji.settlew.vo.report.ClearDailyReportVo; | |||
import cn.com.taiji.settlew.vo.report.EtcTollConfirmZfbVo; | |||
import com.alibaba.excel.EasyExcel; | |||
import com.alibaba.excel.ExcelWriter; | |||
import org.apache.commons.compress.utils.Lists; | |||
@@ -23,8 +31,6 @@ import org.springframework.beans.factory.annotation.Autowired; | |||
import org.springframework.stereotype.Service; | |||
import java.io.File; | |||
import java.math.BigDecimal; | |||
import java.math.RoundingMode; | |||
import java.time.LocalDateTime; | |||
import java.time.format.DateTimeFormatter; | |||
import java.util.List; | |||
@@ -32,7 +38,7 @@ import java.util.Map; | |||
import java.util.stream.Collectors; | |||
/** | |||
* @description: | |||
* @description: 清分日报 | |||
* @author: wangyan | |||
* @date Created in 2025/04/27 11:18 | |||
*/ | |||
@@ -44,17 +50,23 @@ public class ClearDayManagerImpl extends AbstractManager implements ClearDayMana | |||
@Autowired | |||
private MinioUtil minioUtil; | |||
@Autowired | |||
private NoticeDao noticeDao; | |||
/** | |||
* 此方法实现方式不合理,先过期处理 | |||
*/ | |||
@Deprecated | |||
@Override | |||
public List<ClearReportResponse> query(ClearReportListRequest request) { | |||
List<Notice> result=noticeRepo.getClearDayReport(request.getClearDate()); | |||
public List<ClearReportResponse> query(ClearReportPageRequest request) { | |||
List<Notice> result=noticeRepo.getClearDayReport(request.getStartClearDate()); | |||
Map<CardType, Map<TradeType, List<Notice>>> groupedNotices = result.stream().collect(Collectors.groupingBy(Notice::getCardType, Collectors.groupingBy(Notice::getTradeType))); | |||
// 整合分组结果 | |||
List<ClearReportResponse> responses= Lists.newArrayList(); | |||
groupedNotices.forEach((cardType, tradeMap) -> { | |||
tradeMap.forEach((tradeType, noticesList) -> { | |||
ClearReportResponse response=new ClearReportResponse(); | |||
response.setClearDate(request.getClearDate()); | |||
response.setClearDate(request.getStartClearDate()); | |||
response.setClearAgency(cardType.getIssuerEnum().getValue()); | |||
response.setTradeType(tradeType.getValue()); | |||
//计算合值 | |||
@@ -94,18 +106,30 @@ public class ClearDayManagerImpl extends AbstractManager implements ClearDayMana | |||
} | |||
@Override | |||
public CommonExportResponse export(ClearReportListRequest req) throws ManagerException { | |||
CommonExportResponse response=new CommonExportResponse(); | |||
List<ClearReportResponse> result=this.query(req); | |||
public Pagination queryDailyClearReportPage(ClearReportPageRequest request) { | |||
return noticeDao.queryDailyClearReportPage(request); | |||
} | |||
@Override | |||
public List<ClearDailyReportDTO> queryDailyClearReportList(ClearReportPageRequest request) { | |||
return noticeDao.queryDailyClearReportList(request); | |||
} | |||
@Override | |||
public CommonExportResponse export(ClearReportPageRequest req) throws ManagerException { | |||
CommonExportResponse response = new CommonExportResponse(); | |||
// 查询日报单 满足条件的全量数据 | |||
List<ClearDailyReportDTO> dtoList = queryDailyClearReportList(req); | |||
// 将分转为元,方便输出到excel | |||
List<ClearDailyReportVo> voList= LambdaTools.doMap(dtoList,this::dtoConvertVo); | |||
// 获取模板 | |||
File templateFile = new File(AppEnv.getDataPath() + "clearDayExportExcel.xlsx"); | |||
DateTimeFormatter formatter= DateTimeFormatter.ofPattern("yyyy-MM-dd"); | |||
String fileName = LocalDateTime.now().format(formatter)+"清分日报.xlsx"; | |||
String fileName = req.getStartClearDate() + "-" + req.getEndClearDate() +"清分日报.xlsx"; | |||
// 创建输出文件 | |||
File targetFile = new File(AppEnv.getTmpPath() + fileName); | |||
// 填充数据 | |||
try (ExcelWriter excelWriter = EasyExcel.write(targetFile).withTemplate(templateFile).build()) { | |||
excelWriter.fill(result, EasyExcel.writerSheet("sheet1").build()); | |||
excelWriter.fill(voList, EasyExcel.writerSheet("sheet1").build()); | |||
} | |||
// 上传minio | |||
String url = minioUtil.fileUploadHttp(targetFile, BucketFileBus.SETTLEW); | |||
@@ -115,4 +139,27 @@ public class ClearDayManagerImpl extends AbstractManager implements ClearDayMana | |||
return response; | |||
} | |||
// 将 DTO 中的分 转为 VO 的元 | |||
public ClearDailyReportVo dtoConvertVo(ClearDailyReportDTO from) { | |||
ClearDailyReportVo reportVo =new ClearDailyReportVo(); | |||
BeanTools.copyProperties(from,reportVo); | |||
//清分文件,交易额 | |||
reportVo.setAmount(NumberConvert.fenToYuan(from.getAmount())); | |||
//系统记账汇总,交易额 | |||
reportVo.setSystemAccountAmount(NumberConvert.fenToYuan(from.getSystemAccountAmount())); | |||
//总实推交易额 | |||
reportVo.setPushTotalAmount(NumberConvert.fenToYuan(from.getPushTotalAmount())); | |||
//记账卡应推,交易额 | |||
reportVo.setJzkNeedPushAmount(NumberConvert.fenToYuan(from.getJzkNeedPushAmount())); | |||
//记账卡实推,交易额 | |||
reportVo.setJzkActualPushAmount(NumberConvert.fenToYuan(from.getJzkActualPushAmount())); | |||
//储值卡应推,交易额 | |||
reportVo.setCzkNeedPushAmount(NumberConvert.fenToYuan(from.getCzkNeedPushAmount())); | |||
//储值卡实推,交易额 | |||
reportVo.setCzkActualPushAmount(NumberConvert.fenToYuan(from.getCzkActualPushAmount())); | |||
return reportVo; | |||
} | |||
} |
@@ -1,22 +1,27 @@ | |||
package cn.com.taiji.settlew.model.report; | |||
import cn.com.taiji.common.valid.ViolationValidator; | |||
import cn.com.taiji.core.dto.AbstractStaffBizRequestDTO; | |||
import cn.com.taiji.core.dto.AbstractStaffBizPageRequestDTO; | |||
import io.swagger.annotations.ApiModelProperty; | |||
import lombok.Data; | |||
import javax.validation.constraints.NotBlank; | |||
/** | |||
* @description: | |||
* @description: 清分日报分页查询 | |||
* @author: wangyan | |||
* @date Created in 2025/04/27 11:21 | |||
*/ | |||
@Data | |||
public class ClearReportListRequest extends AbstractStaffBizRequestDTO { | |||
public class ClearReportPageRequest extends AbstractStaffBizPageRequestDTO { | |||
@ApiModelProperty(value = "清分日期") | |||
@ApiModelProperty(value = "清分开始日期") | |||
@NotBlank | |||
private String clearDate; | |||
private String startClearDate; | |||
@ApiModelProperty(value = "清分结束日期") | |||
@NotBlank | |||
private String endClearDate; | |||
@Override | |||
protected void validate(ViolationValidator validator) { | |||
@@ -1,6 +1,7 @@ | |||
package cn.com.taiji.settlew.vo.mobilepay; | |||
import cn.com.taiji.common.model.BaseModel; | |||
import cn.com.taiji.core.entity.dict.settle.PayBillBizType; | |||
import lombok.Data; | |||
import java.math.BigDecimal; | |||
@@ -20,6 +21,11 @@ public class InpPayBillVo extends BaseModel { | |||
private String endClearDate; | |||
//业务类型 | |||
private String bizType; | |||
private String bizTypeName; | |||
public String getBizTypeName() { | |||
PayBillBizType payBillBizType = PayBillBizType.fromCode(bizType); | |||
return payBillBizType.getValue(); | |||
} | |||
//付款金额 | |||
private BigDecimal payAmount; | |||
//收款方名称 |
@@ -1,6 +1,7 @@ | |||
package cn.com.taiji.settlew.vo.mobilepay; | |||
import cn.com.taiji.common.model.BaseModel; | |||
import cn.com.taiji.core.entity.dict.settle.PayBillBizType; | |||
import lombok.Data; | |||
import java.math.BigDecimal; | |||
@@ -20,6 +21,12 @@ public class OutPayBillVo extends BaseModel { | |||
private String endClearDate; | |||
//业务类型 | |||
private String bizType; | |||
private String bizTypeName; | |||
public String getBizTypeName() { | |||
PayBillBizType bizType = PayBillBizType.fromCode(getBizType()); | |||
return bizType.getValue(); | |||
} | |||
//付款金额 | |||
private BigDecimal payAmount; | |||
//收款方名称 |
@@ -0,0 +1,75 @@ | |||
package cn.com.taiji.settlew.vo.report; | |||
import cn.com.taiji.common.model.BaseDTO; | |||
import cn.com.taiji.core.entity.dict.settle.TradeType; | |||
import io.swagger.annotations.ApiModelProperty; | |||
import lombok.Data; | |||
import java.math.BigDecimal; | |||
/** | |||
* @description: 清分日报 信息 - 用于输出 - 元 | |||
* @author: wangyan | |||
* @date Created in 2025/04/27 11:23 | |||
*/ | |||
@Data | |||
public class ClearDailyReportVo extends BaseDTO { | |||
@ApiModelProperty(value = "流水类型") | |||
private String tradeType; | |||
private String tradeTypeName; | |||
public String getTradeTypeName() { | |||
TradeType tradeType = TradeType.valueOf(getTradeType()); | |||
return tradeType.getValue(); | |||
} | |||
@ApiModelProperty(value = "清分日期") | |||
private String clearDate; | |||
@ApiModelProperty(value = "卡类型") | |||
private String cardType; | |||
@ApiModelProperty(value = "清分机构") | |||
private String clearAgency; | |||
@ApiModelProperty(value = "清分文件,交易量") | |||
private Long count; | |||
@ApiModelProperty(value = "清分文件,交易额") | |||
private BigDecimal amount; | |||
@ApiModelProperty(value = "系统记账汇总,交易量") | |||
private Long systemAccountCount; | |||
@ApiModelProperty(value = "系统记账汇总,交易额") | |||
private BigDecimal systemAccountAmount; | |||
@ApiModelProperty(value = "清分记账对比结果") | |||
private String status; | |||
public String getStatus() { | |||
// 清分 和 系统记账汇总 FIXME 需要确认 是 amount 和 systemAccountAmount 的关系 还是 amount 和 pushTotalAmount 的关系 | |||
//{ label: '正常', value: 'NORMAL' },{ label: '异常', value: 'ERROR' },{ label: '重算中', value: 'RESUM' }, | |||
return (amount == null? 0 : amount.longValue()) == (pushTotalAmount == null ? 0 : pushTotalAmount.longValue()) ? "NORMAL" : "ERROR"; | |||
} | |||
@ApiModelProperty(value = "实推日") | |||
private String realPushTime; | |||
@ApiModelProperty(value = "总实推交易量(笔)") | |||
private Long pushTotalCount; | |||
@ApiModelProperty(value = "总实推交易额") | |||
private BigDecimal pushTotalAmount; | |||
@ApiModelProperty(value = "记账卡应推,交易量(笔)") | |||
private Long jzkNeedPushCount; | |||
@ApiModelProperty(value = "记账卡应推,交易额") | |||
private BigDecimal jzkNeedPushAmount; | |||
@ApiModelProperty(value = "记账卡实推,交易量(笔)") | |||
private Long jzkActualPushCount; | |||
@ApiModelProperty(value = "记账卡实推,交易额") | |||
private BigDecimal jzkActualPushAmount; | |||
@ApiModelProperty(value = "储值卡应推,交易量(笔)") | |||
private Long czkNeedPushCount; | |||
@ApiModelProperty(value = "储值卡应推,交易额") | |||
private BigDecimal czkNeedPushAmount; | |||
@ApiModelProperty(value = "储值卡实推,交易量(笔)") | |||
private Long czkActualPushCount; | |||
@ApiModelProperty(value = "储值卡实推,交易额") | |||
private BigDecimal czkActualPushAmount; | |||
} |