diff --git a/src/com/engine/salary/entity/taxapiflow/response/QueryAccountBalanceResponse.java b/src/com/engine/salary/entity/taxapiflow/response/QueryAccountBalanceResponse.java index 67779fd42..4c5cb33e3 100644 --- a/src/com/engine/salary/entity/taxapiflow/response/QueryAccountBalanceResponse.java +++ b/src/com/engine/salary/entity/taxapiflow/response/QueryAccountBalanceResponse.java @@ -43,7 +43,7 @@ public class QueryAccountBalanceResponse { /** * 税号 */ - private String taxNumber; + private String taxNum; /** * 已使用流量 */ diff --git a/src/com/engine/salary/service/impl/TaxDeclarationApiFlowStatisticServiceImpl.java b/src/com/engine/salary/service/impl/TaxDeclarationApiFlowStatisticServiceImpl.java index 2a2e51fed..7d09f19f1 100644 --- a/src/com/engine/salary/service/impl/TaxDeclarationApiFlowStatisticServiceImpl.java +++ b/src/com/engine/salary/service/impl/TaxDeclarationApiFlowStatisticServiceImpl.java @@ -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 taxCodes = details.stream().map(QueryAccountBalanceResponse.Detail::getTaxNumber).collect(Collectors.toSet()); + Set taxCodes = details.stream().map(QueryAccountBalanceResponse.Detail::getTaxNum).collect(Collectors.toSet()); List returnPOList = getTaxAgentTaxReturnService(user).getByTaxCodes(taxCodes); if (returnPOList.isEmpty()) { log.info("TaxAgentTaxReturnPO is empty"); @@ -98,7 +98,7 @@ public class TaxDeclarationApiFlowStatisticServiceImpl extends Service implement Map> taxCodeMap = returnPOList.stream().collect(Collectors.groupingBy(TaxAgentTaxReturnPO::getTaxCode)); List flowStatisticDTOS = new ArrayList<>(); for (QueryAccountBalanceResponse.Detail detail : details) { - List list = taxCodeMap.getOrDefault(detail.getTaxNumber(), new ArrayList<>()); + List list = taxCodeMap.getOrDefault(detail.getTaxNum(), new ArrayList<>()); for (TaxAgentTaxReturnPO returnPO : list) { TaxDeclarationApiFlowStatisticListDTO statisticDTO = new TaxDeclarationApiFlowStatisticListDTO(); statisticDTO.setId(IdGenerator.generate());