diff --git a/mallinkService/src/main/java/com/iformall/service/impl/WxPropertyContractServiceImpl.java b/mallinkService/src/main/java/com/iformall/service/impl/WxPropertyContractServiceImpl.java index ab0b5c6b3..099d0a612 100644 --- a/mallinkService/src/main/java/com/iformall/service/impl/WxPropertyContractServiceImpl.java +++ b/mallinkService/src/main/java/com/iformall/service/impl/WxPropertyContractServiceImpl.java @@ -557,16 +557,17 @@ public class WxPropertyContractServiceImpl implements WxPropertyContractService int index = 0; for (BillTimeVo billTimeVo : billTimeVoList){ if(yearList.size() > 1) { - if (sd.format(billTimeVo.getStartDate()).equals(sd.format(endDate)) || billTimeVo.getStartDate().after(endDate)) { + if (endDate!=null && (sd.format(billTimeVo.getStartDate()).equals(sd.format(endDate)) || billTimeVo.getStartDate().after(endDate))) { logger.info("=====billTimeVo.getStartDate():"+sd.format(billTimeVo.getStartDate())+" endDate:"+sd.format(endDate)); index++; if(index >= yearList.size()-1){ - endDate = wxPropertyContract.getRentalEndDate(); + //endDate = wxPropertyContract.getRentalEndDate(); + endDate = null; }else { endDate = yearList.get(index); + logger.info("==========cross:"+sd.format(endDate)); } - logger.info("==========cross:"+sd.format(endDate)); } } diff --git a/mallinkService/src/main/java/com/iformall/service/impl/WxRentContractServiceImpl.java b/mallinkService/src/main/java/com/iformall/service/impl/WxRentContractServiceImpl.java index cd58dc1c2..9f523149f 100644 --- a/mallinkService/src/main/java/com/iformall/service/impl/WxRentContractServiceImpl.java +++ b/mallinkService/src/main/java/com/iformall/service/impl/WxRentContractServiceImpl.java @@ -875,16 +875,18 @@ public class WxRentContractServiceImpl implements WxRentContractService { int index = 0; for (BillTimeVo billTimeVo : billTimeVoList){ if(yearList.size() > 1) { - if (sd.format(billTimeVo.getStartDate()).equals(sd.format(endDate)) || billTimeVo.getStartDate().after(endDate)) { + if (endDate!=null && (sd.format(billTimeVo.getStartDate()).equals(sd.format(endDate)) || billTimeVo.getStartDate().after(endDate))) { logger.info("=====billTimeVo.getStartDate():"+sd.format(billTimeVo.getStartDate())+" endDate:"+sd.format(endDate)); index++; if(index >= yearList.size()-1){ - endDate = wxRentContract.getRentalEndDate(); + //endDate = wxRentContract.getRentalEndDate(); + endDate = null; }else { endDate = yearList.get(index); + logger.info("==========cross:"+sd.format(endDate)); } - logger.info("==========cross:"+sd.format(endDate)); + } }