| | |
| | | import com.by4cloud.platformx.admin.api.entity.SysDictItem; |
| | | import com.by4cloud.platformx.admin.api.feign.RemoteDeptService; |
| | | import com.by4cloud.platformx.admin.api.feign.RemoteDictService; |
| | | import com.by4cloud.platformx.business.dto.AgingQueryDTO; |
| | | import com.by4cloud.platformx.business.dto.AnalysisCommonDTO; |
| | | import com.by4cloud.platformx.business.entity.BusinessCustomer; |
| | | import com.by4cloud.platformx.business.mapper.BusinessCustomerMapper; |
| | | import com.by4cloud.platformx.business.mapper.ContractMapper; |
| | | import com.by4cloud.platformx.business.mapper.ContractPaymentScheduleMapper; |
| | | import com.by4cloud.platformx.business.service.StatisticService; |
| | | import com.by4cloud.platformx.business.vo.*; |
| | | import com.by4cloud.platformx.common.core.util.R; |
| | | import com.by4cloud.platformx.common.data.datascope.DataScope; |
| | | import com.by4cloud.platformx.common.security.util.SecurityUtils; |
| | | import lombok.RequiredArgsConstructor; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.math.RoundingMode; |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | import java.util.stream.IntStream; |
| | | |
| | | @Service |
| | | @RequiredArgsConstructor |
| | | public class StatisticServiceImpl implements StatisticService { |
| | | |
| | | private final ContractMapper contractMapper; |
| | | private final ContractPaymentScheduleMapper contractPaymentScheduleMapper; |
| | | private final BusinessCustomerMapper businessCustomerMapper; |
| | | private final RemoteDeptService remoteDeptService; |
| | | private final RemoteDictService remoteDictService; |
| | | |
| | |
| | | R<List<SysDictItem>> r = remoteDictService.getDictByType("company_area"); |
| | | List<SysDictItem> items = r.getData(); |
| | | if (ArrayUtil.isEmpty(items.toArray())){ |
| | | return R.failed("区域字段获取异常"); |
| | | return R.failed("地区字典分类获取异常"); |
| | | } |
| | | List<Long> compIds = new ArrayList<>(); |
| | | compIds.add(Long.valueOf(sgb)); |
| | |
| | | R<List<SysDictItem>> r = remoteDictService.getDictByType("industry_sector"); |
| | | List<SysDictItem> items = r.getData(); |
| | | if (ArrayUtil.isEmpty(items.toArray())){ |
| | | return R.failed("区域字段获取异常"); |
| | | return R.failed("行业字典分类获取异常"); |
| | | } |
| | | List<Long> compIds = new ArrayList<>(); |
| | | compIds.add(Long.valueOf(sgb)); |
| | |
| | | R<List<SysDictItem>> r = remoteDictService.getDictByType("market_type"); |
| | | List<SysDictItem> items = r.getData(); |
| | | if (ArrayUtil.isEmpty(items.toArray())){ |
| | | return R.failed("区域字段获取异常"); |
| | | return R.failed("市场类型字典分类获取异常"); |
| | | } |
| | | List<Long> compIds = new ArrayList<>(); |
| | | compIds.add(Long.valueOf(sgb)); |
| | |
| | | R<List<SysDictItem>> r = remoteDictService.getDictByType("supply_attribute"); |
| | | List<SysDictItem> items = r.getData(); |
| | | if (ArrayUtil.isEmpty(items.toArray())){ |
| | | return R.failed("区域字段获取异常"); |
| | | return R.failed("供应属性字典分类获取异常"); |
| | | } |
| | | List<Long> compIds = new ArrayList<>(); |
| | | compIds.add(Long.valueOf(sgb)); |
| | |
| | | R<List<SysDictItem>> r = remoteDictService.getDictByType("sales_model"); |
| | | List<SysDictItem> items = r.getData(); |
| | | if (ArrayUtil.isEmpty(items.toArray())){ |
| | | return R.failed("区域字段获取异常"); |
| | | return R.failed("销售模式字典分类获取异常"); |
| | | } |
| | | List<Long> compIds = new ArrayList<>(); |
| | | compIds.add(Long.valueOf(sgb)); |
| | |
| | | }); |
| | | return R.ok(contractIncomeAnalysisVoList); |
| | | } |
| | | |
| | | @Override |
| | | public R agingAnalysisByArea(AnalysisCommonDTO commonDTO) { |
| | | R<List<SysDictItem>> r = remoteDictService.getDictByType("company_area"); |
| | | List<SysDictItem> items = r.getData(); |
| | | if (ArrayUtil.isEmpty(items.toArray())){ |
| | | return R.failed("地区字典分类获取异常"); |
| | | } |
| | | // List<AgingCompanyVo> companys = contractPaymentScheduleMapper.selectAgingCompany(DataScope.of("comp_id")); |
| | | // if (ArrayUtil.isEmpty(companys.toArray())){ |
| | | // return R.failed("暂无账龄"); |
| | | // } |
| | | List<AgingAnalysisVo> result = new ArrayList<>(); |
| | | AgingQueryDTO queryDTO = new AgingQueryDTO(); |
| | | List<AgingVo> agingVoList = contractPaymentScheduleMapper.selectAgingTotal(null); |
| | | items.stream().forEach(item->{ |
| | | AgingAnalysisVo agingAnalysisVo = new AgingAnalysisVo(); |
| | | agingAnalysisVo.setCompanyName(item.getLabel()); |
| | | queryDTO.setAreaId(item.getItemValue()); |
| | | List<AgingVo> companyAgingVo = contractPaymentScheduleMapper.selectAgingTotal(queryDTO); |
| | | //补全数据 |
| | | if (ArrayUtil.isEmpty(companyAgingVo.toArray())){ |
| | | companyAgingVo = new ArrayList<>(); |
| | | AgingVo agingVo1 = new AgingVo("0-30天",new BigDecimal("0"),null); |
| | | AgingVo agingVo2 = new AgingVo("31-60天",new BigDecimal("0"),null); |
| | | AgingVo agingVo3 = new AgingVo("61-90天",new BigDecimal("0"),null); |
| | | AgingVo agingVo4 = new AgingVo("91-180天",new BigDecimal("0"),null); |
| | | AgingVo agingVo5 = new AgingVo("181-365天",new BigDecimal("0"),null); |
| | | AgingVo agingVo6 = new AgingVo("1年以上",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo1); |
| | | companyAgingVo.add(agingVo2); |
| | | companyAgingVo.add(agingVo3); |
| | | companyAgingVo.add(agingVo4); |
| | | companyAgingVo.add(agingVo5); |
| | | companyAgingVo.add(agingVo6); |
| | | }else { |
| | | List<String> overdueRanges = companyAgingVo.stream().map(AgingVo::getOverdueRange).collect(Collectors.toList()); |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"0-30天")){ |
| | | AgingVo agingVo1 = new AgingVo("0-30天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo1); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"31-60天")){ |
| | | AgingVo agingVo2 = new AgingVo("31-60天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo2); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"61-90天")){ |
| | | AgingVo agingVo3 = new AgingVo("61-90天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo3); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"91-180天")){ |
| | | AgingVo agingVo4 = new AgingVo("91-180天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo4); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"181-365天")){ |
| | | AgingVo agingVo5 = new AgingVo("181-365天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo5); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"1年以上")){ |
| | | AgingVo agingVo6 = new AgingVo("1年以上",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo6); |
| | | } |
| | | } |
| | | agingAnalysisVo.setAmount(companyAgingVo.stream().map(AgingVo::getTotalAmount).collect(Collectors.toList())); |
| | | List<AgingVo> finalCompanyAgingVo = companyAgingVo; |
| | | agingAnalysisVo.setPercent(IntStream.range(0, agingVoList.size()) |
| | | .mapToObj(i -> { |
| | | BigDecimal part = finalCompanyAgingVo.get(i).getTotalAmount(); |
| | | BigDecimal total = agingVoList.get(i).getTotalAmount(); |
| | | if (total == null || total.compareTo(BigDecimal.ZERO) == 0) { |
| | | return null; |
| | | } |
| | | return part.divide(total, 4, RoundingMode.HALF_UP) |
| | | .multiply(new BigDecimal("100")) |
| | | .setScale(2, RoundingMode.HALF_UP); |
| | | }) |
| | | .collect(Collectors.toList())); |
| | | result.add(agingAnalysisVo); |
| | | }); |
| | | //合计 |
| | | AgingAnalysisVo agingAnalysisVo = new AgingAnalysisVo(); |
| | | agingAnalysisVo.setCompanyName("合计"); |
| | | agingAnalysisVo.setAmount(agingVoList.stream().map(AgingVo::getTotalAmount).collect(Collectors.toList())); |
| | | List<BigDecimal> percent = IntStream.range(0, agingAnalysisVo.getAmount().size()) |
| | | .mapToObj(i -> { |
| | | |
| | | if (agingAnalysisVo.getAmount().get(i) == null || agingAnalysisVo.getAmount().get(i).compareTo(BigDecimal.ZERO) == 0) { |
| | | return null; |
| | | }else { |
| | | return new BigDecimal("100"); |
| | | } |
| | | }) |
| | | .collect(Collectors.toList()); |
| | | agingAnalysisVo.setPercent(percent); |
| | | result.add(agingAnalysisVo); |
| | | return R.ok(result); |
| | | } |
| | | |
| | | @Override |
| | | public R agingAnalysisByIndustry(AnalysisCommonDTO commonDTO) { |
| | | R<List<SysDictItem>> r = remoteDictService.getDictByType("industry_sector"); |
| | | List<SysDictItem> items = r.getData(); |
| | | if (ArrayUtil.isEmpty(items.toArray())){ |
| | | return R.failed("地区字典分类获取异常"); |
| | | } |
| | | List<AgingAnalysisVo> result = new ArrayList<>(); |
| | | AgingQueryDTO queryDTO = new AgingQueryDTO(); |
| | | List<AgingVo> agingVoList = contractPaymentScheduleMapper.selectAgingTotal(null); |
| | | items.stream().forEach(item->{ |
| | | AgingAnalysisVo agingAnalysisVo = new AgingAnalysisVo(); |
| | | agingAnalysisVo.setCompanyName(item.getLabel()); |
| | | queryDTO.setIndustryId(item.getItemValue()); |
| | | List<AgingVo> companyAgingVo = contractPaymentScheduleMapper.selectAgingTotal(queryDTO); |
| | | //补全数据 |
| | | if (ArrayUtil.isEmpty(companyAgingVo.toArray())){ |
| | | companyAgingVo = new ArrayList<>(); |
| | | AgingVo agingVo1 = new AgingVo("0-30天",new BigDecimal("0"),null); |
| | | AgingVo agingVo2 = new AgingVo("31-60天",new BigDecimal("0"),null); |
| | | AgingVo agingVo3 = new AgingVo("61-90天",new BigDecimal("0"),null); |
| | | AgingVo agingVo4 = new AgingVo("91-180天",new BigDecimal("0"),null); |
| | | AgingVo agingVo5 = new AgingVo("181-365天",new BigDecimal("0"),null); |
| | | AgingVo agingVo6 = new AgingVo("1年以上",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo1); |
| | | companyAgingVo.add(agingVo2); |
| | | companyAgingVo.add(agingVo3); |
| | | companyAgingVo.add(agingVo4); |
| | | companyAgingVo.add(agingVo5); |
| | | companyAgingVo.add(agingVo6); |
| | | }else { |
| | | List<String> overdueRanges = companyAgingVo.stream().map(AgingVo::getOverdueRange).collect(Collectors.toList()); |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"0-30天")){ |
| | | AgingVo agingVo1 = new AgingVo("0-30天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo1); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"31-60天")){ |
| | | AgingVo agingVo2 = new AgingVo("31-60天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo2); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"61-90天")){ |
| | | AgingVo agingVo3 = new AgingVo("61-90天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo3); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"91-180天")){ |
| | | AgingVo agingVo4 = new AgingVo("91-180天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo4); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"181-365天")){ |
| | | AgingVo agingVo5 = new AgingVo("181-365天",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo5); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(),"1年以上")){ |
| | | AgingVo agingVo6 = new AgingVo("1年以上",new BigDecimal("0"),null); |
| | | companyAgingVo.add(agingVo6); |
| | | } |
| | | } |
| | | agingAnalysisVo.setAmount(companyAgingVo.stream().map(AgingVo::getTotalAmount).collect(Collectors.toList())); |
| | | List<AgingVo> finalCompanyAgingVo = companyAgingVo; |
| | | agingAnalysisVo.setPercent(IntStream.range(0, agingVoList.size()) |
| | | .mapToObj(i -> { |
| | | BigDecimal part = finalCompanyAgingVo.get(i).getTotalAmount(); |
| | | BigDecimal total = agingVoList.get(i).getTotalAmount(); |
| | | if (total == null || total.compareTo(BigDecimal.ZERO) == 0) { |
| | | return null; |
| | | } |
| | | return part.divide(total, 4, RoundingMode.HALF_UP) |
| | | .multiply(new BigDecimal("100")) |
| | | .setScale(2, RoundingMode.HALF_UP); |
| | | }) |
| | | .collect(Collectors.toList())); |
| | | result.add(agingAnalysisVo); |
| | | }); |
| | | //合计 |
| | | AgingAnalysisVo agingAnalysisVo = new AgingAnalysisVo(); |
| | | agingAnalysisVo.setCompanyName("合计"); |
| | | agingAnalysisVo.setAmount(agingVoList.stream().map(AgingVo::getTotalAmount).collect(Collectors.toList())); |
| | | List<BigDecimal> percent = IntStream.range(0, agingAnalysisVo.getAmount().size()) |
| | | .mapToObj(i -> { |
| | | |
| | | if (agingAnalysisVo.getAmount().get(i) == null || agingAnalysisVo.getAmount().get(i).compareTo(BigDecimal.ZERO) == 0) { |
| | | return null; |
| | | }else { |
| | | return new BigDecimal("100"); |
| | | } |
| | | }) |
| | | .collect(Collectors.toList()); |
| | | agingAnalysisVo.setPercent(percent); |
| | | result.add(agingAnalysisVo); |
| | | return R.ok(result); |
| | | } |
| | | |
| | | @Override |
| | | public R agingAnalysis(AnalysisCommonDTO commonDTO) { |
| | | if (commonDTO.getAgingType().equals("2")) { |
| | | AgingQueryDTO queryDTO = new AgingQueryDTO(); |
| | | List<AgingCompanyVo> companys = contractPaymentScheduleMapper.selectAgingCompanyShip(DataScope.of("comp_id")); |
| | | |
| | | if (ArrayUtil.isEmpty(companys.toArray())) { |
| | | return R.failed("暂无账龄"); |
| | | } |
| | | //合计数据 |
| | | List<AgingVo> agingVoList = contractPaymentScheduleMapper.selectAgingTotalShip(queryDTO); |
| | | agingVoList = completeData(agingVoList); |
| | | List<AgingVo> finalAgingVoList = agingVoList; |
| | | List<AgingAnalysisVo> result = new ArrayList<>(); |
| | | |
| | | companys.stream().forEach(company -> { |
| | | BusinessCustomer businessCustomer = businessCustomerMapper.selectById(company.getCompanyId()); |
| | | AgingAnalysisVo agingAnalysisVo = new AgingAnalysisVo(); |
| | | agingAnalysisVo.setCompanyName(businessCustomer.getCompanyName()); |
| | | queryDTO.setCompanyId(company.getCompanyId()); |
| | | List<AgingVo> companyAgingVo = contractPaymentScheduleMapper.selectAgingTotalShip(queryDTO); |
| | | //补全数据 |
| | | companyAgingVo = completeData(companyAgingVo); |
| | | |
| | | agingAnalysisVo.setAmount(companyAgingVo.stream().map(AgingVo::getTotalAmount).collect(Collectors.toList())); |
| | | List<AgingVo> finalCompanyAgingVo = companyAgingVo; |
| | | |
| | | agingAnalysisVo.setPercent(IntStream.range(0, finalAgingVoList.size()) |
| | | .mapToObj(i -> { |
| | | BigDecimal part = finalCompanyAgingVo.get(i).getTotalAmount(); |
| | | BigDecimal total = finalAgingVoList.get(i).getTotalAmount(); |
| | | if (total == null || total.compareTo(BigDecimal.ZERO) == 0) { |
| | | return null; |
| | | } |
| | | return part.divide(total, 4, RoundingMode.HALF_UP) |
| | | .multiply(new BigDecimal("100")) |
| | | .setScale(2, RoundingMode.HALF_UP); |
| | | }) |
| | | .collect(Collectors.toList())); |
| | | result.add(agingAnalysisVo); |
| | | }); |
| | | //合计 |
| | | AgingAnalysisVo agingAnalysisVo = new AgingAnalysisVo(); |
| | | agingAnalysisVo.setCompanyName("合计"); |
| | | agingAnalysisVo.setAmount(agingVoList.stream().map(AgingVo::getTotalAmount).collect(Collectors.toList())); |
| | | List<BigDecimal> percent = IntStream.range(0, agingAnalysisVo.getAmount().size()) |
| | | .mapToObj(i -> { |
| | | |
| | | if (agingAnalysisVo.getAmount().get(i) == null || agingAnalysisVo.getAmount().get(i).compareTo(BigDecimal.ZERO) == 0) { |
| | | return null; |
| | | } else { |
| | | return new BigDecimal("100"); |
| | | } |
| | | }) |
| | | .collect(Collectors.toList()); |
| | | agingAnalysisVo.setPercent(percent); |
| | | result.add(agingAnalysisVo); |
| | | return R.ok(result); |
| | | } |
| | | if (commonDTO.getAgingType().equals("3")) { |
| | | AgingQueryDTO queryDTO = new AgingQueryDTO(); |
| | | List<AgingCompanyVo> companys = contractPaymentScheduleMapper.selectAgingCompanyInvoice(DataScope.of("comp_id")); |
| | | if (ArrayUtil.isEmpty(companys.toArray())) { |
| | | return R.failed("暂无账龄"); |
| | | } |
| | | //合计数据 |
| | | List<AgingVo> agingVoList = contractPaymentScheduleMapper.selectAgingTotalInvoice(queryDTO); |
| | | agingVoList = completeData(agingVoList); |
| | | List<AgingVo> finalAgingVoList = agingVoList; |
| | | List<AgingAnalysisVo> result = new ArrayList<>(); |
| | | |
| | | companys.stream().forEach(company -> { |
| | | BusinessCustomer businessCustomer = businessCustomerMapper.selectById(company.getCompanyId()); |
| | | AgingAnalysisVo agingAnalysisVo = new AgingAnalysisVo(); |
| | | agingAnalysisVo.setCompanyName(businessCustomer.getCompanyName()); |
| | | queryDTO.setCompanyId(company.getCompanyId()); |
| | | List<AgingVo> companyAgingVo = contractPaymentScheduleMapper.selectAgingTotalInvoice(queryDTO); |
| | | //补全数据 |
| | | companyAgingVo = completeData(companyAgingVo); |
| | | |
| | | agingAnalysisVo.setAmount(companyAgingVo.stream().map(AgingVo::getTotalAmount).collect(Collectors.toList())); |
| | | List<AgingVo> finalCompanyAgingVo = companyAgingVo; |
| | | |
| | | agingAnalysisVo.setPercent(IntStream.range(0, finalAgingVoList.size()) |
| | | .mapToObj(i -> { |
| | | BigDecimal part = finalCompanyAgingVo.get(i).getTotalAmount(); |
| | | BigDecimal total = finalAgingVoList.get(i).getTotalAmount(); |
| | | if (total == null || total.compareTo(BigDecimal.ZERO) == 0) { |
| | | return null; |
| | | } |
| | | return part.divide(total, 4, RoundingMode.HALF_UP) |
| | | .multiply(new BigDecimal("100")) |
| | | .setScale(2, RoundingMode.HALF_UP); |
| | | }) |
| | | .collect(Collectors.toList())); |
| | | result.add(agingAnalysisVo); |
| | | }); |
| | | //合计 |
| | | AgingAnalysisVo agingAnalysisVo = new AgingAnalysisVo(); |
| | | agingAnalysisVo.setCompanyName("合计"); |
| | | agingAnalysisVo.setAmount(agingVoList.stream().map(AgingVo::getTotalAmount).collect(Collectors.toList())); |
| | | List<BigDecimal> percent = IntStream.range(0, agingAnalysisVo.getAmount().size()) |
| | | .mapToObj(i -> { |
| | | |
| | | if (agingAnalysisVo.getAmount().get(i) == null || agingAnalysisVo.getAmount().get(i).compareTo(BigDecimal.ZERO) == 0) { |
| | | return null; |
| | | } else { |
| | | return new BigDecimal("100"); |
| | | } |
| | | }) |
| | | .collect(Collectors.toList()); |
| | | agingAnalysisVo.setPercent(percent); |
| | | result.add(agingAnalysisVo); |
| | | return R.ok(result); |
| | | } |
| | | return R.ok(); |
| | | } |
| | | |
| | | private List<AgingVo> completeData(List<AgingVo> companyAgingVo) { |
| | | if (ArrayUtil.isEmpty(companyAgingVo.toArray())) { |
| | | companyAgingVo = new ArrayList<>(); |
| | | AgingVo agingVo1 = new AgingVo("0-30天", new BigDecimal("0"), null); |
| | | AgingVo agingVo2 = new AgingVo("31-60天", new BigDecimal("0"), null); |
| | | AgingVo agingVo3 = new AgingVo("61-90天", new BigDecimal("0"), null); |
| | | AgingVo agingVo4 = new AgingVo("91-180天", new BigDecimal("0"), null); |
| | | AgingVo agingVo5 = new AgingVo("181-365天", new BigDecimal("0"), null); |
| | | AgingVo agingVo6 = new AgingVo("1年以上", new BigDecimal("0"), null); |
| | | companyAgingVo.add(agingVo1); |
| | | companyAgingVo.add(agingVo2); |
| | | companyAgingVo.add(agingVo3); |
| | | companyAgingVo.add(agingVo4); |
| | | companyAgingVo.add(agingVo5); |
| | | companyAgingVo.add(agingVo6); |
| | | } else { |
| | | List<String> overdueRanges = companyAgingVo.stream().map(AgingVo::getOverdueRange).collect(Collectors.toList()); |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(), "0-30天")) { |
| | | AgingVo agingVo1 = new AgingVo("0-30天", new BigDecimal("0"), null); |
| | | companyAgingVo.add(agingVo1); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(), "31-60天")) { |
| | | AgingVo agingVo2 = new AgingVo("31-60天", new BigDecimal("0"), null); |
| | | companyAgingVo.add(agingVo2); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(), "61-90天")) { |
| | | AgingVo agingVo3 = new AgingVo("61-90天", new BigDecimal("0"), null); |
| | | companyAgingVo.add(agingVo3); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(), "91-180天")) { |
| | | AgingVo agingVo4 = new AgingVo("91-180天", new BigDecimal("0"), null); |
| | | companyAgingVo.add(agingVo4); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(), "181-365天")) { |
| | | AgingVo agingVo5 = new AgingVo("181-365天", new BigDecimal("0"), null); |
| | | companyAgingVo.add(agingVo5); |
| | | } |
| | | if (!ArrayUtil.contains(overdueRanges.toArray(), "1年以上")) { |
| | | AgingVo agingVo6 = new AgingVo("1年以上", new BigDecimal("0"), null); |
| | | companyAgingVo.add(agingVo6); |
| | | } |
| | | } |
| | | return companyAgingVo; |
| | | } |
| | | } |