个税云参数调整

This commit is contained in:
钱涛 2023-12-01 11:46:21 +08:00
parent 819937edeb
commit 121da2f7ad
2 changed files with 4 additions and 4 deletions

View File

@ -43,7 +43,7 @@ public class QueryAccountBalanceResponse {
/**
* 税号
*/
private String taxNumber;
private String taxNum;
/**
* 已使用流量
*/

View File

@ -62,7 +62,7 @@ public class TaxDeclarationApiFlowStatisticServiceImpl extends Service implement
return TaxDeclarationApiFlowTotalDTO.builder()
.total(apiConfigPO.getTotality())
.remain(apiConfigPO.getRemain())
.used(apiConfigPO.getTotality() - apiConfigPO.getRemain())
.used(Long.parseLong(response.getBody().getSurplus()))
.lastUpdateTime(SalaryDateUtil.getFormatLocalDateTime(apiConfigPO.getLastUpdateTime()))
.build();
}
@ -81,7 +81,7 @@ public class TaxDeclarationApiFlowStatisticServiceImpl extends Service implement
log.info("details is empty");
return new ArrayList<>();
}
Set<String> taxCodes = details.stream().map(QueryAccountBalanceResponse.Detail::getTaxNumber).collect(Collectors.toSet());
Set<String> taxCodes = details.stream().map(QueryAccountBalanceResponse.Detail::getTaxNum).collect(Collectors.toSet());
List<TaxAgentTaxReturnPO> returnPOList = getTaxAgentTaxReturnService(user).getByTaxCodes(taxCodes);
if (returnPOList.isEmpty()) {
log.info("TaxAgentTaxReturnPO is empty");
@ -98,7 +98,7 @@ public class TaxDeclarationApiFlowStatisticServiceImpl extends Service implement
Map<String, List<TaxAgentTaxReturnPO>> taxCodeMap = returnPOList.stream().collect(Collectors.groupingBy(TaxAgentTaxReturnPO::getTaxCode));
List<TaxDeclarationApiFlowStatisticListDTO> flowStatisticDTOS = new ArrayList<>();
for (QueryAccountBalanceResponse.Detail detail : details) {
List<TaxAgentTaxReturnPO> list = taxCodeMap.getOrDefault(detail.getTaxNumber(), new ArrayList<>());
List<TaxAgentTaxReturnPO> list = taxCodeMap.getOrDefault(detail.getTaxNum(), new ArrayList<>());
for (TaxAgentTaxReturnPO returnPO : list) {
TaxDeclarationApiFlowStatisticListDTO statisticDTO = new TaxDeclarationApiFlowStatisticListDTO();
statisticDTO.setId(IdGenerator.generate());